From fca0b45242b6f1c9e64c875d56debca7d0550805 Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Sat, 11 Mar 2023 00:03:40 +0000 Subject: [PATCH 1/2] feat: Add VULNERABILITY_ASSESSMENT Note type to grafeas v1 API, adds Vex_Assessment derived from the Note to resources' occurrences, VEX notes now be written to add CVE assessments PiperOrigin-RevId: 515727862 Source-Link: https://github.com/googleapis/googleapis/commit/a4e62056b0a8b2464e5b0b8f593b798d99c7817e Source-Link: https://github.com/googleapis/googleapis-gen/commit/3bc42dca2900815c165cf7d3419ff70df05dfb90 Copy-Tag: eyJwIjoiR3JhZmVhcy8uT3dsQm90LnlhbWwiLCJoIjoiM2JjNDJkY2EyOTAwODE1YzE2NWNmN2QzNDE5ZmY3MGRmMDVkZmI5MCJ9 --- .../GPBMetadata/Grafeas/V1/Attestation.php | 40 + .../src/GPBMetadata/Grafeas/V1/Build.php | 39 + .../src/GPBMetadata/Grafeas/V1/Common.php | Bin 0 -> 1243 bytes .../src/GPBMetadata/Grafeas/V1/Compliance.php | Bin 0 -> 1315 bytes .../proto/src/GPBMetadata/Grafeas/V1/Cvss.php | Bin 0 -> 3353 bytes .../src/GPBMetadata/Grafeas/V1/Deployment.php | Bin 0 -> 1084 bytes .../src/GPBMetadata/Grafeas/V1/Discovery.php | Bin 0 -> 1786 bytes .../Grafeas/V1/DsseAttestation.php | Bin 0 -> 1079 bytes .../src/GPBMetadata/Grafeas/V1/Grafeas.php | Bin 0 -> 8188 bytes .../src/GPBMetadata/Grafeas/V1/Image.php | 44 + .../Grafeas/V1/IntotoProvenance.php | 54 + .../Grafeas/V1/IntotoStatement.php | Bin 0 -> 1374 bytes .../src/GPBMetadata/Grafeas/V1/Package.php | Bin 0 -> 1945 bytes .../src/GPBMetadata/Grafeas/V1/Provenance.php | Bin 0 -> 2688 bytes .../src/GPBMetadata/Grafeas/V1/Severity.php | Bin 0 -> 744 bytes .../GPBMetadata/Grafeas/V1/SlsaProvenance.php | 61 + .../Grafeas/V1/SlsaProvenanceZeroTwo.php | 71 ++ .../src/GPBMetadata/Grafeas/V1/Upgrade.php | 60 + .../proto/src/GPBMetadata/Grafeas/V1/Vex.php | Bin 0 -> 2395 bytes .../GPBMetadata/Grafeas/V1/Vulnerability.php | 106 ++ .../v1/proto/src/Grafeas/V1/AliasContext.php | 101 ++ .../src/Grafeas/V1/AliasContext/Kind.php | 72 ++ .../src/Grafeas/V1/AliasContext_Kind.php | 16 + .../v1/proto/src/Grafeas/V1/Architecture.php | 61 + .../v1/proto/src/Grafeas/V1/Artifact.php | 159 +++ .../proto/src/Grafeas/V1/AttestationNote.php | 84 ++ .../src/Grafeas/V1/AttestationNote/Hint.php | 80 ++ .../src/Grafeas/V1/AttestationNote_Hint.php | 16 + .../src/Grafeas/V1/AttestationOccurrence.php | 190 +++ .../Grafeas/V1/BatchCreateNotesRequest.php | 105 ++ .../Grafeas/V1/BatchCreateNotesResponse.php | 67 ++ .../V1/BatchCreateOccurrencesRequest.php | 105 ++ .../V1/BatchCreateOccurrencesResponse.php | 67 ++ .../v1/proto/src/Grafeas/V1/BuildNote.php | 68 ++ .../proto/src/Grafeas/V1/BuildOccurrence.php | 251 ++++ .../proto/src/Grafeas/V1/BuildProvenance.php | 528 +++++++++ .../v1/proto/src/Grafeas/V1/BuilderConfig.php | 58 + .../Grafeas/v1/proto/src/Grafeas/V1/CVSS.php | 382 ++++++ .../src/Grafeas/V1/CVSS/AttackComplexity.php | 56 + .../src/Grafeas/V1/CVSS/AttackVector.php | 66 ++ .../src/Grafeas/V1/CVSS/Authentication.php | 61 + .../v1/proto/src/Grafeas/V1/CVSS/Impact.php | 61 + .../Grafeas/V1/CVSS/PrivilegesRequired.php | 61 + .../v1/proto/src/Grafeas/V1/CVSS/Scope.php | 56 + .../src/Grafeas/V1/CVSS/UserInteraction.php | 56 + .../v1/proto/src/Grafeas/V1/CVSSVersion.php | 55 + .../src/Grafeas/V1/CVSS_AttackComplexity.php | 16 + .../src/Grafeas/V1/CVSS_AttackVector.php | 16 + .../src/Grafeas/V1/CVSS_Authentication.php | 16 + .../v1/proto/src/Grafeas/V1/CVSS_Impact.php | 16 + .../Grafeas/V1/CVSS_PrivilegesRequired.php | 16 + .../v1/proto/src/Grafeas/V1/CVSS_Scope.php | 16 + .../src/Grafeas/V1/CVSS_UserInteraction.php | 16 + .../v1/proto/src/Grafeas/V1/CVSSv3.php | 353 ++++++ .../Grafeas/V1/CVSSv3/AttackComplexity.php | 56 + .../src/Grafeas/V1/CVSSv3/AttackVector.php | 66 ++ .../v1/proto/src/Grafeas/V1/CVSSv3/Impact.php | 61 + .../Grafeas/V1/CVSSv3/PrivilegesRequired.php | 61 + .../v1/proto/src/Grafeas/V1/CVSSv3/Scope.php | 56 + .../src/Grafeas/V1/CVSSv3/UserInteraction.php | 56 + .../Grafeas/V1/CVSSv3_AttackComplexity.php | 16 + .../src/Grafeas/V1/CVSSv3_AttackVector.php | 16 + .../v1/proto/src/Grafeas/V1/CVSSv3_Impact.php | 16 + .../Grafeas/V1/CVSSv3_PrivilegesRequired.php | 16 + .../v1/proto/src/Grafeas/V1/CVSSv3_Scope.php | 16 + .../src/Grafeas/V1/CVSSv3_UserInteraction.php | 16 + .../src/Grafeas/V1/CloudRepoSourceContext.php | 153 +++ .../v1/proto/src/Grafeas/V1/Command.php | 249 ++++ .../v1/proto/src/Grafeas/V1/Completeness.php | 148 +++ .../proto/src/Grafeas/V1/ComplianceNote.php | 272 +++++ .../V1/ComplianceNote/CisBenchmark.php | 90 ++ .../V1/ComplianceNote_CisBenchmark.php | 16 + .../src/Grafeas/V1/ComplianceOccurrence.php | 88 ++ .../src/Grafeas/V1/ComplianceVersion.php | 148 +++ .../src/Grafeas/V1/CreateNoteRequest.php | 149 +++ .../Grafeas/V1/CreateOccurrenceRequest.php | 115 ++ .../src/Grafeas/V1/DSSEAttestationNote.php | 75 ++ .../V1/DSSEAttestationNote/DSSEHint.php | 80 ++ .../V1/DSSEAttestationNote_DSSEHint.php | 16 + .../Grafeas/V1/DSSEAttestationOccurrence.php | 119 ++ .../src/Grafeas/V1/DeleteNoteRequest.php | 71 ++ .../Grafeas/V1/DeleteOccurrenceRequest.php | 71 ++ .../proto/src/Grafeas/V1/DeploymentNote.php | 67 ++ .../src/Grafeas/V1/DeploymentOccurrence.php | 295 +++++ .../V1/DeploymentOccurrence/Platform.php | 71 ++ .../V1/DeploymentOccurrence_Platform.php | 16 + .../v1/proto/src/Grafeas/V1/Digest.php | 101 ++ .../v1/proto/src/Grafeas/V1/DiscoveryNote.php | 73 ++ .../src/Grafeas/V1/DiscoveryOccurrence.php | 350 ++++++ .../DiscoveryOccurrence/AnalysisCompleted.php | 64 + .../V1/DiscoveryOccurrence/AnalysisStatus.php | 94 ++ .../ContinuousAnalysis.php | 64 + .../DiscoveryOccurrence_AnalysisCompleted.php | 16 + .../V1/DiscoveryOccurrence_AnalysisStatus.php | 16 + ...DiscoveryOccurrence_ContinuousAnalysis.php | 16 + .../v1/proto/src/Grafeas/V1/Distribution.php | 256 ++++ .../v1/proto/src/Grafeas/V1/Envelope.php | 116 ++ .../src/Grafeas/V1/EnvelopeSignature.php | 85 ++ .../v1/proto/src/Grafeas/V1/FileHashes.php | 68 ++ .../v1/proto/src/Grafeas/V1/FileLocation.php | 71 ++ .../v1/proto/src/Grafeas/V1/Fingerprint.php | 151 +++ .../src/Grafeas/V1/GerritSourceContext.php | 184 +++ .../proto/src/Grafeas/V1/GetNoteRequest.php | 71 ++ .../Grafeas/V1/GetOccurrenceNoteRequest.php | 71 ++ .../src/Grafeas/V1/GetOccurrenceRequest.php | 71 ++ .../proto/src/Grafeas/V1/GitSourceContext.php | 102 ++ .../src/Grafeas/V1/GrafeasGrpcClient.php | 263 +++++ .../Grafeas/v1/proto/src/Grafeas/V1/Hash.php | 101 ++ .../v1/proto/src/Grafeas/V1/ImageNote.php | 119 ++ .../proto/src/Grafeas/V1/ImageOccurrence.php | 197 ++++ .../proto/src/Grafeas/V1/InTotoProvenance.php | 214 ++++ .../proto/src/Grafeas/V1/InTotoStatement.php | 224 ++++ .../Grafeas/v1/proto/src/Grafeas/V1/Jwt.php | 73 ++ .../Grafeas/v1/proto/src/Grafeas/V1/Layer.php | 105 ++ .../v1/proto/src/Grafeas/V1/License.php | 117 ++ .../Grafeas/V1/ListNoteOccurrencesRequest.php | 173 +++ .../V1/ListNoteOccurrencesResponse.php | 101 ++ .../proto/src/Grafeas/V1/ListNotesRequest.php | 177 +++ .../src/Grafeas/V1/ListNotesResponse.php | 109 ++ .../src/Grafeas/V1/ListOccurrencesRequest.php | 177 +++ .../Grafeas/V1/ListOccurrencesResponse.php | 109 ++ .../v1/proto/src/Grafeas/V1/Location.php | 154 +++ .../v1/proto/src/Grafeas/V1/Metadata.php | 249 ++++ .../proto/src/Grafeas/V1/NonCompliantFile.php | 135 +++ .../Grafeas/v1/proto/src/Grafeas/V1/Note.php | 757 ++++++++++++ .../v1/proto/src/Grafeas/V1/NoteKind.php | 124 ++ .../v1/proto/src/Grafeas/V1/Occurrence.php | 701 +++++++++++ .../v1/proto/src/Grafeas/V1/PackageNote.php | 451 +++++++ .../src/Grafeas/V1/PackageOccurrence.php | 311 +++++ .../v1/proto/src/Grafeas/V1/ProjectRepoId.php | 102 ++ .../v1/proto/src/Grafeas/V1/Recipe.php | 273 +++++ .../v1/proto/src/Grafeas/V1/RelatedUrl.php | 101 ++ .../v1/proto/src/Grafeas/V1/RepoId.php | 108 ++ .../v1/proto/src/Grafeas/V1/Severity.php | 82 ++ .../v1/proto/src/Grafeas/V1/Signature.php | 192 +++ .../proto/src/Grafeas/V1/SlsaProvenance.php | 214 ++++ .../Grafeas/V1/SlsaProvenance/Material.php | 88 ++ .../Grafeas/V1/SlsaProvenance/SlsaBuilder.php | 61 + .../V1/SlsaProvenance/SlsaCompleteness.php | 151 +++ .../V1/SlsaProvenance/SlsaMetadata.php | 252 ++++ .../Grafeas/V1/SlsaProvenance/SlsaRecipe.php | 296 +++++ .../src/Grafeas/V1/SlsaProvenanceZeroTwo.php | 235 ++++ .../V1/SlsaProvenanceZeroTwo/SlsaBuilder.php | 64 + .../SlsaCompleteness.php | 118 ++ .../SlsaConfigSource.php | 118 ++ .../SlsaProvenanceZeroTwo/SlsaInvocation.php | 147 +++ .../V1/SlsaProvenanceZeroTwo/SlsaMaterial.php | 91 ++ .../V1/SlsaProvenanceZeroTwo/SlsaMetadata.php | 201 ++++ .../V1/SlsaProvenanceZeroTwo_SlsaBuilder.php | 16 + ...SlsaProvenanceZeroTwo_SlsaCompleteness.php | 16 + ...SlsaProvenanceZeroTwo_SlsaConfigSource.php | 16 + .../SlsaProvenanceZeroTwo_SlsaInvocation.php | 16 + .../V1/SlsaProvenanceZeroTwo_SlsaMaterial.php | 16 + .../V1/SlsaProvenanceZeroTwo_SlsaMetadata.php | 16 + .../Grafeas/V1/SlsaProvenance_Material.php | 16 + .../Grafeas/V1/SlsaProvenance_SlsaBuilder.php | 16 + .../V1/SlsaProvenance_SlsaCompleteness.php | 16 + .../V1/SlsaProvenance_SlsaMetadata.php | 16 + .../Grafeas/V1/SlsaProvenance_SlsaRecipe.php | 16 + .../v1/proto/src/Grafeas/V1/Source.php | 215 ++++ .../v1/proto/src/Grafeas/V1/SourceContext.php | 176 +++ .../v1/proto/src/Grafeas/V1/Subject.php | 104 ++ .../src/Grafeas/V1/UpdateNoteRequest.php | 159 +++ .../Grafeas/V1/UpdateOccurrenceRequest.php | 159 +++ .../src/Grafeas/V1/UpgradeDistribution.php | 187 +++ .../v1/proto/src/Grafeas/V1/UpgradeNote.php | 196 ++++ .../src/Grafeas/V1/UpgradeOccurrence.php | 215 ++++ .../v1/proto/src/Grafeas/V1/Version.php | 269 +++++ .../src/Grafeas/V1/Version/VersionKind.php | 71 ++ .../src/Grafeas/V1/Version_VersionKind.php | 16 + .../V1/VulnerabilityAssessmentNote.php | 306 +++++ .../Assessment.php | 343 ++++++ .../Assessment/Justification.php | 105 ++ .../Justification/JustificationType.php | 94 ++ .../Assessment/Remediation.php | 148 +++ .../Remediation/RemediationType.php | 85 ++ .../Assessment/State.php | 79 ++ .../VulnerabilityAssessmentNote/Product.php | 160 +++ .../VulnerabilityAssessmentNote/Publisher.php | 165 +++ ...VulnerabilityAssessmentNote_Assessment.php | 16 + ...ssessmentNote_Assessment_Justification.php | 16 + ...ssment_Justification_JustificationType.php | 16 + ...yAssessmentNote_Assessment_Remediation.php | 16 + ...Assessment_Remediation_RemediationType.php | 16 + ...abilityAssessmentNote_Assessment_State.php | 16 + .../VulnerabilityAssessmentNote_Product.php | 16 + .../VulnerabilityAssessmentNote_Publisher.php | 16 + .../src/Grafeas/V1/VulnerabilityNote.php | 359 ++++++ .../Grafeas/V1/VulnerabilityNote/Detail.php | 645 +++++++++++ .../V1/VulnerabilityNote/WindowsDetail.php | 186 +++ .../WindowsDetail/KnowledgeBase.php | 106 ++ .../Grafeas/V1/VulnerabilityNote_Detail.php | 16 + .../V1/VulnerabilityNote_WindowsDetail.php | 16 + ...bilityNote_WindowsDetail_KnowledgeBase.php | 16 + .../Grafeas/V1/VulnerabilityOccurrence.php | 550 +++++++++ .../VulnerabilityOccurrence/PackageIssue.php | 429 +++++++ .../VulnerabilityOccurrence/VexAssessment.php | 317 +++++ .../VulnerabilityOccurrence_PackageIssue.php | 16 + .../VulnerabilityOccurrence_VexAssessment.php | 16 + .../v1/proto/src/Grafeas/V1/WindowsUpdate.php | 298 +++++ .../src/Grafeas/V1/WindowsUpdate/Category.php | 104 ++ .../src/Grafeas/V1/WindowsUpdate/Identity.php | 104 ++ .../src/Grafeas/V1/WindowsUpdate_Category.php | 16 + .../src/Grafeas/V1/WindowsUpdate_Identity.php | 16 + .../V1/GrafeasClient/batch_create_notes.php | 70 ++ .../batch_create_occurrences.php | 71 ++ .../samples/V1/GrafeasClient/create_note.php | 72 ++ .../V1/GrafeasClient/create_occurrence.php | 70 ++ .../samples/V1/GrafeasClient/delete_note.php | 65 ++ .../V1/GrafeasClient/delete_occurrence.php | 67 ++ .../v1/samples/V1/GrafeasClient/get_note.php | 67 ++ .../V1/GrafeasClient/get_occurrence.php | 67 ++ .../V1/GrafeasClient/get_occurrence_note.php | 68 ++ .../GrafeasClient/list_note_occurrences.php | 74 ++ .../samples/V1/GrafeasClient/list_notes.php | 72 ++ .../V1/GrafeasClient/list_occurrences.php | 72 ++ .../samples/V1/GrafeasClient/update_note.php | 70 ++ .../V1/GrafeasClient/update_occurrence.php | 70 ++ .../v1/src/V1/Gapic/GrafeasGapicClient.php | 1031 +++++++++++++++++ .../Grafeas/v1/src/V1/GrafeasClient.php | 34 + .../Grafeas/v1/src/V1/gapic_metadata.json | 88 ++ .../V1/resources/grafeas_client_config.json | 115 ++ .../resources/grafeas_descriptor_config.php | 38 + .../resources/grafeas_rest_client_config.php | 172 +++ .../v1/tests/Unit/V1/GrafeasClientTest.php | 990 ++++++++++++++++ 225 files changed, 26867 insertions(+) create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Attestation.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Build.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Common.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Compliance.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Cvss.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Deployment.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Discovery.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/DsseAttestation.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Grafeas.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Image.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoProvenance.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoStatement.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Package.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Provenance.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Severity.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenance.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenanceZeroTwo.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Upgrade.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vex.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vulnerability.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext/Kind.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext_Kind.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Architecture.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Artifact.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote/Hint.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote_Hint.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationOccurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesResponse.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesResponse.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildNote.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildOccurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildProvenance.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuilderConfig.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackComplexity.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackVector.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Authentication.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Impact.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/PrivilegesRequired.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Scope.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/UserInteraction.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSVersion.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_AttackComplexity.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_AttackVector.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_Authentication.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_Impact.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_PrivilegesRequired.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_Scope.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_UserInteraction.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackComplexity.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackVector.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Impact.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/PrivilegesRequired.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Scope.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/UserInteraction.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_AttackComplexity.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_AttackVector.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_Impact.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_PrivilegesRequired.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_Scope.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_UserInteraction.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CloudRepoSourceContext.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Command.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Completeness.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote/CisBenchmark.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote_CisBenchmark.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceOccurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceVersion.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateNoteRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateOccurrenceRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote/DSSEHint.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote_DSSEHint.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationOccurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteNoteRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteOccurrenceRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentNote.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence/Platform.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence_Platform.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Digest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryNote.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisCompleted.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisStatus.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/ContinuousAnalysis.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence_AnalysisCompleted.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence_AnalysisStatus.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence_ContinuousAnalysis.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Distribution.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Envelope.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/EnvelopeSignature.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileHashes.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileLocation.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Fingerprint.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GerritSourceContext.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetNoteRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceNoteRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GitSourceContext.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GrafeasGrpcClient.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Hash.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageNote.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageOccurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoProvenance.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoStatement.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Jwt.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Layer.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/License.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesResponse.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesResponse.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesResponse.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Location.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Metadata.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NonCompliantFile.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Note.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NoteKind.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Occurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageNote.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageOccurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ProjectRepoId.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Recipe.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RelatedUrl.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RepoId.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Severity.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Signature.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/Material.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaBuilder.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaCompleteness.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaMetadata.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaRecipe.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaBuilder.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaCompleteness.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaConfigSource.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaInvocation.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMaterial.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMetadata.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaBuilder.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaCompleteness.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaConfigSource.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaInvocation.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaMaterial.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaMetadata.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance_Material.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance_SlsaBuilder.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance_SlsaCompleteness.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance_SlsaMetadata.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance_SlsaRecipe.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Source.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SourceContext.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Subject.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateNoteRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateOccurrenceRequest.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeDistribution.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeNote.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeOccurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version/VersionKind.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version_VersionKind.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification/JustificationType.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation/RemediationType.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/State.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Product.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Publisher.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment_Justification.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment_Justification_JustificationType.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment_Remediation.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment_Remediation_RemediationType.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment_State.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Product.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Publisher.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/Detail.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail/KnowledgeBase.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote_Detail.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote_WindowsDetail.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote_WindowsDetail_KnowledgeBase.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/PackageIssue.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/VexAssessment.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence_PackageIssue.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence_VexAssessment.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Category.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Identity.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate_Category.php create mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate_Identity.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/batch_create_notes.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/batch_create_occurrences.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_note.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_occurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_note.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_occurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_note.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence_note.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_note_occurrences.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_notes.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_occurrences.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_note.php create mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_occurrence.php create mode 100644 owl-bot-staging/Grafeas/v1/src/V1/Gapic/GrafeasGapicClient.php create mode 100644 owl-bot-staging/Grafeas/v1/src/V1/GrafeasClient.php create mode 100644 owl-bot-staging/Grafeas/v1/src/V1/gapic_metadata.json create mode 100644 owl-bot-staging/Grafeas/v1/src/V1/resources/grafeas_client_config.json create mode 100644 owl-bot-staging/Grafeas/v1/src/V1/resources/grafeas_descriptor_config.php create mode 100644 owl-bot-staging/Grafeas/v1/src/V1/resources/grafeas_rest_client_config.php create mode 100644 owl-bot-staging/Grafeas/v1/tests/Unit/V1/GrafeasClientTest.php diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Attestation.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Attestation.php new file mode 100644 index 00000000000..8db0f36078c --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Attestation.php @@ -0,0 +1,40 @@ +internalAddGeneratedFile( + ' +ˆ +grafeas/v1/attestation.proto +grafeas.v1"f +AttestationNote. +hint ( 2 .grafeas.v1.AttestationNote.Hint# +Hint +human_readable_name ( " +Jwt + compact_jwt ( "} +AttestationOccurrence +serialized_payload ( ) + +signatures ( 2.grafeas.v1.Signature +jwts ( 2.grafeas.v1.JwtBQ + io.grafeas.v1PZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Build.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Build.php new file mode 100644 index 00000000000..6ab3907fa63 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Build.php @@ -0,0 +1,39 @@ +internalAddGeneratedFile( + ' +´ +grafeas/v1/build.proto +grafeas.v1!grafeas/v1/intoto_statement.protografeas/v1/provenance.proto"$ + BuildNote +builder_version ( "Ì +BuildOccurrence/ + +provenance ( 2.grafeas.v1.BuildProvenance +provenance_bytes ( 7 +intoto_provenance ( 2.grafeas.v1.InTotoProvenance5 +intoto_statement ( 2.grafeas.v1.InTotoStatementBQ + io.grafeas.v1PZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Common.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Common.php new file mode 100644 index 0000000000000000000000000000000000000000..2cb169eb609aff4dd5e96630101b9eef5e0d7474 GIT binary patch literal 1243 zcmZ`(e`^~@5Us5EhsJVqITGqZ3mZ2OB_t9~C=|I)IqNRsuq<6H$>1P3R(GTGlJ)L! zyE0XSzf8YXp&zDuKccvp=pXIuzBlvU&d&Y*M|zdQFQktGGpaEr^A*uoNYYGd8A(p& z%f$jS63Oe7am?C;xFa$gO^E0Elc$EN)&N+*S(o~zjXH11mFwH1ue;Jj>WI?$? zL%ok(EJdW56eK5%M1-vuq|BLPpQX~cIwrHelnKXKkQ+57XTH#w3Cd?KswiWrmRVq+ z-EM+qS*IPsbLdRch>Z?}V#ydmzg*!bms|f*Q-L=>vycu;l%N} z?0a+dtu-*GJ%@ib;fHVBxee7p`{wYV1#pf$@9i|>_AbHGu^-M?8cTHZ<-ax98A^?(OvLt&@Wf1w7oPeBq)mSK&L#SDN~)V&-SQV i{=HE*(&k$Q^zHNYQ-4)X(4B$%=CBpWa;|RS7T`Z@m0c$Q literal 0 HcmV?d00001 diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Compliance.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Compliance.php new file mode 100644 index 0000000000000000000000000000000000000000..1927013074764e0c4a1300bbdeb543eee6bdecbb GIT binary patch literal 1315 zcmaJ>T~8B16qS#HTqxKDVns>DN~9#Z4fvu(R0>*ofEFb@m`yg*+1qyFc4jj(OHvJg z#=qmg@RvBd-F_rR`_j$bbI(2Je(c-#Q8$8Tq>cg=H5iaqpO`L^NJ%4^3`r|)w^0!$ zdl3&&xrCfH$VKCdd^|n7dTLX(j1|Kw=_uMpsw+49l>{7eDj2#c4}hRO)DdM!>do3Y z8X8bTz4{=$ z?N~6wr65T{!-^^IkpX9d-HD`icSO9pl${X0W@6Zy_0EJrC1~iKqGpOmMyjTTR;wK} zqc$ax@?KUpq2p~*9%!sqr$inRqhg$_PKZJiD{+|WP6%#CPu|@v^1k8?DsKAK>e$dY zKlStS9naJs2f;|}Cp)V~7t)}Uhn(Ri#NrH@ zDK9zeupDIFvJEfJra>1Ltzex5=Ez)m`C!`}le%NV>jB6qz>-}-3#XQMe#on^hXGIH z#atTv0C{HDpoM~UdsKZdF4*w$fwy}%eWKSr;kq`&f4=8Df`VpL*j3VYGU=A+;-aNl z**b@nNwBjCdAq}H+d@CI0|-;cIp;at*V#N$yQ>EqljVoAsuf^ud=0+oM_9Uq!nFA{ zSY#3UvEo@vx4;=W^aIJ_9tvX{nY7!2hn-DZU5a31Oxa*8R?50X=MAh2Dg2=V<0n3} z6`YLY$)w;5DTWLt*%xOUHYZaV`pRB+I!h~|bOsNmQdVF-qNbY}cnE6&*HK9ON&Oxb zLADpGurNtgyM#QK6Iz-x-(GjpqjWnmq@v?W)v0t)q~DUt;1!Lyu8bG>FnjzpJ6Hd5 d+*(MXuXaaE|6*`~69@axV@;8RySjy2fWPu-lUe`( literal 0 HcmV?d00001 diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Cvss.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Cvss.php new file mode 100644 index 0000000000000000000000000000000000000000..77a230e503ff8fc5b474543f37a7a7640f2968cb GIT binary patch literal 3353 zcmeHK-BQ~|6t2xr%i+(6049ZIG08wWtrr*F_v5!S8^`#~ySHT|=&?dgSY& z?zVMP_jJ|Jet72Jw1Ggl9 zlVpP}!St|Wsz$4fUCq&L&vGOJEtUG%8^}~d^~32sv>)VHDkYLUL7p?f^i3S(ZvO33pY$-r;Pa`{=x-JQtgMo{JyR&7Tg zl2Y`s+jj7;1Kq*h{HHX+qm&5J2we}s%nQg3TjM%pC*84XZK3D6)=+78X;-^ zF48ktRfno>+?-;_TeyQ)c%OlV$RTaRCaWkc_p06GIYq3u8#P(tIpIv;%ehaOO<0S% zYrOJWtiQ@-nES9Eb+P3iSdOnLxh%5*t5IK7Q)Zh$eg7#g56`2zyJ{EZumT%15Ia{lcmdG$GuoxI`OxZ#mX2WJ)2S&J% zNSd)o%P=3>=}t4u5T(O9sZSOD0hsnx||a%rOSp+w&Co_iFPz4Zhk z=$hwuh~7qm7k0_vM9G^-dHNy2o5cDkcbDx@?*7QYQmn_mfctDiIVXxu1UN-kh>pel z7mcbS5EUjW;9m?;vMkgp#1)8t)D^zcA0_vHExBLHFz+jF6FV-ED*vkTf0DtVE+=mt z29_e;C!{IjwxeA3wAF$|-5OJZ(>b3<$8ah0^EZ7umKXb$p_=`o<@68w*rfj>4g!~I r>+Zqr;CmcC{*|4o)Y;A~g&ysVhUKq<8GLMHpE#~lWH6au!!^La2Pne9 literal 0 HcmV?d00001 diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Deployment.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Deployment.php new file mode 100644 index 0000000000000000000000000000000000000000..4c9c49aad310e4ccf57902e664e90149b926943c GIT binary patch literal 1084 zcmah|+fLg+5N#3~U??=Qc!=7UEkz|rt)tMF$|eV|o^KjsKh2)+dU!!P}w%maq6?poOxfw9~XkNFrUcknDIHy9Pu?deP=HnkH zlGRJ3(pcU4UWUy%aOk>;l&I4;41gp?ImRhvp$3;4t40&n@?{w-ZLD6_muq`Z%ph}} zFOQyyS-3V@u%7TmO69+l4XC<;`z)w0Wj!CmGW9&IJgz^?F7EoMrap`|tVAJIzL3-U zvc_%f?V9sA%s*K)?HOU~2v&ZbjXG@F#|NX{@a$xKae8idj|RO#w^MsyEJLOLp<62% zE3ni%?tZG3bw<^ri}TU&q*gin2}1XMpU%2z5Kw=xYTHc_avJqq)E{io@oz)ts`B@Ff+udO`!> z;{^=^OepFP&o8OOQ!KIDPZ93B)+qq-a2TRaj)V_@)GvsxJw{L{u~dIASU6!mlMH+8 zz0!JyX4ng5)-Tp-68ImHR>)8M!?)2qu%tK-ryzUqTOCqwIbOBEeabkH3Eqj!TqsU0dXDG`6#>(rWmGc^2LJt zn=wh_zx$D8Z8oOUqN_dSuSU^_xGOK=&mE}$zp*sP&h%xgel$;-)l4j>M%k2k#iS@N+S7yMx3E_j(&mzC-@qPL=C}=&5&vNRv{pi;#{S8nzS5z` zfxoD;n52+Ol6@0o7b+y6wFfHTk#++6YJtc}NU%SNCtur2fb~3AZVSD*2-*+u z7z=X4mNZ3de-3e8`Nyc#U&EJq-&VCgU2}%KRkBK|)JMk-Xd4Fh9FEL^J+kcaVC+l` z+qn46v7E`+c7|Qk>RH`R^$QJP+b~DgyKc3lJ%%02&fdz$f0tlCSCF;u2)-(4oRKk7 zv>&tW!oy+L?pSs|rE^Tfw&S<5b_ms;Wn0eA-Oj`rn`YN>s+BmUIk+5NbVptFb^uR` zn4V!>D1{HS8XOiMRkrbPIJg?AldXEWS~~v~_84C?&9L=y ynI7SQh0WE4Kg}NhDp&ef#`Sg*`u)pdNqn2G*0oI>dxwz?TR4eKcjX=20sIFWgfim* literal 0 HcmV?d00001 diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/DsseAttestation.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/DsseAttestation.php new file mode 100644 index 0000000000000000000000000000000000000000..ef80894effc944fe157dddad5b1351735c4cb183 GIT binary patch literal 1079 zcmah|(QeZ)6r~$NnO0@T7x0NVNtH&d6M0JPbB@pPJ$d&bnn&ar^iiOq8aS zh=-_bfbI~khZE>^2a{7njb)-3IuI!8BaQ3JM%{~JoKmeZ)>LyT>`aXiK^GWDlp*v- zozJMLM>Tc(Inn*rXcEFg8pqHz0__c-{3KwWD4B(vK_<%JoX1lxxaKtEKaBAf_%w{s zXxzs7iD0P_NC`v1(7J$JGsT`q(gbaR+m|v3(H*7PO>TD}G%7(uw~H}TJknB)4AgM~ z)WwaZE7ryO*i?@DVC5bi=a$J9Xq903bO41qQKFgoP6bxQo4fs<+>dgxkiu~`aW?F` zI3|pVH8vB$1q!{LoL$As_k10^?RiDcPiFj9;Vku8BY$?u>3`>5C2NSiY#f*2<`m;- zn%-4rDX+=dk{ou&<6de0*HUBk4Y@xzjH3!vtb;;Mv-h!5_OdvX=tVkLn3I zoF@w^rV35@W+6_~PG*|>XTK`s=|56K#uBB_G^YBT?4ej`56o5R>v8uI_anlSdvh>7h4`=uIf8*ZD#oa#>=HD&OA*Sv&1OhExQ$R6#vJ wk^Ncqe2Ydru5ZTCT)+O_+3kOA&mLsZ*R^7VFY+puntNw!Gh|+|6G0qH_-3=NqyPCn^AOf~n;1G>8YR{C14(;yV z?j8$6tVA2-9wmoda@s?(e?^pQa?K_3DTkc+6Ov0_eRNmVe83Ef;*0Hi_3C}p`~B)w z*B4(!FCw^TZ_up4#^| z9z4B(s!7<1o3vuLV|SOjNqPTfS^in#ivR@f9!(;*N$t(;+9R5}EjM-Rn__}mv(=^G?lyI-rlHYP$%*|7b|}>TN^a;!-Ksc zYewZ`!%LdsK8=UkK20r2=m)3r!JgY5F}!WJ`Eq2XXA#m_YeY-W>8sH)|GeWf2Hx>} zZx9GLZ~gE~PqI|C)yhffK2q~?P9uy|uEIZVfhCE!hm#3NNooJ)VzJGcrtC&uxycDb z5clGeCfH@H(Abf*ASayFCd3l^Qglv=_z{5QTBZ!$QfPMz#p-*A;V#p;dYS=MPWV_0 z%~fcW(leTLhe1w`7qxLb(GXWsaLyD+@bnS3a)e0XqNdr(U?61|bQ#uq4@5tk_FA&K7A!eKha0^Did<&Ka&7k&1NT#De?t54ioIWwhDG(d73Q1 z@oZxoo!GO+_~<-L@+0!ESU4dplwKo$KZ8_L7#Q{h-V)$IF4{Tqi5=g5I>83atmhZ ztH{HP0h%8HpE{u5kIybZ3v|AV0TzK|G2}FqAU?;Dus-hwy8xmAECcK;`3UnX8O#L` zPwN@sFjw;gzytQ9@hJy=V zftN>`B&=_>7Wg9dt9m+&4X@^N#cGw$-d5LOHcL0cnvIjCK7bBTfKX8sbj#8=mJbJw;Ntd0GU@IxriHyqp}EkViBeKn*z*>Qq_$Q=Xh>`p>}4i zzlG6D@--}GJEP!}m&TB;eIT_p;ap$a|5JMVE7C*FO`9*&uIJ&6vhB63TE{remh@^J zus*+BCHI0fKH&Sm_$2__crip~VEiRLkasx*!@lcxsARmJ?X8U6E;#F8^_m(IP0k^l z*OdEg_9)r7VIDmqCq}2L42ar)1fL8t{{j2G_S-p_+7wL~IfN4iI}+p4Wr!s2E)Ha zFSZqqwV5SUIYao(K~1N6c_{3uI=vTbj8&2nWwZhS!GKXEVd+ z7-&{iepfr#4E%Z{)%DAEe=wvMW&BpO)w*paQW z-{d=lgND|}Z0AilbW1aLj7sdCBsb$Ocd_J%x*OinternalAddGeneratedFile( + ' +× +grafeas/v1/image.proto +grafeas.v1"- +Layer + directive (  + arguments ( "@ + Fingerprint +v1_name (  +v2_blob (  +v2_name ( "O + ImageNote + resource_url ( , + fingerprint ( 2.grafeas.v1.Fingerprint"“ +ImageOccurrence, + fingerprint ( 2.grafeas.v1.Fingerprint +distance (% + +layer_info ( 2.grafeas.v1.Layer +base_resource_url ( BQ + io.grafeas.v1PZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoProvenance.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoProvenance.php new file mode 100644 index 00000000000..5861d7ce8a1 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoProvenance.php @@ -0,0 +1,54 @@ +internalAddGeneratedFile( + ' +Î +"grafeas/v1/intoto_provenance.proto +grafeas.v1google/protobuf/timestamp.proto"œ +Recipe +type (  +defined_in_material ( + entry_point ( \' + arguments ( 2.google.protobuf.Any) + environment ( 2.google.protobuf.Any"I + Completeness + arguments ( + environment ( + materials ("Ú +Metadata +build_invocation_id ( 4 +build_started_on ( 2.google.protobuf.Timestamp5 +build_finished_on ( 2.google.protobuf.Timestamp. + completeness ( 2.grafeas.v1.Completeness + reproducible (" + BuilderConfig + +id ( "¤ +InTotoProvenance1 +builder_config ( 2.grafeas.v1.BuilderConfig" +recipe ( 2.grafeas.v1.Recipe& +metadata ( 2.grafeas.v1.Metadata + materials ( Bh + io.grafeas.v1BInTotoProvenanceProtoPZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoStatement.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoStatement.php new file mode 100644 index 0000000000000000000000000000000000000000..170908323f19bcfbdf0c0728f7e8fbe00f97ba7f GIT binary patch literal 1374 zcmb_b(N5bi6s0W%aXW?-rm3nX%`ha2G*Xpm5(;AzRaxO-13|S16sdC4+u$wOk?jd_H>86cCDk|}{V~y(NJ1&J@I*lR(Qt^8 zc;YH#0ZN;Y_6hlV(j|xODZ9eQ;m-EK;%BrGQ#}ngh$knBX>BxsT@*3o{ap z&Jl8I>^RQU*p%lf^m(A@|G{3M6y0m_`0+`s+aFCcBq1IQ23cmGO)J$im$Bzf_*I6r zfA)|ClM;K>tmRuy8BaaaW|KhDj;n3u2xlsKH%5C;UyHPK{ZA2Aj(OL_nzfy^3iEm# zVzodD^`*0NFaEGLU{OW=@961jk(BC{omG3P$v#iFte5aSlsI6X8G!^>EyX0(4!~4p zb>94|?7Yeoq#CBzb2MkYhm{%e)p7!?<$?Ea)xZv+Is?l*R~Hie+SB;S%^uCQDzKC} zS-*zGJBQC;KAz_^9IF8f1LmW;3+44a>NFI)om3ohEyuNOsN_Da3Y31}ctW-e4{IKd{>m#;F zMS%dgct!%TM^LkO+9n*2F~@^uWIwn*JO;2F90aHr`N5xn#Lo{$4z*CgF&B@08VspR zImHhBL*#jaCfEsx@V#$430;d*&qdOq>sq9IfFew3yYG9Vt`jt9dYRbl8lZJBRpj8vC3Nl z+$`P(EBr*+nLZtyQ{s$I$rR72$7;1@RZEan*9EnMGjBHY+|T?I!4xsl;%Mi{s4PQN%*46=40ar$-GC40garcE(1b_+XfNq; z9UbX9zzmC$#h)-^Lq^r}poPpaHq~Me^5eMw5-KA%OI_Hy@GK!jk@Tarr1gEs-UXJa zJ`lJ78$RY!m0Pa#UmEhU+&dm8f{6_|CNT{eLBp-NDVZ22_%Z-#0)B;wH9iaR><#%R zpBQ;nQ6k}j+E^!eTkL*`;6#Bt4;Q$~>?0K^X11snYs~JdO@S?@oVWoo^!wNs(UD$) z%$VAu#m1hZKu@-|u1-pSrC~Rwv};)*V?<2;XNlGHC$Qzj{S@+&q&`j}E_(e9tP(1P zrBtdVwX0MlwX5kb*R(4&^#y7prvwL5ZfgR%b&nY&RXZKM!oozkWr@7?YGT~ zVoFSAw%zKq+E?vjS}n{EYN7q~1_~>efWS2SXTP;B8)uhS{l*$*7PJqqUkO0@^6KYe z`t%)aQ!i0UFZKItTV1&o+jFpMS3G7{ZQ`nrST#DrJ`JkN+wC}h{X4BS`{pR4OkX}- Y+?&s%+duKKc<@7^ETilE25tcU2e*VT&;S4c literal 0 HcmV?d00001 diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Provenance.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Provenance.php new file mode 100644 index 0000000000000000000000000000000000000000..26eac47b31ced6d96f06119abcebb8a3b04a1c0e GIT binary patch literal 2688 zcma)8ZFAE`5XO#i;&n`nLa7_t>7l?73Q;D80%J;A0i0NN44WB56)% zw`qqz&`+J|@TDL7Gy3bgcPHDj6QKTL>F(LR-DjWO(>ITkqXd>on?+1e$$WBnLgW!6 ziHK$F#UVND_j*haFFsCq$b>`4_8xh$cR+TwI|o!YhV=WR0+G8|b8?3LP@qk4% z@|dIj07Uedr3v*IY42}7XOj9<(r(+BbYHJO1n@$dreuF)3cmxvU(!Dexkpk-CH`IG zsmmiSISu)580{m{qhZR>{4}=Lk37lah$w?S3})pfF+LUcS`uS+k4U#2$3e)tc(9By z*={G2Ohh#7ZnM-AJdv^3M`)`RFgc=0t*qS4j#ch>kF1y&Tdh+;J|a@|S^jiF1e1Lc zJ=Ae42X9AD-3f}OqC4P7q@>45t2It*>_um_`Yq3L*zo;P$WO3*E2BfykvHJqI$Zfc z-7Ls9ox!^OX9*TI`#ki=C9(jD+;0>}VWnc>3l{rl=1CXVihAuj%%O0OY2>Gk88Wj{ zZ7w=vm(G^ivsPi@5Iswm3dwualWC)*(UPG?<*xiAh=w=a03qE}YoqG=Ns zDau--0ot>bPw|!RB}JtaJP4RjR93Z%ZKx@Zd^b*%sME&0W@t5UK2;t^zwa6RP9(*N z^{HXnN6!N$Qgqa)Dfdfv;Nod?6=vSBldQfqI6t6apPACOiVq6*yCRgckeA`guy}5Y zEkgt5W+^Kgj7083wTCKnk7#iu?09axw?b|U}l`TVQR%lQb#hMJdkfboj843*w6Ya~MD zT+bV;MD1lLsefx8O7bLOXK_An{{*wcmO-4FsTmFfWzj$rT2U^j2u#COEZp+BzRxcEbyjVDnWw6)ccx8l!AyX7qm0id z@LW!VzlL&14_P==#PvLW0_;4~IIX~?RjB4(6{{cWjLphOu=XDXnBNFFO^4jvg3=ov znX!4H`9=QxJkEKFAXQ9VXU)6)7)pBe64ak|UTnMHzj(F3v(dddE)0GH3E9%VYKilruw>egy=Vlt^xb$sg+s0udV zYH*CEye?V|FJzhy+byd_<9)g9p4$YN8+x+e6=3m<(kh7_#i`VT)J%}eaKWfU4N`U2 zm}xW}my$x|thiJgRGa@duDeigPbo-MzAwV8Cl=43!+r(jjIFz{FuW2csht=@`z8}( zgF)Bugy9W}M3vMXYu|&~1a9iOHSAo3iauwon9c8?#^YQW_6t8g$S%qt4rvrPu?W@z z7Ga<=UNc)X;py7=yWnB=_)l@B{c_{5tf6;qjJ_pqo6nov*U)>vgf!B8uDpe}0RI8H Cun3p{ literal 0 HcmV?d00001 diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Severity.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Severity.php new file mode 100644 index 0000000000000000000000000000000000000000..bd0c81933da82d252d670e0445a98d5e1628beae GIT binary patch literal 744 zcmZ`%U2EGg6kVFG4R;#^vxn{Njuo1Y&7tgNB+Evcq^_a)Sd(^am=?vkb_K3vBstKH z{F(i<{gTOcmKI9&BB6WEx#u3~^Vjq`g}3ODAjJ$VaDI#CnlM$;$WSIY&!UJFhVmxm z2`Lw`KgQ8`hJ(I8dt<3uW-6o>#)?J6baQ#w)U+hU&8=Ig00?$NI%OfDH#r)TVGCwh z;FW~n;;;=6CQNIbu8Hs)(5^I_Cp<)Ln6cX)*H>I{!&$d zwz(XSuu*z!wH}!4pivp!?~bU*WJt0^efV2} z*N^7zz`Eov58quv?SHt=D|k5_Tnx_q*^jI9(R4EC`N#gCUw`5}gWaJ&@`v5idd1m= z>go70} z#I96vGbT}diDp@1Dc8+A|Lyhh&sNnt>&|xy=*Rud%IJe4cm*qfe}6pT A_y7O^ literal 0 HcmV?d00001 diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenance.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenance.php new file mode 100644 index 00000000000..0a003210680 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenance.php @@ -0,0 +1,61 @@ +internalAddGeneratedFile( + ' +À + grafeas/v1/slsa_provenance.proto +grafeas.v1google/protobuf/timestamp.proto"þ +SlsaProvenance7 +builder ( 2&.grafeas.v1.SlsaProvenance.SlsaBuilder5 +recipe ( 2%.grafeas.v1.SlsaProvenance.SlsaRecipe9 +metadata ( 2\'.grafeas.v1.SlsaProvenance.SlsaMetadata6 + materials ( 2#.grafeas.v1.SlsaProvenance.Material  + +SlsaRecipe +type (  +defined_in_material ( + entry_point ( \' + arguments ( 2.google.protobuf.Any) + environment ( 2.google.protobuf.AnyM +SlsaCompleteness + arguments ( + environment ( + materials (ñ + SlsaMetadata +build_invocation_id ( 4 +build_started_on ( 2.google.protobuf.Timestamp5 +build_finished_on ( 2.google.protobuf.TimestampA + completeness ( 2+.grafeas.v1.SlsaProvenance.SlsaCompleteness + reproducible ( + SlsaBuilder + +id ( ‡ +Material +uri ( ? +digest ( 2/.grafeas.v1.SlsaProvenance.Material.DigestEntry- + DigestEntry +key (  +value ( :8Bf + io.grafeas.v1BSlsaProvenanceProtoPZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenanceZeroTwo.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenanceZeroTwo.php new file mode 100644 index 00000000000..2df7242755b --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenanceZeroTwo.php @@ -0,0 +1,71 @@ +internalAddGeneratedFile( + ' +¥ +)grafeas/v1/slsa_provenance_zero_two.proto +grafeas.v1google/protobuf/timestamp.proto"Ó +SlsaProvenanceZeroTwo> +builder ( 2-.grafeas.v1.SlsaProvenanceZeroTwo.SlsaBuilder + +build_type ( D + +invocation ( 20.grafeas.v1.SlsaProvenanceZeroTwo.SlsaInvocation- + build_config ( 2.google.protobuf.Struct@ +metadata ( 2..grafeas.v1.SlsaProvenanceZeroTwo.SlsaMetadataA + materials ( 2..grafeas.v1.SlsaProvenanceZeroTwo.SlsaMaterial + SlsaBuilder + +id ( – + SlsaMaterial +uri ( J +digest ( 2:.grafeas.v1.SlsaProvenanceZeroTwo.SlsaMaterial.DigestEntry- + DigestEntry +key (  +value ( :8¶ +SlsaInvocationI + config_source ( 22.grafeas.v1.SlsaProvenanceZeroTwo.SlsaConfigSource+ + +parameters ( 2.google.protobuf.Struct, + environment ( 2.google.protobuf.Struct³ +SlsaConfigSource +uri ( N +digest ( 2>.grafeas.v1.SlsaProvenanceZeroTwo.SlsaConfigSource.DigestEntry + entry_point ( - + DigestEntry +key (  +value ( :8ø + SlsaMetadata +build_invocation_id ( 4 +build_started_on ( 2.google.protobuf.Timestamp5 +build_finished_on ( 2.google.protobuf.TimestampH + completeness ( 22.grafeas.v1.SlsaProvenanceZeroTwo.SlsaCompleteness + reproducible (N +SlsaCompleteness + +parameters ( + environment ( + materials (Bm + io.grafeas.v1BSlsaProvenanceZeroTwoProtoPZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Upgrade.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Upgrade.php new file mode 100644 index 00000000000..ccca29a0b7e --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Upgrade.php @@ -0,0 +1,60 @@ +internalAddGeneratedFile( + ' +Ù +grafeas/v1/upgrade.proto +grafeas.v1grafeas/v1/package.proto"¯ + UpgradeNote +package ( $ +version ( 2.grafeas.v1.Version6 + distributions ( 2.grafeas.v1.UpgradeDistribution1 +windows_update ( 2.grafeas.v1.WindowsUpdate"] +UpgradeDistribution +cpe_uri (  +classification (  +severity (  +cve ( "ì + WindowsUpdate4 +identity ( 2".grafeas.v1.WindowsUpdate.Identity +title (  + description ( 6 + +categories ( 2".grafeas.v1.WindowsUpdate.Category +kb_article_ids (  + support_url ( < +last_published_timestamp ( 2.google.protobuf.Timestamp/ +Identity + update_id (  +revision (- +Category + category_id (  +name ( "» +UpgradeOccurrence +package ( + +parsed_version ( 2.grafeas.v1.Version5 + distribution ( 2.grafeas.v1.UpgradeDistribution1 +windows_update ( 2.grafeas.v1.WindowsUpdateBQ + io.grafeas.v1PZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vex.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vex.php new file mode 100644 index 0000000000000000000000000000000000000000..4a915579a237e4c4daf92804a754d7c5d74aacdc GIT binary patch literal 2395 zcmbVOZEqS!5DsACcx-HZsaxt)?bfkmM@m6bOJq zV#Tfe3))}NkNFw>(%;l?oxP)Q#CDXJFD$z=&&)i}><&NvG&!HZW741w^~`_{NdJ-q z=afu5H*hW2CjD?Yq#m){@r2pbD-u#uiK6O6s>%Ad=<2(nXVEeldFGIse(B<%bV1)1 zBLD!$98-T{T9hQK1ILlw!_e|0_Hk|JE)FD_n(j$liTi2T&(Aq^ct=^vT3iyOT_Ye zvJ+6xG3{QB`j*Egf$O!~yWOPD28iby6 z6y?nUu4b#=&D`{=?s)7vNBhtFErZWo75j8A#KnqLJb`4e{-Tiaw6|%UsdU#Nrr&jzxTE!M` z815*%fMx8vL1+bq`w>RzqcLJPp$>rEI4!!c9Dy8uEXbU$?N_iePiqa9_&u1@#(Y0y zNRJr?NFWkDrR@{(A*ro~y758S5gE-KUHC6xKXy^Y?>C^-u7I?q!swzkJ zV>)0FtY3H#75MxPxY`_M`_ByI7UMV|EEHe_my=kT^+W9r(H78)3%_(k<_r$-QD(Lu z_s`D1DcHPjwgX?k?6h^cE>}feRuw}(Ye_~&X}6>*Zc4TMJ$wzes_JP=RU}0>a6lL> zO={yhpAx>oXQk6rBu%U|C8Mg=qy>Yt(A$H@H(AJvA-$2R9bGb7qJEOk2tUBV`-W9f z;o&MASpG8gWD7Acc zrw`fqif+MXTNhEk#b#N92V%W0RdtMz67sOd6`bv)g%!vmFdk-vFW@0!N}3@nT?uv5u@qE65D}et1+3wq< literal 0 HcmV?d00001 diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vulnerability.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vulnerability.php new file mode 100644 index 00000000000..8886bd996b0 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vulnerability.php @@ -0,0 +1,106 @@ +internalAddGeneratedFile( + ' +ø +grafeas/v1/vulnerability.proto +grafeas.v1google/protobuf/timestamp.protografeas/v1/common.protografeas/v1/cvss.protografeas/v1/package.protografeas/v1/severity.protografeas/v1/vex.proto"ì +VulnerabilityNote + +cvss_score (& +severity (2.grafeas.v1.Severity5 +details ( 2$.grafeas.v1.VulnerabilityNote.Detail# +cvss_v3 ( 2.grafeas.v1.CVSSv3D +windows_details ( 2+.grafeas.v1.VulnerabilityNote.WindowsDetail6 +source_update_time ( 2.google.protobuf.Timestamp- + cvss_version (2.grafeas.v1.CVSSVersion! +cvss_v2 ( 2.grafeas.v1.CVSS­ +Detail + severity_name (  + description (  + package_type (  +affected_cpe_uri (  +affected_package ( 3 +affected_version_start ( 2.grafeas.v1.Version1 +affected_version_end ( 2.grafeas.v1.Version + fixed_cpe_uri (  + fixed_package ( * + fixed_version + ( 2.grafeas.v1.Version + is_obsolete (6 +source_update_time ( 2.google.protobuf.Timestamp +source (  +vendor ( ¾ + WindowsDetail +cpe_uri (  +name (  + description ( M + +fixing_kbs ( 29.grafeas.v1.VulnerabilityNote.WindowsDetail.KnowledgeBase* + KnowledgeBase +name (  +url ( "ã +VulnerabilityOccurrence +type ( & +severity (2.grafeas.v1.Severity + +cvss_score ( +cvssv3 + ( 2.grafeas.v1.CVSSG + package_issue ( 20.grafeas.v1.VulnerabilityOccurrence.PackageIssue +short_description (  +long_description ( , + related_urls ( 2.grafeas.v1.RelatedUrl0 +effective_severity (2.grafeas.v1.Severity + fix_available (- + cvss_version (2.grafeas.v1.CVSSVersion! +cvss_v2 ( 2.grafeas.v1.CVSSI +vex_assessment ( 21.grafeas.v1.VulnerabilityOccurrence.VexAssessmentà + PackageIssue +affected_cpe_uri (  +affected_package ( - +affected_version ( 2.grafeas.v1.Version + fixed_cpe_uri (  + fixed_package ( * + fixed_version ( 2.grafeas.v1.Version + fix_available ( + package_type ( 5 +effective_severity (2.grafeas.v1.SeverityBàA/ + file_location + ( 2.grafeas.v1.FileLocationæ + VexAssessment +cve ( , + related_uris ( 2.grafeas.v1.RelatedUrl + note_name ( G +state (28.grafeas.v1.VulnerabilityAssessmentNote.Assessment.State +impacts ( T + remediations ( 2>.grafeas.v1.VulnerabilityAssessmentNote.Assessment.RemediationW + justification ( 2@.grafeas.v1.VulnerabilityAssessmentNote.Assessment.JustificationBQ + io.grafeas.v1PZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext.php new file mode 100644 index 00000000000..36f9800b4f7 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext.php @@ -0,0 +1,101 @@ +grafeas.v1.AliasContext + */ +class AliasContext extends \Google\Protobuf\Internal\Message +{ + /** + * The alias kind. + * + * Generated from protobuf field .grafeas.v1.AliasContext.Kind kind = 1; + */ + protected $kind = 0; + /** + * The alias name. + * + * Generated from protobuf field string name = 2; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $kind + * The alias kind. + * @type string $name + * The alias name. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * The alias kind. + * + * Generated from protobuf field .grafeas.v1.AliasContext.Kind kind = 1; + * @return int + */ + public function getKind() + { + return $this->kind; + } + + /** + * The alias kind. + * + * Generated from protobuf field .grafeas.v1.AliasContext.Kind kind = 1; + * @param int $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\AliasContext\Kind::class); + $this->kind = $var; + + return $this; + } + + /** + * The alias name. + * + * Generated from protobuf field string name = 2; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The alias name. + * + * Generated from protobuf field string name = 2; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext/Kind.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext/Kind.php new file mode 100644 index 00000000000..f46137817ef --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext/Kind.php @@ -0,0 +1,72 @@ +grafeas.v1.AliasContext.Kind + */ +class Kind +{ + /** + * Unknown. + * + * Generated from protobuf enum KIND_UNSPECIFIED = 0; + */ + const KIND_UNSPECIFIED = 0; + /** + * Git tag. + * + * Generated from protobuf enum FIXED = 1; + */ + const FIXED = 1; + /** + * Git branch. + * + * Generated from protobuf enum MOVABLE = 2; + */ + const MOVABLE = 2; + /** + * Used to specify non-standard aliases. For example, if a Git repo has a + * ref named "refs/foo/bar". + * + * Generated from protobuf enum OTHER = 4; + */ + const OTHER = 4; + + private static $valueToName = [ + self::KIND_UNSPECIFIED => 'KIND_UNSPECIFIED', + self::FIXED => 'FIXED', + self::MOVABLE => 'MOVABLE', + self::OTHER => 'OTHER', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Kind::class, \Grafeas\V1\AliasContext_Kind::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext_Kind.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext_Kind.php new file mode 100644 index 00000000000..823c2dd7488 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext_Kind.php @@ -0,0 +1,16 @@ +grafeas.v1.Architecture + */ +class Architecture +{ + /** + * Unknown architecture. + * + * Generated from protobuf enum ARCHITECTURE_UNSPECIFIED = 0; + */ + const ARCHITECTURE_UNSPECIFIED = 0; + /** + * X86 architecture. + * + * Generated from protobuf enum X86 = 1; + */ + const X86 = 1; + /** + * X64 architecture. + * + * Generated from protobuf enum X64 = 2; + */ + const X64 = 2; + + private static $valueToName = [ + self::ARCHITECTURE_UNSPECIFIED => 'ARCHITECTURE_UNSPECIFIED', + self::X86 => 'X86', + self::X64 => 'X64', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Artifact.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Artifact.php new file mode 100644 index 00000000000..ff6f4d0a38d --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Artifact.php @@ -0,0 +1,159 @@ +grafeas.v1.Artifact + */ +class Artifact extends \Google\Protobuf\Internal\Message +{ + /** + * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a + * container. + * + * Generated from protobuf field string checksum = 1; + */ + protected $checksum = ''; + /** + * Artifact ID, if any; for container images, this will be a URL by digest + * like `gcr.io/projectID/imagename@sha256:123456`. + * + * Generated from protobuf field string id = 2; + */ + protected $id = ''; + /** + * 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. + * + * Generated from protobuf field repeated string names = 3; + */ + private $names; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $checksum + * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a + * container. + * @type string $id + * Artifact ID, if any; for container images, this will be a URL by digest + * like `gcr.io/projectID/imagename@sha256:123456`. + * @type array|\Google\Protobuf\Internal\RepeatedField $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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a + * container. + * + * Generated from protobuf field string checksum = 1; + * @return string + */ + public function getChecksum() + { + return $this->checksum; + } + + /** + * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a + * container. + * + * Generated from protobuf field string checksum = 1; + * @param string $var + * @return $this + */ + public function setChecksum($var) + { + GPBUtil::checkString($var, True); + $this->checksum = $var; + + return $this; + } + + /** + * Artifact ID, if any; for container images, this will be a URL by digest + * like `gcr.io/projectID/imagename@sha256:123456`. + * + * Generated from protobuf field string id = 2; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * Artifact ID, if any; for container images, this will be a URL by digest + * like `gcr.io/projectID/imagename@sha256:123456`. + * + * Generated from protobuf field string id = 2; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + 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. + * + * Generated from protobuf field repeated string names = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNames() + { + return $this->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. + * + * Generated from protobuf field repeated string names = 3; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->names = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote.php new file mode 100644 index 00000000000..f6c61a7ac8f --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote.php @@ -0,0 +1,84 @@ +grafeas.v1.AttestationNote + */ +class AttestationNote extends \Google\Protobuf\Internal\Message +{ + /** + * Hint hints at the purpose of the attestation authority. + * + * Generated from protobuf field .grafeas.v1.AttestationNote.Hint hint = 1; + */ + protected $hint = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\AttestationNote\Hint $hint + * Hint hints at the purpose of the attestation authority. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Attestation::initOnce(); + parent::__construct($data); + } + + /** + * Hint hints at the purpose of the attestation authority. + * + * Generated from protobuf field .grafeas.v1.AttestationNote.Hint hint = 1; + * @return \Grafeas\V1\AttestationNote\Hint|null + */ + public function getHint() + { + return $this->hint; + } + + public function hasHint() + { + return isset($this->hint); + } + + public function clearHint() + { + unset($this->hint); + } + + /** + * Hint hints at the purpose of the attestation authority. + * + * Generated from protobuf field .grafeas.v1.AttestationNote.Hint hint = 1; + * @param \Grafeas\V1\AttestationNote\Hint $var + * @return $this + */ + public function setHint($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\AttestationNote\Hint::class); + $this->hint = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote/Hint.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote/Hint.php new file mode 100644 index 00000000000..a9646f50470 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote/Hint.php @@ -0,0 +1,80 @@ +grafeas.v1.AttestationNote.Hint + */ +class Hint extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The human readable name of this attestation authority, for + * example "qa". + * + * Generated from protobuf field string human_readable_name = 1; + */ + protected $human_readable_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $human_readable_name + * Required. The human readable name of this attestation authority, for + * example "qa". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Attestation::initOnce(); + parent::__construct($data); + } + + /** + * Required. The human readable name of this attestation authority, for + * example "qa". + * + * Generated from protobuf field string human_readable_name = 1; + * @return string + */ + public function getHumanReadableName() + { + return $this->human_readable_name; + } + + /** + * Required. The human readable name of this attestation authority, for + * example "qa". + * + * Generated from protobuf field string human_readable_name = 1; + * @param string $var + * @return $this + */ + public function setHumanReadableName($var) + { + GPBUtil::checkString($var, True); + $this->human_readable_name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Hint::class, \Grafeas\V1\AttestationNote_Hint::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote_Hint.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote_Hint.php new file mode 100644 index 00000000000..ce2b4bc895f --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote_Hint.php @@ -0,0 +1,16 @@ +grafeas.v1.AttestationOccurrence + */ +class AttestationOccurrence extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The serialized payload that is verified by one or more + * `signatures`. + * + * Generated from protobuf field bytes serialized_payload = 1; + */ + protected $serialized_payload = ''; + /** + * One or more signatures over `serialized_payload`. Verifier implementations + * should consider this attestation message verified if at least one + * `signature` verifies `serialized_payload`. See `Signature` in common.proto + * for more details on signature structure and verification. + * + * Generated from protobuf field repeated .grafeas.v1.Signature signatures = 2; + */ + private $signatures; + /** + * One or more JWTs encoding a self-contained attestation. + * Each JWT encodes the payload that it verifies within the JWT itself. + * Verifier implementation SHOULD ignore the `serialized_payload` field + * when verifying these JWTs. + * If only JWTs are present on this AttestationOccurrence, then the + * `serialized_payload` SHOULD be left empty. + * Each JWT SHOULD encode a claim specific to the `resource_uri` of this + * Occurrence, but this is not validated by Grafeas metadata API + * implementations. The JWT itself is opaque to Grafeas. + * + * Generated from protobuf field repeated .grafeas.v1.Jwt jwts = 3; + */ + private $jwts; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $serialized_payload + * Required. The serialized payload that is verified by one or more + * `signatures`. + * @type array<\Grafeas\V1\Signature>|\Google\Protobuf\Internal\RepeatedField $signatures + * One or more signatures over `serialized_payload`. Verifier implementations + * should consider this attestation message verified if at least one + * `signature` verifies `serialized_payload`. See `Signature` in common.proto + * for more details on signature structure and verification. + * @type array<\Grafeas\V1\Jwt>|\Google\Protobuf\Internal\RepeatedField $jwts + * One or more JWTs encoding a self-contained attestation. + * Each JWT encodes the payload that it verifies within the JWT itself. + * Verifier implementation SHOULD ignore the `serialized_payload` field + * when verifying these JWTs. + * If only JWTs are present on this AttestationOccurrence, then the + * `serialized_payload` SHOULD be left empty. + * Each JWT SHOULD encode a claim specific to the `resource_uri` of this + * Occurrence, but this is not validated by Grafeas metadata API + * implementations. The JWT itself is opaque to Grafeas. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Attestation::initOnce(); + parent::__construct($data); + } + + /** + * Required. The serialized payload that is verified by one or more + * `signatures`. + * + * Generated from protobuf field bytes serialized_payload = 1; + * @return string + */ + public function getSerializedPayload() + { + return $this->serialized_payload; + } + + /** + * Required. The serialized payload that is verified by one or more + * `signatures`. + * + * Generated from protobuf field bytes serialized_payload = 1; + * @param string $var + * @return $this + */ + public function setSerializedPayload($var) + { + GPBUtil::checkString($var, False); + $this->serialized_payload = $var; + + return $this; + } + + /** + * One or more signatures over `serialized_payload`. Verifier implementations + * should consider this attestation message verified if at least one + * `signature` verifies `serialized_payload`. See `Signature` in common.proto + * for more details on signature structure and verification. + * + * Generated from protobuf field repeated .grafeas.v1.Signature signatures = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSignatures() + { + return $this->signatures; + } + + /** + * One or more signatures over `serialized_payload`. Verifier implementations + * should consider this attestation message verified if at least one + * `signature` verifies `serialized_payload`. See `Signature` in common.proto + * for more details on signature structure and verification. + * + * Generated from protobuf field repeated .grafeas.v1.Signature signatures = 2; + * @param array<\Grafeas\V1\Signature>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSignatures($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Signature::class); + $this->signatures = $arr; + + return $this; + } + + /** + * One or more JWTs encoding a self-contained attestation. + * Each JWT encodes the payload that it verifies within the JWT itself. + * Verifier implementation SHOULD ignore the `serialized_payload` field + * when verifying these JWTs. + * If only JWTs are present on this AttestationOccurrence, then the + * `serialized_payload` SHOULD be left empty. + * Each JWT SHOULD encode a claim specific to the `resource_uri` of this + * Occurrence, but this is not validated by Grafeas metadata API + * implementations. The JWT itself is opaque to Grafeas. + * + * Generated from protobuf field repeated .grafeas.v1.Jwt jwts = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getJwts() + { + return $this->jwts; + } + + /** + * One or more JWTs encoding a self-contained attestation. + * Each JWT encodes the payload that it verifies within the JWT itself. + * Verifier implementation SHOULD ignore the `serialized_payload` field + * when verifying these JWTs. + * If only JWTs are present on this AttestationOccurrence, then the + * `serialized_payload` SHOULD be left empty. + * Each JWT SHOULD encode a claim specific to the `resource_uri` of this + * Occurrence, but this is not validated by Grafeas metadata API + * implementations. The JWT itself is opaque to Grafeas. + * + * Generated from protobuf field repeated .grafeas.v1.Jwt jwts = 3; + * @param array<\Grafeas\V1\Jwt>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setJwts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Jwt::class); + $this->jwts = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesRequest.php new file mode 100644 index 00000000000..8a0a831cf9d --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesRequest.php @@ -0,0 +1,105 @@ +grafeas.v1.BatchCreateNotesRequest + */ +class BatchCreateNotesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the notes are to be created. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The notes to create. Max allowed length is 1000. + * + * Generated from protobuf field map notes = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + private $notes; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the notes are to be created. + * @type array|\Google\Protobuf\Internal\MapField $notes + * The notes to create. Max allowed length is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the notes are to be created. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the notes are to be created. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The notes to create. Max allowed length is 1000. + * + * Generated from protobuf field map notes = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getNotes() + { + return $this->notes; + } + + /** + * The notes to create. Max allowed length is 1000. + * + * Generated from protobuf field map notes = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setNotes($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Note::class); + $this->notes = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesResponse.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesResponse.php new file mode 100644 index 00000000000..da4f910330f --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesResponse.php @@ -0,0 +1,67 @@ +grafeas.v1.BatchCreateNotesResponse + */ +class BatchCreateNotesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The notes that were created. + * + * Generated from protobuf field repeated .grafeas.v1.Note notes = 1; + */ + private $notes; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Grafeas\V1\Note>|\Google\Protobuf\Internal\RepeatedField $notes + * The notes that were created. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The notes that were created. + * + * Generated from protobuf field repeated .grafeas.v1.Note notes = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNotes() + { + return $this->notes; + } + + /** + * The notes that were created. + * + * Generated from protobuf field repeated .grafeas.v1.Note notes = 1; + * @param array<\Grafeas\V1\Note>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNotes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Note::class); + $this->notes = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesRequest.php new file mode 100644 index 00000000000..4497973ea4c --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesRequest.php @@ -0,0 +1,105 @@ +grafeas.v1.BatchCreateOccurrencesRequest + */ +class BatchCreateOccurrencesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the occurrences are to be created. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The occurrences to create. Max allowed length is 1000. + * + * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + private $occurrences; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the occurrences are to be created. + * @type array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $occurrences + * The occurrences to create. Max allowed length is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the occurrences are to be created. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the occurrences are to be created. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The occurrences to create. Max allowed length is 1000. + * + * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOccurrences() + { + return $this->occurrences; + } + + /** + * The occurrences to create. Max allowed length is 1000. + * + * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOccurrences($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Occurrence::class); + $this->occurrences = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesResponse.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesResponse.php new file mode 100644 index 00000000000..ff03d5abda4 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesResponse.php @@ -0,0 +1,67 @@ +grafeas.v1.BatchCreateOccurrencesResponse + */ +class BatchCreateOccurrencesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The occurrences that were created. + * + * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; + */ + private $occurrences; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $occurrences + * The occurrences that were created. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The occurrences that were created. + * + * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOccurrences() + { + return $this->occurrences; + } + + /** + * The occurrences that were created. + * + * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; + * @param array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOccurrences($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Occurrence::class); + $this->occurrences = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildNote.php new file mode 100644 index 00000000000..033b8e22bb8 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildNote.php @@ -0,0 +1,68 @@ +grafeas.v1.BuildNote + */ +class BuildNote extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Immutable. Version of the builder which produced this build. + * + * Generated from protobuf field string builder_version = 1; + */ + protected $builder_version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $builder_version + * Required. Immutable. Version of the builder which produced this build. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Build::initOnce(); + parent::__construct($data); + } + + /** + * Required. Immutable. Version of the builder which produced this build. + * + * Generated from protobuf field string builder_version = 1; + * @return string + */ + public function getBuilderVersion() + { + return $this->builder_version; + } + + /** + * Required. Immutable. Version of the builder which produced this build. + * + * Generated from protobuf field string builder_version = 1; + * @param string $var + * @return $this + */ + public function setBuilderVersion($var) + { + GPBUtil::checkString($var, True); + $this->builder_version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildOccurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildOccurrence.php new file mode 100644 index 00000000000..150d9122a82 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildOccurrence.php @@ -0,0 +1,251 @@ +grafeas.v1.BuildOccurrence + */ +class BuildOccurrence extends \Google\Protobuf\Internal\Message +{ + /** + * The actual provenance for the build. + * + * Generated from protobuf field .grafeas.v1.BuildProvenance provenance = 1; + */ + protected $provenance = null; + /** + * Serialized JSON representation of the provenance, used in generating the + * build signature in the corresponding build note. 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. + * + * Generated from protobuf field string provenance_bytes = 2; + */ + protected $provenance_bytes = ''; + /** + * Deprecated. See InTotoStatement for the replacement. + * In-toto Provenance representation as defined in spec. + * + * Generated from protobuf field .grafeas.v1.InTotoProvenance intoto_provenance = 3; + */ + protected $intoto_provenance = null; + /** + * In-toto Statement representation as defined in spec. + * The intoto_statement can contain any type of provenance. The serialized + * payload of the statement can be stored and signed in the Occurrence's + * envelope. + * + * Generated from protobuf field .grafeas.v1.InTotoStatement intoto_statement = 4; + */ + protected $intoto_statement = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\BuildProvenance $provenance + * The actual provenance for the build. + * @type string $provenance_bytes + * Serialized JSON representation of the provenance, used in generating the + * build signature in the corresponding build note. 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. + * @type \Grafeas\V1\InTotoProvenance $intoto_provenance + * Deprecated. See InTotoStatement for the replacement. + * In-toto Provenance representation as defined in spec. + * @type \Grafeas\V1\InTotoStatement $intoto_statement + * In-toto Statement representation as defined in spec. + * The intoto_statement can contain any type of provenance. The serialized + * payload of the statement can be stored and signed in the Occurrence's + * envelope. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Build::initOnce(); + parent::__construct($data); + } + + /** + * The actual provenance for the build. + * + * Generated from protobuf field .grafeas.v1.BuildProvenance provenance = 1; + * @return \Grafeas\V1\BuildProvenance|null + */ + public function getProvenance() + { + return $this->provenance; + } + + public function hasProvenance() + { + return isset($this->provenance); + } + + public function clearProvenance() + { + unset($this->provenance); + } + + /** + * The actual provenance for the build. + * + * Generated from protobuf field .grafeas.v1.BuildProvenance provenance = 1; + * @param \Grafeas\V1\BuildProvenance $var + * @return $this + */ + public function setProvenance($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\BuildProvenance::class); + $this->provenance = $var; + + return $this; + } + + /** + * Serialized JSON representation of the provenance, used in generating the + * build signature in the corresponding build note. 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. + * + * Generated from protobuf field string provenance_bytes = 2; + * @return string + */ + public function getProvenanceBytes() + { + return $this->provenance_bytes; + } + + /** + * Serialized JSON representation of the provenance, used in generating the + * build signature in the corresponding build note. 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. + * + * Generated from protobuf field string provenance_bytes = 2; + * @param string $var + * @return $this + */ + public function setProvenanceBytes($var) + { + GPBUtil::checkString($var, True); + $this->provenance_bytes = $var; + + return $this; + } + + /** + * Deprecated. See InTotoStatement for the replacement. + * In-toto Provenance representation as defined in spec. + * + * Generated from protobuf field .grafeas.v1.InTotoProvenance intoto_provenance = 3; + * @return \Grafeas\V1\InTotoProvenance|null + */ + public function getIntotoProvenance() + { + return $this->intoto_provenance; + } + + public function hasIntotoProvenance() + { + return isset($this->intoto_provenance); + } + + public function clearIntotoProvenance() + { + unset($this->intoto_provenance); + } + + /** + * Deprecated. See InTotoStatement for the replacement. + * In-toto Provenance representation as defined in spec. + * + * Generated from protobuf field .grafeas.v1.InTotoProvenance intoto_provenance = 3; + * @param \Grafeas\V1\InTotoProvenance $var + * @return $this + */ + public function setIntotoProvenance($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\InTotoProvenance::class); + $this->intoto_provenance = $var; + + return $this; + } + + /** + * In-toto Statement representation as defined in spec. + * The intoto_statement can contain any type of provenance. The serialized + * payload of the statement can be stored and signed in the Occurrence's + * envelope. + * + * Generated from protobuf field .grafeas.v1.InTotoStatement intoto_statement = 4; + * @return \Grafeas\V1\InTotoStatement|null + */ + public function getIntotoStatement() + { + return $this->intoto_statement; + } + + public function hasIntotoStatement() + { + return isset($this->intoto_statement); + } + + public function clearIntotoStatement() + { + unset($this->intoto_statement); + } + + /** + * In-toto Statement representation as defined in spec. + * The intoto_statement can contain any type of provenance. The serialized + * payload of the statement can be stored and signed in the Occurrence's + * envelope. + * + * Generated from protobuf field .grafeas.v1.InTotoStatement intoto_statement = 4; + * @param \Grafeas\V1\InTotoStatement $var + * @return $this + */ + public function setIntotoStatement($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\InTotoStatement::class); + $this->intoto_statement = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildProvenance.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildProvenance.php new file mode 100644 index 00000000000..8e8c3289d1e --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildProvenance.php @@ -0,0 +1,528 @@ +grafeas.v1.BuildProvenance + */ +class BuildProvenance extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Unique identifier of the build. + * + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + /** + * ID of the project. + * + * Generated from protobuf field string project_id = 2; + */ + protected $project_id = ''; + /** + * Commands requested by the build. + * + * Generated from protobuf field repeated .grafeas.v1.Command commands = 3; + */ + private $commands; + /** + * Output of the build. + * + * Generated from protobuf field repeated .grafeas.v1.Artifact built_artifacts = 4; + */ + private $built_artifacts; + /** + * Time at which the build was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; + */ + protected $create_time = null; + /** + * Time at which execution of the build was started. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 6; + */ + protected $start_time = null; + /** + * Time at which execution of the build was finished. + * + * Generated from protobuf field .google.protobuf.Timestamp end_time = 7; + */ + protected $end_time = null; + /** + * 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. + * + * Generated from protobuf field string creator = 8; + */ + protected $creator = ''; + /** + * URI where any logs for this provenance were written. + * + * Generated from protobuf field string logs_uri = 9; + */ + protected $logs_uri = ''; + /** + * Details of the Source input to the build. + * + * Generated from protobuf field .grafeas.v1.Source source_provenance = 10; + */ + protected $source_provenance = null; + /** + * Trigger identifier if the build was triggered automatically; empty if not. + * + * Generated from protobuf field string trigger_id = 11; + */ + protected $trigger_id = ''; + /** + * Special options applied to this build. This is a catch-all field where + * build providers can enter any desired additional details. + * + * Generated from protobuf field map build_options = 12; + */ + private $build_options; + /** + * Version string of the builder at the time this build was executed. + * + * Generated from protobuf field string builder_version = 13; + */ + protected $builder_version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * Required. Unique identifier of the build. + * @type string $project_id + * ID of the project. + * @type array<\Grafeas\V1\Command>|\Google\Protobuf\Internal\RepeatedField $commands + * Commands requested by the build. + * @type array<\Grafeas\V1\Artifact>|\Google\Protobuf\Internal\RepeatedField $built_artifacts + * Output of the build. + * @type \Google\Protobuf\Timestamp $create_time + * Time at which the build was created. + * @type \Google\Protobuf\Timestamp $start_time + * Time at which execution of the build was started. + * @type \Google\Protobuf\Timestamp $end_time + * Time at which execution of the build was finished. + * @type string $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. + * @type string $logs_uri + * URI where any logs for this provenance were written. + * @type \Grafeas\V1\Source $source_provenance + * Details of the Source input to the build. + * @type string $trigger_id + * Trigger identifier if the build was triggered automatically; empty if not. + * @type array|\Google\Protobuf\Internal\MapField $build_options + * Special options applied to this build. This is a catch-all field where + * build providers can enter any desired additional details. + * @type string $builder_version + * Version string of the builder at the time this build was executed. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * Required. Unique identifier of the build. + * + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * Required. Unique identifier of the build. + * + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * ID of the project. + * + * Generated from protobuf field string project_id = 2; + * @return string + */ + public function getProjectId() + { + return $this->project_id; + } + + /** + * ID of the project. + * + * Generated from protobuf field string project_id = 2; + * @param string $var + * @return $this + */ + public function setProjectId($var) + { + GPBUtil::checkString($var, True); + $this->project_id = $var; + + return $this; + } + + /** + * Commands requested by the build. + * + * Generated from protobuf field repeated .grafeas.v1.Command commands = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getCommands() + { + return $this->commands; + } + + /** + * Commands requested by the build. + * + * Generated from protobuf field repeated .grafeas.v1.Command commands = 3; + * @param array<\Grafeas\V1\Command>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setCommands($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Command::class); + $this->commands = $arr; + + return $this; + } + + /** + * Output of the build. + * + * Generated from protobuf field repeated .grafeas.v1.Artifact built_artifacts = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBuiltArtifacts() + { + return $this->built_artifacts; + } + + /** + * Output of the build. + * + * Generated from protobuf field repeated .grafeas.v1.Artifact built_artifacts = 4; + * @param array<\Grafeas\V1\Artifact>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBuiltArtifacts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Artifact::class); + $this->built_artifacts = $arr; + + return $this; + } + + /** + * Time at which the build was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * Time at which the build was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * Time at which execution of the build was started. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 6; + * @return \Google\Protobuf\Timestamp|null + */ + public function getStartTime() + { + return $this->start_time; + } + + public function hasStartTime() + { + return isset($this->start_time); + } + + public function clearStartTime() + { + unset($this->start_time); + } + + /** + * Time at which execution of the build was started. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 6; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setStartTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->start_time = $var; + + return $this; + } + + /** + * Time at which execution of the build was finished. + * + * Generated from protobuf field .google.protobuf.Timestamp end_time = 7; + * @return \Google\Protobuf\Timestamp|null + */ + public function getEndTime() + { + return $this->end_time; + } + + public function hasEndTime() + { + return isset($this->end_time); + } + + public function clearEndTime() + { + unset($this->end_time); + } + + /** + * Time at which execution of the build was finished. + * + * Generated from protobuf field .google.protobuf.Timestamp end_time = 7; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setEndTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->end_time = $var; + + 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. + * + * Generated from protobuf field string creator = 8; + * @return string + */ + public function getCreator() + { + return $this->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. + * + * Generated from protobuf field string creator = 8; + * @param string $var + * @return $this + */ + public function setCreator($var) + { + GPBUtil::checkString($var, True); + $this->creator = $var; + + return $this; + } + + /** + * URI where any logs for this provenance were written. + * + * Generated from protobuf field string logs_uri = 9; + * @return string + */ + public function getLogsUri() + { + return $this->logs_uri; + } + + /** + * URI where any logs for this provenance were written. + * + * Generated from protobuf field string logs_uri = 9; + * @param string $var + * @return $this + */ + public function setLogsUri($var) + { + GPBUtil::checkString($var, True); + $this->logs_uri = $var; + + return $this; + } + + /** + * Details of the Source input to the build. + * + * Generated from protobuf field .grafeas.v1.Source source_provenance = 10; + * @return \Grafeas\V1\Source|null + */ + public function getSourceProvenance() + { + return $this->source_provenance; + } + + public function hasSourceProvenance() + { + return isset($this->source_provenance); + } + + public function clearSourceProvenance() + { + unset($this->source_provenance); + } + + /** + * Details of the Source input to the build. + * + * Generated from protobuf field .grafeas.v1.Source source_provenance = 10; + * @param \Grafeas\V1\Source $var + * @return $this + */ + public function setSourceProvenance($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Source::class); + $this->source_provenance = $var; + + return $this; + } + + /** + * Trigger identifier if the build was triggered automatically; empty if not. + * + * Generated from protobuf field string trigger_id = 11; + * @return string + */ + public function getTriggerId() + { + return $this->trigger_id; + } + + /** + * Trigger identifier if the build was triggered automatically; empty if not. + * + * Generated from protobuf field string trigger_id = 11; + * @param string $var + * @return $this + */ + public function setTriggerId($var) + { + GPBUtil::checkString($var, True); + $this->trigger_id = $var; + + return $this; + } + + /** + * Special options applied to this build. This is a catch-all field where + * build providers can enter any desired additional details. + * + * Generated from protobuf field map build_options = 12; + * @return \Google\Protobuf\Internal\MapField + */ + public function getBuildOptions() + { + return $this->build_options; + } + + /** + * Special options applied to this build. This is a catch-all field where + * build providers can enter any desired additional details. + * + * Generated from protobuf field map build_options = 12; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setBuildOptions($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->build_options = $arr; + + return $this; + } + + /** + * Version string of the builder at the time this build was executed. + * + * Generated from protobuf field string builder_version = 13; + * @return string + */ + public function getBuilderVersion() + { + return $this->builder_version; + } + + /** + * Version string of the builder at the time this build was executed. + * + * Generated from protobuf field string builder_version = 13; + * @param string $var + * @return $this + */ + public function setBuilderVersion($var) + { + GPBUtil::checkString($var, True); + $this->builder_version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuilderConfig.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuilderConfig.php new file mode 100644 index 00000000000..97732fb870d --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuilderConfig.php @@ -0,0 +1,58 @@ +grafeas.v1.BuilderConfig + */ +class BuilderConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\IntotoProvenance::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS.php new file mode 100644 index 00000000000..eed433379f3 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS.php @@ -0,0 +1,382 @@ +grafeas.v1.CVSS + */ +class CVSS extends \Google\Protobuf\Internal\Message +{ + /** + * The base score is a function of the base metric scores. + * + * Generated from protobuf field float base_score = 1; + */ + protected $base_score = 0.0; + /** + * Generated from protobuf field float exploitability_score = 2; + */ + protected $exploitability_score = 0.0; + /** + * Generated from protobuf field float impact_score = 3; + */ + protected $impact_score = 0.0; + /** + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * + * Generated from protobuf field .grafeas.v1.CVSS.AttackVector attack_vector = 4; + */ + protected $attack_vector = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSS.AttackComplexity attack_complexity = 5; + */ + protected $attack_complexity = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSS.Authentication authentication = 6; + */ + protected $authentication = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSS.PrivilegesRequired privileges_required = 7; + */ + protected $privileges_required = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSS.UserInteraction user_interaction = 8; + */ + protected $user_interaction = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSS.Scope scope = 9; + */ + protected $scope = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSS.Impact confidentiality_impact = 10; + */ + protected $confidentiality_impact = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSS.Impact integrity_impact = 11; + */ + protected $integrity_impact = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSS.Impact availability_impact = 12; + */ + protected $availability_impact = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $base_score + * The base score is a function of the base metric scores. + * @type float $exploitability_score + * @type float $impact_score + * @type int $attack_vector + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * @type int $attack_complexity + * @type int $authentication + * @type int $privileges_required + * @type int $user_interaction + * @type int $scope + * @type int $confidentiality_impact + * @type int $integrity_impact + * @type int $availability_impact + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Cvss::initOnce(); + parent::__construct($data); + } + + /** + * The base score is a function of the base metric scores. + * + * Generated from protobuf field float base_score = 1; + * @return float + */ + public function getBaseScore() + { + return $this->base_score; + } + + /** + * The base score is a function of the base metric scores. + * + * Generated from protobuf field float base_score = 1; + * @param float $var + * @return $this + */ + public function setBaseScore($var) + { + GPBUtil::checkFloat($var); + $this->base_score = $var; + + return $this; + } + + /** + * Generated from protobuf field float exploitability_score = 2; + * @return float + */ + public function getExploitabilityScore() + { + return $this->exploitability_score; + } + + /** + * Generated from protobuf field float exploitability_score = 2; + * @param float $var + * @return $this + */ + public function setExploitabilityScore($var) + { + GPBUtil::checkFloat($var); + $this->exploitability_score = $var; + + return $this; + } + + /** + * Generated from protobuf field float impact_score = 3; + * @return float + */ + public function getImpactScore() + { + return $this->impact_score; + } + + /** + * Generated from protobuf field float impact_score = 3; + * @param float $var + * @return $this + */ + public function setImpactScore($var) + { + GPBUtil::checkFloat($var); + $this->impact_score = $var; + + return $this; + } + + /** + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * + * Generated from protobuf field .grafeas.v1.CVSS.AttackVector attack_vector = 4; + * @return int + */ + public function getAttackVector() + { + return $this->attack_vector; + } + + /** + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * + * Generated from protobuf field .grafeas.v1.CVSS.AttackVector attack_vector = 4; + * @param int $var + * @return $this + */ + public function setAttackVector($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\AttackVector::class); + $this->attack_vector = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.AttackComplexity attack_complexity = 5; + * @return int + */ + public function getAttackComplexity() + { + return $this->attack_complexity; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.AttackComplexity attack_complexity = 5; + * @param int $var + * @return $this + */ + public function setAttackComplexity($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\AttackComplexity::class); + $this->attack_complexity = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.Authentication authentication = 6; + * @return int + */ + public function getAuthentication() + { + return $this->authentication; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.Authentication authentication = 6; + * @param int $var + * @return $this + */ + public function setAuthentication($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\Authentication::class); + $this->authentication = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.PrivilegesRequired privileges_required = 7; + * @return int + */ + public function getPrivilegesRequired() + { + return $this->privileges_required; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.PrivilegesRequired privileges_required = 7; + * @param int $var + * @return $this + */ + public function setPrivilegesRequired($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\PrivilegesRequired::class); + $this->privileges_required = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.UserInteraction user_interaction = 8; + * @return int + */ + public function getUserInteraction() + { + return $this->user_interaction; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.UserInteraction user_interaction = 8; + * @param int $var + * @return $this + */ + public function setUserInteraction($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\UserInteraction::class); + $this->user_interaction = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.Scope scope = 9; + * @return int + */ + public function getScope() + { + return $this->scope; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.Scope scope = 9; + * @param int $var + * @return $this + */ + public function setScope($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\Scope::class); + $this->scope = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.Impact confidentiality_impact = 10; + * @return int + */ + public function getConfidentialityImpact() + { + return $this->confidentiality_impact; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.Impact confidentiality_impact = 10; + * @param int $var + * @return $this + */ + public function setConfidentialityImpact($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\Impact::class); + $this->confidentiality_impact = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.Impact integrity_impact = 11; + * @return int + */ + public function getIntegrityImpact() + { + return $this->integrity_impact; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.Impact integrity_impact = 11; + * @param int $var + * @return $this + */ + public function setIntegrityImpact($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\Impact::class); + $this->integrity_impact = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.Impact availability_impact = 12; + * @return int + */ + public function getAvailabilityImpact() + { + return $this->availability_impact; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSS.Impact availability_impact = 12; + * @param int $var + * @return $this + */ + public function setAvailabilityImpact($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\Impact::class); + $this->availability_impact = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackComplexity.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackComplexity.php new file mode 100644 index 00000000000..5921b034341 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackComplexity.php @@ -0,0 +1,56 @@ +grafeas.v1.CVSS.AttackComplexity + */ +class AttackComplexity +{ + /** + * Generated from protobuf enum ATTACK_COMPLEXITY_UNSPECIFIED = 0; + */ + const ATTACK_COMPLEXITY_UNSPECIFIED = 0; + /** + * Generated from protobuf enum ATTACK_COMPLEXITY_LOW = 1; + */ + const ATTACK_COMPLEXITY_LOW = 1; + /** + * Generated from protobuf enum ATTACK_COMPLEXITY_HIGH = 2; + */ + const ATTACK_COMPLEXITY_HIGH = 2; + + private static $valueToName = [ + self::ATTACK_COMPLEXITY_UNSPECIFIED => 'ATTACK_COMPLEXITY_UNSPECIFIED', + self::ATTACK_COMPLEXITY_LOW => 'ATTACK_COMPLEXITY_LOW', + self::ATTACK_COMPLEXITY_HIGH => 'ATTACK_COMPLEXITY_HIGH', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AttackComplexity::class, \Grafeas\V1\CVSS_AttackComplexity::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackVector.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackVector.php new file mode 100644 index 00000000000..e012b40cdfd --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackVector.php @@ -0,0 +1,66 @@ +grafeas.v1.CVSS.AttackVector + */ +class AttackVector +{ + /** + * Generated from protobuf enum ATTACK_VECTOR_UNSPECIFIED = 0; + */ + const ATTACK_VECTOR_UNSPECIFIED = 0; + /** + * Generated from protobuf enum ATTACK_VECTOR_NETWORK = 1; + */ + const ATTACK_VECTOR_NETWORK = 1; + /** + * Generated from protobuf enum ATTACK_VECTOR_ADJACENT = 2; + */ + const ATTACK_VECTOR_ADJACENT = 2; + /** + * Generated from protobuf enum ATTACK_VECTOR_LOCAL = 3; + */ + const ATTACK_VECTOR_LOCAL = 3; + /** + * Generated from protobuf enum ATTACK_VECTOR_PHYSICAL = 4; + */ + const ATTACK_VECTOR_PHYSICAL = 4; + + private static $valueToName = [ + self::ATTACK_VECTOR_UNSPECIFIED => 'ATTACK_VECTOR_UNSPECIFIED', + self::ATTACK_VECTOR_NETWORK => 'ATTACK_VECTOR_NETWORK', + self::ATTACK_VECTOR_ADJACENT => 'ATTACK_VECTOR_ADJACENT', + self::ATTACK_VECTOR_LOCAL => 'ATTACK_VECTOR_LOCAL', + self::ATTACK_VECTOR_PHYSICAL => 'ATTACK_VECTOR_PHYSICAL', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AttackVector::class, \Grafeas\V1\CVSS_AttackVector::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Authentication.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Authentication.php new file mode 100644 index 00000000000..3e49c8c45e1 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Authentication.php @@ -0,0 +1,61 @@ +grafeas.v1.CVSS.Authentication + */ +class Authentication +{ + /** + * Generated from protobuf enum AUTHENTICATION_UNSPECIFIED = 0; + */ + const AUTHENTICATION_UNSPECIFIED = 0; + /** + * Generated from protobuf enum AUTHENTICATION_MULTIPLE = 1; + */ + const AUTHENTICATION_MULTIPLE = 1; + /** + * Generated from protobuf enum AUTHENTICATION_SINGLE = 2; + */ + const AUTHENTICATION_SINGLE = 2; + /** + * Generated from protobuf enum AUTHENTICATION_NONE = 3; + */ + const AUTHENTICATION_NONE = 3; + + private static $valueToName = [ + self::AUTHENTICATION_UNSPECIFIED => 'AUTHENTICATION_UNSPECIFIED', + self::AUTHENTICATION_MULTIPLE => 'AUTHENTICATION_MULTIPLE', + self::AUTHENTICATION_SINGLE => 'AUTHENTICATION_SINGLE', + self::AUTHENTICATION_NONE => 'AUTHENTICATION_NONE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Authentication::class, \Grafeas\V1\CVSS_Authentication::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Impact.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Impact.php new file mode 100644 index 00000000000..ea32fc11f66 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Impact.php @@ -0,0 +1,61 @@ +grafeas.v1.CVSS.Impact + */ +class Impact +{ + /** + * Generated from protobuf enum IMPACT_UNSPECIFIED = 0; + */ + const IMPACT_UNSPECIFIED = 0; + /** + * Generated from protobuf enum IMPACT_HIGH = 1; + */ + const IMPACT_HIGH = 1; + /** + * Generated from protobuf enum IMPACT_LOW = 2; + */ + const IMPACT_LOW = 2; + /** + * Generated from protobuf enum IMPACT_NONE = 3; + */ + const IMPACT_NONE = 3; + + private static $valueToName = [ + self::IMPACT_UNSPECIFIED => 'IMPACT_UNSPECIFIED', + self::IMPACT_HIGH => 'IMPACT_HIGH', + self::IMPACT_LOW => 'IMPACT_LOW', + self::IMPACT_NONE => 'IMPACT_NONE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Impact::class, \Grafeas\V1\CVSS_Impact::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/PrivilegesRequired.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/PrivilegesRequired.php new file mode 100644 index 00000000000..b3f593d0689 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/PrivilegesRequired.php @@ -0,0 +1,61 @@ +grafeas.v1.CVSS.PrivilegesRequired + */ +class PrivilegesRequired +{ + /** + * Generated from protobuf enum PRIVILEGES_REQUIRED_UNSPECIFIED = 0; + */ + const PRIVILEGES_REQUIRED_UNSPECIFIED = 0; + /** + * Generated from protobuf enum PRIVILEGES_REQUIRED_NONE = 1; + */ + const PRIVILEGES_REQUIRED_NONE = 1; + /** + * Generated from protobuf enum PRIVILEGES_REQUIRED_LOW = 2; + */ + const PRIVILEGES_REQUIRED_LOW = 2; + /** + * Generated from protobuf enum PRIVILEGES_REQUIRED_HIGH = 3; + */ + const PRIVILEGES_REQUIRED_HIGH = 3; + + private static $valueToName = [ + self::PRIVILEGES_REQUIRED_UNSPECIFIED => 'PRIVILEGES_REQUIRED_UNSPECIFIED', + self::PRIVILEGES_REQUIRED_NONE => 'PRIVILEGES_REQUIRED_NONE', + self::PRIVILEGES_REQUIRED_LOW => 'PRIVILEGES_REQUIRED_LOW', + self::PRIVILEGES_REQUIRED_HIGH => 'PRIVILEGES_REQUIRED_HIGH', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PrivilegesRequired::class, \Grafeas\V1\CVSS_PrivilegesRequired::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Scope.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Scope.php new file mode 100644 index 00000000000..44ac100792e --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Scope.php @@ -0,0 +1,56 @@ +grafeas.v1.CVSS.Scope + */ +class Scope +{ + /** + * Generated from protobuf enum SCOPE_UNSPECIFIED = 0; + */ + const SCOPE_UNSPECIFIED = 0; + /** + * Generated from protobuf enum SCOPE_UNCHANGED = 1; + */ + const SCOPE_UNCHANGED = 1; + /** + * Generated from protobuf enum SCOPE_CHANGED = 2; + */ + const SCOPE_CHANGED = 2; + + private static $valueToName = [ + self::SCOPE_UNSPECIFIED => 'SCOPE_UNSPECIFIED', + self::SCOPE_UNCHANGED => 'SCOPE_UNCHANGED', + self::SCOPE_CHANGED => 'SCOPE_CHANGED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Scope::class, \Grafeas\V1\CVSS_Scope::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/UserInteraction.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/UserInteraction.php new file mode 100644 index 00000000000..2e0e911d1c8 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/UserInteraction.php @@ -0,0 +1,56 @@ +grafeas.v1.CVSS.UserInteraction + */ +class UserInteraction +{ + /** + * Generated from protobuf enum USER_INTERACTION_UNSPECIFIED = 0; + */ + const USER_INTERACTION_UNSPECIFIED = 0; + /** + * Generated from protobuf enum USER_INTERACTION_NONE = 1; + */ + const USER_INTERACTION_NONE = 1; + /** + * Generated from protobuf enum USER_INTERACTION_REQUIRED = 2; + */ + const USER_INTERACTION_REQUIRED = 2; + + private static $valueToName = [ + self::USER_INTERACTION_UNSPECIFIED => 'USER_INTERACTION_UNSPECIFIED', + self::USER_INTERACTION_NONE => 'USER_INTERACTION_NONE', + self::USER_INTERACTION_REQUIRED => 'USER_INTERACTION_REQUIRED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(UserInteraction::class, \Grafeas\V1\CVSS_UserInteraction::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSVersion.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSVersion.php new file mode 100644 index 00000000000..8c25036f4ff --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSVersion.php @@ -0,0 +1,55 @@ +grafeas.v1.CVSSVersion + */ +class CVSSVersion +{ + /** + * Generated from protobuf enum CVSS_VERSION_UNSPECIFIED = 0; + */ + const CVSS_VERSION_UNSPECIFIED = 0; + /** + * Generated from protobuf enum CVSS_VERSION_2 = 1; + */ + const CVSS_VERSION_2 = 1; + /** + * Generated from protobuf enum CVSS_VERSION_3 = 2; + */ + const CVSS_VERSION_3 = 2; + + private static $valueToName = [ + self::CVSS_VERSION_UNSPECIFIED => 'CVSS_VERSION_UNSPECIFIED', + self::CVSS_VERSION_2 => 'CVSS_VERSION_2', + self::CVSS_VERSION_3 => 'CVSS_VERSION_3', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_AttackComplexity.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_AttackComplexity.php new file mode 100644 index 00000000000..f53fa0e2874 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_AttackComplexity.php @@ -0,0 +1,16 @@ +grafeas.v1.CVSSv3 + */ +class CVSSv3 extends \Google\Protobuf\Internal\Message +{ + /** + * The base score is a function of the base metric scores. + * + * Generated from protobuf field float base_score = 1; + */ + protected $base_score = 0.0; + /** + * Generated from protobuf field float exploitability_score = 2; + */ + protected $exploitability_score = 0.0; + /** + * Generated from protobuf field float impact_score = 3; + */ + protected $impact_score = 0.0; + /** + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * + * Generated from protobuf field .grafeas.v1.CVSSv3.AttackVector attack_vector = 5; + */ + protected $attack_vector = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.AttackComplexity attack_complexity = 6; + */ + protected $attack_complexity = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.PrivilegesRequired privileges_required = 7; + */ + protected $privileges_required = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.UserInteraction user_interaction = 8; + */ + protected $user_interaction = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.Scope scope = 9; + */ + protected $scope = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.Impact confidentiality_impact = 10; + */ + protected $confidentiality_impact = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.Impact integrity_impact = 11; + */ + protected $integrity_impact = 0; + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.Impact availability_impact = 12; + */ + protected $availability_impact = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $base_score + * The base score is a function of the base metric scores. + * @type float $exploitability_score + * @type float $impact_score + * @type int $attack_vector + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * @type int $attack_complexity + * @type int $privileges_required + * @type int $user_interaction + * @type int $scope + * @type int $confidentiality_impact + * @type int $integrity_impact + * @type int $availability_impact + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Cvss::initOnce(); + parent::__construct($data); + } + + /** + * The base score is a function of the base metric scores. + * + * Generated from protobuf field float base_score = 1; + * @return float + */ + public function getBaseScore() + { + return $this->base_score; + } + + /** + * The base score is a function of the base metric scores. + * + * Generated from protobuf field float base_score = 1; + * @param float $var + * @return $this + */ + public function setBaseScore($var) + { + GPBUtil::checkFloat($var); + $this->base_score = $var; + + return $this; + } + + /** + * Generated from protobuf field float exploitability_score = 2; + * @return float + */ + public function getExploitabilityScore() + { + return $this->exploitability_score; + } + + /** + * Generated from protobuf field float exploitability_score = 2; + * @param float $var + * @return $this + */ + public function setExploitabilityScore($var) + { + GPBUtil::checkFloat($var); + $this->exploitability_score = $var; + + return $this; + } + + /** + * Generated from protobuf field float impact_score = 3; + * @return float + */ + public function getImpactScore() + { + return $this->impact_score; + } + + /** + * Generated from protobuf field float impact_score = 3; + * @param float $var + * @return $this + */ + public function setImpactScore($var) + { + GPBUtil::checkFloat($var); + $this->impact_score = $var; + + return $this; + } + + /** + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * + * Generated from protobuf field .grafeas.v1.CVSSv3.AttackVector attack_vector = 5; + * @return int + */ + public function getAttackVector() + { + return $this->attack_vector; + } + + /** + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * + * Generated from protobuf field .grafeas.v1.CVSSv3.AttackVector attack_vector = 5; + * @param int $var + * @return $this + */ + public function setAttackVector($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\AttackVector::class); + $this->attack_vector = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.AttackComplexity attack_complexity = 6; + * @return int + */ + public function getAttackComplexity() + { + return $this->attack_complexity; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.AttackComplexity attack_complexity = 6; + * @param int $var + * @return $this + */ + public function setAttackComplexity($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\AttackComplexity::class); + $this->attack_complexity = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.PrivilegesRequired privileges_required = 7; + * @return int + */ + public function getPrivilegesRequired() + { + return $this->privileges_required; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.PrivilegesRequired privileges_required = 7; + * @param int $var + * @return $this + */ + public function setPrivilegesRequired($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\PrivilegesRequired::class); + $this->privileges_required = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.UserInteraction user_interaction = 8; + * @return int + */ + public function getUserInteraction() + { + return $this->user_interaction; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.UserInteraction user_interaction = 8; + * @param int $var + * @return $this + */ + public function setUserInteraction($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\UserInteraction::class); + $this->user_interaction = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.Scope scope = 9; + * @return int + */ + public function getScope() + { + return $this->scope; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.Scope scope = 9; + * @param int $var + * @return $this + */ + public function setScope($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\Scope::class); + $this->scope = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.Impact confidentiality_impact = 10; + * @return int + */ + public function getConfidentialityImpact() + { + return $this->confidentiality_impact; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.Impact confidentiality_impact = 10; + * @param int $var + * @return $this + */ + public function setConfidentialityImpact($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\Impact::class); + $this->confidentiality_impact = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.Impact integrity_impact = 11; + * @return int + */ + public function getIntegrityImpact() + { + return $this->integrity_impact; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.Impact integrity_impact = 11; + * @param int $var + * @return $this + */ + public function setIntegrityImpact($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\Impact::class); + $this->integrity_impact = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.Impact availability_impact = 12; + * @return int + */ + public function getAvailabilityImpact() + { + return $this->availability_impact; + } + + /** + * Generated from protobuf field .grafeas.v1.CVSSv3.Impact availability_impact = 12; + * @param int $var + * @return $this + */ + public function setAvailabilityImpact($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\Impact::class); + $this->availability_impact = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackComplexity.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackComplexity.php new file mode 100644 index 00000000000..6086d84dc98 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackComplexity.php @@ -0,0 +1,56 @@ +grafeas.v1.CVSSv3.AttackComplexity + */ +class AttackComplexity +{ + /** + * Generated from protobuf enum ATTACK_COMPLEXITY_UNSPECIFIED = 0; + */ + const ATTACK_COMPLEXITY_UNSPECIFIED = 0; + /** + * Generated from protobuf enum ATTACK_COMPLEXITY_LOW = 1; + */ + const ATTACK_COMPLEXITY_LOW = 1; + /** + * Generated from protobuf enum ATTACK_COMPLEXITY_HIGH = 2; + */ + const ATTACK_COMPLEXITY_HIGH = 2; + + private static $valueToName = [ + self::ATTACK_COMPLEXITY_UNSPECIFIED => 'ATTACK_COMPLEXITY_UNSPECIFIED', + self::ATTACK_COMPLEXITY_LOW => 'ATTACK_COMPLEXITY_LOW', + self::ATTACK_COMPLEXITY_HIGH => 'ATTACK_COMPLEXITY_HIGH', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AttackComplexity::class, \Grafeas\V1\CVSSv3_AttackComplexity::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackVector.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackVector.php new file mode 100644 index 00000000000..9f089274962 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackVector.php @@ -0,0 +1,66 @@ +grafeas.v1.CVSSv3.AttackVector + */ +class AttackVector +{ + /** + * Generated from protobuf enum ATTACK_VECTOR_UNSPECIFIED = 0; + */ + const ATTACK_VECTOR_UNSPECIFIED = 0; + /** + * Generated from protobuf enum ATTACK_VECTOR_NETWORK = 1; + */ + const ATTACK_VECTOR_NETWORK = 1; + /** + * Generated from protobuf enum ATTACK_VECTOR_ADJACENT = 2; + */ + const ATTACK_VECTOR_ADJACENT = 2; + /** + * Generated from protobuf enum ATTACK_VECTOR_LOCAL = 3; + */ + const ATTACK_VECTOR_LOCAL = 3; + /** + * Generated from protobuf enum ATTACK_VECTOR_PHYSICAL = 4; + */ + const ATTACK_VECTOR_PHYSICAL = 4; + + private static $valueToName = [ + self::ATTACK_VECTOR_UNSPECIFIED => 'ATTACK_VECTOR_UNSPECIFIED', + self::ATTACK_VECTOR_NETWORK => 'ATTACK_VECTOR_NETWORK', + self::ATTACK_VECTOR_ADJACENT => 'ATTACK_VECTOR_ADJACENT', + self::ATTACK_VECTOR_LOCAL => 'ATTACK_VECTOR_LOCAL', + self::ATTACK_VECTOR_PHYSICAL => 'ATTACK_VECTOR_PHYSICAL', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AttackVector::class, \Grafeas\V1\CVSSv3_AttackVector::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Impact.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Impact.php new file mode 100644 index 00000000000..d933d36fe7f --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Impact.php @@ -0,0 +1,61 @@ +grafeas.v1.CVSSv3.Impact + */ +class Impact +{ + /** + * Generated from protobuf enum IMPACT_UNSPECIFIED = 0; + */ + const IMPACT_UNSPECIFIED = 0; + /** + * Generated from protobuf enum IMPACT_HIGH = 1; + */ + const IMPACT_HIGH = 1; + /** + * Generated from protobuf enum IMPACT_LOW = 2; + */ + const IMPACT_LOW = 2; + /** + * Generated from protobuf enum IMPACT_NONE = 3; + */ + const IMPACT_NONE = 3; + + private static $valueToName = [ + self::IMPACT_UNSPECIFIED => 'IMPACT_UNSPECIFIED', + self::IMPACT_HIGH => 'IMPACT_HIGH', + self::IMPACT_LOW => 'IMPACT_LOW', + self::IMPACT_NONE => 'IMPACT_NONE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Impact::class, \Grafeas\V1\CVSSv3_Impact::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/PrivilegesRequired.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/PrivilegesRequired.php new file mode 100644 index 00000000000..dff9206db9b --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/PrivilegesRequired.php @@ -0,0 +1,61 @@ +grafeas.v1.CVSSv3.PrivilegesRequired + */ +class PrivilegesRequired +{ + /** + * Generated from protobuf enum PRIVILEGES_REQUIRED_UNSPECIFIED = 0; + */ + const PRIVILEGES_REQUIRED_UNSPECIFIED = 0; + /** + * Generated from protobuf enum PRIVILEGES_REQUIRED_NONE = 1; + */ + const PRIVILEGES_REQUIRED_NONE = 1; + /** + * Generated from protobuf enum PRIVILEGES_REQUIRED_LOW = 2; + */ + const PRIVILEGES_REQUIRED_LOW = 2; + /** + * Generated from protobuf enum PRIVILEGES_REQUIRED_HIGH = 3; + */ + const PRIVILEGES_REQUIRED_HIGH = 3; + + private static $valueToName = [ + self::PRIVILEGES_REQUIRED_UNSPECIFIED => 'PRIVILEGES_REQUIRED_UNSPECIFIED', + self::PRIVILEGES_REQUIRED_NONE => 'PRIVILEGES_REQUIRED_NONE', + self::PRIVILEGES_REQUIRED_LOW => 'PRIVILEGES_REQUIRED_LOW', + self::PRIVILEGES_REQUIRED_HIGH => 'PRIVILEGES_REQUIRED_HIGH', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PrivilegesRequired::class, \Grafeas\V1\CVSSv3_PrivilegesRequired::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Scope.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Scope.php new file mode 100644 index 00000000000..fc48b6eed3d --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Scope.php @@ -0,0 +1,56 @@ +grafeas.v1.CVSSv3.Scope + */ +class Scope +{ + /** + * Generated from protobuf enum SCOPE_UNSPECIFIED = 0; + */ + const SCOPE_UNSPECIFIED = 0; + /** + * Generated from protobuf enum SCOPE_UNCHANGED = 1; + */ + const SCOPE_UNCHANGED = 1; + /** + * Generated from protobuf enum SCOPE_CHANGED = 2; + */ + const SCOPE_CHANGED = 2; + + private static $valueToName = [ + self::SCOPE_UNSPECIFIED => 'SCOPE_UNSPECIFIED', + self::SCOPE_UNCHANGED => 'SCOPE_UNCHANGED', + self::SCOPE_CHANGED => 'SCOPE_CHANGED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Scope::class, \Grafeas\V1\CVSSv3_Scope::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/UserInteraction.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/UserInteraction.php new file mode 100644 index 00000000000..2348d20766d --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/UserInteraction.php @@ -0,0 +1,56 @@ +grafeas.v1.CVSSv3.UserInteraction + */ +class UserInteraction +{ + /** + * Generated from protobuf enum USER_INTERACTION_UNSPECIFIED = 0; + */ + const USER_INTERACTION_UNSPECIFIED = 0; + /** + * Generated from protobuf enum USER_INTERACTION_NONE = 1; + */ + const USER_INTERACTION_NONE = 1; + /** + * Generated from protobuf enum USER_INTERACTION_REQUIRED = 2; + */ + const USER_INTERACTION_REQUIRED = 2; + + private static $valueToName = [ + self::USER_INTERACTION_UNSPECIFIED => 'USER_INTERACTION_UNSPECIFIED', + self::USER_INTERACTION_NONE => 'USER_INTERACTION_NONE', + self::USER_INTERACTION_REQUIRED => 'USER_INTERACTION_REQUIRED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(UserInteraction::class, \Grafeas\V1\CVSSv3_UserInteraction::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_AttackComplexity.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_AttackComplexity.php new file mode 100644 index 00000000000..5194d471da3 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_AttackComplexity.php @@ -0,0 +1,16 @@ +grafeas.v1.CloudRepoSourceContext + */ +class CloudRepoSourceContext extends \Google\Protobuf\Internal\Message +{ + /** + * The ID of the repo. + * + * Generated from protobuf field .grafeas.v1.RepoId repo_id = 1; + */ + protected $repo_id = null; + protected $revision; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\RepoId $repo_id + * The ID of the repo. + * @type string $revision_id + * A revision ID. + * @type \Grafeas\V1\AliasContext $alias_context + * An alias, which may be a branch or tag. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * The ID of the repo. + * + * Generated from protobuf field .grafeas.v1.RepoId repo_id = 1; + * @return \Grafeas\V1\RepoId|null + */ + public function getRepoId() + { + return $this->repo_id; + } + + public function hasRepoId() + { + return isset($this->repo_id); + } + + public function clearRepoId() + { + unset($this->repo_id); + } + + /** + * The ID of the repo. + * + * Generated from protobuf field .grafeas.v1.RepoId repo_id = 1; + * @param \Grafeas\V1\RepoId $var + * @return $this + */ + public function setRepoId($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\RepoId::class); + $this->repo_id = $var; + + return $this; + } + + /** + * A revision ID. + * + * Generated from protobuf field string revision_id = 2; + * @return string + */ + public function getRevisionId() + { + return $this->readOneof(2); + } + + public function hasRevisionId() + { + return $this->hasOneof(2); + } + + /** + * A revision ID. + * + * Generated from protobuf field string revision_id = 2; + * @param string $var + * @return $this + */ + public function setRevisionId($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * An alias, which may be a branch or tag. + * + * Generated from protobuf field .grafeas.v1.AliasContext alias_context = 3; + * @return \Grafeas\V1\AliasContext|null + */ + public function getAliasContext() + { + return $this->readOneof(3); + } + + public function hasAliasContext() + { + return $this->hasOneof(3); + } + + /** + * An alias, which may be a branch or tag. + * + * Generated from protobuf field .grafeas.v1.AliasContext alias_context = 3; + * @param \Grafeas\V1\AliasContext $var + * @return $this + */ + public function setAliasContext($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\AliasContext::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getRevision() + { + return $this->whichOneof("revision"); + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Command.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Command.php new file mode 100644 index 00000000000..40d507cfd67 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Command.php @@ -0,0 +1,249 @@ +grafeas.v1.Command + */ +class Command extends \Google\Protobuf\Internal\Message +{ + /** + * Required. 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`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Environment variables set before running this command. + * + * Generated from protobuf field repeated string env = 2; + */ + private $env; + /** + * Command-line arguments used when executing this command. + * + * Generated from protobuf field repeated string args = 3; + */ + private $args; + /** + * Working directory (relative to project source root) used when running this + * command. + * + * Generated from protobuf field string dir = 4; + */ + protected $dir = ''; + /** + * Optional unique identifier for this command, used in wait_for to reference + * this command as a dependency. + * + * Generated from protobuf field string id = 5; + */ + protected $id = ''; + /** + * The ID(s) of the command(s) that this command depends on. + * + * Generated from protobuf field repeated string wait_for = 6; + */ + private $wait_for; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. 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`. + * @type array|\Google\Protobuf\Internal\RepeatedField $env + * Environment variables set before running this command. + * @type array|\Google\Protobuf\Internal\RepeatedField $args + * Command-line arguments used when executing this command. + * @type string $dir + * Working directory (relative to project source root) used when running this + * command. + * @type string $id + * Optional unique identifier for this command, used in wait_for to reference + * this command as a dependency. + * @type array|\Google\Protobuf\Internal\RepeatedField $wait_for + * The ID(s) of the command(s) that this command depends on. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * Required. 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`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. 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`. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Environment variables set before running this command. + * + * Generated from protobuf field repeated string env = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getEnv() + { + return $this->env; + } + + /** + * Environment variables set before running this command. + * + * Generated from protobuf field repeated string env = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setEnv($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->env = $arr; + + return $this; + } + + /** + * Command-line arguments used when executing this command. + * + * Generated from protobuf field repeated string args = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getArgs() + { + return $this->args; + } + + /** + * Command-line arguments used when executing this command. + * + * Generated from protobuf field repeated string args = 3; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setArgs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->args = $arr; + + return $this; + } + + /** + * Working directory (relative to project source root) used when running this + * command. + * + * Generated from protobuf field string dir = 4; + * @return string + */ + public function getDir() + { + return $this->dir; + } + + /** + * Working directory (relative to project source root) used when running this + * command. + * + * Generated from protobuf field string dir = 4; + * @param string $var + * @return $this + */ + public function setDir($var) + { + GPBUtil::checkString($var, True); + $this->dir = $var; + + return $this; + } + + /** + * Optional unique identifier for this command, used in wait_for to reference + * this command as a dependency. + * + * Generated from protobuf field string id = 5; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * Optional unique identifier for this command, used in wait_for to reference + * this command as a dependency. + * + * Generated from protobuf field string id = 5; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * The ID(s) of the command(s) that this command depends on. + * + * Generated from protobuf field repeated string wait_for = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getWaitFor() + { + return $this->wait_for; + } + + /** + * The ID(s) of the command(s) that this command depends on. + * + * Generated from protobuf field repeated string wait_for = 6; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setWaitFor($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->wait_for = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Completeness.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Completeness.php new file mode 100644 index 00000000000..d5cd151e9b5 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Completeness.php @@ -0,0 +1,148 @@ +grafeas.v1.Completeness + */ +class Completeness extends \Google\Protobuf\Internal\Message +{ + /** + * If true, the builder claims that recipe.arguments is complete, meaning that + * all external inputs are properly captured in the recipe. + * + * Generated from protobuf field bool arguments = 1; + */ + protected $arguments = false; + /** + * If true, the builder claims that recipe.environment is claimed to be + * complete. + * + * Generated from protobuf field bool environment = 2; + */ + protected $environment = false; + /** + * If true, the builder claims that materials are complete, usually through + * some controls to prevent network access. Sometimes called "hermetic". + * + * Generated from protobuf field bool materials = 3; + */ + protected $materials = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $arguments + * If true, the builder claims that recipe.arguments is complete, meaning that + * all external inputs are properly captured in the recipe. + * @type bool $environment + * If true, the builder claims that recipe.environment is claimed to be + * complete. + * @type bool $materials + * If true, the builder claims that materials are complete, usually through + * some controls to prevent network access. Sometimes called "hermetic". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\IntotoProvenance::initOnce(); + parent::__construct($data); + } + + /** + * If true, the builder claims that recipe.arguments is complete, meaning that + * all external inputs are properly captured in the recipe. + * + * Generated from protobuf field bool arguments = 1; + * @return bool + */ + public function getArguments() + { + return $this->arguments; + } + + /** + * If true, the builder claims that recipe.arguments is complete, meaning that + * all external inputs are properly captured in the recipe. + * + * Generated from protobuf field bool arguments = 1; + * @param bool $var + * @return $this + */ + public function setArguments($var) + { + GPBUtil::checkBool($var); + $this->arguments = $var; + + return $this; + } + + /** + * If true, the builder claims that recipe.environment is claimed to be + * complete. + * + * Generated from protobuf field bool environment = 2; + * @return bool + */ + public function getEnvironment() + { + return $this->environment; + } + + /** + * If true, the builder claims that recipe.environment is claimed to be + * complete. + * + * Generated from protobuf field bool environment = 2; + * @param bool $var + * @return $this + */ + public function setEnvironment($var) + { + GPBUtil::checkBool($var); + $this->environment = $var; + + return $this; + } + + /** + * If true, the builder claims that materials are complete, usually through + * some controls to prevent network access. Sometimes called "hermetic". + * + * Generated from protobuf field bool materials = 3; + * @return bool + */ + public function getMaterials() + { + return $this->materials; + } + + /** + * If true, the builder claims that materials are complete, usually through + * some controls to prevent network access. Sometimes called "hermetic". + * + * Generated from protobuf field bool materials = 3; + * @param bool $var + * @return $this + */ + public function setMaterials($var) + { + GPBUtil::checkBool($var); + $this->materials = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote.php new file mode 100644 index 00000000000..651c3573ec4 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote.php @@ -0,0 +1,272 @@ +grafeas.v1.ComplianceNote + */ +class ComplianceNote extends \Google\Protobuf\Internal\Message +{ + /** + * The title that identifies this compliance check. + * + * Generated from protobuf field string title = 1; + */ + protected $title = ''; + /** + * A description about this compliance check. + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + /** + * The OS and config versions the benchmark applies to. + * + * Generated from protobuf field repeated .grafeas.v1.ComplianceVersion version = 3; + */ + private $version; + /** + * A rationale for the existence of this compliance check. + * + * Generated from protobuf field string rationale = 4; + */ + protected $rationale = ''; + /** + * A description of remediation steps if the compliance check fails. + * + * Generated from protobuf field string remediation = 5; + */ + protected $remediation = ''; + /** + * Serialized scan instructions with a predefined format. + * + * Generated from protobuf field bytes scan_instructions = 7; + */ + protected $scan_instructions = ''; + protected $compliance_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $title + * The title that identifies this compliance check. + * @type string $description + * A description about this compliance check. + * @type array<\Grafeas\V1\ComplianceVersion>|\Google\Protobuf\Internal\RepeatedField $version + * The OS and config versions the benchmark applies to. + * @type string $rationale + * A rationale for the existence of this compliance check. + * @type string $remediation + * A description of remediation steps if the compliance check fails. + * @type \Grafeas\V1\ComplianceNote\CisBenchmark $cis_benchmark + * @type string $scan_instructions + * Serialized scan instructions with a predefined format. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Compliance::initOnce(); + parent::__construct($data); + } + + /** + * The title that identifies this compliance check. + * + * Generated from protobuf field string title = 1; + * @return string + */ + public function getTitle() + { + return $this->title; + } + + /** + * The title that identifies this compliance check. + * + * Generated from protobuf field string title = 1; + * @param string $var + * @return $this + */ + public function setTitle($var) + { + GPBUtil::checkString($var, True); + $this->title = $var; + + return $this; + } + + /** + * A description about this compliance check. + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * A description about this compliance check. + * + * Generated from protobuf field string description = 2; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * The OS and config versions the benchmark applies to. + * + * Generated from protobuf field repeated .grafeas.v1.ComplianceVersion version = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getVersion() + { + return $this->version; + } + + /** + * The OS and config versions the benchmark applies to. + * + * Generated from protobuf field repeated .grafeas.v1.ComplianceVersion version = 3; + * @param array<\Grafeas\V1\ComplianceVersion>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setVersion($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\ComplianceVersion::class); + $this->version = $arr; + + return $this; + } + + /** + * A rationale for the existence of this compliance check. + * + * Generated from protobuf field string rationale = 4; + * @return string + */ + public function getRationale() + { + return $this->rationale; + } + + /** + * A rationale for the existence of this compliance check. + * + * Generated from protobuf field string rationale = 4; + * @param string $var + * @return $this + */ + public function setRationale($var) + { + GPBUtil::checkString($var, True); + $this->rationale = $var; + + return $this; + } + + /** + * A description of remediation steps if the compliance check fails. + * + * Generated from protobuf field string remediation = 5; + * @return string + */ + public function getRemediation() + { + return $this->remediation; + } + + /** + * A description of remediation steps if the compliance check fails. + * + * Generated from protobuf field string remediation = 5; + * @param string $var + * @return $this + */ + public function setRemediation($var) + { + GPBUtil::checkString($var, True); + $this->remediation = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.ComplianceNote.CisBenchmark cis_benchmark = 6; + * @return \Grafeas\V1\ComplianceNote\CisBenchmark|null + */ + public function getCisBenchmark() + { + return $this->readOneof(6); + } + + public function hasCisBenchmark() + { + return $this->hasOneof(6); + } + + /** + * Generated from protobuf field .grafeas.v1.ComplianceNote.CisBenchmark cis_benchmark = 6; + * @param \Grafeas\V1\ComplianceNote\CisBenchmark $var + * @return $this + */ + public function setCisBenchmark($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\ComplianceNote\CisBenchmark::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * Serialized scan instructions with a predefined format. + * + * Generated from protobuf field bytes scan_instructions = 7; + * @return string + */ + public function getScanInstructions() + { + return $this->scan_instructions; + } + + /** + * Serialized scan instructions with a predefined format. + * + * Generated from protobuf field bytes scan_instructions = 7; + * @param string $var + * @return $this + */ + public function setScanInstructions($var) + { + GPBUtil::checkString($var, False); + $this->scan_instructions = $var; + + return $this; + } + + /** + * @return string + */ + public function getComplianceType() + { + return $this->whichOneof("compliance_type"); + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote/CisBenchmark.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote/CisBenchmark.php new file mode 100644 index 00000000000..be70e77b166 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote/CisBenchmark.php @@ -0,0 +1,90 @@ +grafeas.v1.ComplianceNote.CisBenchmark + */ +class CisBenchmark extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field int32 profile_level = 1; + */ + protected $profile_level = 0; + /** + * Generated from protobuf field .grafeas.v1.Severity severity = 2; + */ + protected $severity = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $profile_level + * @type int $severity + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Compliance::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field int32 profile_level = 1; + * @return int + */ + public function getProfileLevel() + { + return $this->profile_level; + } + + /** + * Generated from protobuf field int32 profile_level = 1; + * @param int $var + * @return $this + */ + public function setProfileLevel($var) + { + GPBUtil::checkInt32($var); + $this->profile_level = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.Severity severity = 2; + * @return int + */ + public function getSeverity() + { + return $this->severity; + } + + /** + * Generated from protobuf field .grafeas.v1.Severity severity = 2; + * @param int $var + * @return $this + */ + public function setSeverity($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\Severity::class); + $this->severity = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(CisBenchmark::class, \Grafeas\V1\ComplianceNote_CisBenchmark::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote_CisBenchmark.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote_CisBenchmark.php new file mode 100644 index 00000000000..05b17cf4e1c --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote_CisBenchmark.php @@ -0,0 +1,16 @@ +grafeas.v1.ComplianceOccurrence + */ +class ComplianceOccurrence extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field repeated .grafeas.v1.NonCompliantFile non_compliant_files = 2; + */ + private $non_compliant_files; + /** + * Generated from protobuf field string non_compliance_reason = 3; + */ + protected $non_compliance_reason = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Grafeas\V1\NonCompliantFile>|\Google\Protobuf\Internal\RepeatedField $non_compliant_files + * @type string $non_compliance_reason + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Compliance::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field repeated .grafeas.v1.NonCompliantFile non_compliant_files = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNonCompliantFiles() + { + return $this->non_compliant_files; + } + + /** + * Generated from protobuf field repeated .grafeas.v1.NonCompliantFile non_compliant_files = 2; + * @param array<\Grafeas\V1\NonCompliantFile>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNonCompliantFiles($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\NonCompliantFile::class); + $this->non_compliant_files = $arr; + + return $this; + } + + /** + * Generated from protobuf field string non_compliance_reason = 3; + * @return string + */ + public function getNonComplianceReason() + { + return $this->non_compliance_reason; + } + + /** + * Generated from protobuf field string non_compliance_reason = 3; + * @param string $var + * @return $this + */ + public function setNonComplianceReason($var) + { + GPBUtil::checkString($var, True); + $this->non_compliance_reason = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceVersion.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceVersion.php new file mode 100644 index 00000000000..19d19abd80b --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceVersion.php @@ -0,0 +1,148 @@ +grafeas.v1.ComplianceVersion + */ +class ComplianceVersion extends \Google\Protobuf\Internal\Message +{ + /** + * The CPE URI (https://cpe.mitre.org/specification/) this benchmark is + * applicable to. + * + * Generated from protobuf field string cpe_uri = 1; + */ + protected $cpe_uri = ''; + /** + * The name of the document that defines this benchmark, e.g. "CIS + * Container-Optimized OS". + * + * Generated from protobuf field string benchmark_document = 3; + */ + protected $benchmark_document = ''; + /** + * The version of the benchmark. This is set to the version of the OS-specific + * CIS document the benchmark is defined in. + * + * Generated from protobuf field string version = 2; + */ + protected $version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $cpe_uri + * The CPE URI (https://cpe.mitre.org/specification/) this benchmark is + * applicable to. + * @type string $benchmark_document + * The name of the document that defines this benchmark, e.g. "CIS + * Container-Optimized OS". + * @type string $version + * The version of the benchmark. This is set to the version of the OS-specific + * CIS document the benchmark is defined in. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Compliance::initOnce(); + parent::__construct($data); + } + + /** + * The CPE URI (https://cpe.mitre.org/specification/) this benchmark is + * applicable to. + * + * Generated from protobuf field string cpe_uri = 1; + * @return string + */ + public function getCpeUri() + { + return $this->cpe_uri; + } + + /** + * The CPE URI (https://cpe.mitre.org/specification/) this benchmark is + * applicable to. + * + * Generated from protobuf field string cpe_uri = 1; + * @param string $var + * @return $this + */ + public function setCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->cpe_uri = $var; + + return $this; + } + + /** + * The name of the document that defines this benchmark, e.g. "CIS + * Container-Optimized OS". + * + * Generated from protobuf field string benchmark_document = 3; + * @return string + */ + public function getBenchmarkDocument() + { + return $this->benchmark_document; + } + + /** + * The name of the document that defines this benchmark, e.g. "CIS + * Container-Optimized OS". + * + * Generated from protobuf field string benchmark_document = 3; + * @param string $var + * @return $this + */ + public function setBenchmarkDocument($var) + { + GPBUtil::checkString($var, True); + $this->benchmark_document = $var; + + return $this; + } + + /** + * The version of the benchmark. This is set to the version of the OS-specific + * CIS document the benchmark is defined in. + * + * Generated from protobuf field string version = 2; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * The version of the benchmark. This is set to the version of the OS-specific + * CIS document the benchmark is defined in. + * + * Generated from protobuf field string version = 2; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateNoteRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateNoteRequest.php new file mode 100644 index 00000000000..65774554b46 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateNoteRequest.php @@ -0,0 +1,149 @@ +grafeas.v1.CreateNoteRequest + */ +class CreateNoteRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the note is to be created. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The ID to use for this note. + * + * Generated from protobuf field string note_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $note_id = ''; + /** + * The note to create. + * + * Generated from protobuf field .grafeas.v1.Note note = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $note = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the note is to be created. + * @type string $note_id + * The ID to use for this note. + * @type \Grafeas\V1\Note $note + * The note to create. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the note is to be created. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the note is to be created. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The ID to use for this note. + * + * Generated from protobuf field string note_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getNoteId() + { + return $this->note_id; + } + + /** + * The ID to use for this note. + * + * Generated from protobuf field string note_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setNoteId($var) + { + GPBUtil::checkString($var, True); + $this->note_id = $var; + + return $this; + } + + /** + * The note to create. + * + * Generated from protobuf field .grafeas.v1.Note note = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Grafeas\V1\Note|null + */ + public function getNote() + { + return $this->note; + } + + public function hasNote() + { + return isset($this->note); + } + + public function clearNote() + { + unset($this->note); + } + + /** + * The note to create. + * + * Generated from protobuf field .grafeas.v1.Note note = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Grafeas\V1\Note $var + * @return $this + */ + public function setNote($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Note::class); + $this->note = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateOccurrenceRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateOccurrenceRequest.php new file mode 100644 index 00000000000..406afefc2f6 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateOccurrenceRequest.php @@ -0,0 +1,115 @@ +grafeas.v1.CreateOccurrenceRequest + */ +class CreateOccurrenceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the occurrence is to be created. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The occurrence to create. + * + * Generated from protobuf field .grafeas.v1.Occurrence occurrence = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $occurrence = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the occurrence is to be created. + * @type \Grafeas\V1\Occurrence $occurrence + * The occurrence to create. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the occurrence is to be created. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the occurrence is to be created. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The occurrence to create. + * + * Generated from protobuf field .grafeas.v1.Occurrence occurrence = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Grafeas\V1\Occurrence|null + */ + public function getOccurrence() + { + return $this->occurrence; + } + + public function hasOccurrence() + { + return isset($this->occurrence); + } + + public function clearOccurrence() + { + unset($this->occurrence); + } + + /** + * The occurrence to create. + * + * Generated from protobuf field .grafeas.v1.Occurrence occurrence = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Grafeas\V1\Occurrence $var + * @return $this + */ + public function setOccurrence($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Occurrence::class); + $this->occurrence = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote.php new file mode 100644 index 00000000000..b40b73c92c3 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote.php @@ -0,0 +1,75 @@ +grafeas.v1.DSSEAttestationNote + */ +class DSSEAttestationNote extends \Google\Protobuf\Internal\Message +{ + /** + * DSSEHint hints at the purpose of the attestation authority. + * + * Generated from protobuf field .grafeas.v1.DSSEAttestationNote.DSSEHint hint = 1; + */ + protected $hint = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\DSSEAttestationNote\DSSEHint $hint + * DSSEHint hints at the purpose of the attestation authority. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\DsseAttestation::initOnce(); + parent::__construct($data); + } + + /** + * DSSEHint hints at the purpose of the attestation authority. + * + * Generated from protobuf field .grafeas.v1.DSSEAttestationNote.DSSEHint hint = 1; + * @return \Grafeas\V1\DSSEAttestationNote\DSSEHint|null + */ + public function getHint() + { + return $this->hint; + } + + public function hasHint() + { + return isset($this->hint); + } + + public function clearHint() + { + unset($this->hint); + } + + /** + * DSSEHint hints at the purpose of the attestation authority. + * + * Generated from protobuf field .grafeas.v1.DSSEAttestationNote.DSSEHint hint = 1; + * @param \Grafeas\V1\DSSEAttestationNote\DSSEHint $var + * @return $this + */ + public function setHint($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\DSSEAttestationNote\DSSEHint::class); + $this->hint = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote/DSSEHint.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote/DSSEHint.php new file mode 100644 index 00000000000..972f8428516 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote/DSSEHint.php @@ -0,0 +1,80 @@ +grafeas.v1.DSSEAttestationNote.DSSEHint + */ +class DSSEHint extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The human readable name of this attestation authority, for + * example "cloudbuild-prod". + * + * Generated from protobuf field string human_readable_name = 1; + */ + protected $human_readable_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $human_readable_name + * Required. The human readable name of this attestation authority, for + * example "cloudbuild-prod". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\DsseAttestation::initOnce(); + parent::__construct($data); + } + + /** + * Required. The human readable name of this attestation authority, for + * example "cloudbuild-prod". + * + * Generated from protobuf field string human_readable_name = 1; + * @return string + */ + public function getHumanReadableName() + { + return $this->human_readable_name; + } + + /** + * Required. The human readable name of this attestation authority, for + * example "cloudbuild-prod". + * + * Generated from protobuf field string human_readable_name = 1; + * @param string $var + * @return $this + */ + public function setHumanReadableName($var) + { + GPBUtil::checkString($var, True); + $this->human_readable_name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(DSSEHint::class, \Grafeas\V1\DSSEAttestationNote_DSSEHint::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote_DSSEHint.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote_DSSEHint.php new file mode 100644 index 00000000000..59c6d41f948 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote_DSSEHint.php @@ -0,0 +1,16 @@ +grafeas.v1.DSSEAttestationOccurrence + */ +class DSSEAttestationOccurrence extends \Google\Protobuf\Internal\Message +{ + /** + * If doing something security critical, make sure to verify the signatures in + * this metadata. + * + * Generated from protobuf field .grafeas.v1.Envelope envelope = 1; + */ + protected $envelope = null; + protected $decoded_payload; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\Envelope $envelope + * If doing something security critical, make sure to verify the signatures in + * this metadata. + * @type \Grafeas\V1\InTotoStatement $statement + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\DsseAttestation::initOnce(); + parent::__construct($data); + } + + /** + * If doing something security critical, make sure to verify the signatures in + * this metadata. + * + * Generated from protobuf field .grafeas.v1.Envelope envelope = 1; + * @return \Grafeas\V1\Envelope|null + */ + public function getEnvelope() + { + return $this->envelope; + } + + public function hasEnvelope() + { + return isset($this->envelope); + } + + public function clearEnvelope() + { + unset($this->envelope); + } + + /** + * If doing something security critical, make sure to verify the signatures in + * this metadata. + * + * Generated from protobuf field .grafeas.v1.Envelope envelope = 1; + * @param \Grafeas\V1\Envelope $var + * @return $this + */ + public function setEnvelope($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Envelope::class); + $this->envelope = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.InTotoStatement statement = 2; + * @return \Grafeas\V1\InTotoStatement|null + */ + public function getStatement() + { + return $this->readOneof(2); + } + + public function hasStatement() + { + return $this->hasOneof(2); + } + + /** + * Generated from protobuf field .grafeas.v1.InTotoStatement statement = 2; + * @param \Grafeas\V1\InTotoStatement $var + * @return $this + */ + public function setStatement($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\InTotoStatement::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getDecodedPayload() + { + return $this->whichOneof("decoded_payload"); + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteNoteRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteNoteRequest.php new file mode 100644 index 00000000000..776c3531767 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteNoteRequest.php @@ -0,0 +1,71 @@ +grafeas.v1.DeleteNoteRequest + */ +class DeleteNoteRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteOccurrenceRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteOccurrenceRequest.php new file mode 100644 index 00000000000..78bc19ab372 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteOccurrenceRequest.php @@ -0,0 +1,71 @@ +grafeas.v1.DeleteOccurrenceRequest + */ +class DeleteOccurrenceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentNote.php new file mode 100644 index 00000000000..d934670e3bb --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentNote.php @@ -0,0 +1,67 @@ +grafeas.v1.DeploymentNote + */ +class DeploymentNote extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource URI for the artifact being deployed. + * + * Generated from protobuf field repeated string resource_uri = 1; + */ + private $resource_uri; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $resource_uri + * Required. Resource URI for the artifact being deployed. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Deployment::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource URI for the artifact being deployed. + * + * Generated from protobuf field repeated string resource_uri = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getResourceUri() + { + return $this->resource_uri; + } + + /** + * Required. Resource URI for the artifact being deployed. + * + * Generated from protobuf field repeated string resource_uri = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setResourceUri($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->resource_uri = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence.php new file mode 100644 index 00000000000..9971d3eb3d4 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence.php @@ -0,0 +1,295 @@ +grafeas.v1.DeploymentOccurrence + */ +class DeploymentOccurrence extends \Google\Protobuf\Internal\Message +{ + /** + * Identity of the user that triggered this deployment. + * + * Generated from protobuf field string user_email = 1; + */ + protected $user_email = ''; + /** + * Required. Beginning of the lifetime of this deployment. + * + * Generated from protobuf field .google.protobuf.Timestamp deploy_time = 2; + */ + protected $deploy_time = null; + /** + * End of the lifetime of this deployment. + * + * Generated from protobuf field .google.protobuf.Timestamp undeploy_time = 3; + */ + protected $undeploy_time = null; + /** + * Configuration used to create this deployment. + * + * Generated from protobuf field string config = 4; + */ + protected $config = ''; + /** + * Address of the runtime element hosting this deployment. + * + * Generated from protobuf field string address = 5; + */ + protected $address = ''; + /** + * Output only. Resource URI for the artifact being deployed taken from + * the deployable field with the same name. + * + * Generated from protobuf field repeated string resource_uri = 6; + */ + private $resource_uri; + /** + * Platform hosting this deployment. + * + * Generated from protobuf field .grafeas.v1.DeploymentOccurrence.Platform platform = 7; + */ + protected $platform = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $user_email + * Identity of the user that triggered this deployment. + * @type \Google\Protobuf\Timestamp $deploy_time + * Required. Beginning of the lifetime of this deployment. + * @type \Google\Protobuf\Timestamp $undeploy_time + * End of the lifetime of this deployment. + * @type string $config + * Configuration used to create this deployment. + * @type string $address + * Address of the runtime element hosting this deployment. + * @type array|\Google\Protobuf\Internal\RepeatedField $resource_uri + * Output only. Resource URI for the artifact being deployed taken from + * the deployable field with the same name. + * @type int $platform + * Platform hosting this deployment. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Deployment::initOnce(); + parent::__construct($data); + } + + /** + * Identity of the user that triggered this deployment. + * + * Generated from protobuf field string user_email = 1; + * @return string + */ + public function getUserEmail() + { + return $this->user_email; + } + + /** + * Identity of the user that triggered this deployment. + * + * Generated from protobuf field string user_email = 1; + * @param string $var + * @return $this + */ + public function setUserEmail($var) + { + GPBUtil::checkString($var, True); + $this->user_email = $var; + + return $this; + } + + /** + * Required. Beginning of the lifetime of this deployment. + * + * Generated from protobuf field .google.protobuf.Timestamp deploy_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getDeployTime() + { + return $this->deploy_time; + } + + public function hasDeployTime() + { + return isset($this->deploy_time); + } + + public function clearDeployTime() + { + unset($this->deploy_time); + } + + /** + * Required. Beginning of the lifetime of this deployment. + * + * Generated from protobuf field .google.protobuf.Timestamp deploy_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setDeployTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->deploy_time = $var; + + return $this; + } + + /** + * End of the lifetime of this deployment. + * + * Generated from protobuf field .google.protobuf.Timestamp undeploy_time = 3; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUndeployTime() + { + return $this->undeploy_time; + } + + public function hasUndeployTime() + { + return isset($this->undeploy_time); + } + + public function clearUndeployTime() + { + unset($this->undeploy_time); + } + + /** + * End of the lifetime of this deployment. + * + * Generated from protobuf field .google.protobuf.Timestamp undeploy_time = 3; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUndeployTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->undeploy_time = $var; + + return $this; + } + + /** + * Configuration used to create this deployment. + * + * Generated from protobuf field string config = 4; + * @return string + */ + public function getConfig() + { + return $this->config; + } + + /** + * Configuration used to create this deployment. + * + * Generated from protobuf field string config = 4; + * @param string $var + * @return $this + */ + public function setConfig($var) + { + GPBUtil::checkString($var, True); + $this->config = $var; + + return $this; + } + + /** + * Address of the runtime element hosting this deployment. + * + * Generated from protobuf field string address = 5; + * @return string + */ + public function getAddress() + { + return $this->address; + } + + /** + * Address of the runtime element hosting this deployment. + * + * Generated from protobuf field string address = 5; + * @param string $var + * @return $this + */ + public function setAddress($var) + { + GPBUtil::checkString($var, True); + $this->address = $var; + + return $this; + } + + /** + * Output only. Resource URI for the artifact being deployed taken from + * the deployable field with the same name. + * + * Generated from protobuf field repeated string resource_uri = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getResourceUri() + { + return $this->resource_uri; + } + + /** + * Output only. Resource URI for the artifact being deployed taken from + * the deployable field with the same name. + * + * Generated from protobuf field repeated string resource_uri = 6; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setResourceUri($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->resource_uri = $arr; + + return $this; + } + + /** + * Platform hosting this deployment. + * + * Generated from protobuf field .grafeas.v1.DeploymentOccurrence.Platform platform = 7; + * @return int + */ + public function getPlatform() + { + return $this->platform; + } + + /** + * Platform hosting this deployment. + * + * Generated from protobuf field .grafeas.v1.DeploymentOccurrence.Platform platform = 7; + * @param int $var + * @return $this + */ + public function setPlatform($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\DeploymentOccurrence\Platform::class); + $this->platform = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence/Platform.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence/Platform.php new file mode 100644 index 00000000000..35b13b4c785 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence/Platform.php @@ -0,0 +1,71 @@ +grafeas.v1.DeploymentOccurrence.Platform + */ +class Platform +{ + /** + * Unknown. + * + * Generated from protobuf enum PLATFORM_UNSPECIFIED = 0; + */ + const PLATFORM_UNSPECIFIED = 0; + /** + * Google Container Engine. + * + * Generated from protobuf enum GKE = 1; + */ + const GKE = 1; + /** + * Google App Engine: Flexible Environment. + * + * Generated from protobuf enum FLEX = 2; + */ + const FLEX = 2; + /** + * Custom user-defined platform. + * + * Generated from protobuf enum CUSTOM = 3; + */ + const CUSTOM = 3; + + private static $valueToName = [ + self::PLATFORM_UNSPECIFIED => 'PLATFORM_UNSPECIFIED', + self::GKE => 'GKE', + self::FLEX => 'FLEX', + self::CUSTOM => 'CUSTOM', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Platform::class, \Grafeas\V1\DeploymentOccurrence_Platform::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence_Platform.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence_Platform.php new file mode 100644 index 00000000000..411764953ea --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence_Platform.php @@ -0,0 +1,16 @@ +grafeas.v1.Digest + */ +class Digest extends \Google\Protobuf\Internal\Message +{ + /** + * `SHA1`, `SHA512` etc. + * + * Generated from protobuf field string algo = 1; + */ + protected $algo = ''; + /** + * Value of the digest. + * + * Generated from protobuf field bytes digest_bytes = 2; + */ + protected $digest_bytes = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $algo + * `SHA1`, `SHA512` etc. + * @type string $digest_bytes + * Value of the digest. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Common::initOnce(); + parent::__construct($data); + } + + /** + * `SHA1`, `SHA512` etc. + * + * Generated from protobuf field string algo = 1; + * @return string + */ + public function getAlgo() + { + return $this->algo; + } + + /** + * `SHA1`, `SHA512` etc. + * + * Generated from protobuf field string algo = 1; + * @param string $var + * @return $this + */ + public function setAlgo($var) + { + GPBUtil::checkString($var, True); + $this->algo = $var; + + return $this; + } + + /** + * Value of the digest. + * + * Generated from protobuf field bytes digest_bytes = 2; + * @return string + */ + public function getDigestBytes() + { + return $this->digest_bytes; + } + + /** + * Value of the digest. + * + * Generated from protobuf field bytes digest_bytes = 2; + * @param string $var + * @return $this + */ + public function setDigestBytes($var) + { + GPBUtil::checkString($var, False); + $this->digest_bytes = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryNote.php new file mode 100644 index 00000000000..d1fa446c046 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryNote.php @@ -0,0 +1,73 @@ +grafeas.v1.DiscoveryNote + */ +class DiscoveryNote extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Immutable. The kind of analysis that is handled by this + * discovery. + * + * Generated from protobuf field .grafeas.v1.NoteKind analysis_kind = 1; + */ + protected $analysis_kind = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $analysis_kind + * Required. Immutable. The kind of analysis that is handled by this + * discovery. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Discovery::initOnce(); + parent::__construct($data); + } + + /** + * Required. Immutable. The kind of analysis that is handled by this + * discovery. + * + * Generated from protobuf field .grafeas.v1.NoteKind analysis_kind = 1; + * @return int + */ + public function getAnalysisKind() + { + return $this->analysis_kind; + } + + /** + * Required. Immutable. The kind of analysis that is handled by this + * discovery. + * + * Generated from protobuf field .grafeas.v1.NoteKind analysis_kind = 1; + * @param int $var + * @return $this + */ + public function setAnalysisKind($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\NoteKind::class); + $this->analysis_kind = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence.php new file mode 100644 index 00000000000..e1710bb863e --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence.php @@ -0,0 +1,350 @@ +grafeas.v1.DiscoveryOccurrence + */ +class DiscoveryOccurrence extends \Google\Protobuf\Internal\Message +{ + /** + * Whether the resource is continuously analyzed. + * + * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.ContinuousAnalysis continuous_analysis = 1; + */ + protected $continuous_analysis = 0; + /** + * The status of discovery for the resource. + * + * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.AnalysisStatus analysis_status = 2; + */ + protected $analysis_status = 0; + /** + * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.AnalysisCompleted analysis_completed = 7; + */ + protected $analysis_completed = null; + /** + * Indicates any errors encountered during analysis of a resource. There + * could be 0 or more of these errors. + * + * Generated from protobuf field repeated .google.rpc.Status analysis_error = 8; + */ + private $analysis_error; + /** + * 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. + * + * Generated from protobuf field .google.rpc.Status analysis_status_error = 3; + */ + protected $analysis_status_error = null; + /** + * The CPE of the resource being scanned. + * + * Generated from protobuf field string cpe = 4; + */ + protected $cpe = ''; + /** + * The last time this resource was scanned. + * + * Generated from protobuf field .google.protobuf.Timestamp last_scan_time = 5; + */ + protected $last_scan_time = null; + /** + * The time occurrences related to this discovery occurrence were archived. + * + * Generated from protobuf field .google.protobuf.Timestamp archive_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $archive_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $continuous_analysis + * Whether the resource is continuously analyzed. + * @type int $analysis_status + * The status of discovery for the resource. + * @type \Grafeas\V1\DiscoveryOccurrence\AnalysisCompleted $analysis_completed + * @type array<\Google\Rpc\Status>|\Google\Protobuf\Internal\RepeatedField $analysis_error + * Indicates any errors encountered during analysis of a resource. There + * could be 0 or more of these errors. + * @type \Google\Rpc\Status $analysis_status_error + * 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. + * @type string $cpe + * The CPE of the resource being scanned. + * @type \Google\Protobuf\Timestamp $last_scan_time + * The last time this resource was scanned. + * @type \Google\Protobuf\Timestamp $archive_time + * The time occurrences related to this discovery occurrence were archived. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Discovery::initOnce(); + parent::__construct($data); + } + + /** + * Whether the resource is continuously analyzed. + * + * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.ContinuousAnalysis continuous_analysis = 1; + * @return int + */ + public function getContinuousAnalysis() + { + return $this->continuous_analysis; + } + + /** + * Whether the resource is continuously analyzed. + * + * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.ContinuousAnalysis continuous_analysis = 1; + * @param int $var + * @return $this + */ + public function setContinuousAnalysis($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\DiscoveryOccurrence\ContinuousAnalysis::class); + $this->continuous_analysis = $var; + + return $this; + } + + /** + * The status of discovery for the resource. + * + * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.AnalysisStatus analysis_status = 2; + * @return int + */ + public function getAnalysisStatus() + { + return $this->analysis_status; + } + + /** + * The status of discovery for the resource. + * + * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.AnalysisStatus analysis_status = 2; + * @param int $var + * @return $this + */ + public function setAnalysisStatus($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\DiscoveryOccurrence\AnalysisStatus::class); + $this->analysis_status = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.AnalysisCompleted analysis_completed = 7; + * @return \Grafeas\V1\DiscoveryOccurrence\AnalysisCompleted|null + */ + public function getAnalysisCompleted() + { + return $this->analysis_completed; + } + + public function hasAnalysisCompleted() + { + return isset($this->analysis_completed); + } + + public function clearAnalysisCompleted() + { + unset($this->analysis_completed); + } + + /** + * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.AnalysisCompleted analysis_completed = 7; + * @param \Grafeas\V1\DiscoveryOccurrence\AnalysisCompleted $var + * @return $this + */ + public function setAnalysisCompleted($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\DiscoveryOccurrence\AnalysisCompleted::class); + $this->analysis_completed = $var; + + return $this; + } + + /** + * Indicates any errors encountered during analysis of a resource. There + * could be 0 or more of these errors. + * + * Generated from protobuf field repeated .google.rpc.Status analysis_error = 8; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAnalysisError() + { + return $this->analysis_error; + } + + /** + * Indicates any errors encountered during analysis of a resource. There + * could be 0 or more of these errors. + * + * Generated from protobuf field repeated .google.rpc.Status analysis_error = 8; + * @param array<\Google\Rpc\Status>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAnalysisError($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Rpc\Status::class); + $this->analysis_error = $arr; + + 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. + * + * Generated from protobuf field .google.rpc.Status analysis_status_error = 3; + * @return \Google\Rpc\Status|null + */ + public function getAnalysisStatusError() + { + return $this->analysis_status_error; + } + + public function hasAnalysisStatusError() + { + return isset($this->analysis_status_error); + } + + public function clearAnalysisStatusError() + { + unset($this->analysis_status_error); + } + + /** + * 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. + * + * Generated from protobuf field .google.rpc.Status analysis_status_error = 3; + * @param \Google\Rpc\Status $var + * @return $this + */ + public function setAnalysisStatusError($var) + { + GPBUtil::checkMessage($var, \Google\Rpc\Status::class); + $this->analysis_status_error = $var; + + return $this; + } + + /** + * The CPE of the resource being scanned. + * + * Generated from protobuf field string cpe = 4; + * @return string + */ + public function getCpe() + { + return $this->cpe; + } + + /** + * The CPE of the resource being scanned. + * + * Generated from protobuf field string cpe = 4; + * @param string $var + * @return $this + */ + public function setCpe($var) + { + GPBUtil::checkString($var, True); + $this->cpe = $var; + + return $this; + } + + /** + * The last time this resource was scanned. + * + * Generated from protobuf field .google.protobuf.Timestamp last_scan_time = 5; + * @return \Google\Protobuf\Timestamp|null + */ + public function getLastScanTime() + { + return $this->last_scan_time; + } + + public function hasLastScanTime() + { + return isset($this->last_scan_time); + } + + public function clearLastScanTime() + { + unset($this->last_scan_time); + } + + /** + * The last time this resource was scanned. + * + * Generated from protobuf field .google.protobuf.Timestamp last_scan_time = 5; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setLastScanTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->last_scan_time = $var; + + return $this; + } + + /** + * The time occurrences related to this discovery occurrence were archived. + * + * Generated from protobuf field .google.protobuf.Timestamp archive_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getArchiveTime() + { + return $this->archive_time; + } + + public function hasArchiveTime() + { + return isset($this->archive_time); + } + + public function clearArchiveTime() + { + unset($this->archive_time); + } + + /** + * The time occurrences related to this discovery occurrence were archived. + * + * Generated from protobuf field .google.protobuf.Timestamp archive_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setArchiveTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->archive_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisCompleted.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisCompleted.php new file mode 100644 index 00000000000..5d1e7201fb2 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisCompleted.php @@ -0,0 +1,64 @@ +grafeas.v1.DiscoveryOccurrence.AnalysisCompleted + */ +class AnalysisCompleted extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field repeated string analysis_type = 1; + */ + private $analysis_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $analysis_type + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Discovery::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field repeated string analysis_type = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAnalysisType() + { + return $this->analysis_type; + } + + /** + * Generated from protobuf field repeated string analysis_type = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAnalysisType($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->analysis_type = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AnalysisCompleted::class, \Grafeas\V1\DiscoveryOccurrence_AnalysisCompleted::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisStatus.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisStatus.php new file mode 100644 index 00000000000..fcef24fb33a --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisStatus.php @@ -0,0 +1,94 @@ +grafeas.v1.DiscoveryOccurrence.AnalysisStatus + */ +class AnalysisStatus +{ + /** + * Unknown. + * + * Generated from protobuf enum ANALYSIS_STATUS_UNSPECIFIED = 0; + */ + const ANALYSIS_STATUS_UNSPECIFIED = 0; + /** + * Resource is known but no action has been taken yet. + * + * Generated from protobuf enum PENDING = 1; + */ + const PENDING = 1; + /** + * Resource is being analyzed. + * + * Generated from protobuf enum SCANNING = 2; + */ + const SCANNING = 2; + /** + * Analysis has finished successfully. + * + * Generated from protobuf enum FINISHED_SUCCESS = 3; + */ + const FINISHED_SUCCESS = 3; + /** + * Analysis has completed. + * + * Generated from protobuf enum COMPLETE = 3; + */ + const COMPLETE = 3; + /** + * Analysis has finished unsuccessfully, the analysis itself is in a bad + * state. + * + * Generated from protobuf enum FINISHED_FAILED = 4; + */ + const FINISHED_FAILED = 4; + /** + * The resource is known not to be supported. + * + * Generated from protobuf enum FINISHED_UNSUPPORTED = 5; + */ + const FINISHED_UNSUPPORTED = 5; + + private static $valueToName = [ + self::ANALYSIS_STATUS_UNSPECIFIED => 'ANALYSIS_STATUS_UNSPECIFIED', + self::PENDING => 'PENDING', + self::SCANNING => 'SCANNING', + self::FINISHED_SUCCESS => 'FINISHED_SUCCESS', + self::COMPLETE => 'COMPLETE', + self::FINISHED_FAILED => 'FINISHED_FAILED', + self::FINISHED_UNSUPPORTED => 'FINISHED_UNSUPPORTED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AnalysisStatus::class, \Grafeas\V1\DiscoveryOccurrence_AnalysisStatus::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/ContinuousAnalysis.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/ContinuousAnalysis.php new file mode 100644 index 00000000000..350c2fb7590 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/ContinuousAnalysis.php @@ -0,0 +1,64 @@ +grafeas.v1.DiscoveryOccurrence.ContinuousAnalysis + */ +class ContinuousAnalysis +{ + /** + * Unknown. + * + * Generated from protobuf enum CONTINUOUS_ANALYSIS_UNSPECIFIED = 0; + */ + const CONTINUOUS_ANALYSIS_UNSPECIFIED = 0; + /** + * The resource is continuously analyzed. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The resource is ignored for continuous analysis. + * + * Generated from protobuf enum INACTIVE = 2; + */ + const INACTIVE = 2; + + private static $valueToName = [ + self::CONTINUOUS_ANALYSIS_UNSPECIFIED => 'CONTINUOUS_ANALYSIS_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::INACTIVE => 'INACTIVE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ContinuousAnalysis::class, \Grafeas\V1\DiscoveryOccurrence_ContinuousAnalysis::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence_AnalysisCompleted.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence_AnalysisCompleted.php new file mode 100644 index 00000000000..8fb46b02d27 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence_AnalysisCompleted.php @@ -0,0 +1,16 @@ +grafeas.v1.Distribution + */ +class Distribution extends \Google\Protobuf\Internal\Message +{ + /** + * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) + * denoting the package manager version distributing a package. + * + * Generated from protobuf field string cpe_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $cpe_uri = ''; + /** + * The CPU architecture for which packages in this distribution channel were + * built. + * + * Generated from protobuf field .grafeas.v1.Architecture architecture = 2; + */ + protected $architecture = 0; + /** + * The latest available version of this package in this distribution channel. + * + * Generated from protobuf field .grafeas.v1.Version latest_version = 3; + */ + protected $latest_version = null; + /** + * A freeform string denoting the maintainer of this package. + * + * Generated from protobuf field string maintainer = 4; + */ + protected $maintainer = ''; + /** + * The distribution channel-specific homepage for this package. + * + * Generated from protobuf field string url = 5; + */ + protected $url = ''; + /** + * The distribution channel-specific description of this package. + * + * Generated from protobuf field string description = 6; + */ + protected $description = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $cpe_uri + * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) + * denoting the package manager version distributing a package. + * @type int $architecture + * The CPU architecture for which packages in this distribution channel were + * built. + * @type \Grafeas\V1\Version $latest_version + * The latest available version of this package in this distribution channel. + * @type string $maintainer + * A freeform string denoting the maintainer of this package. + * @type string $url + * The distribution channel-specific homepage for this package. + * @type string $description + * The distribution channel-specific description of this package. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Package::initOnce(); + parent::__construct($data); + } + + /** + * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) + * denoting the package manager version distributing a package. + * + * Generated from protobuf field string cpe_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getCpeUri() + { + return $this->cpe_uri; + } + + /** + * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) + * denoting the package manager version distributing a package. + * + * Generated from protobuf field string cpe_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->cpe_uri = $var; + + return $this; + } + + /** + * The CPU architecture for which packages in this distribution channel were + * built. + * + * Generated from protobuf field .grafeas.v1.Architecture architecture = 2; + * @return int + */ + public function getArchitecture() + { + return $this->architecture; + } + + /** + * The CPU architecture for which packages in this distribution channel were + * built. + * + * Generated from protobuf field .grafeas.v1.Architecture architecture = 2; + * @param int $var + * @return $this + */ + public function setArchitecture($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\Architecture::class); + $this->architecture = $var; + + return $this; + } + + /** + * The latest available version of this package in this distribution channel. + * + * Generated from protobuf field .grafeas.v1.Version latest_version = 3; + * @return \Grafeas\V1\Version|null + */ + public function getLatestVersion() + { + return $this->latest_version; + } + + public function hasLatestVersion() + { + return isset($this->latest_version); + } + + public function clearLatestVersion() + { + unset($this->latest_version); + } + + /** + * The latest available version of this package in this distribution channel. + * + * Generated from protobuf field .grafeas.v1.Version latest_version = 3; + * @param \Grafeas\V1\Version $var + * @return $this + */ + public function setLatestVersion($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); + $this->latest_version = $var; + + return $this; + } + + /** + * A freeform string denoting the maintainer of this package. + * + * Generated from protobuf field string maintainer = 4; + * @return string + */ + public function getMaintainer() + { + return $this->maintainer; + } + + /** + * A freeform string denoting the maintainer of this package. + * + * Generated from protobuf field string maintainer = 4; + * @param string $var + * @return $this + */ + public function setMaintainer($var) + { + GPBUtil::checkString($var, True); + $this->maintainer = $var; + + return $this; + } + + /** + * The distribution channel-specific homepage for this package. + * + * Generated from protobuf field string url = 5; + * @return string + */ + public function getUrl() + { + return $this->url; + } + + /** + * The distribution channel-specific homepage for this package. + * + * Generated from protobuf field string url = 5; + * @param string $var + * @return $this + */ + public function setUrl($var) + { + GPBUtil::checkString($var, True); + $this->url = $var; + + return $this; + } + + /** + * The distribution channel-specific description of this package. + * + * Generated from protobuf field string description = 6; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The distribution channel-specific description of this package. + * + * Generated from protobuf field string description = 6; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Envelope.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Envelope.php new file mode 100644 index 00000000000..17bcc1346ae --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Envelope.php @@ -0,0 +1,116 @@ +grafeas.v1.Envelope + */ +class Envelope extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field bytes payload = 1; + */ + protected $payload = ''; + /** + * Generated from protobuf field string payload_type = 2; + */ + protected $payload_type = ''; + /** + * Generated from protobuf field repeated .grafeas.v1.EnvelopeSignature signatures = 3; + */ + private $signatures; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $payload + * @type string $payload_type + * @type array<\Grafeas\V1\EnvelopeSignature>|\Google\Protobuf\Internal\RepeatedField $signatures + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Common::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field bytes payload = 1; + * @return string + */ + public function getPayload() + { + return $this->payload; + } + + /** + * Generated from protobuf field bytes payload = 1; + * @param string $var + * @return $this + */ + public function setPayload($var) + { + GPBUtil::checkString($var, False); + $this->payload = $var; + + return $this; + } + + /** + * Generated from protobuf field string payload_type = 2; + * @return string + */ + public function getPayloadType() + { + return $this->payload_type; + } + + /** + * Generated from protobuf field string payload_type = 2; + * @param string $var + * @return $this + */ + public function setPayloadType($var) + { + GPBUtil::checkString($var, True); + $this->payload_type = $var; + + return $this; + } + + /** + * Generated from protobuf field repeated .grafeas.v1.EnvelopeSignature signatures = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSignatures() + { + return $this->signatures; + } + + /** + * Generated from protobuf field repeated .grafeas.v1.EnvelopeSignature signatures = 3; + * @param array<\Grafeas\V1\EnvelopeSignature>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSignatures($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\EnvelopeSignature::class); + $this->signatures = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/EnvelopeSignature.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/EnvelopeSignature.php new file mode 100644 index 00000000000..61ebdc60fbc --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/EnvelopeSignature.php @@ -0,0 +1,85 @@ +grafeas.v1.EnvelopeSignature + */ +class EnvelopeSignature extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field bytes sig = 1; + */ + protected $sig = ''; + /** + * Generated from protobuf field string keyid = 2; + */ + protected $keyid = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $sig + * @type string $keyid + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Common::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field bytes sig = 1; + * @return string + */ + public function getSig() + { + return $this->sig; + } + + /** + * Generated from protobuf field bytes sig = 1; + * @param string $var + * @return $this + */ + public function setSig($var) + { + GPBUtil::checkString($var, False); + $this->sig = $var; + + return $this; + } + + /** + * Generated from protobuf field string keyid = 2; + * @return string + */ + public function getKeyid() + { + return $this->keyid; + } + + /** + * Generated from protobuf field string keyid = 2; + * @param string $var + * @return $this + */ + public function setKeyid($var) + { + GPBUtil::checkString($var, True); + $this->keyid = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileHashes.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileHashes.php new file mode 100644 index 00000000000..a24ab1da840 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileHashes.php @@ -0,0 +1,68 @@ +grafeas.v1.FileHashes + */ +class FileHashes extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Collection of file hashes. + * + * Generated from protobuf field repeated .grafeas.v1.Hash file_hash = 1; + */ + private $file_hash; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Grafeas\V1\Hash>|\Google\Protobuf\Internal\RepeatedField $file_hash + * Required. Collection of file hashes. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * Required. Collection of file hashes. + * + * Generated from protobuf field repeated .grafeas.v1.Hash file_hash = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFileHash() + { + return $this->file_hash; + } + + /** + * Required. Collection of file hashes. + * + * Generated from protobuf field repeated .grafeas.v1.Hash file_hash = 1; + * @param array<\Grafeas\V1\Hash>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFileHash($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Hash::class); + $this->file_hash = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileLocation.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileLocation.php new file mode 100644 index 00000000000..c7f6d9e7ccc --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileLocation.php @@ -0,0 +1,71 @@ +grafeas.v1.FileLocation + */ +class FileLocation extends \Google\Protobuf\Internal\Message +{ + /** + * For jars that are contained inside .war files, this filepath + * can indicate the path to war file combined with the path to jar file. + * + * Generated from protobuf field string file_path = 1; + */ + protected $file_path = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $file_path + * For jars that are contained inside .war files, this filepath + * can indicate the path to war file combined with the path to jar file. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Common::initOnce(); + parent::__construct($data); + } + + /** + * For jars that are contained inside .war files, this filepath + * can indicate the path to war file combined with the path to jar file. + * + * Generated from protobuf field string file_path = 1; + * @return string + */ + public function getFilePath() + { + return $this->file_path; + } + + /** + * For jars that are contained inside .war files, this filepath + * can indicate the path to war file combined with the path to jar file. + * + * Generated from protobuf field string file_path = 1; + * @param string $var + * @return $this + */ + public function setFilePath($var) + { + GPBUtil::checkString($var, True); + $this->file_path = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Fingerprint.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Fingerprint.php new file mode 100644 index 00000000000..7191d7383ef --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Fingerprint.php @@ -0,0 +1,151 @@ +grafeas.v1.Fingerprint + */ +class Fingerprint extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The layer ID of the final layer in the Docker image's v1 + * representation. + * + * Generated from protobuf field string v1_name = 1; + */ + protected $v1_name = ''; + /** + * Required. The ordered list of v2 blobs that represent a given image. + * + * Generated from protobuf field repeated string v2_blob = 2; + */ + private $v2_blob; + /** + * 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. + * + * Generated from protobuf field string v2_name = 3; + */ + protected $v2_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $v1_name + * Required. The layer ID of the final layer in the Docker image's v1 + * representation. + * @type array|\Google\Protobuf\Internal\RepeatedField $v2_blob + * Required. The ordered list of v2 blobs that represent a given image. + * @type string $v2_name + * 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Image::initOnce(); + parent::__construct($data); + } + + /** + * Required. The layer ID of the final layer in the Docker image's v1 + * representation. + * + * Generated from protobuf field string v1_name = 1; + * @return string + */ + public function getV1Name() + { + return $this->v1_name; + } + + /** + * Required. The layer ID of the final layer in the Docker image's v1 + * representation. + * + * Generated from protobuf field string v1_name = 1; + * @param string $var + * @return $this + */ + public function setV1Name($var) + { + GPBUtil::checkString($var, True); + $this->v1_name = $var; + + return $this; + } + + /** + * Required. The ordered list of v2 blobs that represent a given image. + * + * Generated from protobuf field repeated string v2_blob = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getV2Blob() + { + return $this->v2_blob; + } + + /** + * Required. The ordered list of v2 blobs that represent a given image. + * + * Generated from protobuf field repeated string v2_blob = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setV2Blob($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->v2_blob = $arr; + + 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. + * + * Generated from protobuf field string v2_name = 3; + * @return string + */ + public function getV2Name() + { + return $this->v2_name; + } + + /** + * 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. + * + * Generated from protobuf field string v2_name = 3; + * @param string $var + * @return $this + */ + public function setV2Name($var) + { + GPBUtil::checkString($var, True); + $this->v2_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GerritSourceContext.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GerritSourceContext.php new file mode 100644 index 00000000000..616fb62984a --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GerritSourceContext.php @@ -0,0 +1,184 @@ +grafeas.v1.GerritSourceContext + */ +class GerritSourceContext extends \Google\Protobuf\Internal\Message +{ + /** + * The URI of a running Gerrit instance. + * + * Generated from protobuf field string host_uri = 1; + */ + protected $host_uri = ''; + /** + * 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. + * + * Generated from protobuf field string gerrit_project = 2; + */ + protected $gerrit_project = ''; + protected $revision; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $host_uri + * The URI of a running Gerrit instance. + * @type string $gerrit_project + * 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. + * @type string $revision_id + * A revision (commit) ID. + * @type \Grafeas\V1\AliasContext $alias_context + * An alias, which may be a branch or tag. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * The URI of a running Gerrit instance. + * + * Generated from protobuf field string host_uri = 1; + * @return string + */ + public function getHostUri() + { + return $this->host_uri; + } + + /** + * The URI of a running Gerrit instance. + * + * Generated from protobuf field string host_uri = 1; + * @param string $var + * @return $this + */ + public function setHostUri($var) + { + GPBUtil::checkString($var, True); + $this->host_uri = $var; + + 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. + * + * Generated from protobuf field string gerrit_project = 2; + * @return string + */ + public function getGerritProject() + { + return $this->gerrit_project; + } + + /** + * 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. + * + * Generated from protobuf field string gerrit_project = 2; + * @param string $var + * @return $this + */ + public function setGerritProject($var) + { + GPBUtil::checkString($var, True); + $this->gerrit_project = $var; + + return $this; + } + + /** + * A revision (commit) ID. + * + * Generated from protobuf field string revision_id = 3; + * @return string + */ + public function getRevisionId() + { + return $this->readOneof(3); + } + + public function hasRevisionId() + { + return $this->hasOneof(3); + } + + /** + * A revision (commit) ID. + * + * Generated from protobuf field string revision_id = 3; + * @param string $var + * @return $this + */ + public function setRevisionId($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * An alias, which may be a branch or tag. + * + * Generated from protobuf field .grafeas.v1.AliasContext alias_context = 4; + * @return \Grafeas\V1\AliasContext|null + */ + public function getAliasContext() + { + return $this->readOneof(4); + } + + public function hasAliasContext() + { + return $this->hasOneof(4); + } + + /** + * An alias, which may be a branch or tag. + * + * Generated from protobuf field .grafeas.v1.AliasContext alias_context = 4; + * @param \Grafeas\V1\AliasContext $var + * @return $this + */ + public function setAliasContext($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\AliasContext::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getRevision() + { + return $this->whichOneof("revision"); + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetNoteRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetNoteRequest.php new file mode 100644 index 00000000000..1f34634c9e3 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetNoteRequest.php @@ -0,0 +1,71 @@ +grafeas.v1.GetNoteRequest + */ +class GetNoteRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceNoteRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceNoteRequest.php new file mode 100644 index 00000000000..16072c0db57 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceNoteRequest.php @@ -0,0 +1,71 @@ +grafeas.v1.GetOccurrenceNoteRequest + */ +class GetOccurrenceNoteRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceRequest.php new file mode 100644 index 00000000000..44e659ea0b8 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceRequest.php @@ -0,0 +1,71 @@ +grafeas.v1.GetOccurrenceRequest + */ +class GetOccurrenceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GitSourceContext.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GitSourceContext.php new file mode 100644 index 00000000000..6eb31ad84fe --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GitSourceContext.php @@ -0,0 +1,102 @@ +grafeas.v1.GitSourceContext + */ +class GitSourceContext extends \Google\Protobuf\Internal\Message +{ + /** + * Git repository URL. + * + * Generated from protobuf field string url = 1; + */ + protected $url = ''; + /** + * Git commit hash. + * + * Generated from protobuf field string revision_id = 2; + */ + protected $revision_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $url + * Git repository URL. + * @type string $revision_id + * Git commit hash. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * Git repository URL. + * + * Generated from protobuf field string url = 1; + * @return string + */ + public function getUrl() + { + return $this->url; + } + + /** + * Git repository URL. + * + * Generated from protobuf field string url = 1; + * @param string $var + * @return $this + */ + public function setUrl($var) + { + GPBUtil::checkString($var, True); + $this->url = $var; + + return $this; + } + + /** + * Git commit hash. + * + * Generated from protobuf field string revision_id = 2; + * @return string + */ + public function getRevisionId() + { + return $this->revision_id; + } + + /** + * Git commit hash. + * + * Generated from protobuf field string revision_id = 2; + * @param string $var + * @return $this + */ + public function setRevisionId($var) + { + GPBUtil::checkString($var, True); + $this->revision_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GrafeasGrpcClient.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GrafeasGrpcClient.php new file mode 100644 index 00000000000..5c3784661a8 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GrafeasGrpcClient.php @@ -0,0 +1,263 @@ +_simpleRequest('/grafeas.v1.Grafeas/GetOccurrence', + $argument, + ['\Grafeas\V1\Occurrence', 'decode'], + $metadata, $options); + } + + /** + * Lists occurrences for the specified project. + * @param \Grafeas\V1\ListOccurrencesRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function ListOccurrences(\Grafeas\V1\ListOccurrencesRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/ListOccurrences', + $argument, + ['\Grafeas\V1\ListOccurrencesResponse', 'decode'], + $metadata, $options); + } + + /** + * Deletes the specified occurrence. For example, use this method to delete an + * occurrence when the occurrence is no longer applicable for the given + * resource. + * @param \Grafeas\V1\DeleteOccurrenceRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function DeleteOccurrence(\Grafeas\V1\DeleteOccurrenceRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/DeleteOccurrence', + $argument, + ['\Google\Protobuf\GPBEmpty', 'decode'], + $metadata, $options); + } + + /** + * Creates a new occurrence. + * @param \Grafeas\V1\CreateOccurrenceRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function CreateOccurrence(\Grafeas\V1\CreateOccurrenceRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/CreateOccurrence', + $argument, + ['\Grafeas\V1\Occurrence', 'decode'], + $metadata, $options); + } + + /** + * Creates new occurrences in batch. + * @param \Grafeas\V1\BatchCreateOccurrencesRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function BatchCreateOccurrences(\Grafeas\V1\BatchCreateOccurrencesRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/BatchCreateOccurrences', + $argument, + ['\Grafeas\V1\BatchCreateOccurrencesResponse', 'decode'], + $metadata, $options); + } + + /** + * Updates the specified occurrence. + * @param \Grafeas\V1\UpdateOccurrenceRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function UpdateOccurrence(\Grafeas\V1\UpdateOccurrenceRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/UpdateOccurrence', + $argument, + ['\Grafeas\V1\Occurrence', 'decode'], + $metadata, $options); + } + + /** + * Gets the note attached to the specified occurrence. Consumer projects can + * use this method to get a note that belongs to a provider project. + * @param \Grafeas\V1\GetOccurrenceNoteRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function GetOccurrenceNote(\Grafeas\V1\GetOccurrenceNoteRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/GetOccurrenceNote', + $argument, + ['\Grafeas\V1\Note', 'decode'], + $metadata, $options); + } + + /** + * Gets the specified note. + * @param \Grafeas\V1\GetNoteRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function GetNote(\Grafeas\V1\GetNoteRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/GetNote', + $argument, + ['\Grafeas\V1\Note', 'decode'], + $metadata, $options); + } + + /** + * Lists notes for the specified project. + * @param \Grafeas\V1\ListNotesRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function ListNotes(\Grafeas\V1\ListNotesRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/ListNotes', + $argument, + ['\Grafeas\V1\ListNotesResponse', 'decode'], + $metadata, $options); + } + + /** + * Deletes the specified note. + * @param \Grafeas\V1\DeleteNoteRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function DeleteNote(\Grafeas\V1\DeleteNoteRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/DeleteNote', + $argument, + ['\Google\Protobuf\GPBEmpty', 'decode'], + $metadata, $options); + } + + /** + * Creates a new note. + * @param \Grafeas\V1\CreateNoteRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function CreateNote(\Grafeas\V1\CreateNoteRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/CreateNote', + $argument, + ['\Grafeas\V1\Note', 'decode'], + $metadata, $options); + } + + /** + * Creates new notes in batch. + * @param \Grafeas\V1\BatchCreateNotesRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function BatchCreateNotes(\Grafeas\V1\BatchCreateNotesRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/BatchCreateNotes', + $argument, + ['\Grafeas\V1\BatchCreateNotesResponse', 'decode'], + $metadata, $options); + } + + /** + * Updates the specified note. + * @param \Grafeas\V1\UpdateNoteRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function UpdateNote(\Grafeas\V1\UpdateNoteRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/UpdateNote', + $argument, + ['\Grafeas\V1\Note', 'decode'], + $metadata, $options); + } + + /** + * Lists occurrences referencing the specified note. Provider projects can use + * this method to get all occurrences across consumer projects referencing the + * specified note. + * @param \Grafeas\V1\ListNoteOccurrencesRequest $argument input argument + * @param array $metadata metadata + * @param array $options call options + * @return \Grpc\UnaryCall + */ + public function ListNoteOccurrences(\Grafeas\V1\ListNoteOccurrencesRequest $argument, + $metadata = [], $options = []) { + return $this->_simpleRequest('/grafeas.v1.Grafeas/ListNoteOccurrences', + $argument, + ['\Grafeas\V1\ListNoteOccurrencesResponse', 'decode'], + $metadata, $options); + } + +} diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Hash.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Hash.php new file mode 100644 index 00000000000..a6f6d1b8ae0 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Hash.php @@ -0,0 +1,101 @@ +grafeas.v1.Hash + */ +class Hash extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The type of hash that was performed, e.g. "SHA-256". + * + * Generated from protobuf field string type = 1; + */ + protected $type = ''; + /** + * Required. The hash value. + * + * Generated from protobuf field bytes value = 2; + */ + protected $value = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $type + * Required. The type of hash that was performed, e.g. "SHA-256". + * @type string $value + * Required. The hash value. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * Required. The type of hash that was performed, e.g. "SHA-256". + * + * Generated from protobuf field string type = 1; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * Required. The type of hash that was performed, e.g. "SHA-256". + * + * Generated from protobuf field string type = 1; + * @param string $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkString($var, True); + $this->type = $var; + + return $this; + } + + /** + * Required. The hash value. + * + * Generated from protobuf field bytes value = 2; + * @return string + */ + public function getValue() + { + return $this->value; + } + + /** + * Required. The hash value. + * + * Generated from protobuf field bytes value = 2; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, False); + $this->value = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageNote.php new file mode 100644 index 00000000000..661c9908716 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageNote.php @@ -0,0 +1,119 @@ + + * Or an equivalent reference, e.g., a tag of the resource_url. + * + * Generated from protobuf message grafeas.v1.ImageNote + */ +class ImageNote extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Immutable. The resource_url for the resource representing the + * basis of associated occurrence images. + * + * Generated from protobuf field string resource_url = 1; + */ + protected $resource_url = ''; + /** + * Required. Immutable. The fingerprint of the base image. + * + * Generated from protobuf field .grafeas.v1.Fingerprint fingerprint = 2; + */ + protected $fingerprint = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $resource_url + * Required. Immutable. The resource_url for the resource representing the + * basis of associated occurrence images. + * @type \Grafeas\V1\Fingerprint $fingerprint + * Required. Immutable. The fingerprint of the base image. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Image::initOnce(); + parent::__construct($data); + } + + /** + * Required. Immutable. The resource_url for the resource representing the + * basis of associated occurrence images. + * + * Generated from protobuf field string resource_url = 1; + * @return string + */ + public function getResourceUrl() + { + return $this->resource_url; + } + + /** + * Required. Immutable. The resource_url for the resource representing the + * basis of associated occurrence images. + * + * Generated from protobuf field string resource_url = 1; + * @param string $var + * @return $this + */ + public function setResourceUrl($var) + { + GPBUtil::checkString($var, True); + $this->resource_url = $var; + + return $this; + } + + /** + * Required. Immutable. The fingerprint of the base image. + * + * Generated from protobuf field .grafeas.v1.Fingerprint fingerprint = 2; + * @return \Grafeas\V1\Fingerprint|null + */ + public function getFingerprint() + { + return $this->fingerprint; + } + + public function hasFingerprint() + { + return isset($this->fingerprint); + } + + public function clearFingerprint() + { + unset($this->fingerprint); + } + + /** + * Required. Immutable. The fingerprint of the base image. + * + * Generated from protobuf field .grafeas.v1.Fingerprint fingerprint = 2; + * @param \Grafeas\V1\Fingerprint $var + * @return $this + */ + public function setFingerprint($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Fingerprint::class); + $this->fingerprint = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageOccurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageOccurrence.php new file mode 100644 index 00000000000..e6c64fc037e --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageOccurrence.php @@ -0,0 +1,197 @@ +. + * + * Generated from protobuf message grafeas.v1.ImageOccurrence + */ +class ImageOccurrence extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The fingerprint of the derived image. + * + * Generated from protobuf field .grafeas.v1.Fingerprint fingerprint = 1; + */ + protected $fingerprint = null; + /** + * Output only. The number of layers by which this image differs from the + * associated image basis. + * + * Generated from protobuf field int32 distance = 2; + */ + protected $distance = 0; + /** + * 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. + * + * Generated from protobuf field repeated .grafeas.v1.Layer layer_info = 3; + */ + private $layer_info; + /** + * Output only. This contains the base image URL for the derived image + * occurrence. + * + * Generated from protobuf field string base_resource_url = 4; + */ + protected $base_resource_url = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\Fingerprint $fingerprint + * Required. The fingerprint of the derived image. + * @type int $distance + * Output only. The number of layers by which this image differs from the + * associated image basis. + * @type array<\Grafeas\V1\Layer>|\Google\Protobuf\Internal\RepeatedField $layer_info + * 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. + * @type string $base_resource_url + * Output only. This contains the base image URL for the derived image + * occurrence. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Image::initOnce(); + parent::__construct($data); + } + + /** + * Required. The fingerprint of the derived image. + * + * Generated from protobuf field .grafeas.v1.Fingerprint fingerprint = 1; + * @return \Grafeas\V1\Fingerprint|null + */ + public function getFingerprint() + { + return $this->fingerprint; + } + + public function hasFingerprint() + { + return isset($this->fingerprint); + } + + public function clearFingerprint() + { + unset($this->fingerprint); + } + + /** + * Required. The fingerprint of the derived image. + * + * Generated from protobuf field .grafeas.v1.Fingerprint fingerprint = 1; + * @param \Grafeas\V1\Fingerprint $var + * @return $this + */ + public function setFingerprint($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Fingerprint::class); + $this->fingerprint = $var; + + return $this; + } + + /** + * Output only. The number of layers by which this image differs from the + * associated image basis. + * + * Generated from protobuf field int32 distance = 2; + * @return int + */ + public function getDistance() + { + return $this->distance; + } + + /** + * Output only. The number of layers by which this image differs from the + * associated image basis. + * + * Generated from protobuf field int32 distance = 2; + * @param int $var + * @return $this + */ + public function setDistance($var) + { + GPBUtil::checkInt32($var); + $this->distance = $var; + + 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. + * + * Generated from protobuf field repeated .grafeas.v1.Layer layer_info = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLayerInfo() + { + return $this->layer_info; + } + + /** + * 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. + * + * Generated from protobuf field repeated .grafeas.v1.Layer layer_info = 3; + * @param array<\Grafeas\V1\Layer>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLayerInfo($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Layer::class); + $this->layer_info = $arr; + + return $this; + } + + /** + * Output only. This contains the base image URL for the derived image + * occurrence. + * + * Generated from protobuf field string base_resource_url = 4; + * @return string + */ + public function getBaseResourceUrl() + { + return $this->base_resource_url; + } + + /** + * Output only. This contains the base image URL for the derived image + * occurrence. + * + * Generated from protobuf field string base_resource_url = 4; + * @param string $var + * @return $this + */ + public function setBaseResourceUrl($var) + { + GPBUtil::checkString($var, True); + $this->base_resource_url = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoProvenance.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoProvenance.php new file mode 100644 index 00000000000..74cc83a629c --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoProvenance.php @@ -0,0 +1,214 @@ +grafeas.v1.InTotoProvenance + */ +class InTotoProvenance extends \Google\Protobuf\Internal\Message +{ + /** + * required + * + * Generated from protobuf field .grafeas.v1.BuilderConfig builder_config = 1; + */ + protected $builder_config = null; + /** + * Identifies the configuration used for the build. + * When combined with materials, this SHOULD fully describe the build, + * such that re-running this recipe results in bit-for-bit identical output + * (if the build is reproducible). + * + * Generated from protobuf field .grafeas.v1.Recipe recipe = 2; + */ + protected $recipe = null; + /** + * Generated from protobuf field .grafeas.v1.Metadata metadata = 3; + */ + protected $metadata = null; + /** + * The collection of artifacts that influenced the build including sources, + * dependencies, build tools, base images, and so on. This is considered to be + * incomplete unless metadata.completeness.materials is true. Unset or null is + * equivalent to empty. + * + * Generated from protobuf field repeated string materials = 4; + */ + private $materials; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\BuilderConfig $builder_config + * required + * @type \Grafeas\V1\Recipe $recipe + * Identifies the configuration used for the build. + * When combined with materials, this SHOULD fully describe the build, + * such that re-running this recipe results in bit-for-bit identical output + * (if the build is reproducible). + * @type \Grafeas\V1\Metadata $metadata + * @type array|\Google\Protobuf\Internal\RepeatedField $materials + * The collection of artifacts that influenced the build including sources, + * dependencies, build tools, base images, and so on. This is considered to be + * incomplete unless metadata.completeness.materials is true. Unset or null is + * equivalent to empty. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\IntotoProvenance::initOnce(); + parent::__construct($data); + } + + /** + * required + * + * Generated from protobuf field .grafeas.v1.BuilderConfig builder_config = 1; + * @return \Grafeas\V1\BuilderConfig|null + */ + public function getBuilderConfig() + { + return $this->builder_config; + } + + public function hasBuilderConfig() + { + return isset($this->builder_config); + } + + public function clearBuilderConfig() + { + unset($this->builder_config); + } + + /** + * required + * + * Generated from protobuf field .grafeas.v1.BuilderConfig builder_config = 1; + * @param \Grafeas\V1\BuilderConfig $var + * @return $this + */ + public function setBuilderConfig($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\BuilderConfig::class); + $this->builder_config = $var; + + return $this; + } + + /** + * Identifies the configuration used for the build. + * When combined with materials, this SHOULD fully describe the build, + * such that re-running this recipe results in bit-for-bit identical output + * (if the build is reproducible). + * + * Generated from protobuf field .grafeas.v1.Recipe recipe = 2; + * @return \Grafeas\V1\Recipe|null + */ + public function getRecipe() + { + return $this->recipe; + } + + public function hasRecipe() + { + return isset($this->recipe); + } + + public function clearRecipe() + { + unset($this->recipe); + } + + /** + * Identifies the configuration used for the build. + * When combined with materials, this SHOULD fully describe the build, + * such that re-running this recipe results in bit-for-bit identical output + * (if the build is reproducible). + * + * Generated from protobuf field .grafeas.v1.Recipe recipe = 2; + * @param \Grafeas\V1\Recipe $var + * @return $this + */ + public function setRecipe($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Recipe::class); + $this->recipe = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.Metadata metadata = 3; + * @return \Grafeas\V1\Metadata|null + */ + public function getMetadata() + { + return $this->metadata; + } + + public function hasMetadata() + { + return isset($this->metadata); + } + + public function clearMetadata() + { + unset($this->metadata); + } + + /** + * Generated from protobuf field .grafeas.v1.Metadata metadata = 3; + * @param \Grafeas\V1\Metadata $var + * @return $this + */ + public function setMetadata($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Metadata::class); + $this->metadata = $var; + + return $this; + } + + /** + * The collection of artifacts that influenced the build including sources, + * dependencies, build tools, base images, and so on. This is considered to be + * incomplete unless metadata.completeness.materials is true. Unset or null is + * equivalent to empty. + * + * Generated from protobuf field repeated string materials = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMaterials() + { + return $this->materials; + } + + /** + * The collection of artifacts that influenced the build including sources, + * dependencies, build tools, base images, and so on. This is considered to be + * incomplete unless metadata.completeness.materials is true. Unset or null is + * equivalent to empty. + * + * Generated from protobuf field repeated string materials = 4; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMaterials($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->materials = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoStatement.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoStatement.php new file mode 100644 index 00000000000..93a86b0dd50 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoStatement.php @@ -0,0 +1,224 @@ +grafeas.v1.InTotoStatement + */ +class InTotoStatement extends \Google\Protobuf\Internal\Message +{ + /** + * Always `https://in-toto.io/Statement/v0.1`. + * + * Generated from protobuf field string type = 1 [json_name = "_type"]; + */ + protected $type = ''; + /** + * Generated from protobuf field repeated .grafeas.v1.Subject subject = 2; + */ + private $subject; + /** + * `https://slsa.dev/provenance/v0.1` for SlsaProvenance. + * + * Generated from protobuf field string predicate_type = 3; + */ + protected $predicate_type = ''; + protected $predicate; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $type + * Always `https://in-toto.io/Statement/v0.1`. + * @type array<\Grafeas\V1\Subject>|\Google\Protobuf\Internal\RepeatedField $subject + * @type string $predicate_type + * `https://slsa.dev/provenance/v0.1` for SlsaProvenance. + * @type \Grafeas\V1\InTotoProvenance $provenance + * @type \Grafeas\V1\SlsaProvenance $slsa_provenance + * @type \Grafeas\V1\SlsaProvenanceZeroTwo $slsa_provenance_zero_two + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\IntotoStatement::initOnce(); + parent::__construct($data); + } + + /** + * Always `https://in-toto.io/Statement/v0.1`. + * + * Generated from protobuf field string type = 1 [json_name = "_type"]; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * Always `https://in-toto.io/Statement/v0.1`. + * + * Generated from protobuf field string type = 1 [json_name = "_type"]; + * @param string $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkString($var, True); + $this->type = $var; + + return $this; + } + + /** + * Generated from protobuf field repeated .grafeas.v1.Subject subject = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSubject() + { + return $this->subject; + } + + /** + * Generated from protobuf field repeated .grafeas.v1.Subject subject = 2; + * @param array<\Grafeas\V1\Subject>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSubject($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Subject::class); + $this->subject = $arr; + + return $this; + } + + /** + * `https://slsa.dev/provenance/v0.1` for SlsaProvenance. + * + * Generated from protobuf field string predicate_type = 3; + * @return string + */ + public function getPredicateType() + { + return $this->predicate_type; + } + + /** + * `https://slsa.dev/provenance/v0.1` for SlsaProvenance. + * + * Generated from protobuf field string predicate_type = 3; + * @param string $var + * @return $this + */ + public function setPredicateType($var) + { + GPBUtil::checkString($var, True); + $this->predicate_type = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.InTotoProvenance provenance = 4; + * @return \Grafeas\V1\InTotoProvenance|null + */ + public function getProvenance() + { + return $this->readOneof(4); + } + + public function hasProvenance() + { + return $this->hasOneof(4); + } + + /** + * Generated from protobuf field .grafeas.v1.InTotoProvenance provenance = 4; + * @param \Grafeas\V1\InTotoProvenance $var + * @return $this + */ + public function setProvenance($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\InTotoProvenance::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenance slsa_provenance = 5; + * @return \Grafeas\V1\SlsaProvenance|null + */ + public function getSlsaProvenance() + { + return $this->readOneof(5); + } + + public function hasSlsaProvenance() + { + return $this->hasOneof(5); + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenance slsa_provenance = 5; + * @param \Grafeas\V1\SlsaProvenance $var + * @return $this + */ + public function setSlsaProvenance($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenance::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo slsa_provenance_zero_two = 6; + * @return \Grafeas\V1\SlsaProvenanceZeroTwo|null + */ + public function getSlsaProvenanceZeroTwo() + { + return $this->readOneof(6); + } + + public function hasSlsaProvenanceZeroTwo() + { + return $this->hasOneof(6); + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo slsa_provenance_zero_two = 6; + * @param \Grafeas\V1\SlsaProvenanceZeroTwo $var + * @return $this + */ + public function setSlsaProvenanceZeroTwo($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenanceZeroTwo::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * @return string + */ + public function getPredicate() + { + return $this->whichOneof("predicate"); + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Jwt.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Jwt.php new file mode 100644 index 00000000000..3b9e9a5ece4 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Jwt.php @@ -0,0 +1,73 @@ +grafeas.v1.Jwt + */ +class Jwt extends \Google\Protobuf\Internal\Message +{ + /** + * The compact encoding of a JWS, which is always three base64 encoded strings + * joined by periods. For details, see: + * https://tools.ietf.org/html/rfc7515.html#section-3.1 + * + * Generated from protobuf field string compact_jwt = 1; + */ + protected $compact_jwt = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $compact_jwt + * The compact encoding of a JWS, which is always three base64 encoded strings + * joined by periods. For details, see: + * https://tools.ietf.org/html/rfc7515.html#section-3.1 + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Attestation::initOnce(); + parent::__construct($data); + } + + /** + * The compact encoding of a JWS, which is always three base64 encoded strings + * joined by periods. For details, see: + * https://tools.ietf.org/html/rfc7515.html#section-3.1 + * + * Generated from protobuf field string compact_jwt = 1; + * @return string + */ + public function getCompactJwt() + { + return $this->compact_jwt; + } + + /** + * The compact encoding of a JWS, which is always three base64 encoded strings + * joined by periods. For details, see: + * https://tools.ietf.org/html/rfc7515.html#section-3.1 + * + * Generated from protobuf field string compact_jwt = 1; + * @param string $var + * @return $this + */ + public function setCompactJwt($var) + { + GPBUtil::checkString($var, True); + $this->compact_jwt = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Layer.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Layer.php new file mode 100644 index 00000000000..429ce63f2c3 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Layer.php @@ -0,0 +1,105 @@ +grafeas.v1.Layer + */ +class Layer extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The recovered Dockerfile directive used to construct this layer. + * See https://docs.docker.com/engine/reference/builder/ for more information. + * + * Generated from protobuf field string directive = 1; + */ + protected $directive = ''; + /** + * The recovered arguments to the Dockerfile directive. + * + * Generated from protobuf field string arguments = 2; + */ + protected $arguments = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $directive + * Required. The recovered Dockerfile directive used to construct this layer. + * See https://docs.docker.com/engine/reference/builder/ for more information. + * @type string $arguments + * The recovered arguments to the Dockerfile directive. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Image::initOnce(); + parent::__construct($data); + } + + /** + * Required. The recovered Dockerfile directive used to construct this layer. + * See https://docs.docker.com/engine/reference/builder/ for more information. + * + * Generated from protobuf field string directive = 1; + * @return string + */ + public function getDirective() + { + return $this->directive; + } + + /** + * Required. The recovered Dockerfile directive used to construct this layer. + * See https://docs.docker.com/engine/reference/builder/ for more information. + * + * Generated from protobuf field string directive = 1; + * @param string $var + * @return $this + */ + public function setDirective($var) + { + GPBUtil::checkString($var, True); + $this->directive = $var; + + return $this; + } + + /** + * The recovered arguments to the Dockerfile directive. + * + * Generated from protobuf field string arguments = 2; + * @return string + */ + public function getArguments() + { + return $this->arguments; + } + + /** + * The recovered arguments to the Dockerfile directive. + * + * Generated from protobuf field string arguments = 2; + * @param string $var + * @return $this + */ + public function setArguments($var) + { + GPBUtil::checkString($var, True); + $this->arguments = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/License.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/License.php new file mode 100644 index 00000000000..cf2409f0739 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/License.php @@ -0,0 +1,117 @@ +grafeas.v1.License + */ +class License extends \Google\Protobuf\Internal\Message +{ + /** + * Often a single license can be used to represent the licensing terms. + * Sometimes it is necessary to include a choice of one or more licenses + * or some combination of license identifiers. + * Examples: "LGPL-2.1-only OR MIT", "LGPL-2.1-only AND MIT", + * "GPL-2.0-or-later WITH Bison-exception-2.2". + * + * Generated from protobuf field string expression = 1; + */ + protected $expression = ''; + /** + * Comments + * + * Generated from protobuf field string comments = 2; + */ + protected $comments = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $expression + * Often a single license can be used to represent the licensing terms. + * Sometimes it is necessary to include a choice of one or more licenses + * or some combination of license identifiers. + * Examples: "LGPL-2.1-only OR MIT", "LGPL-2.1-only AND MIT", + * "GPL-2.0-or-later WITH Bison-exception-2.2". + * @type string $comments + * Comments + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Common::initOnce(); + parent::__construct($data); + } + + /** + * Often a single license can be used to represent the licensing terms. + * Sometimes it is necessary to include a choice of one or more licenses + * or some combination of license identifiers. + * Examples: "LGPL-2.1-only OR MIT", "LGPL-2.1-only AND MIT", + * "GPL-2.0-or-later WITH Bison-exception-2.2". + * + * Generated from protobuf field string expression = 1; + * @return string + */ + public function getExpression() + { + return $this->expression; + } + + /** + * Often a single license can be used to represent the licensing terms. + * Sometimes it is necessary to include a choice of one or more licenses + * or some combination of license identifiers. + * Examples: "LGPL-2.1-only OR MIT", "LGPL-2.1-only AND MIT", + * "GPL-2.0-or-later WITH Bison-exception-2.2". + * + * Generated from protobuf field string expression = 1; + * @param string $var + * @return $this + */ + public function setExpression($var) + { + GPBUtil::checkString($var, True); + $this->expression = $var; + + return $this; + } + + /** + * Comments + * + * Generated from protobuf field string comments = 2; + * @return string + */ + public function getComments() + { + return $this->comments; + } + + /** + * Comments + * + * Generated from protobuf field string comments = 2; + * @param string $var + * @return $this + */ + public function setComments($var) + { + GPBUtil::checkString($var, True); + $this->comments = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesRequest.php new file mode 100644 index 00000000000..2a4ff134f9e --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesRequest.php @@ -0,0 +1,173 @@ +grafeas.v1.ListNoteOccurrencesRequest + */ +class ListNoteOccurrencesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the note to list occurrences for in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * The filter expression. + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Number of occurrences to return in the list. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + /** + * Token to provide to skip to a particular spot in the list. + * + * Generated from protobuf field string page_token = 4; + */ + protected $page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the note to list occurrences for in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * @type string $filter + * The filter expression. + * @type int $page_size + * Number of occurrences to return in the list. + * @type string $page_token + * Token to provide to skip to a particular spot in the list. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the note to list occurrences for in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the note to list occurrences for in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The filter expression. + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * The filter expression. + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Number of occurrences to return in the list. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Number of occurrences to return in the list. + * + * Generated from protobuf field int32 page_size = 3; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * Token to provide to skip to a particular spot in the list. + * + * Generated from protobuf field string page_token = 4; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Token to provide to skip to a particular spot in the list. + * + * Generated from protobuf field string page_token = 4; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesResponse.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesResponse.php new file mode 100644 index 00000000000..d76a8a59df9 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesResponse.php @@ -0,0 +1,101 @@ +grafeas.v1.ListNoteOccurrencesResponse + */ +class ListNoteOccurrencesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The occurrences attached to the specified note. + * + * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; + */ + private $occurrences; + /** + * Token to provide to skip to a particular spot in the list. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $occurrences + * The occurrences attached to the specified note. + * @type string $next_page_token + * Token to provide to skip to a particular spot in the list. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The occurrences attached to the specified note. + * + * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOccurrences() + { + return $this->occurrences; + } + + /** + * The occurrences attached to the specified note. + * + * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; + * @param array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOccurrences($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Occurrence::class); + $this->occurrences = $arr; + + return $this; + } + + /** + * Token to provide to skip to a particular spot in the list. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to provide to skip to a particular spot in the list. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesRequest.php new file mode 100644 index 00000000000..79a61227145 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesRequest.php @@ -0,0 +1,177 @@ +grafeas.v1.ListNotesRequest + */ +class ListNotesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the project to list notes for in the form of + * `projects/[PROJECT_ID]`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The filter expression. + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Number of notes to return in the list. Must be positive. Max allowed page + * size is 1000. If not specified, page size defaults to 20. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + /** + * Token to provide to skip to a particular spot in the list. + * + * Generated from protobuf field string page_token = 4; + */ + protected $page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * The name of the project to list notes for in the form of + * `projects/[PROJECT_ID]`. + * @type string $filter + * The filter expression. + * @type int $page_size + * Number of notes to return in the list. Must be positive. Max allowed page + * size is 1000. If not specified, page size defaults to 20. + * @type string $page_token + * Token to provide to skip to a particular spot in the list. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the project to list notes for in the form of + * `projects/[PROJECT_ID]`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The name of the project to list notes for in the form of + * `projects/[PROJECT_ID]`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The filter expression. + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * The filter expression. + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Number of notes to return in the list. Must be positive. Max allowed page + * size is 1000. If not specified, page size defaults to 20. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Number of notes to return in the list. Must be positive. Max allowed page + * size is 1000. If not specified, page size defaults to 20. + * + * Generated from protobuf field int32 page_size = 3; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * Token to provide to skip to a particular spot in the list. + * + * Generated from protobuf field string page_token = 4; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Token to provide to skip to a particular spot in the list. + * + * Generated from protobuf field string page_token = 4; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesResponse.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesResponse.php new file mode 100644 index 00000000000..22c8bc22a25 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesResponse.php @@ -0,0 +1,109 @@ +grafeas.v1.ListNotesResponse + */ +class ListNotesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The notes requested. + * + * Generated from protobuf field repeated .grafeas.v1.Note notes = 1; + */ + private $notes; + /** + * 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. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Grafeas\V1\Note>|\Google\Protobuf\Internal\RepeatedField $notes + * The notes requested. + * @type string $next_page_token + * 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The notes requested. + * + * Generated from protobuf field repeated .grafeas.v1.Note notes = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNotes() + { + return $this->notes; + } + + /** + * The notes requested. + * + * Generated from protobuf field repeated .grafeas.v1.Note notes = 1; + * @param array<\Grafeas\V1\Note>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNotes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Note::class); + $this->notes = $arr; + + 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. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * 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. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesRequest.php new file mode 100644 index 00000000000..e6fb4083763 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesRequest.php @@ -0,0 +1,177 @@ +grafeas.v1.ListOccurrencesRequest + */ +class ListOccurrencesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the project to list occurrences for in the form of + * `projects/[PROJECT_ID]`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The filter expression. + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Number of occurrences to return in the list. Must be positive. Max allowed + * page size is 1000. If not specified, page size defaults to 20. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + /** + * Token to provide to skip to a particular spot in the list. + * + * Generated from protobuf field string page_token = 4; + */ + protected $page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * The name of the project to list occurrences for in the form of + * `projects/[PROJECT_ID]`. + * @type string $filter + * The filter expression. + * @type int $page_size + * Number of occurrences to return in the list. Must be positive. Max allowed + * page size is 1000. If not specified, page size defaults to 20. + * @type string $page_token + * Token to provide to skip to a particular spot in the list. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the project to list occurrences for in the form of + * `projects/[PROJECT_ID]`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The name of the project to list occurrences for in the form of + * `projects/[PROJECT_ID]`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The filter expression. + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * The filter expression. + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Number of occurrences to return in the list. Must be positive. Max allowed + * page size is 1000. If not specified, page size defaults to 20. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Number of occurrences to return in the list. Must be positive. Max allowed + * page size is 1000. If not specified, page size defaults to 20. + * + * Generated from protobuf field int32 page_size = 3; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * Token to provide to skip to a particular spot in the list. + * + * Generated from protobuf field string page_token = 4; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Token to provide to skip to a particular spot in the list. + * + * Generated from protobuf field string page_token = 4; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesResponse.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesResponse.php new file mode 100644 index 00000000000..c698cc7476a --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesResponse.php @@ -0,0 +1,109 @@ +grafeas.v1.ListOccurrencesResponse + */ +class ListOccurrencesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The occurrences requested. + * + * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; + */ + private $occurrences; + /** + * 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. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $occurrences + * The occurrences requested. + * @type string $next_page_token + * 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The occurrences requested. + * + * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOccurrences() + { + return $this->occurrences; + } + + /** + * The occurrences requested. + * + * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; + * @param array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOccurrences($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Occurrence::class); + $this->occurrences = $arr; + + 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. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * 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. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Location.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Location.php new file mode 100644 index 00000000000..b8381eca4d4 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Location.php @@ -0,0 +1,154 @@ +grafeas.v1.Location + */ +class Location extends \Google\Protobuf\Internal\Message +{ + /** + * Deprecated. + * The CPE URI in [CPE format](https://cpe.mitre.org/specification/) + * + * Generated from protobuf field string cpe_uri = 1; + */ + protected $cpe_uri = ''; + /** + * Deprecated. + * The version installed at this location. + * + * Generated from protobuf field .grafeas.v1.Version version = 2; + */ + protected $version = null; + /** + * The path from which we gathered that this package/version is installed. + * + * Generated from protobuf field string path = 3; + */ + protected $path = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $cpe_uri + * Deprecated. + * The CPE URI in [CPE format](https://cpe.mitre.org/specification/) + * @type \Grafeas\V1\Version $version + * Deprecated. + * The version installed at this location. + * @type string $path + * The path from which we gathered that this package/version is installed. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Package::initOnce(); + parent::__construct($data); + } + + /** + * Deprecated. + * The CPE URI in [CPE format](https://cpe.mitre.org/specification/) + * + * Generated from protobuf field string cpe_uri = 1; + * @return string + */ + public function getCpeUri() + { + return $this->cpe_uri; + } + + /** + * Deprecated. + * The CPE URI in [CPE format](https://cpe.mitre.org/specification/) + * + * Generated from protobuf field string cpe_uri = 1; + * @param string $var + * @return $this + */ + public function setCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->cpe_uri = $var; + + return $this; + } + + /** + * Deprecated. + * The version installed at this location. + * + * Generated from protobuf field .grafeas.v1.Version version = 2; + * @return \Grafeas\V1\Version|null + */ + public function getVersion() + { + return $this->version; + } + + public function hasVersion() + { + return isset($this->version); + } + + public function clearVersion() + { + unset($this->version); + } + + /** + * Deprecated. + * The version installed at this location. + * + * Generated from protobuf field .grafeas.v1.Version version = 2; + * @param \Grafeas\V1\Version $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); + $this->version = $var; + + return $this; + } + + /** + * The path from which we gathered that this package/version is installed. + * + * Generated from protobuf field string path = 3; + * @return string + */ + public function getPath() + { + return $this->path; + } + + /** + * The path from which we gathered that this package/version is installed. + * + * Generated from protobuf field string path = 3; + * @param string $var + * @return $this + */ + public function setPath($var) + { + GPBUtil::checkString($var, True); + $this->path = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Metadata.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Metadata.php new file mode 100644 index 00000000000..496b347e8c5 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Metadata.php @@ -0,0 +1,249 @@ +grafeas.v1.Metadata + */ +class Metadata extends \Google\Protobuf\Internal\Message +{ + /** + * Identifies the particular build invocation, which can be useful for finding + * associated logs or other ad-hoc analysis. The value SHOULD be globally + * unique, per in-toto Provenance spec. + * + * Generated from protobuf field string build_invocation_id = 1; + */ + protected $build_invocation_id = ''; + /** + * The timestamp of when the build started. + * + * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; + */ + protected $build_started_on = null; + /** + * The timestamp of when the build completed. + * + * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; + */ + protected $build_finished_on = null; + /** + * Indicates that the builder claims certain fields in this message to be + * complete. + * + * Generated from protobuf field .grafeas.v1.Completeness completeness = 4; + */ + protected $completeness = null; + /** + * If true, the builder claims that running the recipe on materials will + * produce bit-for-bit identical output. + * + * Generated from protobuf field bool reproducible = 5; + */ + protected $reproducible = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $build_invocation_id + * Identifies the particular build invocation, which can be useful for finding + * associated logs or other ad-hoc analysis. The value SHOULD be globally + * unique, per in-toto Provenance spec. + * @type \Google\Protobuf\Timestamp $build_started_on + * The timestamp of when the build started. + * @type \Google\Protobuf\Timestamp $build_finished_on + * The timestamp of when the build completed. + * @type \Grafeas\V1\Completeness $completeness + * Indicates that the builder claims certain fields in this message to be + * complete. + * @type bool $reproducible + * If true, the builder claims that running the recipe on materials will + * produce bit-for-bit identical output. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\IntotoProvenance::initOnce(); + parent::__construct($data); + } + + /** + * Identifies the particular build invocation, which can be useful for finding + * associated logs or other ad-hoc analysis. The value SHOULD be globally + * unique, per in-toto Provenance spec. + * + * Generated from protobuf field string build_invocation_id = 1; + * @return string + */ + public function getBuildInvocationId() + { + return $this->build_invocation_id; + } + + /** + * Identifies the particular build invocation, which can be useful for finding + * associated logs or other ad-hoc analysis. The value SHOULD be globally + * unique, per in-toto Provenance spec. + * + * Generated from protobuf field string build_invocation_id = 1; + * @param string $var + * @return $this + */ + public function setBuildInvocationId($var) + { + GPBUtil::checkString($var, True); + $this->build_invocation_id = $var; + + return $this; + } + + /** + * The timestamp of when the build started. + * + * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getBuildStartedOn() + { + return $this->build_started_on; + } + + public function hasBuildStartedOn() + { + return isset($this->build_started_on); + } + + public function clearBuildStartedOn() + { + unset($this->build_started_on); + } + + /** + * The timestamp of when the build started. + * + * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setBuildStartedOn($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->build_started_on = $var; + + return $this; + } + + /** + * The timestamp of when the build completed. + * + * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; + * @return \Google\Protobuf\Timestamp|null + */ + public function getBuildFinishedOn() + { + return $this->build_finished_on; + } + + public function hasBuildFinishedOn() + { + return isset($this->build_finished_on); + } + + public function clearBuildFinishedOn() + { + unset($this->build_finished_on); + } + + /** + * The timestamp of when the build completed. + * + * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setBuildFinishedOn($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->build_finished_on = $var; + + return $this; + } + + /** + * Indicates that the builder claims certain fields in this message to be + * complete. + * + * Generated from protobuf field .grafeas.v1.Completeness completeness = 4; + * @return \Grafeas\V1\Completeness|null + */ + public function getCompleteness() + { + return $this->completeness; + } + + public function hasCompleteness() + { + return isset($this->completeness); + } + + public function clearCompleteness() + { + unset($this->completeness); + } + + /** + * Indicates that the builder claims certain fields in this message to be + * complete. + * + * Generated from protobuf field .grafeas.v1.Completeness completeness = 4; + * @param \Grafeas\V1\Completeness $var + * @return $this + */ + public function setCompleteness($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Completeness::class); + $this->completeness = $var; + + return $this; + } + + /** + * If true, the builder claims that running the recipe on materials will + * produce bit-for-bit identical output. + * + * Generated from protobuf field bool reproducible = 5; + * @return bool + */ + public function getReproducible() + { + return $this->reproducible; + } + + /** + * If true, the builder claims that running the recipe on materials will + * produce bit-for-bit identical output. + * + * Generated from protobuf field bool reproducible = 5; + * @param bool $var + * @return $this + */ + public function setReproducible($var) + { + GPBUtil::checkBool($var); + $this->reproducible = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NonCompliantFile.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NonCompliantFile.php new file mode 100644 index 00000000000..db2f7ae1e2f --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NonCompliantFile.php @@ -0,0 +1,135 @@ +grafeas.v1.NonCompliantFile + */ +class NonCompliantFile extends \Google\Protobuf\Internal\Message +{ + /** + * Empty if `display_command` is set. + * + * Generated from protobuf field string path = 1; + */ + protected $path = ''; + /** + * Command to display the non-compliant files. + * + * Generated from protobuf field string display_command = 2; + */ + protected $display_command = ''; + /** + * Explains why a file is non compliant for a CIS check. + * + * Generated from protobuf field string reason = 3; + */ + protected $reason = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $path + * Empty if `display_command` is set. + * @type string $display_command + * Command to display the non-compliant files. + * @type string $reason + * Explains why a file is non compliant for a CIS check. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Compliance::initOnce(); + parent::__construct($data); + } + + /** + * Empty if `display_command` is set. + * + * Generated from protobuf field string path = 1; + * @return string + */ + public function getPath() + { + return $this->path; + } + + /** + * Empty if `display_command` is set. + * + * Generated from protobuf field string path = 1; + * @param string $var + * @return $this + */ + public function setPath($var) + { + GPBUtil::checkString($var, True); + $this->path = $var; + + return $this; + } + + /** + * Command to display the non-compliant files. + * + * Generated from protobuf field string display_command = 2; + * @return string + */ + public function getDisplayCommand() + { + return $this->display_command; + } + + /** + * Command to display the non-compliant files. + * + * Generated from protobuf field string display_command = 2; + * @param string $var + * @return $this + */ + public function setDisplayCommand($var) + { + GPBUtil::checkString($var, True); + $this->display_command = $var; + + return $this; + } + + /** + * Explains why a file is non compliant for a CIS check. + * + * Generated from protobuf field string reason = 3; + * @return string + */ + public function getReason() + { + return $this->reason; + } + + /** + * Explains why a file is non compliant for a CIS check. + * + * Generated from protobuf field string reason = 3; + * @param string $var + * @return $this + */ + public function setReason($var) + { + GPBUtil::checkString($var, True); + $this->reason = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Note.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Note.php new file mode 100644 index 00000000000..1ca897a111f --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Note.php @@ -0,0 +1,757 @@ +grafeas.v1.Note + */ +class Note extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * A one sentence description of this note. + * + * Generated from protobuf field string short_description = 2; + */ + protected $short_description = ''; + /** + * A detailed description of this note. + * + * Generated from protobuf field string long_description = 3; + */ + protected $long_description = ''; + /** + * Output only. The type of analysis. This field can be used as a filter in + * list requests. + * + * Generated from protobuf field .grafeas.v1.NoteKind kind = 4; + */ + protected $kind = 0; + /** + * URLs associated with this note. + * + * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_url = 5; + */ + private $related_url; + /** + * Time of expiration for this note. Empty if note does not expire. + * + * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 6; + */ + protected $expiration_time = null; + /** + * Output only. The time this note was created. This field can be used as a + * filter in list requests. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7; + */ + protected $create_time = null; + /** + * Output only. The time this note was last updated. This field can be used as + * a filter in list requests. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 8; + */ + protected $update_time = null; + /** + * Other notes related to this note. + * + * Generated from protobuf field repeated string related_note_names = 9; + */ + private $related_note_names; + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * @type string $short_description + * A one sentence description of this note. + * @type string $long_description + * A detailed description of this note. + * @type int $kind + * Output only. The type of analysis. This field can be used as a filter in + * list requests. + * @type array<\Grafeas\V1\RelatedUrl>|\Google\Protobuf\Internal\RepeatedField $related_url + * URLs associated with this note. + * @type \Google\Protobuf\Timestamp $expiration_time + * Time of expiration for this note. Empty if note does not expire. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The time this note was created. This field can be used as a + * filter in list requests. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The time this note was last updated. This field can be used as + * a filter in list requests. + * @type array|\Google\Protobuf\Internal\RepeatedField $related_note_names + * Other notes related to this note. + * @type \Grafeas\V1\VulnerabilityNote $vulnerability + * A note describing a package vulnerability. + * @type \Grafeas\V1\BuildNote $build + * A note describing build provenance for a verifiable build. + * @type \Grafeas\V1\ImageNote $image + * A note describing a base image. + * @type \Grafeas\V1\PackageNote $package + * A note describing a package hosted by various package managers. + * @type \Grafeas\V1\DeploymentNote $deployment + * A note describing something that can be deployed. + * @type \Grafeas\V1\DiscoveryNote $discovery + * A note describing the initial analysis of a resource. + * @type \Grafeas\V1\AttestationNote $attestation + * A note describing an attestation role. + * @type \Grafeas\V1\UpgradeNote $upgrade + * A note describing available package upgrades. + * @type \Grafeas\V1\ComplianceNote $compliance + * A note describing a compliance check. + * @type \Grafeas\V1\DSSEAttestationNote $dsse_attestation + * A note describing a dsse attestation note. + * @type \Grafeas\V1\VulnerabilityAssessmentNote $vulnerability_assessment + * A note describing a vulnerability assessment. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * A one sentence description of this note. + * + * Generated from protobuf field string short_description = 2; + * @return string + */ + public function getShortDescription() + { + return $this->short_description; + } + + /** + * A one sentence description of this note. + * + * Generated from protobuf field string short_description = 2; + * @param string $var + * @return $this + */ + public function setShortDescription($var) + { + GPBUtil::checkString($var, True); + $this->short_description = $var; + + return $this; + } + + /** + * A detailed description of this note. + * + * Generated from protobuf field string long_description = 3; + * @return string + */ + public function getLongDescription() + { + return $this->long_description; + } + + /** + * A detailed description of this note. + * + * Generated from protobuf field string long_description = 3; + * @param string $var + * @return $this + */ + public function setLongDescription($var) + { + GPBUtil::checkString($var, True); + $this->long_description = $var; + + return $this; + } + + /** + * Output only. The type of analysis. This field can be used as a filter in + * list requests. + * + * Generated from protobuf field .grafeas.v1.NoteKind kind = 4; + * @return int + */ + public function getKind() + { + return $this->kind; + } + + /** + * Output only. The type of analysis. This field can be used as a filter in + * list requests. + * + * Generated from protobuf field .grafeas.v1.NoteKind kind = 4; + * @param int $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\NoteKind::class); + $this->kind = $var; + + return $this; + } + + /** + * URLs associated with this note. + * + * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_url = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRelatedUrl() + { + return $this->related_url; + } + + /** + * URLs associated with this note. + * + * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_url = 5; + * @param array<\Grafeas\V1\RelatedUrl>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRelatedUrl($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\RelatedUrl::class); + $this->related_url = $arr; + + return $this; + } + + /** + * Time of expiration for this note. Empty if note does not expire. + * + * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 6; + * @return \Google\Protobuf\Timestamp|null + */ + public function getExpirationTime() + { + return $this->expiration_time; + } + + public function hasExpirationTime() + { + return isset($this->expiration_time); + } + + public function clearExpirationTime() + { + unset($this->expiration_time); + } + + /** + * Time of expiration for this note. Empty if note does not expire. + * + * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 6; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setExpirationTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->expiration_time = $var; + + return $this; + } + + /** + * Output only. The time this note was created. This field can be used as a + * filter in list requests. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * Output only. The time this note was created. This field can be used as a + * filter in list requests. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * Output only. The time this note was last updated. This field can be used as + * a filter in list requests. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 8; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUpdateTime() + { + return $this->update_time; + } + + public function hasUpdateTime() + { + return isset($this->update_time); + } + + public function clearUpdateTime() + { + unset($this->update_time); + } + + /** + * Output only. The time this note was last updated. This field can be used as + * a filter in list requests. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 8; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Other notes related to this note. + * + * Generated from protobuf field repeated string related_note_names = 9; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRelatedNoteNames() + { + return $this->related_note_names; + } + + /** + * Other notes related to this note. + * + * Generated from protobuf field repeated string related_note_names = 9; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRelatedNoteNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->related_note_names = $arr; + + return $this; + } + + /** + * A note describing a package vulnerability. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityNote vulnerability = 10; + * @return \Grafeas\V1\VulnerabilityNote|null + */ + public function getVulnerability() + { + return $this->readOneof(10); + } + + public function hasVulnerability() + { + return $this->hasOneof(10); + } + + /** + * A note describing a package vulnerability. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityNote vulnerability = 10; + * @param \Grafeas\V1\VulnerabilityNote $var + * @return $this + */ + public function setVulnerability($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityNote::class); + $this->writeOneof(10, $var); + + return $this; + } + + /** + * A note describing build provenance for a verifiable build. + * + * Generated from protobuf field .grafeas.v1.BuildNote build = 11; + * @return \Grafeas\V1\BuildNote|null + */ + public function getBuild() + { + return $this->readOneof(11); + } + + public function hasBuild() + { + return $this->hasOneof(11); + } + + /** + * A note describing build provenance for a verifiable build. + * + * Generated from protobuf field .grafeas.v1.BuildNote build = 11; + * @param \Grafeas\V1\BuildNote $var + * @return $this + */ + public function setBuild($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\BuildNote::class); + $this->writeOneof(11, $var); + + return $this; + } + + /** + * A note describing a base image. + * + * Generated from protobuf field .grafeas.v1.ImageNote image = 12; + * @return \Grafeas\V1\ImageNote|null + */ + public function getImage() + { + return $this->readOneof(12); + } + + public function hasImage() + { + return $this->hasOneof(12); + } + + /** + * A note describing a base image. + * + * Generated from protobuf field .grafeas.v1.ImageNote image = 12; + * @param \Grafeas\V1\ImageNote $var + * @return $this + */ + public function setImage($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\ImageNote::class); + $this->writeOneof(12, $var); + + return $this; + } + + /** + * A note describing a package hosted by various package managers. + * + * Generated from protobuf field .grafeas.v1.PackageNote package = 13; + * @return \Grafeas\V1\PackageNote|null + */ + public function getPackage() + { + return $this->readOneof(13); + } + + public function hasPackage() + { + return $this->hasOneof(13); + } + + /** + * A note describing a package hosted by various package managers. + * + * Generated from protobuf field .grafeas.v1.PackageNote package = 13; + * @param \Grafeas\V1\PackageNote $var + * @return $this + */ + public function setPackage($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\PackageNote::class); + $this->writeOneof(13, $var); + + return $this; + } + + /** + * A note describing something that can be deployed. + * + * Generated from protobuf field .grafeas.v1.DeploymentNote deployment = 14; + * @return \Grafeas\V1\DeploymentNote|null + */ + public function getDeployment() + { + return $this->readOneof(14); + } + + public function hasDeployment() + { + return $this->hasOneof(14); + } + + /** + * A note describing something that can be deployed. + * + * Generated from protobuf field .grafeas.v1.DeploymentNote deployment = 14; + * @param \Grafeas\V1\DeploymentNote $var + * @return $this + */ + public function setDeployment($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\DeploymentNote::class); + $this->writeOneof(14, $var); + + return $this; + } + + /** + * A note describing the initial analysis of a resource. + * + * Generated from protobuf field .grafeas.v1.DiscoveryNote discovery = 15; + * @return \Grafeas\V1\DiscoveryNote|null + */ + public function getDiscovery() + { + return $this->readOneof(15); + } + + public function hasDiscovery() + { + return $this->hasOneof(15); + } + + /** + * A note describing the initial analysis of a resource. + * + * Generated from protobuf field .grafeas.v1.DiscoveryNote discovery = 15; + * @param \Grafeas\V1\DiscoveryNote $var + * @return $this + */ + public function setDiscovery($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\DiscoveryNote::class); + $this->writeOneof(15, $var); + + return $this; + } + + /** + * A note describing an attestation role. + * + * Generated from protobuf field .grafeas.v1.AttestationNote attestation = 16; + * @return \Grafeas\V1\AttestationNote|null + */ + public function getAttestation() + { + return $this->readOneof(16); + } + + public function hasAttestation() + { + return $this->hasOneof(16); + } + + /** + * A note describing an attestation role. + * + * Generated from protobuf field .grafeas.v1.AttestationNote attestation = 16; + * @param \Grafeas\V1\AttestationNote $var + * @return $this + */ + public function setAttestation($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\AttestationNote::class); + $this->writeOneof(16, $var); + + return $this; + } + + /** + * A note describing available package upgrades. + * + * Generated from protobuf field .grafeas.v1.UpgradeNote upgrade = 17; + * @return \Grafeas\V1\UpgradeNote|null + */ + public function getUpgrade() + { + return $this->readOneof(17); + } + + public function hasUpgrade() + { + return $this->hasOneof(17); + } + + /** + * A note describing available package upgrades. + * + * Generated from protobuf field .grafeas.v1.UpgradeNote upgrade = 17; + * @param \Grafeas\V1\UpgradeNote $var + * @return $this + */ + public function setUpgrade($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\UpgradeNote::class); + $this->writeOneof(17, $var); + + return $this; + } + + /** + * A note describing a compliance check. + * + * Generated from protobuf field .grafeas.v1.ComplianceNote compliance = 18; + * @return \Grafeas\V1\ComplianceNote|null + */ + public function getCompliance() + { + return $this->readOneof(18); + } + + public function hasCompliance() + { + return $this->hasOneof(18); + } + + /** + * A note describing a compliance check. + * + * Generated from protobuf field .grafeas.v1.ComplianceNote compliance = 18; + * @param \Grafeas\V1\ComplianceNote $var + * @return $this + */ + public function setCompliance($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\ComplianceNote::class); + $this->writeOneof(18, $var); + + return $this; + } + + /** + * A note describing a dsse attestation note. + * + * Generated from protobuf field .grafeas.v1.DSSEAttestationNote dsse_attestation = 19; + * @return \Grafeas\V1\DSSEAttestationNote|null + */ + public function getDsseAttestation() + { + return $this->readOneof(19); + } + + public function hasDsseAttestation() + { + return $this->hasOneof(19); + } + + /** + * A note describing a dsse attestation note. + * + * Generated from protobuf field .grafeas.v1.DSSEAttestationNote dsse_attestation = 19; + * @param \Grafeas\V1\DSSEAttestationNote $var + * @return $this + */ + public function setDsseAttestation($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\DSSEAttestationNote::class); + $this->writeOneof(19, $var); + + return $this; + } + + /** + * A note describing a vulnerability assessment. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote vulnerability_assessment = 20; + * @return \Grafeas\V1\VulnerabilityAssessmentNote|null + */ + public function getVulnerabilityAssessment() + { + return $this->readOneof(20); + } + + public function hasVulnerabilityAssessment() + { + return $this->hasOneof(20); + } + + /** + * A note describing a vulnerability assessment. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote vulnerability_assessment = 20; + * @param \Grafeas\V1\VulnerabilityAssessmentNote $var + * @return $this + */ + public function setVulnerabilityAssessment($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityAssessmentNote::class); + $this->writeOneof(20, $var); + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NoteKind.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NoteKind.php new file mode 100644 index 00000000000..7616d7f290c --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NoteKind.php @@ -0,0 +1,124 @@ +grafeas.v1.NoteKind + */ +class NoteKind +{ + /** + * Default value. This value is unused. + * + * Generated from protobuf enum NOTE_KIND_UNSPECIFIED = 0; + */ + const NOTE_KIND_UNSPECIFIED = 0; + /** + * The note and occurrence represent a package vulnerability. + * + * Generated from protobuf enum VULNERABILITY = 1; + */ + const VULNERABILITY = 1; + /** + * The note and occurrence assert build provenance. + * + * Generated from protobuf enum BUILD = 2; + */ + const BUILD = 2; + /** + * This represents an image basis relationship. + * + * Generated from protobuf enum IMAGE = 3; + */ + const IMAGE = 3; + /** + * This represents a package installed via a package manager. + * + * Generated from protobuf enum PACKAGE = 4; + */ + const PACKAGE = 4; + /** + * The note and occurrence track deployment events. + * + * Generated from protobuf enum DEPLOYMENT = 5; + */ + const DEPLOYMENT = 5; + /** + * The note and occurrence track the initial discovery status of a resource. + * + * Generated from protobuf enum DISCOVERY = 6; + */ + const DISCOVERY = 6; + /** + * This represents a logical "role" that can attest to artifacts. + * + * Generated from protobuf enum ATTESTATION = 7; + */ + const ATTESTATION = 7; + /** + * This represents an available package upgrade. + * + * Generated from protobuf enum UPGRADE = 8; + */ + const UPGRADE = 8; + /** + * This represents a Compliance Note + * + * Generated from protobuf enum COMPLIANCE = 9; + */ + const COMPLIANCE = 9; + /** + * This represents a DSSE attestation Note + * + * Generated from protobuf enum DSSE_ATTESTATION = 10; + */ + const DSSE_ATTESTATION = 10; + /** + * This represents a Vulnerability Assessment. + * + * Generated from protobuf enum VULNERABILITY_ASSESSMENT = 11; + */ + const VULNERABILITY_ASSESSMENT = 11; + + private static $valueToName = [ + self::NOTE_KIND_UNSPECIFIED => 'NOTE_KIND_UNSPECIFIED', + self::VULNERABILITY => 'VULNERABILITY', + self::BUILD => 'BUILD', + self::IMAGE => 'IMAGE', + self::PACKAGE => 'PACKAGE', + self::DEPLOYMENT => 'DEPLOYMENT', + self::DISCOVERY => 'DISCOVERY', + self::ATTESTATION => 'ATTESTATION', + self::UPGRADE => 'UPGRADE', + self::COMPLIANCE => 'COMPLIANCE', + self::DSSE_ATTESTATION => 'DSSE_ATTESTATION', + self::VULNERABILITY_ASSESSMENT => 'VULNERABILITY_ASSESSMENT', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Occurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Occurrence.php new file mode 100644 index 00000000000..afc520226b1 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Occurrence.php @@ -0,0 +1,701 @@ +grafeas.v1.Occurrence + */ +class Occurrence extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Required. Immutable. A URI that represents the resource for which the + * occurrence applies. For example, + * `https://gcr.io/project/image@sha256:123abc` for a Docker image. + * + * Generated from protobuf field string resource_uri = 2; + */ + protected $resource_uri = ''; + /** + * 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. + * + * Generated from protobuf field string note_name = 3; + */ + protected $note_name = ''; + /** + * Output only. This explicitly denotes which of the occurrence details are + * specified. This field can be used as a filter in list requests. + * + * Generated from protobuf field .grafeas.v1.NoteKind kind = 4; + */ + protected $kind = 0; + /** + * A description of actions that can be taken to remedy the note. + * + * Generated from protobuf field string remediation = 5; + */ + protected $remediation = ''; + /** + * Output only. The time this occurrence was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; + */ + protected $create_time = null; + /** + * Output only. The time this occurrence was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 7; + */ + protected $update_time = null; + /** + * https://github.com/secure-systems-lab/dsse + * + * Generated from protobuf field .grafeas.v1.Envelope envelope = 18; + */ + protected $envelope = null; + protected $details; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * @type string $resource_uri + * Required. Immutable. A URI that represents the resource for which the + * occurrence applies. For example, + * `https://gcr.io/project/image@sha256:123abc` for a Docker image. + * @type string $note_name + * 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. + * @type 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. + * @type string $remediation + * A description of actions that can be taken to remedy the note. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The time this occurrence was created. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The time this occurrence was last updated. + * @type \Grafeas\V1\VulnerabilityOccurrence $vulnerability + * Describes a security vulnerability. + * @type \Grafeas\V1\BuildOccurrence $build + * Describes a verifiable build. + * @type \Grafeas\V1\ImageOccurrence $image + * Describes how this resource derives from the basis in the associated + * note. + * @type \Grafeas\V1\PackageOccurrence $package + * Describes the installation of a package on the linked resource. + * @type \Grafeas\V1\DeploymentOccurrence $deployment + * Describes the deployment of an artifact on a runtime. + * @type \Grafeas\V1\DiscoveryOccurrence $discovery + * Describes when a resource was discovered. + * @type \Grafeas\V1\AttestationOccurrence $attestation + * Describes an attestation of an artifact. + * @type \Grafeas\V1\UpgradeOccurrence $upgrade + * Describes an available package upgrade on the linked resource. + * @type \Grafeas\V1\ComplianceOccurrence $compliance + * Describes a compliance violation on a linked resource. + * @type \Grafeas\V1\DSSEAttestationOccurrence $dsse_attestation + * Describes an attestation of an artifact using dsse. + * @type \Grafeas\V1\Envelope $envelope + * https://github.com/secure-systems-lab/dsse + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Required. Immutable. A URI that represents the resource for which the + * occurrence applies. For example, + * `https://gcr.io/project/image@sha256:123abc` for a Docker image. + * + * Generated from protobuf field string resource_uri = 2; + * @return string + */ + public function getResourceUri() + { + return $this->resource_uri; + } + + /** + * Required. Immutable. A URI that represents the resource for which the + * occurrence applies. For example, + * `https://gcr.io/project/image@sha256:123abc` for a Docker image. + * + * Generated from protobuf field string resource_uri = 2; + * @param string $var + * @return $this + */ + public function setResourceUri($var) + { + GPBUtil::checkString($var, True); + $this->resource_uri = $var; + + 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. + * + * Generated from protobuf field string note_name = 3; + * @return string + */ + public function getNoteName() + { + return $this->note_name; + } + + /** + * 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. + * + * Generated from protobuf field string note_name = 3; + * @param string $var + * @return $this + */ + public function setNoteName($var) + { + GPBUtil::checkString($var, True); + $this->note_name = $var; + + 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. + * + * Generated from protobuf field .grafeas.v1.NoteKind kind = 4; + * @return int + */ + public function getKind() + { + return $this->kind; + } + + /** + * Output only. This explicitly denotes which of the occurrence details are + * specified. This field can be used as a filter in list requests. + * + * Generated from protobuf field .grafeas.v1.NoteKind kind = 4; + * @param int $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\NoteKind::class); + $this->kind = $var; + + return $this; + } + + /** + * A description of actions that can be taken to remedy the note. + * + * Generated from protobuf field string remediation = 5; + * @return string + */ + public function getRemediation() + { + return $this->remediation; + } + + /** + * A description of actions that can be taken to remedy the note. + * + * Generated from protobuf field string remediation = 5; + * @param string $var + * @return $this + */ + public function setRemediation($var) + { + GPBUtil::checkString($var, True); + $this->remediation = $var; + + return $this; + } + + /** + * Output only. The time this occurrence was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * Output only. The time this occurrence was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * Output only. The time this occurrence was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 7; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUpdateTime() + { + return $this->update_time; + } + + public function hasUpdateTime() + { + return isset($this->update_time); + } + + public function clearUpdateTime() + { + unset($this->update_time); + } + + /** + * Output only. The time this occurrence was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 7; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Describes a security vulnerability. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence vulnerability = 8; + * @return \Grafeas\V1\VulnerabilityOccurrence|null + */ + public function getVulnerability() + { + return $this->readOneof(8); + } + + public function hasVulnerability() + { + return $this->hasOneof(8); + } + + /** + * Describes a security vulnerability. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence vulnerability = 8; + * @param \Grafeas\V1\VulnerabilityOccurrence $var + * @return $this + */ + public function setVulnerability($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityOccurrence::class); + $this->writeOneof(8, $var); + + return $this; + } + + /** + * Describes a verifiable build. + * + * Generated from protobuf field .grafeas.v1.BuildOccurrence build = 9; + * @return \Grafeas\V1\BuildOccurrence|null + */ + public function getBuild() + { + return $this->readOneof(9); + } + + public function hasBuild() + { + return $this->hasOneof(9); + } + + /** + * Describes a verifiable build. + * + * Generated from protobuf field .grafeas.v1.BuildOccurrence build = 9; + * @param \Grafeas\V1\BuildOccurrence $var + * @return $this + */ + public function setBuild($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\BuildOccurrence::class); + $this->writeOneof(9, $var); + + return $this; + } + + /** + * Describes how this resource derives from the basis in the associated + * note. + * + * Generated from protobuf field .grafeas.v1.ImageOccurrence image = 10; + * @return \Grafeas\V1\ImageOccurrence|null + */ + public function getImage() + { + return $this->readOneof(10); + } + + public function hasImage() + { + return $this->hasOneof(10); + } + + /** + * Describes how this resource derives from the basis in the associated + * note. + * + * Generated from protobuf field .grafeas.v1.ImageOccurrence image = 10; + * @param \Grafeas\V1\ImageOccurrence $var + * @return $this + */ + public function setImage($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\ImageOccurrence::class); + $this->writeOneof(10, $var); + + return $this; + } + + /** + * Describes the installation of a package on the linked resource. + * + * Generated from protobuf field .grafeas.v1.PackageOccurrence package = 11; + * @return \Grafeas\V1\PackageOccurrence|null + */ + public function getPackage() + { + return $this->readOneof(11); + } + + public function hasPackage() + { + return $this->hasOneof(11); + } + + /** + * Describes the installation of a package on the linked resource. + * + * Generated from protobuf field .grafeas.v1.PackageOccurrence package = 11; + * @param \Grafeas\V1\PackageOccurrence $var + * @return $this + */ + public function setPackage($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\PackageOccurrence::class); + $this->writeOneof(11, $var); + + return $this; + } + + /** + * Describes the deployment of an artifact on a runtime. + * + * Generated from protobuf field .grafeas.v1.DeploymentOccurrence deployment = 12; + * @return \Grafeas\V1\DeploymentOccurrence|null + */ + public function getDeployment() + { + return $this->readOneof(12); + } + + public function hasDeployment() + { + return $this->hasOneof(12); + } + + /** + * Describes the deployment of an artifact on a runtime. + * + * Generated from protobuf field .grafeas.v1.DeploymentOccurrence deployment = 12; + * @param \Grafeas\V1\DeploymentOccurrence $var + * @return $this + */ + public function setDeployment($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\DeploymentOccurrence::class); + $this->writeOneof(12, $var); + + return $this; + } + + /** + * Describes when a resource was discovered. + * + * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence discovery = 13; + * @return \Grafeas\V1\DiscoveryOccurrence|null + */ + public function getDiscovery() + { + return $this->readOneof(13); + } + + public function hasDiscovery() + { + return $this->hasOneof(13); + } + + /** + * Describes when a resource was discovered. + * + * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence discovery = 13; + * @param \Grafeas\V1\DiscoveryOccurrence $var + * @return $this + */ + public function setDiscovery($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\DiscoveryOccurrence::class); + $this->writeOneof(13, $var); + + return $this; + } + + /** + * Describes an attestation of an artifact. + * + * Generated from protobuf field .grafeas.v1.AttestationOccurrence attestation = 14; + * @return \Grafeas\V1\AttestationOccurrence|null + */ + public function getAttestation() + { + return $this->readOneof(14); + } + + public function hasAttestation() + { + return $this->hasOneof(14); + } + + /** + * Describes an attestation of an artifact. + * + * Generated from protobuf field .grafeas.v1.AttestationOccurrence attestation = 14; + * @param \Grafeas\V1\AttestationOccurrence $var + * @return $this + */ + public function setAttestation($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\AttestationOccurrence::class); + $this->writeOneof(14, $var); + + return $this; + } + + /** + * Describes an available package upgrade on the linked resource. + * + * Generated from protobuf field .grafeas.v1.UpgradeOccurrence upgrade = 15; + * @return \Grafeas\V1\UpgradeOccurrence|null + */ + public function getUpgrade() + { + return $this->readOneof(15); + } + + public function hasUpgrade() + { + return $this->hasOneof(15); + } + + /** + * Describes an available package upgrade on the linked resource. + * + * Generated from protobuf field .grafeas.v1.UpgradeOccurrence upgrade = 15; + * @param \Grafeas\V1\UpgradeOccurrence $var + * @return $this + */ + public function setUpgrade($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\UpgradeOccurrence::class); + $this->writeOneof(15, $var); + + return $this; + } + + /** + * Describes a compliance violation on a linked resource. + * + * Generated from protobuf field .grafeas.v1.ComplianceOccurrence compliance = 16; + * @return \Grafeas\V1\ComplianceOccurrence|null + */ + public function getCompliance() + { + return $this->readOneof(16); + } + + public function hasCompliance() + { + return $this->hasOneof(16); + } + + /** + * Describes a compliance violation on a linked resource. + * + * Generated from protobuf field .grafeas.v1.ComplianceOccurrence compliance = 16; + * @param \Grafeas\V1\ComplianceOccurrence $var + * @return $this + */ + public function setCompliance($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\ComplianceOccurrence::class); + $this->writeOneof(16, $var); + + return $this; + } + + /** + * Describes an attestation of an artifact using dsse. + * + * Generated from protobuf field .grafeas.v1.DSSEAttestationOccurrence dsse_attestation = 17; + * @return \Grafeas\V1\DSSEAttestationOccurrence|null + */ + public function getDsseAttestation() + { + return $this->readOneof(17); + } + + public function hasDsseAttestation() + { + return $this->hasOneof(17); + } + + /** + * Describes an attestation of an artifact using dsse. + * + * Generated from protobuf field .grafeas.v1.DSSEAttestationOccurrence dsse_attestation = 17; + * @param \Grafeas\V1\DSSEAttestationOccurrence $var + * @return $this + */ + public function setDsseAttestation($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\DSSEAttestationOccurrence::class); + $this->writeOneof(17, $var); + + return $this; + } + + /** + * https://github.com/secure-systems-lab/dsse + * + * Generated from protobuf field .grafeas.v1.Envelope envelope = 18; + * @return \Grafeas\V1\Envelope|null + */ + public function getEnvelope() + { + return $this->envelope; + } + + public function hasEnvelope() + { + return isset($this->envelope); + } + + public function clearEnvelope() + { + unset($this->envelope); + } + + /** + * https://github.com/secure-systems-lab/dsse + * + * Generated from protobuf field .grafeas.v1.Envelope envelope = 18; + * @param \Grafeas\V1\Envelope $var + * @return $this + */ + public function setEnvelope($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Envelope::class); + $this->envelope = $var; + + return $this; + } + + /** + * @return string + */ + public function getDetails() + { + return $this->whichOneof("details"); + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageNote.php new file mode 100644 index 00000000000..a7295d29168 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageNote.php @@ -0,0 +1,451 @@ +grafeas.v1.PackageNote + */ +class PackageNote extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the package. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + */ + protected $name = ''; + /** + * Deprecated. + * The various channels by which a package is distributed. + * + * Generated from protobuf field repeated .grafeas.v1.Distribution distribution = 10; + */ + private $distribution; + /** + * The type of package; whether native or non native (e.g., ruby gems, + * node.js packages, etc.). + * + * Generated from protobuf field string package_type = 11; + */ + protected $package_type = ''; + /** + * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) + * denoting the package manager version distributing a package. + * The cpe_uri will be blank for language packages. + * + * Generated from protobuf field string cpe_uri = 12; + */ + protected $cpe_uri = ''; + /** + * The CPU architecture for which packages in this distribution channel were + * built. Architecture will be blank for language packages. + * + * Generated from protobuf field .grafeas.v1.Architecture architecture = 13; + */ + protected $architecture = 0; + /** + * The version of the package. + * + * Generated from protobuf field .grafeas.v1.Version version = 14; + */ + protected $version = null; + /** + * A freeform text denoting the maintainer of this package. + * + * Generated from protobuf field string maintainer = 15; + */ + protected $maintainer = ''; + /** + * The homepage for this package. + * + * Generated from protobuf field string url = 16; + */ + protected $url = ''; + /** + * The description of this package. + * + * Generated from protobuf field string description = 17; + */ + protected $description = ''; + /** + * Licenses that have been declared by the authors of the package. + * + * Generated from protobuf field .grafeas.v1.License license = 18; + */ + protected $license = null; + /** + * Hash value, typically a file digest, that allows unique + * identification a specific package. + * + * Generated from protobuf field repeated .grafeas.v1.Digest digest = 19; + */ + private $digest; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the package. + * @type array<\Grafeas\V1\Distribution>|\Google\Protobuf\Internal\RepeatedField $distribution + * Deprecated. + * The various channels by which a package is distributed. + * @type string $package_type + * The type of package; whether native or non native (e.g., ruby gems, + * node.js packages, etc.). + * @type string $cpe_uri + * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) + * denoting the package manager version distributing a package. + * The cpe_uri will be blank for language packages. + * @type int $architecture + * The CPU architecture for which packages in this distribution channel were + * built. Architecture will be blank for language packages. + * @type \Grafeas\V1\Version $version + * The version of the package. + * @type string $maintainer + * A freeform text denoting the maintainer of this package. + * @type string $url + * The homepage for this package. + * @type string $description + * The description of this package. + * @type \Grafeas\V1\License $license + * Licenses that have been declared by the authors of the package. + * @type array<\Grafeas\V1\Digest>|\Google\Protobuf\Internal\RepeatedField $digest + * Hash value, typically a file digest, that allows unique + * identification a specific package. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Package::initOnce(); + parent::__construct($data); + } + + /** + * The name of the package. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the package. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Deprecated. + * The various channels by which a package is distributed. + * + * Generated from protobuf field repeated .grafeas.v1.Distribution distribution = 10; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDistribution() + { + return $this->distribution; + } + + /** + * Deprecated. + * The various channels by which a package is distributed. + * + * Generated from protobuf field repeated .grafeas.v1.Distribution distribution = 10; + * @param array<\Grafeas\V1\Distribution>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDistribution($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Distribution::class); + $this->distribution = $arr; + + return $this; + } + + /** + * The type of package; whether native or non native (e.g., ruby gems, + * node.js packages, etc.). + * + * Generated from protobuf field string package_type = 11; + * @return string + */ + public function getPackageType() + { + return $this->package_type; + } + + /** + * The type of package; whether native or non native (e.g., ruby gems, + * node.js packages, etc.). + * + * Generated from protobuf field string package_type = 11; + * @param string $var + * @return $this + */ + public function setPackageType($var) + { + GPBUtil::checkString($var, True); + $this->package_type = $var; + + return $this; + } + + /** + * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) + * denoting the package manager version distributing a package. + * The cpe_uri will be blank for language packages. + * + * Generated from protobuf field string cpe_uri = 12; + * @return string + */ + public function getCpeUri() + { + return $this->cpe_uri; + } + + /** + * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) + * denoting the package manager version distributing a package. + * The cpe_uri will be blank for language packages. + * + * Generated from protobuf field string cpe_uri = 12; + * @param string $var + * @return $this + */ + public function setCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->cpe_uri = $var; + + return $this; + } + + /** + * The CPU architecture for which packages in this distribution channel were + * built. Architecture will be blank for language packages. + * + * Generated from protobuf field .grafeas.v1.Architecture architecture = 13; + * @return int + */ + public function getArchitecture() + { + return $this->architecture; + } + + /** + * The CPU architecture for which packages in this distribution channel were + * built. Architecture will be blank for language packages. + * + * Generated from protobuf field .grafeas.v1.Architecture architecture = 13; + * @param int $var + * @return $this + */ + public function setArchitecture($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\Architecture::class); + $this->architecture = $var; + + return $this; + } + + /** + * The version of the package. + * + * Generated from protobuf field .grafeas.v1.Version version = 14; + * @return \Grafeas\V1\Version|null + */ + public function getVersion() + { + return $this->version; + } + + public function hasVersion() + { + return isset($this->version); + } + + public function clearVersion() + { + unset($this->version); + } + + /** + * The version of the package. + * + * Generated from protobuf field .grafeas.v1.Version version = 14; + * @param \Grafeas\V1\Version $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); + $this->version = $var; + + return $this; + } + + /** + * A freeform text denoting the maintainer of this package. + * + * Generated from protobuf field string maintainer = 15; + * @return string + */ + public function getMaintainer() + { + return $this->maintainer; + } + + /** + * A freeform text denoting the maintainer of this package. + * + * Generated from protobuf field string maintainer = 15; + * @param string $var + * @return $this + */ + public function setMaintainer($var) + { + GPBUtil::checkString($var, True); + $this->maintainer = $var; + + return $this; + } + + /** + * The homepage for this package. + * + * Generated from protobuf field string url = 16; + * @return string + */ + public function getUrl() + { + return $this->url; + } + + /** + * The homepage for this package. + * + * Generated from protobuf field string url = 16; + * @param string $var + * @return $this + */ + public function setUrl($var) + { + GPBUtil::checkString($var, True); + $this->url = $var; + + return $this; + } + + /** + * The description of this package. + * + * Generated from protobuf field string description = 17; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The description of this package. + * + * Generated from protobuf field string description = 17; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Licenses that have been declared by the authors of the package. + * + * Generated from protobuf field .grafeas.v1.License license = 18; + * @return \Grafeas\V1\License|null + */ + public function getLicense() + { + return $this->license; + } + + public function hasLicense() + { + return isset($this->license); + } + + public function clearLicense() + { + unset($this->license); + } + + /** + * Licenses that have been declared by the authors of the package. + * + * Generated from protobuf field .grafeas.v1.License license = 18; + * @param \Grafeas\V1\License $var + * @return $this + */ + public function setLicense($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\License::class); + $this->license = $var; + + return $this; + } + + /** + * Hash value, typically a file digest, that allows unique + * identification a specific package. + * + * Generated from protobuf field repeated .grafeas.v1.Digest digest = 19; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDigest() + { + return $this->digest; + } + + /** + * Hash value, typically a file digest, that allows unique + * identification a specific package. + * + * Generated from protobuf field repeated .grafeas.v1.Digest digest = 19; + * @param array<\Grafeas\V1\Digest>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDigest($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Digest::class); + $this->digest = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageOccurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageOccurrence.php new file mode 100644 index 00000000000..dafa0769a93 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageOccurrence.php @@ -0,0 +1,311 @@ +grafeas.v1.PackageOccurrence + */ +class PackageOccurrence extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the installed package. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * All of the places within the filesystem versions of this package + * have been found. + * + * Generated from protobuf field repeated .grafeas.v1.Location location = 2; + */ + private $location; + /** + * The type of package; whether native or non native (e.g., ruby gems, + * node.js packages, etc.). + * + * Generated from protobuf field string package_type = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $package_type = ''; + /** + * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) + * denoting the package manager version distributing a package. + * The cpe_uri will be blank for language packages. + * + * Generated from protobuf field string cpe_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $cpe_uri = ''; + /** + * The CPU architecture for which packages in this distribution channel were + * built. Architecture will be blank for language packages. + * + * Generated from protobuf field .grafeas.v1.Architecture architecture = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $architecture = 0; + /** + * Licenses that have been declared by the authors of the package. + * + * Generated from protobuf field .grafeas.v1.License license = 6; + */ + protected $license = null; + /** + * The version of the package. + * + * Generated from protobuf field .grafeas.v1.Version version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $version = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the installed package. + * @type array<\Grafeas\V1\Location>|\Google\Protobuf\Internal\RepeatedField $location + * All of the places within the filesystem versions of this package + * have been found. + * @type string $package_type + * The type of package; whether native or non native (e.g., ruby gems, + * node.js packages, etc.). + * @type string $cpe_uri + * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) + * denoting the package manager version distributing a package. + * The cpe_uri will be blank for language packages. + * @type int $architecture + * The CPU architecture for which packages in this distribution channel were + * built. Architecture will be blank for language packages. + * @type \Grafeas\V1\License $license + * Licenses that have been declared by the authors of the package. + * @type \Grafeas\V1\Version $version + * The version of the package. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Package::initOnce(); + parent::__construct($data); + } + + /** + * The name of the installed package. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the installed package. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * All of the places within the filesystem versions of this package + * have been found. + * + * Generated from protobuf field repeated .grafeas.v1.Location location = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLocation() + { + return $this->location; + } + + /** + * All of the places within the filesystem versions of this package + * have been found. + * + * Generated from protobuf field repeated .grafeas.v1.Location location = 2; + * @param array<\Grafeas\V1\Location>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLocation($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Location::class); + $this->location = $arr; + + return $this; + } + + /** + * The type of package; whether native or non native (e.g., ruby gems, + * node.js packages, etc.). + * + * Generated from protobuf field string package_type = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getPackageType() + { + return $this->package_type; + } + + /** + * The type of package; whether native or non native (e.g., ruby gems, + * node.js packages, etc.). + * + * Generated from protobuf field string package_type = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setPackageType($var) + { + GPBUtil::checkString($var, True); + $this->package_type = $var; + + return $this; + } + + /** + * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) + * denoting the package manager version distributing a package. + * The cpe_uri will be blank for language packages. + * + * Generated from protobuf field string cpe_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getCpeUri() + { + return $this->cpe_uri; + } + + /** + * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) + * denoting the package manager version distributing a package. + * The cpe_uri will be blank for language packages. + * + * Generated from protobuf field string cpe_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->cpe_uri = $var; + + return $this; + } + + /** + * The CPU architecture for which packages in this distribution channel were + * built. Architecture will be blank for language packages. + * + * Generated from protobuf field .grafeas.v1.Architecture architecture = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getArchitecture() + { + return $this->architecture; + } + + /** + * The CPU architecture for which packages in this distribution channel were + * built. Architecture will be blank for language packages. + * + * Generated from protobuf field .grafeas.v1.Architecture architecture = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setArchitecture($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\Architecture::class); + $this->architecture = $var; + + return $this; + } + + /** + * Licenses that have been declared by the authors of the package. + * + * Generated from protobuf field .grafeas.v1.License license = 6; + * @return \Grafeas\V1\License|null + */ + public function getLicense() + { + return $this->license; + } + + public function hasLicense() + { + return isset($this->license); + } + + public function clearLicense() + { + unset($this->license); + } + + /** + * Licenses that have been declared by the authors of the package. + * + * Generated from protobuf field .grafeas.v1.License license = 6; + * @param \Grafeas\V1\License $var + * @return $this + */ + public function setLicense($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\License::class); + $this->license = $var; + + return $this; + } + + /** + * The version of the package. + * + * Generated from protobuf field .grafeas.v1.Version version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Grafeas\V1\Version|null + */ + public function getVersion() + { + return $this->version; + } + + public function hasVersion() + { + return isset($this->version); + } + + public function clearVersion() + { + unset($this->version); + } + + /** + * The version of the package. + * + * Generated from protobuf field .grafeas.v1.Version version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Grafeas\V1\Version $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); + $this->version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ProjectRepoId.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ProjectRepoId.php new file mode 100644 index 00000000000..d2c9475a063 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ProjectRepoId.php @@ -0,0 +1,102 @@ +grafeas.v1.ProjectRepoId + */ +class ProjectRepoId extends \Google\Protobuf\Internal\Message +{ + /** + * The ID of the project. + * + * Generated from protobuf field string project_id = 1; + */ + protected $project_id = ''; + /** + * The name of the repo. Leave empty for the default repo. + * + * Generated from protobuf field string repo_name = 2; + */ + protected $repo_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $project_id + * The ID of the project. + * @type string $repo_name + * The name of the repo. Leave empty for the default repo. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * The ID of the project. + * + * Generated from protobuf field string project_id = 1; + * @return string + */ + public function getProjectId() + { + return $this->project_id; + } + + /** + * The ID of the project. + * + * Generated from protobuf field string project_id = 1; + * @param string $var + * @return $this + */ + public function setProjectId($var) + { + GPBUtil::checkString($var, True); + $this->project_id = $var; + + return $this; + } + + /** + * The name of the repo. Leave empty for the default repo. + * + * Generated from protobuf field string repo_name = 2; + * @return string + */ + public function getRepoName() + { + return $this->repo_name; + } + + /** + * The name of the repo. Leave empty for the default repo. + * + * Generated from protobuf field string repo_name = 2; + * @param string $var + * @return $this + */ + public function setRepoName($var) + { + GPBUtil::checkString($var, True); + $this->repo_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Recipe.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Recipe.php new file mode 100644 index 00000000000..0806a1ed630 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Recipe.php @@ -0,0 +1,273 @@ +grafeas.v1.Recipe + */ +class Recipe extends \Google\Protobuf\Internal\Message +{ + /** + * URI indicating what type of recipe was performed. It determines the meaning + * of recipe.entryPoint, recipe.arguments, recipe.environment, and materials. + * + * Generated from protobuf field string type = 1; + */ + protected $type = ''; + /** + * Index in materials containing the recipe steps that are not implied by + * recipe.type. For example, if the recipe type were "make", then this would + * point to the source containing the Makefile, not the make program itself. + * Set to -1 if the recipe doesn't come from a material, as zero is default + * unset value for int64. + * + * Generated from protobuf field int64 defined_in_material = 2; + */ + protected $defined_in_material = 0; + /** + * String identifying the entry point into the build. + * This is often a path to a configuration file and/or a target label within + * that file. The syntax and meaning are defined by recipe.type. For example, + * if the recipe type were "make", then this would reference the directory in + * which to run make as well as which target to use. + * + * Generated from protobuf field string entry_point = 3; + */ + protected $entry_point = ''; + /** + * Collection of all external inputs that influenced the build on top of + * recipe.definedInMaterial and recipe.entryPoint. For example, if the recipe + * type were "make", then this might be the flags passed to make aside from + * the target, which is captured in recipe.entryPoint. Since the arguments + * field can greatly vary in structure, depending on the builder and recipe + * type, this is of form "Any". + * + * Generated from protobuf field repeated .google.protobuf.Any arguments = 4; + */ + private $arguments; + /** + * Any other builder-controlled inputs necessary for correctly evaluating the + * recipe. Usually only needed for reproducing the build but not evaluated as + * part of policy. Since the environment field can greatly vary in structure, + * depending on the builder and recipe type, this is of form "Any". + * + * Generated from protobuf field repeated .google.protobuf.Any environment = 5; + */ + private $environment; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $type + * URI indicating what type of recipe was performed. It determines the meaning + * of recipe.entryPoint, recipe.arguments, recipe.environment, and materials. + * @type int|string $defined_in_material + * Index in materials containing the recipe steps that are not implied by + * recipe.type. For example, if the recipe type were "make", then this would + * point to the source containing the Makefile, not the make program itself. + * Set to -1 if the recipe doesn't come from a material, as zero is default + * unset value for int64. + * @type string $entry_point + * String identifying the entry point into the build. + * This is often a path to a configuration file and/or a target label within + * that file. The syntax and meaning are defined by recipe.type. For example, + * if the recipe type were "make", then this would reference the directory in + * which to run make as well as which target to use. + * @type array<\Google\Protobuf\Any>|\Google\Protobuf\Internal\RepeatedField $arguments + * Collection of all external inputs that influenced the build on top of + * recipe.definedInMaterial and recipe.entryPoint. For example, if the recipe + * type were "make", then this might be the flags passed to make aside from + * the target, which is captured in recipe.entryPoint. Since the arguments + * field can greatly vary in structure, depending on the builder and recipe + * type, this is of form "Any". + * @type array<\Google\Protobuf\Any>|\Google\Protobuf\Internal\RepeatedField $environment + * Any other builder-controlled inputs necessary for correctly evaluating the + * recipe. Usually only needed for reproducing the build but not evaluated as + * part of policy. Since the environment field can greatly vary in structure, + * depending on the builder and recipe type, this is of form "Any". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\IntotoProvenance::initOnce(); + parent::__construct($data); + } + + /** + * URI indicating what type of recipe was performed. It determines the meaning + * of recipe.entryPoint, recipe.arguments, recipe.environment, and materials. + * + * Generated from protobuf field string type = 1; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * URI indicating what type of recipe was performed. It determines the meaning + * of recipe.entryPoint, recipe.arguments, recipe.environment, and materials. + * + * Generated from protobuf field string type = 1; + * @param string $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkString($var, True); + $this->type = $var; + + return $this; + } + + /** + * Index in materials containing the recipe steps that are not implied by + * recipe.type. For example, if the recipe type were "make", then this would + * point to the source containing the Makefile, not the make program itself. + * Set to -1 if the recipe doesn't come from a material, as zero is default + * unset value for int64. + * + * Generated from protobuf field int64 defined_in_material = 2; + * @return int|string + */ + public function getDefinedInMaterial() + { + return $this->defined_in_material; + } + + /** + * Index in materials containing the recipe steps that are not implied by + * recipe.type. For example, if the recipe type were "make", then this would + * point to the source containing the Makefile, not the make program itself. + * Set to -1 if the recipe doesn't come from a material, as zero is default + * unset value for int64. + * + * Generated from protobuf field int64 defined_in_material = 2; + * @param int|string $var + * @return $this + */ + public function setDefinedInMaterial($var) + { + GPBUtil::checkInt64($var); + $this->defined_in_material = $var; + + return $this; + } + + /** + * String identifying the entry point into the build. + * This is often a path to a configuration file and/or a target label within + * that file. The syntax and meaning are defined by recipe.type. For example, + * if the recipe type were "make", then this would reference the directory in + * which to run make as well as which target to use. + * + * Generated from protobuf field string entry_point = 3; + * @return string + */ + public function getEntryPoint() + { + return $this->entry_point; + } + + /** + * String identifying the entry point into the build. + * This is often a path to a configuration file and/or a target label within + * that file. The syntax and meaning are defined by recipe.type. For example, + * if the recipe type were "make", then this would reference the directory in + * which to run make as well as which target to use. + * + * Generated from protobuf field string entry_point = 3; + * @param string $var + * @return $this + */ + public function setEntryPoint($var) + { + GPBUtil::checkString($var, True); + $this->entry_point = $var; + + return $this; + } + + /** + * Collection of all external inputs that influenced the build on top of + * recipe.definedInMaterial and recipe.entryPoint. For example, if the recipe + * type were "make", then this might be the flags passed to make aside from + * the target, which is captured in recipe.entryPoint. Since the arguments + * field can greatly vary in structure, depending on the builder and recipe + * type, this is of form "Any". + * + * Generated from protobuf field repeated .google.protobuf.Any arguments = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getArguments() + { + return $this->arguments; + } + + /** + * Collection of all external inputs that influenced the build on top of + * recipe.definedInMaterial and recipe.entryPoint. For example, if the recipe + * type were "make", then this might be the flags passed to make aside from + * the target, which is captured in recipe.entryPoint. Since the arguments + * field can greatly vary in structure, depending on the builder and recipe + * type, this is of form "Any". + * + * Generated from protobuf field repeated .google.protobuf.Any arguments = 4; + * @param array<\Google\Protobuf\Any>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setArguments($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Any::class); + $this->arguments = $arr; + + return $this; + } + + /** + * Any other builder-controlled inputs necessary for correctly evaluating the + * recipe. Usually only needed for reproducing the build but not evaluated as + * part of policy. Since the environment field can greatly vary in structure, + * depending on the builder and recipe type, this is of form "Any". + * + * Generated from protobuf field repeated .google.protobuf.Any environment = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getEnvironment() + { + return $this->environment; + } + + /** + * Any other builder-controlled inputs necessary for correctly evaluating the + * recipe. Usually only needed for reproducing the build but not evaluated as + * part of policy. Since the environment field can greatly vary in structure, + * depending on the builder and recipe type, this is of form "Any". + * + * Generated from protobuf field repeated .google.protobuf.Any environment = 5; + * @param array<\Google\Protobuf\Any>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setEnvironment($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Any::class); + $this->environment = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RelatedUrl.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RelatedUrl.php new file mode 100644 index 00000000000..c407db0064b --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RelatedUrl.php @@ -0,0 +1,101 @@ +grafeas.v1.RelatedUrl + */ +class RelatedUrl extends \Google\Protobuf\Internal\Message +{ + /** + * Specific URL associated with the resource. + * + * Generated from protobuf field string url = 1; + */ + protected $url = ''; + /** + * Label to describe usage of the URL. + * + * Generated from protobuf field string label = 2; + */ + protected $label = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $url + * Specific URL associated with the resource. + * @type string $label + * Label to describe usage of the URL. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Common::initOnce(); + parent::__construct($data); + } + + /** + * Specific URL associated with the resource. + * + * Generated from protobuf field string url = 1; + * @return string + */ + public function getUrl() + { + return $this->url; + } + + /** + * Specific URL associated with the resource. + * + * Generated from protobuf field string url = 1; + * @param string $var + * @return $this + */ + public function setUrl($var) + { + GPBUtil::checkString($var, True); + $this->url = $var; + + return $this; + } + + /** + * Label to describe usage of the URL. + * + * Generated from protobuf field string label = 2; + * @return string + */ + public function getLabel() + { + return $this->label; + } + + /** + * Label to describe usage of the URL. + * + * Generated from protobuf field string label = 2; + * @param string $var + * @return $this + */ + public function setLabel($var) + { + GPBUtil::checkString($var, True); + $this->label = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RepoId.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RepoId.php new file mode 100644 index 00000000000..5643c66c7c2 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RepoId.php @@ -0,0 +1,108 @@ +grafeas.v1.RepoId + */ +class RepoId extends \Google\Protobuf\Internal\Message +{ + protected $id; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\ProjectRepoId $project_repo_id + * A combination of a project ID and a repo name. + * @type string $uid + * A server-assigned, globally unique identifier. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * A combination of a project ID and a repo name. + * + * Generated from protobuf field .grafeas.v1.ProjectRepoId project_repo_id = 1; + * @return \Grafeas\V1\ProjectRepoId|null + */ + public function getProjectRepoId() + { + return $this->readOneof(1); + } + + public function hasProjectRepoId() + { + return $this->hasOneof(1); + } + + /** + * A combination of a project ID and a repo name. + * + * Generated from protobuf field .grafeas.v1.ProjectRepoId project_repo_id = 1; + * @param \Grafeas\V1\ProjectRepoId $var + * @return $this + */ + public function setProjectRepoId($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\ProjectRepoId::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * A server-assigned, globally unique identifier. + * + * Generated from protobuf field string uid = 2; + * @return string + */ + public function getUid() + { + return $this->readOneof(2); + } + + public function hasUid() + { + return $this->hasOneof(2); + } + + /** + * A server-assigned, globally unique identifier. + * + * Generated from protobuf field string uid = 2; + * @param string $var + * @return $this + */ + public function setUid($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getId() + { + return $this->whichOneof("id"); + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Severity.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Severity.php new file mode 100644 index 00000000000..698112c5460 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Severity.php @@ -0,0 +1,82 @@ +grafeas.v1.Severity + */ +class Severity +{ + /** + * Unknown. + * + * Generated from protobuf enum SEVERITY_UNSPECIFIED = 0; + */ + const SEVERITY_UNSPECIFIED = 0; + /** + * Minimal severity. + * + * Generated from protobuf enum MINIMAL = 1; + */ + const MINIMAL = 1; + /** + * Low severity. + * + * Generated from protobuf enum LOW = 2; + */ + const LOW = 2; + /** + * Medium severity. + * + * Generated from protobuf enum MEDIUM = 3; + */ + const MEDIUM = 3; + /** + * High severity. + * + * Generated from protobuf enum HIGH = 4; + */ + const HIGH = 4; + /** + * Critical severity. + * + * Generated from protobuf enum CRITICAL = 5; + */ + const CRITICAL = 5; + + private static $valueToName = [ + self::SEVERITY_UNSPECIFIED => 'SEVERITY_UNSPECIFIED', + self::MINIMAL => 'MINIMAL', + self::LOW => 'LOW', + self::MEDIUM => 'MEDIUM', + self::HIGH => 'HIGH', + self::CRITICAL => 'CRITICAL', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Signature.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Signature.php new file mode 100644 index 00000000000..de57d7bfe08 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Signature.php @@ -0,0 +1,192 @@ +grafeas.v1.Signature + */ +class Signature extends \Google\Protobuf\Internal\Message +{ + /** + * The content of the signature, an opaque bytestring. + * The payload that this signature verifies MUST be unambiguously provided + * with the Signature during verification. A wrapper message might provide + * the payload explicitly. Alternatively, a message might have a canonical + * serialization that can always be unambiguously computed to derive the + * payload. + * + * Generated from protobuf field bytes signature = 1; + */ + protected $signature = ''; + /** + * The identifier for the public key that verifies this signature. + * * The `public_key_id` is required. + * * The `public_key_id` SHOULD be an RFC3986 conformant URI. + * * When possible, the `public_key_id` SHOULD be an immutable reference, + * such as a cryptographic digest. + * Examples of valid `public_key_id`s: + * OpenPGP V4 public key fingerprint: + * * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" + * See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more + * details on this scheme. + * RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER + * serialization): + * * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" + * * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" + * + * Generated from protobuf field string public_key_id = 2; + */ + protected $public_key_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $signature + * The content of the signature, an opaque bytestring. + * The payload that this signature verifies MUST be unambiguously provided + * with the Signature during verification. A wrapper message might provide + * the payload explicitly. Alternatively, a message might have a canonical + * serialization that can always be unambiguously computed to derive the + * payload. + * @type string $public_key_id + * The identifier for the public key that verifies this signature. + * * The `public_key_id` is required. + * * The `public_key_id` SHOULD be an RFC3986 conformant URI. + * * When possible, the `public_key_id` SHOULD be an immutable reference, + * such as a cryptographic digest. + * Examples of valid `public_key_id`s: + * OpenPGP V4 public key fingerprint: + * * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" + * See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more + * details on this scheme. + * RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER + * serialization): + * * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" + * * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Common::initOnce(); + parent::__construct($data); + } + + /** + * The content of the signature, an opaque bytestring. + * The payload that this signature verifies MUST be unambiguously provided + * with the Signature during verification. A wrapper message might provide + * the payload explicitly. Alternatively, a message might have a canonical + * serialization that can always be unambiguously computed to derive the + * payload. + * + * Generated from protobuf field bytes signature = 1; + * @return string + */ + public function getSignature() + { + return $this->signature; + } + + /** + * The content of the signature, an opaque bytestring. + * The payload that this signature verifies MUST be unambiguously provided + * with the Signature during verification. A wrapper message might provide + * the payload explicitly. Alternatively, a message might have a canonical + * serialization that can always be unambiguously computed to derive the + * payload. + * + * Generated from protobuf field bytes signature = 1; + * @param string $var + * @return $this + */ + public function setSignature($var) + { + GPBUtil::checkString($var, False); + $this->signature = $var; + + return $this; + } + + /** + * The identifier for the public key that verifies this signature. + * * The `public_key_id` is required. + * * The `public_key_id` SHOULD be an RFC3986 conformant URI. + * * When possible, the `public_key_id` SHOULD be an immutable reference, + * such as a cryptographic digest. + * Examples of valid `public_key_id`s: + * OpenPGP V4 public key fingerprint: + * * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" + * See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more + * details on this scheme. + * RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER + * serialization): + * * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" + * * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" + * + * Generated from protobuf field string public_key_id = 2; + * @return string + */ + public function getPublicKeyId() + { + return $this->public_key_id; + } + + /** + * The identifier for the public key that verifies this signature. + * * The `public_key_id` is required. + * * The `public_key_id` SHOULD be an RFC3986 conformant URI. + * * When possible, the `public_key_id` SHOULD be an immutable reference, + * such as a cryptographic digest. + * Examples of valid `public_key_id`s: + * OpenPGP V4 public key fingerprint: + * * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" + * See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more + * details on this scheme. + * RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER + * serialization): + * * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" + * * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" + * + * Generated from protobuf field string public_key_id = 2; + * @param string $var + * @return $this + */ + public function setPublicKeyId($var) + { + GPBUtil::checkString($var, True); + $this->public_key_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance.php new file mode 100644 index 00000000000..0113d091326 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance.php @@ -0,0 +1,214 @@ +grafeas.v1.SlsaProvenance + */ +class SlsaProvenance extends \Google\Protobuf\Internal\Message +{ + /** + * required + * + * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaBuilder builder = 1; + */ + protected $builder = null; + /** + * Identifies the configuration used for the build. + * When combined with materials, this SHOULD fully describe the build, + * such that re-running this recipe results in bit-for-bit identical output + * (if the build is reproducible). + * + * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaRecipe recipe = 2; + */ + protected $recipe = null; + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaMetadata metadata = 3; + */ + protected $metadata = null; + /** + * The collection of artifacts that influenced the build including sources, + * dependencies, build tools, base images, and so on. This is considered to be + * incomplete unless metadata.completeness.materials is true. Unset or null is + * equivalent to empty. + * + * Generated from protobuf field repeated .grafeas.v1.SlsaProvenance.Material materials = 4; + */ + private $materials; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\SlsaProvenance\SlsaBuilder $builder + * required + * @type \Grafeas\V1\SlsaProvenance\SlsaRecipe $recipe + * Identifies the configuration used for the build. + * When combined with materials, this SHOULD fully describe the build, + * such that re-running this recipe results in bit-for-bit identical output + * (if the build is reproducible). + * @type \Grafeas\V1\SlsaProvenance\SlsaMetadata $metadata + * @type array<\Grafeas\V1\SlsaProvenance\Material>|\Google\Protobuf\Internal\RepeatedField $materials + * The collection of artifacts that influenced the build including sources, + * dependencies, build tools, base images, and so on. This is considered to be + * incomplete unless metadata.completeness.materials is true. Unset or null is + * equivalent to empty. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenance::initOnce(); + parent::__construct($data); + } + + /** + * required + * + * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaBuilder builder = 1; + * @return \Grafeas\V1\SlsaProvenance\SlsaBuilder|null + */ + public function getBuilder() + { + return $this->builder; + } + + public function hasBuilder() + { + return isset($this->builder); + } + + public function clearBuilder() + { + unset($this->builder); + } + + /** + * required + * + * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaBuilder builder = 1; + * @param \Grafeas\V1\SlsaProvenance\SlsaBuilder $var + * @return $this + */ + public function setBuilder($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenance\SlsaBuilder::class); + $this->builder = $var; + + return $this; + } + + /** + * Identifies the configuration used for the build. + * When combined with materials, this SHOULD fully describe the build, + * such that re-running this recipe results in bit-for-bit identical output + * (if the build is reproducible). + * + * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaRecipe recipe = 2; + * @return \Grafeas\V1\SlsaProvenance\SlsaRecipe|null + */ + public function getRecipe() + { + return $this->recipe; + } + + public function hasRecipe() + { + return isset($this->recipe); + } + + public function clearRecipe() + { + unset($this->recipe); + } + + /** + * Identifies the configuration used for the build. + * When combined with materials, this SHOULD fully describe the build, + * such that re-running this recipe results in bit-for-bit identical output + * (if the build is reproducible). + * + * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaRecipe recipe = 2; + * @param \Grafeas\V1\SlsaProvenance\SlsaRecipe $var + * @return $this + */ + public function setRecipe($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenance\SlsaRecipe::class); + $this->recipe = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaMetadata metadata = 3; + * @return \Grafeas\V1\SlsaProvenance\SlsaMetadata|null + */ + public function getMetadata() + { + return $this->metadata; + } + + public function hasMetadata() + { + return isset($this->metadata); + } + + public function clearMetadata() + { + unset($this->metadata); + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaMetadata metadata = 3; + * @param \Grafeas\V1\SlsaProvenance\SlsaMetadata $var + * @return $this + */ + public function setMetadata($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenance\SlsaMetadata::class); + $this->metadata = $var; + + return $this; + } + + /** + * The collection of artifacts that influenced the build including sources, + * dependencies, build tools, base images, and so on. This is considered to be + * incomplete unless metadata.completeness.materials is true. Unset or null is + * equivalent to empty. + * + * Generated from protobuf field repeated .grafeas.v1.SlsaProvenance.Material materials = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMaterials() + { + return $this->materials; + } + + /** + * The collection of artifacts that influenced the build including sources, + * dependencies, build tools, base images, and so on. This is considered to be + * incomplete unless metadata.completeness.materials is true. Unset or null is + * equivalent to empty. + * + * Generated from protobuf field repeated .grafeas.v1.SlsaProvenance.Material materials = 4; + * @param array<\Grafeas\V1\SlsaProvenance\Material>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMaterials($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\SlsaProvenance\Material::class); + $this->materials = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/Material.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/Material.php new file mode 100644 index 00000000000..d2165056a94 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/Material.php @@ -0,0 +1,88 @@ +grafeas.v1.SlsaProvenance.Material + */ +class Material extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field string uri = 1; + */ + protected $uri = ''; + /** + * Generated from protobuf field map digest = 2; + */ + private $digest; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $uri + * @type array|\Google\Protobuf\Internal\MapField $digest + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenance::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field string uri = 1; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * Generated from protobuf field string uri = 1; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + + /** + * Generated from protobuf field map digest = 2; + * @return \Google\Protobuf\Internal\MapField + */ + public function getDigest() + { + return $this->digest; + } + + /** + * Generated from protobuf field map digest = 2; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setDigest($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->digest = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Material::class, \Grafeas\V1\SlsaProvenance_Material::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaBuilder.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaBuilder.php new file mode 100644 index 00000000000..455fa4993f0 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaBuilder.php @@ -0,0 +1,61 @@ +grafeas.v1.SlsaProvenance.SlsaBuilder + */ +class SlsaBuilder extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenance::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SlsaBuilder::class, \Grafeas\V1\SlsaProvenance_SlsaBuilder::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaCompleteness.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaCompleteness.php new file mode 100644 index 00000000000..15d1ba47810 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaCompleteness.php @@ -0,0 +1,151 @@ +grafeas.v1.SlsaProvenance.SlsaCompleteness + */ +class SlsaCompleteness extends \Google\Protobuf\Internal\Message +{ + /** + * If true, the builder claims that recipe.arguments is complete, meaning + * that all external inputs are properly captured in the recipe. + * + * Generated from protobuf field bool arguments = 1; + */ + protected $arguments = false; + /** + * If true, the builder claims that recipe.environment is claimed to be + * complete. + * + * Generated from protobuf field bool environment = 2; + */ + protected $environment = false; + /** + * If true, the builder claims that materials are complete, usually through + * some controls to prevent network access. Sometimes called "hermetic". + * + * Generated from protobuf field bool materials = 3; + */ + protected $materials = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $arguments + * If true, the builder claims that recipe.arguments is complete, meaning + * that all external inputs are properly captured in the recipe. + * @type bool $environment + * If true, the builder claims that recipe.environment is claimed to be + * complete. + * @type bool $materials + * If true, the builder claims that materials are complete, usually through + * some controls to prevent network access. Sometimes called "hermetic". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenance::initOnce(); + parent::__construct($data); + } + + /** + * If true, the builder claims that recipe.arguments is complete, meaning + * that all external inputs are properly captured in the recipe. + * + * Generated from protobuf field bool arguments = 1; + * @return bool + */ + public function getArguments() + { + return $this->arguments; + } + + /** + * If true, the builder claims that recipe.arguments is complete, meaning + * that all external inputs are properly captured in the recipe. + * + * Generated from protobuf field bool arguments = 1; + * @param bool $var + * @return $this + */ + public function setArguments($var) + { + GPBUtil::checkBool($var); + $this->arguments = $var; + + return $this; + } + + /** + * If true, the builder claims that recipe.environment is claimed to be + * complete. + * + * Generated from protobuf field bool environment = 2; + * @return bool + */ + public function getEnvironment() + { + return $this->environment; + } + + /** + * If true, the builder claims that recipe.environment is claimed to be + * complete. + * + * Generated from protobuf field bool environment = 2; + * @param bool $var + * @return $this + */ + public function setEnvironment($var) + { + GPBUtil::checkBool($var); + $this->environment = $var; + + return $this; + } + + /** + * If true, the builder claims that materials are complete, usually through + * some controls to prevent network access. Sometimes called "hermetic". + * + * Generated from protobuf field bool materials = 3; + * @return bool + */ + public function getMaterials() + { + return $this->materials; + } + + /** + * If true, the builder claims that materials are complete, usually through + * some controls to prevent network access. Sometimes called "hermetic". + * + * Generated from protobuf field bool materials = 3; + * @param bool $var + * @return $this + */ + public function setMaterials($var) + { + GPBUtil::checkBool($var); + $this->materials = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SlsaCompleteness::class, \Grafeas\V1\SlsaProvenance_SlsaCompleteness::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaMetadata.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaMetadata.php new file mode 100644 index 00000000000..05447be11b5 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaMetadata.php @@ -0,0 +1,252 @@ +grafeas.v1.SlsaProvenance.SlsaMetadata + */ +class SlsaMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * Identifies the particular build invocation, which can be useful for + * finding associated logs or other ad-hoc analysis. The value SHOULD be + * globally unique, per in-toto Provenance spec. + * + * Generated from protobuf field string build_invocation_id = 1; + */ + protected $build_invocation_id = ''; + /** + * The timestamp of when the build started. + * + * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; + */ + protected $build_started_on = null; + /** + * The timestamp of when the build completed. + * + * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; + */ + protected $build_finished_on = null; + /** + * Indicates that the builder claims certain fields in this message to be + * complete. + * + * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaCompleteness completeness = 4; + */ + protected $completeness = null; + /** + * If true, the builder claims that running the recipe on materials will + * produce bit-for-bit identical output. + * + * Generated from protobuf field bool reproducible = 5; + */ + protected $reproducible = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $build_invocation_id + * Identifies the particular build invocation, which can be useful for + * finding associated logs or other ad-hoc analysis. The value SHOULD be + * globally unique, per in-toto Provenance spec. + * @type \Google\Protobuf\Timestamp $build_started_on + * The timestamp of when the build started. + * @type \Google\Protobuf\Timestamp $build_finished_on + * The timestamp of when the build completed. + * @type \Grafeas\V1\SlsaProvenance\SlsaCompleteness $completeness + * Indicates that the builder claims certain fields in this message to be + * complete. + * @type bool $reproducible + * If true, the builder claims that running the recipe on materials will + * produce bit-for-bit identical output. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenance::initOnce(); + parent::__construct($data); + } + + /** + * Identifies the particular build invocation, which can be useful for + * finding associated logs or other ad-hoc analysis. The value SHOULD be + * globally unique, per in-toto Provenance spec. + * + * Generated from protobuf field string build_invocation_id = 1; + * @return string + */ + public function getBuildInvocationId() + { + return $this->build_invocation_id; + } + + /** + * Identifies the particular build invocation, which can be useful for + * finding associated logs or other ad-hoc analysis. The value SHOULD be + * globally unique, per in-toto Provenance spec. + * + * Generated from protobuf field string build_invocation_id = 1; + * @param string $var + * @return $this + */ + public function setBuildInvocationId($var) + { + GPBUtil::checkString($var, True); + $this->build_invocation_id = $var; + + return $this; + } + + /** + * The timestamp of when the build started. + * + * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getBuildStartedOn() + { + return $this->build_started_on; + } + + public function hasBuildStartedOn() + { + return isset($this->build_started_on); + } + + public function clearBuildStartedOn() + { + unset($this->build_started_on); + } + + /** + * The timestamp of when the build started. + * + * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setBuildStartedOn($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->build_started_on = $var; + + return $this; + } + + /** + * The timestamp of when the build completed. + * + * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; + * @return \Google\Protobuf\Timestamp|null + */ + public function getBuildFinishedOn() + { + return $this->build_finished_on; + } + + public function hasBuildFinishedOn() + { + return isset($this->build_finished_on); + } + + public function clearBuildFinishedOn() + { + unset($this->build_finished_on); + } + + /** + * The timestamp of when the build completed. + * + * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setBuildFinishedOn($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->build_finished_on = $var; + + return $this; + } + + /** + * Indicates that the builder claims certain fields in this message to be + * complete. + * + * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaCompleteness completeness = 4; + * @return \Grafeas\V1\SlsaProvenance\SlsaCompleteness|null + */ + public function getCompleteness() + { + return $this->completeness; + } + + public function hasCompleteness() + { + return isset($this->completeness); + } + + public function clearCompleteness() + { + unset($this->completeness); + } + + /** + * Indicates that the builder claims certain fields in this message to be + * complete. + * + * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaCompleteness completeness = 4; + * @param \Grafeas\V1\SlsaProvenance\SlsaCompleteness $var + * @return $this + */ + public function setCompleteness($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenance\SlsaCompleteness::class); + $this->completeness = $var; + + return $this; + } + + /** + * If true, the builder claims that running the recipe on materials will + * produce bit-for-bit identical output. + * + * Generated from protobuf field bool reproducible = 5; + * @return bool + */ + public function getReproducible() + { + return $this->reproducible; + } + + /** + * If true, the builder claims that running the recipe on materials will + * produce bit-for-bit identical output. + * + * Generated from protobuf field bool reproducible = 5; + * @param bool $var + * @return $this + */ + public function setReproducible($var) + { + GPBUtil::checkBool($var); + $this->reproducible = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SlsaMetadata::class, \Grafeas\V1\SlsaProvenance_SlsaMetadata::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaRecipe.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaRecipe.php new file mode 100644 index 00000000000..a448a91e95f --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaRecipe.php @@ -0,0 +1,296 @@ +grafeas.v1.SlsaProvenance.SlsaRecipe + */ +class SlsaRecipe extends \Google\Protobuf\Internal\Message +{ + /** + * URI indicating what type of recipe was performed. It determines the + * meaning of recipe.entryPoint, recipe.arguments, recipe.environment, and + * materials. + * + * Generated from protobuf field string type = 1; + */ + protected $type = ''; + /** + * Index in materials containing the recipe steps that are not implied by + * recipe.type. For example, if the recipe type were "make", then this would + * point to the source containing the Makefile, not the make program itself. + * Set to -1 if the recipe doesn't come from a material, as zero is default + * unset value for int64. + * + * Generated from protobuf field int64 defined_in_material = 2; + */ + protected $defined_in_material = 0; + /** + * String identifying the entry point into the build. + * This is often a path to a configuration file and/or a target label within + * that file. The syntax and meaning are defined by recipe.type. For + * example, if the recipe type were "make", then this would reference the + * directory in which to run make as well as which target to use. + * + * Generated from protobuf field string entry_point = 3; + */ + protected $entry_point = ''; + /** + * Collection of all external inputs that influenced the build on top of + * recipe.definedInMaterial and recipe.entryPoint. For example, if the + * recipe type were "make", then this might be the flags passed to make + * aside from the target, which is captured in recipe.entryPoint. Depending + * on the recipe Type, the structure may be different. + * + * Generated from protobuf field .google.protobuf.Any arguments = 4; + */ + protected $arguments = null; + /** + * Any other builder-controlled inputs necessary for correctly evaluating + * the recipe. Usually only needed for reproducing the build but not + * evaluated as part of policy. Depending on the recipe Type, the structure + * may be different. + * + * Generated from protobuf field .google.protobuf.Any environment = 5; + */ + protected $environment = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $type + * URI indicating what type of recipe was performed. It determines the + * meaning of recipe.entryPoint, recipe.arguments, recipe.environment, and + * materials. + * @type int|string $defined_in_material + * Index in materials containing the recipe steps that are not implied by + * recipe.type. For example, if the recipe type were "make", then this would + * point to the source containing the Makefile, not the make program itself. + * Set to -1 if the recipe doesn't come from a material, as zero is default + * unset value for int64. + * @type string $entry_point + * String identifying the entry point into the build. + * This is often a path to a configuration file and/or a target label within + * that file. The syntax and meaning are defined by recipe.type. For + * example, if the recipe type were "make", then this would reference the + * directory in which to run make as well as which target to use. + * @type \Google\Protobuf\Any $arguments + * Collection of all external inputs that influenced the build on top of + * recipe.definedInMaterial and recipe.entryPoint. For example, if the + * recipe type were "make", then this might be the flags passed to make + * aside from the target, which is captured in recipe.entryPoint. Depending + * on the recipe Type, the structure may be different. + * @type \Google\Protobuf\Any $environment + * Any other builder-controlled inputs necessary for correctly evaluating + * the recipe. Usually only needed for reproducing the build but not + * evaluated as part of policy. Depending on the recipe Type, the structure + * may be different. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenance::initOnce(); + parent::__construct($data); + } + + /** + * URI indicating what type of recipe was performed. It determines the + * meaning of recipe.entryPoint, recipe.arguments, recipe.environment, and + * materials. + * + * Generated from protobuf field string type = 1; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * URI indicating what type of recipe was performed. It determines the + * meaning of recipe.entryPoint, recipe.arguments, recipe.environment, and + * materials. + * + * Generated from protobuf field string type = 1; + * @param string $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkString($var, True); + $this->type = $var; + + return $this; + } + + /** + * Index in materials containing the recipe steps that are not implied by + * recipe.type. For example, if the recipe type were "make", then this would + * point to the source containing the Makefile, not the make program itself. + * Set to -1 if the recipe doesn't come from a material, as zero is default + * unset value for int64. + * + * Generated from protobuf field int64 defined_in_material = 2; + * @return int|string + */ + public function getDefinedInMaterial() + { + return $this->defined_in_material; + } + + /** + * Index in materials containing the recipe steps that are not implied by + * recipe.type. For example, if the recipe type were "make", then this would + * point to the source containing the Makefile, not the make program itself. + * Set to -1 if the recipe doesn't come from a material, as zero is default + * unset value for int64. + * + * Generated from protobuf field int64 defined_in_material = 2; + * @param int|string $var + * @return $this + */ + public function setDefinedInMaterial($var) + { + GPBUtil::checkInt64($var); + $this->defined_in_material = $var; + + return $this; + } + + /** + * String identifying the entry point into the build. + * This is often a path to a configuration file and/or a target label within + * that file. The syntax and meaning are defined by recipe.type. For + * example, if the recipe type were "make", then this would reference the + * directory in which to run make as well as which target to use. + * + * Generated from protobuf field string entry_point = 3; + * @return string + */ + public function getEntryPoint() + { + return $this->entry_point; + } + + /** + * String identifying the entry point into the build. + * This is often a path to a configuration file and/or a target label within + * that file. The syntax and meaning are defined by recipe.type. For + * example, if the recipe type were "make", then this would reference the + * directory in which to run make as well as which target to use. + * + * Generated from protobuf field string entry_point = 3; + * @param string $var + * @return $this + */ + public function setEntryPoint($var) + { + GPBUtil::checkString($var, True); + $this->entry_point = $var; + + return $this; + } + + /** + * Collection of all external inputs that influenced the build on top of + * recipe.definedInMaterial and recipe.entryPoint. For example, if the + * recipe type were "make", then this might be the flags passed to make + * aside from the target, which is captured in recipe.entryPoint. Depending + * on the recipe Type, the structure may be different. + * + * Generated from protobuf field .google.protobuf.Any arguments = 4; + * @return \Google\Protobuf\Any|null + */ + public function getArguments() + { + return $this->arguments; + } + + public function hasArguments() + { + return isset($this->arguments); + } + + public function clearArguments() + { + unset($this->arguments); + } + + /** + * Collection of all external inputs that influenced the build on top of + * recipe.definedInMaterial and recipe.entryPoint. For example, if the + * recipe type were "make", then this might be the flags passed to make + * aside from the target, which is captured in recipe.entryPoint. Depending + * on the recipe Type, the structure may be different. + * + * Generated from protobuf field .google.protobuf.Any arguments = 4; + * @param \Google\Protobuf\Any $var + * @return $this + */ + public function setArguments($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Any::class); + $this->arguments = $var; + + return $this; + } + + /** + * Any other builder-controlled inputs necessary for correctly evaluating + * the recipe. Usually only needed for reproducing the build but not + * evaluated as part of policy. Depending on the recipe Type, the structure + * may be different. + * + * Generated from protobuf field .google.protobuf.Any environment = 5; + * @return \Google\Protobuf\Any|null + */ + public function getEnvironment() + { + return $this->environment; + } + + public function hasEnvironment() + { + return isset($this->environment); + } + + public function clearEnvironment() + { + unset($this->environment); + } + + /** + * Any other builder-controlled inputs necessary for correctly evaluating + * the recipe. Usually only needed for reproducing the build but not + * evaluated as part of policy. Depending on the recipe Type, the structure + * may be different. + * + * Generated from protobuf field .google.protobuf.Any environment = 5; + * @param \Google\Protobuf\Any $var + * @return $this + */ + public function setEnvironment($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Any::class); + $this->environment = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SlsaRecipe::class, \Grafeas\V1\SlsaProvenance_SlsaRecipe::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo.php new file mode 100644 index 00000000000..c066b7a6521 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo.php @@ -0,0 +1,235 @@ +grafeas.v1.SlsaProvenanceZeroTwo + */ +class SlsaProvenanceZeroTwo extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaBuilder builder = 1; + */ + protected $builder = null; + /** + * Generated from protobuf field string build_type = 2; + */ + protected $build_type = ''; + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaInvocation invocation = 3; + */ + protected $invocation = null; + /** + * Generated from protobuf field .google.protobuf.Struct build_config = 4; + */ + protected $build_config = null; + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaMetadata metadata = 5; + */ + protected $metadata = null; + /** + * Generated from protobuf field repeated .grafeas.v1.SlsaProvenanceZeroTwo.SlsaMaterial materials = 6; + */ + private $materials; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaBuilder $builder + * @type string $build_type + * @type \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaInvocation $invocation + * @type \Google\Protobuf\Struct $build_config + * @type \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMetadata $metadata + * @type array<\Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMaterial>|\Google\Protobuf\Internal\RepeatedField $materials + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaBuilder builder = 1; + * @return \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaBuilder|null + */ + public function getBuilder() + { + return $this->builder; + } + + public function hasBuilder() + { + return isset($this->builder); + } + + public function clearBuilder() + { + unset($this->builder); + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaBuilder builder = 1; + * @param \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaBuilder $var + * @return $this + */ + public function setBuilder($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaBuilder::class); + $this->builder = $var; + + return $this; + } + + /** + * Generated from protobuf field string build_type = 2; + * @return string + */ + public function getBuildType() + { + return $this->build_type; + } + + /** + * Generated from protobuf field string build_type = 2; + * @param string $var + * @return $this + */ + public function setBuildType($var) + { + GPBUtil::checkString($var, True); + $this->build_type = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaInvocation invocation = 3; + * @return \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaInvocation|null + */ + public function getInvocation() + { + return $this->invocation; + } + + public function hasInvocation() + { + return isset($this->invocation); + } + + public function clearInvocation() + { + unset($this->invocation); + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaInvocation invocation = 3; + * @param \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaInvocation $var + * @return $this + */ + public function setInvocation($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaInvocation::class); + $this->invocation = $var; + + return $this; + } + + /** + * Generated from protobuf field .google.protobuf.Struct build_config = 4; + * @return \Google\Protobuf\Struct|null + */ + public function getBuildConfig() + { + return $this->build_config; + } + + public function hasBuildConfig() + { + return isset($this->build_config); + } + + public function clearBuildConfig() + { + unset($this->build_config); + } + + /** + * Generated from protobuf field .google.protobuf.Struct build_config = 4; + * @param \Google\Protobuf\Struct $var + * @return $this + */ + public function setBuildConfig($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); + $this->build_config = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaMetadata metadata = 5; + * @return \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMetadata|null + */ + public function getMetadata() + { + return $this->metadata; + } + + public function hasMetadata() + { + return isset($this->metadata); + } + + public function clearMetadata() + { + unset($this->metadata); + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaMetadata metadata = 5; + * @param \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMetadata $var + * @return $this + */ + public function setMetadata($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMetadata::class); + $this->metadata = $var; + + return $this; + } + + /** + * Generated from protobuf field repeated .grafeas.v1.SlsaProvenanceZeroTwo.SlsaMaterial materials = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMaterials() + { + return $this->materials; + } + + /** + * Generated from protobuf field repeated .grafeas.v1.SlsaProvenanceZeroTwo.SlsaMaterial materials = 6; + * @param array<\Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMaterial>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMaterials($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMaterial::class); + $this->materials = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaBuilder.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaBuilder.php new file mode 100644 index 00000000000..8029c7d4c11 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaBuilder.php @@ -0,0 +1,64 @@ +grafeas.v1.SlsaProvenanceZeroTwo.SlsaBuilder + */ +class SlsaBuilder extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SlsaBuilder::class, \Grafeas\V1\SlsaProvenanceZeroTwo_SlsaBuilder::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaCompleteness.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaCompleteness.php new file mode 100644 index 00000000000..dcb6e0a819c --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaCompleteness.php @@ -0,0 +1,118 @@ +grafeas.v1.SlsaProvenanceZeroTwo.SlsaCompleteness + */ +class SlsaCompleteness extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field bool parameters = 1; + */ + protected $parameters = false; + /** + * Generated from protobuf field bool environment = 2; + */ + protected $environment = false; + /** + * Generated from protobuf field bool materials = 3; + */ + protected $materials = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $parameters + * @type bool $environment + * @type bool $materials + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field bool parameters = 1; + * @return bool + */ + public function getParameters() + { + return $this->parameters; + } + + /** + * Generated from protobuf field bool parameters = 1; + * @param bool $var + * @return $this + */ + public function setParameters($var) + { + GPBUtil::checkBool($var); + $this->parameters = $var; + + return $this; + } + + /** + * Generated from protobuf field bool environment = 2; + * @return bool + */ + public function getEnvironment() + { + return $this->environment; + } + + /** + * Generated from protobuf field bool environment = 2; + * @param bool $var + * @return $this + */ + public function setEnvironment($var) + { + GPBUtil::checkBool($var); + $this->environment = $var; + + return $this; + } + + /** + * Generated from protobuf field bool materials = 3; + * @return bool + */ + public function getMaterials() + { + return $this->materials; + } + + /** + * Generated from protobuf field bool materials = 3; + * @param bool $var + * @return $this + */ + public function setMaterials($var) + { + GPBUtil::checkBool($var); + $this->materials = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SlsaCompleteness::class, \Grafeas\V1\SlsaProvenanceZeroTwo_SlsaCompleteness::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaConfigSource.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaConfigSource.php new file mode 100644 index 00000000000..236b9d68539 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaConfigSource.php @@ -0,0 +1,118 @@ +grafeas.v1.SlsaProvenanceZeroTwo.SlsaConfigSource + */ +class SlsaConfigSource extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field string uri = 1; + */ + protected $uri = ''; + /** + * Generated from protobuf field map digest = 2; + */ + private $digest; + /** + * Generated from protobuf field string entry_point = 3; + */ + protected $entry_point = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $uri + * @type array|\Google\Protobuf\Internal\MapField $digest + * @type string $entry_point + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field string uri = 1; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * Generated from protobuf field string uri = 1; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + + /** + * Generated from protobuf field map digest = 2; + * @return \Google\Protobuf\Internal\MapField + */ + public function getDigest() + { + return $this->digest; + } + + /** + * Generated from protobuf field map digest = 2; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setDigest($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->digest = $arr; + + return $this; + } + + /** + * Generated from protobuf field string entry_point = 3; + * @return string + */ + public function getEntryPoint() + { + return $this->entry_point; + } + + /** + * Generated from protobuf field string entry_point = 3; + * @param string $var + * @return $this + */ + public function setEntryPoint($var) + { + GPBUtil::checkString($var, True); + $this->entry_point = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SlsaConfigSource::class, \Grafeas\V1\SlsaProvenanceZeroTwo_SlsaConfigSource::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaInvocation.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaInvocation.php new file mode 100644 index 00000000000..14076ccc465 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaInvocation.php @@ -0,0 +1,147 @@ +grafeas.v1.SlsaProvenanceZeroTwo.SlsaInvocation + */ +class SlsaInvocation extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaConfigSource config_source = 1; + */ + protected $config_source = null; + /** + * Generated from protobuf field .google.protobuf.Struct parameters = 2; + */ + protected $parameters = null; + /** + * Generated from protobuf field .google.protobuf.Struct environment = 3; + */ + protected $environment = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaConfigSource $config_source + * @type \Google\Protobuf\Struct $parameters + * @type \Google\Protobuf\Struct $environment + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaConfigSource config_source = 1; + * @return \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaConfigSource|null + */ + public function getConfigSource() + { + return $this->config_source; + } + + public function hasConfigSource() + { + return isset($this->config_source); + } + + public function clearConfigSource() + { + unset($this->config_source); + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaConfigSource config_source = 1; + * @param \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaConfigSource $var + * @return $this + */ + public function setConfigSource($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaConfigSource::class); + $this->config_source = $var; + + return $this; + } + + /** + * Generated from protobuf field .google.protobuf.Struct parameters = 2; + * @return \Google\Protobuf\Struct|null + */ + public function getParameters() + { + return $this->parameters; + } + + public function hasParameters() + { + return isset($this->parameters); + } + + public function clearParameters() + { + unset($this->parameters); + } + + /** + * Generated from protobuf field .google.protobuf.Struct parameters = 2; + * @param \Google\Protobuf\Struct $var + * @return $this + */ + public function setParameters($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); + $this->parameters = $var; + + return $this; + } + + /** + * Generated from protobuf field .google.protobuf.Struct environment = 3; + * @return \Google\Protobuf\Struct|null + */ + public function getEnvironment() + { + return $this->environment; + } + + public function hasEnvironment() + { + return isset($this->environment); + } + + public function clearEnvironment() + { + unset($this->environment); + } + + /** + * Generated from protobuf field .google.protobuf.Struct environment = 3; + * @param \Google\Protobuf\Struct $var + * @return $this + */ + public function setEnvironment($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); + $this->environment = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SlsaInvocation::class, \Grafeas\V1\SlsaProvenanceZeroTwo_SlsaInvocation::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMaterial.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMaterial.php new file mode 100644 index 00000000000..e25c459a24c --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMaterial.php @@ -0,0 +1,91 @@ +grafeas.v1.SlsaProvenanceZeroTwo.SlsaMaterial + */ +class SlsaMaterial extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field string uri = 1; + */ + protected $uri = ''; + /** + * Generated from protobuf field map digest = 2; + */ + private $digest; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $uri + * @type array|\Google\Protobuf\Internal\MapField $digest + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field string uri = 1; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * Generated from protobuf field string uri = 1; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + + /** + * Generated from protobuf field map digest = 2; + * @return \Google\Protobuf\Internal\MapField + */ + public function getDigest() + { + return $this->digest; + } + + /** + * Generated from protobuf field map digest = 2; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setDigest($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->digest = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SlsaMaterial::class, \Grafeas\V1\SlsaProvenanceZeroTwo_SlsaMaterial::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMetadata.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMetadata.php new file mode 100644 index 00000000000..611a1e27205 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMetadata.php @@ -0,0 +1,201 @@ +grafeas.v1.SlsaProvenanceZeroTwo.SlsaMetadata + */ +class SlsaMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field string build_invocation_id = 1; + */ + protected $build_invocation_id = ''; + /** + * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; + */ + protected $build_started_on = null; + /** + * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; + */ + protected $build_finished_on = null; + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaCompleteness completeness = 4; + */ + protected $completeness = null; + /** + * Generated from protobuf field bool reproducible = 5; + */ + protected $reproducible = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $build_invocation_id + * @type \Google\Protobuf\Timestamp $build_started_on + * @type \Google\Protobuf\Timestamp $build_finished_on + * @type \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaCompleteness $completeness + * @type bool $reproducible + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field string build_invocation_id = 1; + * @return string + */ + public function getBuildInvocationId() + { + return $this->build_invocation_id; + } + + /** + * Generated from protobuf field string build_invocation_id = 1; + * @param string $var + * @return $this + */ + public function setBuildInvocationId($var) + { + GPBUtil::checkString($var, True); + $this->build_invocation_id = $var; + + return $this; + } + + /** + * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getBuildStartedOn() + { + return $this->build_started_on; + } + + public function hasBuildStartedOn() + { + return isset($this->build_started_on); + } + + public function clearBuildStartedOn() + { + unset($this->build_started_on); + } + + /** + * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setBuildStartedOn($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->build_started_on = $var; + + return $this; + } + + /** + * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; + * @return \Google\Protobuf\Timestamp|null + */ + public function getBuildFinishedOn() + { + return $this->build_finished_on; + } + + public function hasBuildFinishedOn() + { + return isset($this->build_finished_on); + } + + public function clearBuildFinishedOn() + { + unset($this->build_finished_on); + } + + /** + * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setBuildFinishedOn($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->build_finished_on = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaCompleteness completeness = 4; + * @return \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaCompleteness|null + */ + public function getCompleteness() + { + return $this->completeness; + } + + public function hasCompleteness() + { + return isset($this->completeness); + } + + public function clearCompleteness() + { + unset($this->completeness); + } + + /** + * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaCompleteness completeness = 4; + * @param \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaCompleteness $var + * @return $this + */ + public function setCompleteness($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaCompleteness::class); + $this->completeness = $var; + + return $this; + } + + /** + * Generated from protobuf field bool reproducible = 5; + * @return bool + */ + public function getReproducible() + { + return $this->reproducible; + } + + /** + * Generated from protobuf field bool reproducible = 5; + * @param bool $var + * @return $this + */ + public function setReproducible($var) + { + GPBUtil::checkBool($var); + $this->reproducible = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SlsaMetadata::class, \Grafeas\V1\SlsaProvenanceZeroTwo_SlsaMetadata::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaBuilder.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaBuilder.php new file mode 100644 index 00000000000..47d4e33cdfd --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaBuilder.php @@ -0,0 +1,16 @@ +grafeas.v1.Source + */ +class Source extends \Google\Protobuf\Internal\Message +{ + /** + * If provided, the input binary artifacts for the build came from this + * location. + * + * Generated from protobuf field string artifact_storage_source_uri = 1; + */ + protected $artifact_storage_source_uri = ''; + /** + * 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. + * + * Generated from protobuf field map file_hashes = 2; + */ + private $file_hashes; + /** + * If provided, the source code used for the build came from this location. + * + * Generated from protobuf field .grafeas.v1.SourceContext context = 3; + */ + protected $context = null; + /** + * 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. + * + * Generated from protobuf field repeated .grafeas.v1.SourceContext additional_contexts = 4; + */ + private $additional_contexts; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $artifact_storage_source_uri + * If provided, the input binary artifacts for the build came from this + * location. + * @type array|\Google\Protobuf\Internal\MapField $file_hashes + * 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. + * @type \Grafeas\V1\SourceContext $context + * If provided, the source code used for the build came from this location. + * @type array<\Grafeas\V1\SourceContext>|\Google\Protobuf\Internal\RepeatedField $additional_contexts + * 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * If provided, the input binary artifacts for the build came from this + * location. + * + * Generated from protobuf field string artifact_storage_source_uri = 1; + * @return string + */ + public function getArtifactStorageSourceUri() + { + return $this->artifact_storage_source_uri; + } + + /** + * If provided, the input binary artifacts for the build came from this + * location. + * + * Generated from protobuf field string artifact_storage_source_uri = 1; + * @param string $var + * @return $this + */ + public function setArtifactStorageSourceUri($var) + { + GPBUtil::checkString($var, True); + $this->artifact_storage_source_uri = $var; + + 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. + * + * Generated from protobuf field map file_hashes = 2; + * @return \Google\Protobuf\Internal\MapField + */ + public function getFileHashes() + { + return $this->file_hashes; + } + + /** + * 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. + * + * Generated from protobuf field map file_hashes = 2; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setFileHashes($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\FileHashes::class); + $this->file_hashes = $arr; + + return $this; + } + + /** + * If provided, the source code used for the build came from this location. + * + * Generated from protobuf field .grafeas.v1.SourceContext context = 3; + * @return \Grafeas\V1\SourceContext|null + */ + public function getContext() + { + return $this->context; + } + + public function hasContext() + { + return isset($this->context); + } + + public function clearContext() + { + unset($this->context); + } + + /** + * If provided, the source code used for the build came from this location. + * + * Generated from protobuf field .grafeas.v1.SourceContext context = 3; + * @param \Grafeas\V1\SourceContext $var + * @return $this + */ + public function setContext($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\SourceContext::class); + $this->context = $var; + + 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. + * + * Generated from protobuf field repeated .grafeas.v1.SourceContext additional_contexts = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAdditionalContexts() + { + return $this->additional_contexts; + } + + /** + * 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. + * + * Generated from protobuf field repeated .grafeas.v1.SourceContext additional_contexts = 4; + * @param array<\Grafeas\V1\SourceContext>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAdditionalContexts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\SourceContext::class); + $this->additional_contexts = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SourceContext.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SourceContext.php new file mode 100644 index 00000000000..fced17b0d00 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SourceContext.php @@ -0,0 +1,176 @@ +grafeas.v1.SourceContext + */ +class SourceContext extends \Google\Protobuf\Internal\Message +{ + /** + * Labels with user defined metadata. + * + * Generated from protobuf field map labels = 4; + */ + private $labels; + protected $context; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\CloudRepoSourceContext $cloud_repo + * A SourceContext referring to a revision in a Google Cloud Source Repo. + * @type \Grafeas\V1\GerritSourceContext $gerrit + * A SourceContext referring to a Gerrit project. + * @type \Grafeas\V1\GitSourceContext $git + * A SourceContext referring to any third party Git repo (e.g., GitHub). + * @type array|\Google\Protobuf\Internal\MapField $labels + * Labels with user defined metadata. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Provenance::initOnce(); + parent::__construct($data); + } + + /** + * A SourceContext referring to a revision in a Google Cloud Source Repo. + * + * Generated from protobuf field .grafeas.v1.CloudRepoSourceContext cloud_repo = 1; + * @return \Grafeas\V1\CloudRepoSourceContext|null + */ + public function getCloudRepo() + { + return $this->readOneof(1); + } + + public function hasCloudRepo() + { + return $this->hasOneof(1); + } + + /** + * A SourceContext referring to a revision in a Google Cloud Source Repo. + * + * Generated from protobuf field .grafeas.v1.CloudRepoSourceContext cloud_repo = 1; + * @param \Grafeas\V1\CloudRepoSourceContext $var + * @return $this + */ + public function setCloudRepo($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\CloudRepoSourceContext::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * A SourceContext referring to a Gerrit project. + * + * Generated from protobuf field .grafeas.v1.GerritSourceContext gerrit = 2; + * @return \Grafeas\V1\GerritSourceContext|null + */ + public function getGerrit() + { + return $this->readOneof(2); + } + + public function hasGerrit() + { + return $this->hasOneof(2); + } + + /** + * A SourceContext referring to a Gerrit project. + * + * Generated from protobuf field .grafeas.v1.GerritSourceContext gerrit = 2; + * @param \Grafeas\V1\GerritSourceContext $var + * @return $this + */ + public function setGerrit($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\GerritSourceContext::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * A SourceContext referring to any third party Git repo (e.g., GitHub). + * + * Generated from protobuf field .grafeas.v1.GitSourceContext git = 3; + * @return \Grafeas\V1\GitSourceContext|null + */ + public function getGit() + { + return $this->readOneof(3); + } + + public function hasGit() + { + return $this->hasOneof(3); + } + + /** + * A SourceContext referring to any third party Git repo (e.g., GitHub). + * + * Generated from protobuf field .grafeas.v1.GitSourceContext git = 3; + * @param \Grafeas\V1\GitSourceContext $var + * @return $this + */ + public function setGit($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\GitSourceContext::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Labels with user defined metadata. + * + * Generated from protobuf field map labels = 4; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Labels with user defined metadata. + * + * Generated from protobuf field map labels = 4; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setLabels($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->labels = $arr; + + return $this; + } + + /** + * @return string + */ + public function getContext() + { + return $this->whichOneof("context"); + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Subject.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Subject.php new file mode 100644 index 00000000000..14d4fa6fe2e --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Subject.php @@ -0,0 +1,104 @@ +grafeas.v1.Subject + */ +class Subject extends \Google\Protobuf\Internal\Message +{ + /** + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * `"": ""` + * Algorithms can be e.g. sha256, sha512 + * See + * https://github.com/in-toto/attestation/blob/main/spec/field_types.md#DigestSet + * + * Generated from protobuf field map digest = 2; + */ + private $digest; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * @type array|\Google\Protobuf\Internal\MapField $digest + * `"": ""` + * Algorithms can be e.g. sha256, sha512 + * See + * https://github.com/in-toto/attestation/blob/main/spec/field_types.md#DigestSet + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\IntotoStatement::initOnce(); + parent::__construct($data); + } + + /** + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * `"": ""` + * Algorithms can be e.g. sha256, sha512 + * See + * https://github.com/in-toto/attestation/blob/main/spec/field_types.md#DigestSet + * + * Generated from protobuf field map digest = 2; + * @return \Google\Protobuf\Internal\MapField + */ + public function getDigest() + { + return $this->digest; + } + + /** + * `"": ""` + * Algorithms can be e.g. sha256, sha512 + * See + * https://github.com/in-toto/attestation/blob/main/spec/field_types.md#DigestSet + * + * Generated from protobuf field map digest = 2; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setDigest($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->digest = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateNoteRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateNoteRequest.php new file mode 100644 index 00000000000..f9630fde979 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateNoteRequest.php @@ -0,0 +1,159 @@ +grafeas.v1.UpdateNoteRequest + */ +class UpdateNoteRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * The updated note. + * + * Generated from protobuf field .grafeas.v1.Note note = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $note = null; + /** + * The fields to update. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; + */ + protected $update_mask = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * @type \Grafeas\V1\Note $note + * The updated note. + * @type \Google\Protobuf\FieldMask $update_mask + * The fields to update. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The updated note. + * + * Generated from protobuf field .grafeas.v1.Note note = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Grafeas\V1\Note|null + */ + public function getNote() + { + return $this->note; + } + + public function hasNote() + { + return isset($this->note); + } + + public function clearNote() + { + unset($this->note); + } + + /** + * The updated note. + * + * Generated from protobuf field .grafeas.v1.Note note = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Grafeas\V1\Note $var + * @return $this + */ + public function setNote($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Note::class); + $this->note = $var; + + return $this; + } + + /** + * The fields to update. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The fields to update. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateOccurrenceRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateOccurrenceRequest.php new file mode 100644 index 00000000000..6e79019d4de --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateOccurrenceRequest.php @@ -0,0 +1,159 @@ +grafeas.v1.UpdateOccurrenceRequest + */ +class UpdateOccurrenceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * The updated occurrence. + * + * Generated from protobuf field .grafeas.v1.Occurrence occurrence = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $occurrence = null; + /** + * The fields to update. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; + */ + protected $update_mask = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * @type \Grafeas\V1\Occurrence $occurrence + * The updated occurrence. + * @type \Google\Protobuf\FieldMask $update_mask + * The fields to update. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); + parent::__construct($data); + } + + /** + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The updated occurrence. + * + * Generated from protobuf field .grafeas.v1.Occurrence occurrence = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Grafeas\V1\Occurrence|null + */ + public function getOccurrence() + { + return $this->occurrence; + } + + public function hasOccurrence() + { + return isset($this->occurrence); + } + + public function clearOccurrence() + { + unset($this->occurrence); + } + + /** + * The updated occurrence. + * + * Generated from protobuf field .grafeas.v1.Occurrence occurrence = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Grafeas\V1\Occurrence $var + * @return $this + */ + public function setOccurrence($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Occurrence::class); + $this->occurrence = $var; + + return $this; + } + + /** + * The fields to update. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The fields to update. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeDistribution.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeDistribution.php new file mode 100644 index 00000000000..b5b16a112b0 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeDistribution.php @@ -0,0 +1,187 @@ +grafeas.v1.UpgradeDistribution + */ +class UpgradeDistribution extends \Google\Protobuf\Internal\Message +{ + /** + * Required - The specific operating system this metadata applies to. See + * https://cpe.mitre.org/specification/. + * + * Generated from protobuf field string cpe_uri = 1; + */ + protected $cpe_uri = ''; + /** + * The operating system classification of this Upgrade, as specified by the + * upstream operating system upgrade feed. For Windows the classification is + * one of the category_ids listed at + * https://docs.microsoft.com/en-us/previous-versions/windows/desktop/ff357803(v=vs.85) + * + * Generated from protobuf field string classification = 2; + */ + protected $classification = ''; + /** + * The severity as specified by the upstream operating system. + * + * Generated from protobuf field string severity = 3; + */ + protected $severity = ''; + /** + * The cve tied to this Upgrade. + * + * Generated from protobuf field repeated string cve = 4; + */ + private $cve; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $cpe_uri + * Required - The specific operating system this metadata applies to. See + * https://cpe.mitre.org/specification/. + * @type string $classification + * The operating system classification of this Upgrade, as specified by the + * upstream operating system upgrade feed. For Windows the classification is + * one of the category_ids listed at + * https://docs.microsoft.com/en-us/previous-versions/windows/desktop/ff357803(v=vs.85) + * @type string $severity + * The severity as specified by the upstream operating system. + * @type array|\Google\Protobuf\Internal\RepeatedField $cve + * The cve tied to this Upgrade. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Upgrade::initOnce(); + parent::__construct($data); + } + + /** + * Required - The specific operating system this metadata applies to. See + * https://cpe.mitre.org/specification/. + * + * Generated from protobuf field string cpe_uri = 1; + * @return string + */ + public function getCpeUri() + { + return $this->cpe_uri; + } + + /** + * Required - The specific operating system this metadata applies to. See + * https://cpe.mitre.org/specification/. + * + * Generated from protobuf field string cpe_uri = 1; + * @param string $var + * @return $this + */ + public function setCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->cpe_uri = $var; + + return $this; + } + + /** + * The operating system classification of this Upgrade, as specified by the + * upstream operating system upgrade feed. For Windows the classification is + * one of the category_ids listed at + * https://docs.microsoft.com/en-us/previous-versions/windows/desktop/ff357803(v=vs.85) + * + * Generated from protobuf field string classification = 2; + * @return string + */ + public function getClassification() + { + return $this->classification; + } + + /** + * The operating system classification of this Upgrade, as specified by the + * upstream operating system upgrade feed. For Windows the classification is + * one of the category_ids listed at + * https://docs.microsoft.com/en-us/previous-versions/windows/desktop/ff357803(v=vs.85) + * + * Generated from protobuf field string classification = 2; + * @param string $var + * @return $this + */ + public function setClassification($var) + { + GPBUtil::checkString($var, True); + $this->classification = $var; + + return $this; + } + + /** + * The severity as specified by the upstream operating system. + * + * Generated from protobuf field string severity = 3; + * @return string + */ + public function getSeverity() + { + return $this->severity; + } + + /** + * The severity as specified by the upstream operating system. + * + * Generated from protobuf field string severity = 3; + * @param string $var + * @return $this + */ + public function setSeverity($var) + { + GPBUtil::checkString($var, True); + $this->severity = $var; + + return $this; + } + + /** + * The cve tied to this Upgrade. + * + * Generated from protobuf field repeated string cve = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getCve() + { + return $this->cve; + } + + /** + * The cve tied to this Upgrade. + * + * Generated from protobuf field repeated string cve = 4; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setCve($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->cve = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeNote.php new file mode 100644 index 00000000000..b91b637b0c3 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeNote.php @@ -0,0 +1,196 @@ +grafeas.v1.UpgradeNote + */ +class UpgradeNote extends \Google\Protobuf\Internal\Message +{ + /** + * Required for non-Windows OS. The package this Upgrade is for. + * + * Generated from protobuf field string package = 1; + */ + protected $package = ''; + /** + * Required for non-Windows OS. The version of the package in machine + human + * readable form. + * + * Generated from protobuf field .grafeas.v1.Version version = 2; + */ + protected $version = null; + /** + * Metadata about the upgrade for each specific operating system. + * + * Generated from protobuf field repeated .grafeas.v1.UpgradeDistribution distributions = 3; + */ + private $distributions; + /** + * Required for Windows OS. Represents the metadata about the Windows update. + * + * Generated from protobuf field .grafeas.v1.WindowsUpdate windows_update = 4; + */ + protected $windows_update = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $package + * Required for non-Windows OS. The package this Upgrade is for. + * @type \Grafeas\V1\Version $version + * Required for non-Windows OS. The version of the package in machine + human + * readable form. + * @type array<\Grafeas\V1\UpgradeDistribution>|\Google\Protobuf\Internal\RepeatedField $distributions + * Metadata about the upgrade for each specific operating system. + * @type \Grafeas\V1\WindowsUpdate $windows_update + * Required for Windows OS. Represents the metadata about the Windows update. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Upgrade::initOnce(); + parent::__construct($data); + } + + /** + * Required for non-Windows OS. The package this Upgrade is for. + * + * Generated from protobuf field string package = 1; + * @return string + */ + public function getPackage() + { + return $this->package; + } + + /** + * Required for non-Windows OS. The package this Upgrade is for. + * + * Generated from protobuf field string package = 1; + * @param string $var + * @return $this + */ + public function setPackage($var) + { + GPBUtil::checkString($var, True); + $this->package = $var; + + return $this; + } + + /** + * Required for non-Windows OS. The version of the package in machine + human + * readable form. + * + * Generated from protobuf field .grafeas.v1.Version version = 2; + * @return \Grafeas\V1\Version|null + */ + public function getVersion() + { + return $this->version; + } + + public function hasVersion() + { + return isset($this->version); + } + + public function clearVersion() + { + unset($this->version); + } + + /** + * Required for non-Windows OS. The version of the package in machine + human + * readable form. + * + * Generated from protobuf field .grafeas.v1.Version version = 2; + * @param \Grafeas\V1\Version $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); + $this->version = $var; + + return $this; + } + + /** + * Metadata about the upgrade for each specific operating system. + * + * Generated from protobuf field repeated .grafeas.v1.UpgradeDistribution distributions = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDistributions() + { + return $this->distributions; + } + + /** + * Metadata about the upgrade for each specific operating system. + * + * Generated from protobuf field repeated .grafeas.v1.UpgradeDistribution distributions = 3; + * @param array<\Grafeas\V1\UpgradeDistribution>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDistributions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\UpgradeDistribution::class); + $this->distributions = $arr; + + return $this; + } + + /** + * Required for Windows OS. Represents the metadata about the Windows update. + * + * Generated from protobuf field .grafeas.v1.WindowsUpdate windows_update = 4; + * @return \Grafeas\V1\WindowsUpdate|null + */ + public function getWindowsUpdate() + { + return $this->windows_update; + } + + public function hasWindowsUpdate() + { + return isset($this->windows_update); + } + + public function clearWindowsUpdate() + { + unset($this->windows_update); + } + + /** + * Required for Windows OS. Represents the metadata about the Windows update. + * + * Generated from protobuf field .grafeas.v1.WindowsUpdate windows_update = 4; + * @param \Grafeas\V1\WindowsUpdate $var + * @return $this + */ + public function setWindowsUpdate($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\WindowsUpdate::class); + $this->windows_update = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeOccurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeOccurrence.php new file mode 100644 index 00000000000..15c700918d0 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeOccurrence.php @@ -0,0 +1,215 @@ +grafeas.v1.UpgradeOccurrence + */ +class UpgradeOccurrence extends \Google\Protobuf\Internal\Message +{ + /** + * Required for non-Windows OS. The package this Upgrade is for. + * + * Generated from protobuf field string package = 1; + */ + protected $package = ''; + /** + * Required for non-Windows OS. The version of the package in a machine + + * human readable form. + * + * Generated from protobuf field .grafeas.v1.Version parsed_version = 3; + */ + protected $parsed_version = null; + /** + * Metadata about the upgrade for available for the specific operating system + * for the resource_url. This allows efficient filtering, as well as + * making it easier to use the occurrence. + * + * Generated from protobuf field .grafeas.v1.UpgradeDistribution distribution = 4; + */ + protected $distribution = null; + /** + * Required for Windows OS. Represents the metadata about the Windows update. + * + * Generated from protobuf field .grafeas.v1.WindowsUpdate windows_update = 5; + */ + protected $windows_update = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $package + * Required for non-Windows OS. The package this Upgrade is for. + * @type \Grafeas\V1\Version $parsed_version + * Required for non-Windows OS. The version of the package in a machine + + * human readable form. + * @type \Grafeas\V1\UpgradeDistribution $distribution + * Metadata about the upgrade for available for the specific operating system + * for the resource_url. This allows efficient filtering, as well as + * making it easier to use the occurrence. + * @type \Grafeas\V1\WindowsUpdate $windows_update + * Required for Windows OS. Represents the metadata about the Windows update. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Upgrade::initOnce(); + parent::__construct($data); + } + + /** + * Required for non-Windows OS. The package this Upgrade is for. + * + * Generated from protobuf field string package = 1; + * @return string + */ + public function getPackage() + { + return $this->package; + } + + /** + * Required for non-Windows OS. The package this Upgrade is for. + * + * Generated from protobuf field string package = 1; + * @param string $var + * @return $this + */ + public function setPackage($var) + { + GPBUtil::checkString($var, True); + $this->package = $var; + + return $this; + } + + /** + * Required for non-Windows OS. The version of the package in a machine + + * human readable form. + * + * Generated from protobuf field .grafeas.v1.Version parsed_version = 3; + * @return \Grafeas\V1\Version|null + */ + public function getParsedVersion() + { + return $this->parsed_version; + } + + public function hasParsedVersion() + { + return isset($this->parsed_version); + } + + public function clearParsedVersion() + { + unset($this->parsed_version); + } + + /** + * Required for non-Windows OS. The version of the package in a machine + + * human readable form. + * + * Generated from protobuf field .grafeas.v1.Version parsed_version = 3; + * @param \Grafeas\V1\Version $var + * @return $this + */ + public function setParsedVersion($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); + $this->parsed_version = $var; + + return $this; + } + + /** + * Metadata about the upgrade for available for the specific operating system + * for the resource_url. This allows efficient filtering, as well as + * making it easier to use the occurrence. + * + * Generated from protobuf field .grafeas.v1.UpgradeDistribution distribution = 4; + * @return \Grafeas\V1\UpgradeDistribution|null + */ + public function getDistribution() + { + return $this->distribution; + } + + public function hasDistribution() + { + return isset($this->distribution); + } + + public function clearDistribution() + { + unset($this->distribution); + } + + /** + * Metadata about the upgrade for available for the specific operating system + * for the resource_url. This allows efficient filtering, as well as + * making it easier to use the occurrence. + * + * Generated from protobuf field .grafeas.v1.UpgradeDistribution distribution = 4; + * @param \Grafeas\V1\UpgradeDistribution $var + * @return $this + */ + public function setDistribution($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\UpgradeDistribution::class); + $this->distribution = $var; + + return $this; + } + + /** + * Required for Windows OS. Represents the metadata about the Windows update. + * + * Generated from protobuf field .grafeas.v1.WindowsUpdate windows_update = 5; + * @return \Grafeas\V1\WindowsUpdate|null + */ + public function getWindowsUpdate() + { + return $this->windows_update; + } + + public function hasWindowsUpdate() + { + return isset($this->windows_update); + } + + public function clearWindowsUpdate() + { + unset($this->windows_update); + } + + /** + * Required for Windows OS. Represents the metadata about the Windows update. + * + * Generated from protobuf field .grafeas.v1.WindowsUpdate windows_update = 5; + * @param \Grafeas\V1\WindowsUpdate $var + * @return $this + */ + public function setWindowsUpdate($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\WindowsUpdate::class); + $this->windows_update = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version.php new file mode 100644 index 00000000000..ed635362b2f --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version.php @@ -0,0 +1,269 @@ +grafeas.v1.Version + */ +class Version extends \Google\Protobuf\Internal\Message +{ + /** + * Used to correct mistakes in the version numbering scheme. + * + * Generated from protobuf field int32 epoch = 1; + */ + protected $epoch = 0; + /** + * Required only when version kind is NORMAL. The main part of the version + * name. + * + * Generated from protobuf field string name = 2; + */ + protected $name = ''; + /** + * The iteration of the package build from the above version. + * + * Generated from protobuf field string revision = 3; + */ + protected $revision = ''; + /** + * Whether this version is specifying part of an inclusive range. Grafeas + * does not have the capability to specify version ranges; instead we have + * fields that specify start version and end versions. At times this is + * insufficient - we also need to specify whether the version is included in + * the range or is excluded from the range. This boolean is expected to be set + * to true when the version is included in a range. + * + * Generated from protobuf field bool inclusive = 6; + */ + protected $inclusive = false; + /** + * Required. Distinguishes between sentinel MIN/MAX versions and normal + * versions. + * + * Generated from protobuf field .grafeas.v1.Version.VersionKind kind = 4; + */ + protected $kind = 0; + /** + * Human readable version string. This string is of the form + * :- and is only set when kind is NORMAL. + * + * Generated from protobuf field string full_name = 5; + */ + protected $full_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $epoch + * Used to correct mistakes in the version numbering scheme. + * @type string $name + * Required only when version kind is NORMAL. The main part of the version + * name. + * @type string $revision + * The iteration of the package build from the above version. + * @type bool $inclusive + * Whether this version is specifying part of an inclusive range. Grafeas + * does not have the capability to specify version ranges; instead we have + * fields that specify start version and end versions. At times this is + * insufficient - we also need to specify whether the version is included in + * the range or is excluded from the range. This boolean is expected to be set + * to true when the version is included in a range. + * @type int $kind + * Required. Distinguishes between sentinel MIN/MAX versions and normal + * versions. + * @type string $full_name + * Human readable version string. This string is of the form + * :- and is only set when kind is NORMAL. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Package::initOnce(); + parent::__construct($data); + } + + /** + * Used to correct mistakes in the version numbering scheme. + * + * Generated from protobuf field int32 epoch = 1; + * @return int + */ + public function getEpoch() + { + return $this->epoch; + } + + /** + * Used to correct mistakes in the version numbering scheme. + * + * Generated from protobuf field int32 epoch = 1; + * @param int $var + * @return $this + */ + public function setEpoch($var) + { + GPBUtil::checkInt32($var); + $this->epoch = $var; + + return $this; + } + + /** + * Required only when version kind is NORMAL. The main part of the version + * name. + * + * Generated from protobuf field string name = 2; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required only when version kind is NORMAL. The main part of the version + * name. + * + * Generated from protobuf field string name = 2; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The iteration of the package build from the above version. + * + * Generated from protobuf field string revision = 3; + * @return string + */ + public function getRevision() + { + return $this->revision; + } + + /** + * The iteration of the package build from the above version. + * + * Generated from protobuf field string revision = 3; + * @param string $var + * @return $this + */ + public function setRevision($var) + { + GPBUtil::checkString($var, True); + $this->revision = $var; + + return $this; + } + + /** + * Whether this version is specifying part of an inclusive range. Grafeas + * does not have the capability to specify version ranges; instead we have + * fields that specify start version and end versions. At times this is + * insufficient - we also need to specify whether the version is included in + * the range or is excluded from the range. This boolean is expected to be set + * to true when the version is included in a range. + * + * Generated from protobuf field bool inclusive = 6; + * @return bool + */ + public function getInclusive() + { + return $this->inclusive; + } + + /** + * Whether this version is specifying part of an inclusive range. Grafeas + * does not have the capability to specify version ranges; instead we have + * fields that specify start version and end versions. At times this is + * insufficient - we also need to specify whether the version is included in + * the range or is excluded from the range. This boolean is expected to be set + * to true when the version is included in a range. + * + * Generated from protobuf field bool inclusive = 6; + * @param bool $var + * @return $this + */ + public function setInclusive($var) + { + GPBUtil::checkBool($var); + $this->inclusive = $var; + + return $this; + } + + /** + * Required. Distinguishes between sentinel MIN/MAX versions and normal + * versions. + * + * Generated from protobuf field .grafeas.v1.Version.VersionKind kind = 4; + * @return int + */ + public function getKind() + { + return $this->kind; + } + + /** + * Required. Distinguishes between sentinel MIN/MAX versions and normal + * versions. + * + * Generated from protobuf field .grafeas.v1.Version.VersionKind kind = 4; + * @param int $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\Version\VersionKind::class); + $this->kind = $var; + + return $this; + } + + /** + * Human readable version string. This string is of the form + * :- and is only set when kind is NORMAL. + * + * Generated from protobuf field string full_name = 5; + * @return string + */ + public function getFullName() + { + return $this->full_name; + } + + /** + * Human readable version string. This string is of the form + * :- and is only set when kind is NORMAL. + * + * Generated from protobuf field string full_name = 5; + * @param string $var + * @return $this + */ + public function setFullName($var) + { + GPBUtil::checkString($var, True); + $this->full_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version/VersionKind.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version/VersionKind.php new file mode 100644 index 00000000000..d978c7d44cf --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version/VersionKind.php @@ -0,0 +1,71 @@ +grafeas.v1.Version.VersionKind + */ +class VersionKind +{ + /** + * Unknown. + * + * Generated from protobuf enum VERSION_KIND_UNSPECIFIED = 0; + */ + const VERSION_KIND_UNSPECIFIED = 0; + /** + * A standard package version. + * + * Generated from protobuf enum NORMAL = 1; + */ + const NORMAL = 1; + /** + * A special version representing negative infinity. + * + * Generated from protobuf enum MINIMUM = 2; + */ + const MINIMUM = 2; + /** + * A special version representing positive infinity. + * + * Generated from protobuf enum MAXIMUM = 3; + */ + const MAXIMUM = 3; + + private static $valueToName = [ + self::VERSION_KIND_UNSPECIFIED => 'VERSION_KIND_UNSPECIFIED', + self::NORMAL => 'NORMAL', + self::MINIMUM => 'MINIMUM', + self::MAXIMUM => 'MAXIMUM', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(VersionKind::class, \Grafeas\V1\Version_VersionKind::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version_VersionKind.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version_VersionKind.php new file mode 100644 index 00000000000..681173bb0c7 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version_VersionKind.php @@ -0,0 +1,16 @@ +grafeas.v1.VulnerabilityAssessmentNote + */ +class VulnerabilityAssessmentNote extends \Google\Protobuf\Internal\Message +{ + /** + * The title of the note. E.g. `Vex-Debian-11.4` + * + * Generated from protobuf field string title = 1; + */ + protected $title = ''; + /** + * A one sentence description of this Vex. + * + * Generated from protobuf field string short_description = 2; + */ + protected $short_description = ''; + /** + * A detailed description of this Vex. + * + * Generated from protobuf field string long_description = 3; + */ + protected $long_description = ''; + /** + * Identifies the language used by this document, + * corresponding to IETF BCP 47 / RFC 5646. + * + * Generated from protobuf field string language_code = 4; + */ + protected $language_code = ''; + /** + * Publisher details of this Note. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Publisher publisher = 5; + */ + protected $publisher = null; + /** + * The product affected by this vex. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Product product = 6; + */ + protected $product = null; + /** + * Represents a vulnerability assessment for the product. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment assessment = 7; + */ + protected $assessment = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $title + * The title of the note. E.g. `Vex-Debian-11.4` + * @type string $short_description + * A one sentence description of this Vex. + * @type string $long_description + * A detailed description of this Vex. + * @type string $language_code + * Identifies the language used by this document, + * corresponding to IETF BCP 47 / RFC 5646. + * @type \Grafeas\V1\VulnerabilityAssessmentNote\Publisher $publisher + * Publisher details of this Note. + * @type \Grafeas\V1\VulnerabilityAssessmentNote\Product $product + * The product affected by this vex. + * @type \Grafeas\V1\VulnerabilityAssessmentNote\Assessment $assessment + * Represents a vulnerability assessment for the product. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vex::initOnce(); + parent::__construct($data); + } + + /** + * The title of the note. E.g. `Vex-Debian-11.4` + * + * Generated from protobuf field string title = 1; + * @return string + */ + public function getTitle() + { + return $this->title; + } + + /** + * The title of the note. E.g. `Vex-Debian-11.4` + * + * Generated from protobuf field string title = 1; + * @param string $var + * @return $this + */ + public function setTitle($var) + { + GPBUtil::checkString($var, True); + $this->title = $var; + + return $this; + } + + /** + * A one sentence description of this Vex. + * + * Generated from protobuf field string short_description = 2; + * @return string + */ + public function getShortDescription() + { + return $this->short_description; + } + + /** + * A one sentence description of this Vex. + * + * Generated from protobuf field string short_description = 2; + * @param string $var + * @return $this + */ + public function setShortDescription($var) + { + GPBUtil::checkString($var, True); + $this->short_description = $var; + + return $this; + } + + /** + * A detailed description of this Vex. + * + * Generated from protobuf field string long_description = 3; + * @return string + */ + public function getLongDescription() + { + return $this->long_description; + } + + /** + * A detailed description of this Vex. + * + * Generated from protobuf field string long_description = 3; + * @param string $var + * @return $this + */ + public function setLongDescription($var) + { + GPBUtil::checkString($var, True); + $this->long_description = $var; + + return $this; + } + + /** + * Identifies the language used by this document, + * corresponding to IETF BCP 47 / RFC 5646. + * + * Generated from protobuf field string language_code = 4; + * @return string + */ + public function getLanguageCode() + { + return $this->language_code; + } + + /** + * Identifies the language used by this document, + * corresponding to IETF BCP 47 / RFC 5646. + * + * Generated from protobuf field string language_code = 4; + * @param string $var + * @return $this + */ + public function setLanguageCode($var) + { + GPBUtil::checkString($var, True); + $this->language_code = $var; + + return $this; + } + + /** + * Publisher details of this Note. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Publisher publisher = 5; + * @return \Grafeas\V1\VulnerabilityAssessmentNote\Publisher|null + */ + public function getPublisher() + { + return $this->publisher; + } + + public function hasPublisher() + { + return isset($this->publisher); + } + + public function clearPublisher() + { + unset($this->publisher); + } + + /** + * Publisher details of this Note. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Publisher publisher = 5; + * @param \Grafeas\V1\VulnerabilityAssessmentNote\Publisher $var + * @return $this + */ + public function setPublisher($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityAssessmentNote\Publisher::class); + $this->publisher = $var; + + return $this; + } + + /** + * The product affected by this vex. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Product product = 6; + * @return \Grafeas\V1\VulnerabilityAssessmentNote\Product|null + */ + public function getProduct() + { + return $this->product; + } + + public function hasProduct() + { + return isset($this->product); + } + + public function clearProduct() + { + unset($this->product); + } + + /** + * The product affected by this vex. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Product product = 6; + * @param \Grafeas\V1\VulnerabilityAssessmentNote\Product $var + * @return $this + */ + public function setProduct($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityAssessmentNote\Product::class); + $this->product = $var; + + return $this; + } + + /** + * Represents a vulnerability assessment for the product. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment assessment = 7; + * @return \Grafeas\V1\VulnerabilityAssessmentNote\Assessment|null + */ + public function getAssessment() + { + return $this->assessment; + } + + public function hasAssessment() + { + return isset($this->assessment); + } + + public function clearAssessment() + { + unset($this->assessment); + } + + /** + * Represents a vulnerability assessment for the product. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment assessment = 7; + * @param \Grafeas\V1\VulnerabilityAssessmentNote\Assessment $var + * @return $this + */ + public function setAssessment($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityAssessmentNote\Assessment::class); + $this->assessment = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment.php new file mode 100644 index 00000000000..c7432ee84db --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment.php @@ -0,0 +1,343 @@ +grafeas.v1.VulnerabilityAssessmentNote.Assessment + */ +class Assessment extends \Google\Protobuf\Internal\Message +{ + /** + * Holds the MITRE standard Common Vulnerabilities and Exposures (CVE) + * tracking number for the vulnerability. + * + * Generated from protobuf field string cve = 1; + */ + protected $cve = ''; + /** + * A one sentence description of this Vex. + * + * Generated from protobuf field string short_description = 2; + */ + protected $short_description = ''; + /** + * A detailed description of this Vex. + * + * Generated from protobuf field string long_description = 3; + */ + protected $long_description = ''; + /** + * Holds a list of references associated with this vulnerability item and + * assessment. These uris have additional information about the + * vulnerability and the assessment itself. E.g. Link to a document which + * details how this assessment concluded the state of this vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_uris = 4; + */ + private $related_uris; + /** + * Provides the state of this Vulnerability assessment. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.State state = 5; + */ + protected $state = 0; + /** + * Contains information about the impact of this vulnerability, + * this will change with time. + * + * Generated from protobuf field repeated string impacts = 6; + */ + private $impacts; + /** + * Justification provides the justification when the state of the + * assessment if NOT_AFFECTED. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification justification = 7; + */ + protected $justification = null; + /** + * Specifies details on how to handle (and presumably, fix) a vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Remediation remediations = 8; + */ + private $remediations; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $cve + * Holds the MITRE standard Common Vulnerabilities and Exposures (CVE) + * tracking number for the vulnerability. + * @type string $short_description + * A one sentence description of this Vex. + * @type string $long_description + * A detailed description of this Vex. + * @type array<\Grafeas\V1\RelatedUrl>|\Google\Protobuf\Internal\RepeatedField $related_uris + * Holds a list of references associated with this vulnerability item and + * assessment. These uris have additional information about the + * vulnerability and the assessment itself. E.g. Link to a document which + * details how this assessment concluded the state of this vulnerability. + * @type int $state + * Provides the state of this Vulnerability assessment. + * @type array|\Google\Protobuf\Internal\RepeatedField $impacts + * Contains information about the impact of this vulnerability, + * this will change with time. + * @type \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Justification $justification + * Justification provides the justification when the state of the + * assessment if NOT_AFFECTED. + * @type array<\Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Remediation>|\Google\Protobuf\Internal\RepeatedField $remediations + * Specifies details on how to handle (and presumably, fix) a vulnerability. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vex::initOnce(); + parent::__construct($data); + } + + /** + * Holds the MITRE standard Common Vulnerabilities and Exposures (CVE) + * tracking number for the vulnerability. + * + * Generated from protobuf field string cve = 1; + * @return string + */ + public function getCve() + { + return $this->cve; + } + + /** + * Holds the MITRE standard Common Vulnerabilities and Exposures (CVE) + * tracking number for the vulnerability. + * + * Generated from protobuf field string cve = 1; + * @param string $var + * @return $this + */ + public function setCve($var) + { + GPBUtil::checkString($var, True); + $this->cve = $var; + + return $this; + } + + /** + * A one sentence description of this Vex. + * + * Generated from protobuf field string short_description = 2; + * @return string + */ + public function getShortDescription() + { + return $this->short_description; + } + + /** + * A one sentence description of this Vex. + * + * Generated from protobuf field string short_description = 2; + * @param string $var + * @return $this + */ + public function setShortDescription($var) + { + GPBUtil::checkString($var, True); + $this->short_description = $var; + + return $this; + } + + /** + * A detailed description of this Vex. + * + * Generated from protobuf field string long_description = 3; + * @return string + */ + public function getLongDescription() + { + return $this->long_description; + } + + /** + * A detailed description of this Vex. + * + * Generated from protobuf field string long_description = 3; + * @param string $var + * @return $this + */ + public function setLongDescription($var) + { + GPBUtil::checkString($var, True); + $this->long_description = $var; + + return $this; + } + + /** + * Holds a list of references associated with this vulnerability item and + * assessment. These uris have additional information about the + * vulnerability and the assessment itself. E.g. Link to a document which + * details how this assessment concluded the state of this vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_uris = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRelatedUris() + { + return $this->related_uris; + } + + /** + * Holds a list of references associated with this vulnerability item and + * assessment. These uris have additional information about the + * vulnerability and the assessment itself. E.g. Link to a document which + * details how this assessment concluded the state of this vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_uris = 4; + * @param array<\Grafeas\V1\RelatedUrl>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRelatedUris($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\RelatedUrl::class); + $this->related_uris = $arr; + + return $this; + } + + /** + * Provides the state of this Vulnerability assessment. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.State state = 5; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Provides the state of this Vulnerability assessment. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.State state = 5; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\State::class); + $this->state = $var; + + return $this; + } + + /** + * Contains information about the impact of this vulnerability, + * this will change with time. + * + * Generated from protobuf field repeated string impacts = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getImpacts() + { + return $this->impacts; + } + + /** + * Contains information about the impact of this vulnerability, + * this will change with time. + * + * Generated from protobuf field repeated string impacts = 6; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setImpacts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->impacts = $arr; + + return $this; + } + + /** + * Justification provides the justification when the state of the + * assessment if NOT_AFFECTED. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification justification = 7; + * @return \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Justification|null + */ + public function getJustification() + { + return $this->justification; + } + + public function hasJustification() + { + return isset($this->justification); + } + + public function clearJustification() + { + unset($this->justification); + } + + /** + * Justification provides the justification when the state of the + * assessment if NOT_AFFECTED. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification justification = 7; + * @param \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Justification $var + * @return $this + */ + public function setJustification($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Justification::class); + $this->justification = $var; + + return $this; + } + + /** + * Specifies details on how to handle (and presumably, fix) a vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Remediation remediations = 8; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRemediations() + { + return $this->remediations; + } + + /** + * Specifies details on how to handle (and presumably, fix) a vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Remediation remediations = 8; + * @param array<\Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Remediation>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRemediations($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Remediation::class); + $this->remediations = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Assessment::class, \Grafeas\V1\VulnerabilityAssessmentNote_Assessment::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification.php new file mode 100644 index 00000000000..fdb666012d6 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification.php @@ -0,0 +1,105 @@ +grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification + */ +class Justification extends \Google\Protobuf\Internal\Message +{ + /** + * The justification type for this vulnerability. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification.JustificationType justification_type = 1; + */ + protected $justification_type = 0; + /** + * Additional details on why this justification was chosen. + * + * Generated from protobuf field string details = 2; + */ + protected $details = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $justification_type + * The justification type for this vulnerability. + * @type string $details + * Additional details on why this justification was chosen. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vex::initOnce(); + parent::__construct($data); + } + + /** + * The justification type for this vulnerability. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification.JustificationType justification_type = 1; + * @return int + */ + public function getJustificationType() + { + return $this->justification_type; + } + + /** + * The justification type for this vulnerability. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification.JustificationType justification_type = 1; + * @param int $var + * @return $this + */ + public function setJustificationType($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Justification\JustificationType::class); + $this->justification_type = $var; + + return $this; + } + + /** + * Additional details on why this justification was chosen. + * + * Generated from protobuf field string details = 2; + * @return string + */ + public function getDetails() + { + return $this->details; + } + + /** + * Additional details on why this justification was chosen. + * + * Generated from protobuf field string details = 2; + * @param string $var + * @return $this + */ + public function setDetails($var) + { + GPBUtil::checkString($var, True); + $this->details = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Justification::class, \Grafeas\V1\VulnerabilityAssessmentNote_Assessment_Justification::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification/JustificationType.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification/JustificationType.php new file mode 100644 index 00000000000..8d0a2417083 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification/JustificationType.php @@ -0,0 +1,94 @@ +grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification.JustificationType + */ +class JustificationType +{ + /** + * JUSTIFICATION_TYPE_UNSPECIFIED. + * + * Generated from protobuf enum JUSTIFICATION_TYPE_UNSPECIFIED = 0; + */ + const JUSTIFICATION_TYPE_UNSPECIFIED = 0; + /** + * The vulnerable component is not present in the product. + * + * Generated from protobuf enum COMPONENT_NOT_PRESENT = 1; + */ + const COMPONENT_NOT_PRESENT = 1; + /** + * The vulnerable code is not present. Typically this case + * occurs when source code is configured or built in a way that excludes + * the vulnerable code. + * + * Generated from protobuf enum VULNERABLE_CODE_NOT_PRESENT = 2; + */ + const VULNERABLE_CODE_NOT_PRESENT = 2; + /** + * The vulnerable code can not be executed. + * Typically this case occurs when the product includes the vulnerable + * code but does not call or use the vulnerable code. + * + * Generated from protobuf enum VULNERABLE_CODE_NOT_IN_EXECUTE_PATH = 3; + */ + const VULNERABLE_CODE_NOT_IN_EXECUTE_PATH = 3; + /** + * The vulnerable code cannot be controlled by an attacker to exploit + * the vulnerability. + * + * Generated from protobuf enum VULNERABLE_CODE_CANNOT_BE_CONTROLLED_BY_ADVERSARY = 4; + */ + const VULNERABLE_CODE_CANNOT_BE_CONTROLLED_BY_ADVERSARY = 4; + /** + * The product includes built-in protections or features that prevent + * exploitation of the vulnerability. These built-in protections cannot + * be subverted by the attacker and cannot be configured or disabled by + * the user. These mitigations completely prevent exploitation based on + * known attack vectors. + * + * Generated from protobuf enum INLINE_MITIGATIONS_ALREADY_EXIST = 5; + */ + const INLINE_MITIGATIONS_ALREADY_EXIST = 5; + + private static $valueToName = [ + self::JUSTIFICATION_TYPE_UNSPECIFIED => 'JUSTIFICATION_TYPE_UNSPECIFIED', + self::COMPONENT_NOT_PRESENT => 'COMPONENT_NOT_PRESENT', + self::VULNERABLE_CODE_NOT_PRESENT => 'VULNERABLE_CODE_NOT_PRESENT', + self::VULNERABLE_CODE_NOT_IN_EXECUTE_PATH => 'VULNERABLE_CODE_NOT_IN_EXECUTE_PATH', + self::VULNERABLE_CODE_CANNOT_BE_CONTROLLED_BY_ADVERSARY => 'VULNERABLE_CODE_CANNOT_BE_CONTROLLED_BY_ADVERSARY', + self::INLINE_MITIGATIONS_ALREADY_EXIST => 'INLINE_MITIGATIONS_ALREADY_EXIST', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(JustificationType::class, \Grafeas\V1\VulnerabilityAssessmentNote_Assessment_Justification_JustificationType::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation.php new file mode 100644 index 00000000000..43bea6f40ec --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation.php @@ -0,0 +1,148 @@ +grafeas.v1.VulnerabilityAssessmentNote.Assessment.Remediation + */ +class Remediation extends \Google\Protobuf\Internal\Message +{ + /** + * The type of remediation that can be applied. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Remediation.RemediationType remediation_type = 1; + */ + protected $remediation_type = 0; + /** + * Contains a comprehensive human-readable discussion of the remediation. + * + * Generated from protobuf field string details = 2; + */ + protected $details = ''; + /** + * Contains the URL where to obtain the remediation. + * + * Generated from protobuf field .grafeas.v1.RelatedUrl remediation_uri = 3; + */ + protected $remediation_uri = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $remediation_type + * The type of remediation that can be applied. + * @type string $details + * Contains a comprehensive human-readable discussion of the remediation. + * @type \Grafeas\V1\RelatedUrl $remediation_uri + * Contains the URL where to obtain the remediation. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vex::initOnce(); + parent::__construct($data); + } + + /** + * The type of remediation that can be applied. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Remediation.RemediationType remediation_type = 1; + * @return int + */ + public function getRemediationType() + { + return $this->remediation_type; + } + + /** + * The type of remediation that can be applied. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Remediation.RemediationType remediation_type = 1; + * @param int $var + * @return $this + */ + public function setRemediationType($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Remediation\RemediationType::class); + $this->remediation_type = $var; + + return $this; + } + + /** + * Contains a comprehensive human-readable discussion of the remediation. + * + * Generated from protobuf field string details = 2; + * @return string + */ + public function getDetails() + { + return $this->details; + } + + /** + * Contains a comprehensive human-readable discussion of the remediation. + * + * Generated from protobuf field string details = 2; + * @param string $var + * @return $this + */ + public function setDetails($var) + { + GPBUtil::checkString($var, True); + $this->details = $var; + + return $this; + } + + /** + * Contains the URL where to obtain the remediation. + * + * Generated from protobuf field .grafeas.v1.RelatedUrl remediation_uri = 3; + * @return \Grafeas\V1\RelatedUrl|null + */ + public function getRemediationUri() + { + return $this->remediation_uri; + } + + public function hasRemediationUri() + { + return isset($this->remediation_uri); + } + + public function clearRemediationUri() + { + unset($this->remediation_uri); + } + + /** + * Contains the URL where to obtain the remediation. + * + * Generated from protobuf field .grafeas.v1.RelatedUrl remediation_uri = 3; + * @param \Grafeas\V1\RelatedUrl $var + * @return $this + */ + public function setRemediationUri($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\RelatedUrl::class); + $this->remediation_uri = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Remediation::class, \Grafeas\V1\VulnerabilityAssessmentNote_Assessment_Remediation::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation/RemediationType.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation/RemediationType.php new file mode 100644 index 00000000000..66c51c0be9f --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation/RemediationType.php @@ -0,0 +1,85 @@ +grafeas.v1.VulnerabilityAssessmentNote.Assessment.Remediation.RemediationType + */ +class RemediationType +{ + /** + * No remediation type specified. + * + * Generated from protobuf enum REMEDIATION_TYPE_UNSPECIFIED = 0; + */ + const REMEDIATION_TYPE_UNSPECIFIED = 0; + /** + * A MITIGATION is available. + * + * Generated from protobuf enum MITIGATION = 1; + */ + const MITIGATION = 1; + /** + * No fix is planned. + * + * Generated from protobuf enum NO_FIX_PLANNED = 2; + */ + const NO_FIX_PLANNED = 2; + /** + * Not available. + * + * Generated from protobuf enum NONE_AVAILABLE = 3; + */ + const NONE_AVAILABLE = 3; + /** + * A vendor fix is available. + * + * Generated from protobuf enum VENDOR_FIX = 4; + */ + const VENDOR_FIX = 4; + /** + * A workaround is available. + * + * Generated from protobuf enum WORKAROUND = 5; + */ + const WORKAROUND = 5; + + private static $valueToName = [ + self::REMEDIATION_TYPE_UNSPECIFIED => 'REMEDIATION_TYPE_UNSPECIFIED', + self::MITIGATION => 'MITIGATION', + self::NO_FIX_PLANNED => 'NO_FIX_PLANNED', + self::NONE_AVAILABLE => 'NONE_AVAILABLE', + self::VENDOR_FIX => 'VENDOR_FIX', + self::WORKAROUND => 'WORKAROUND', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(RemediationType::class, \Grafeas\V1\VulnerabilityAssessmentNote_Assessment_Remediation_RemediationType::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/State.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/State.php new file mode 100644 index 00000000000..69b81a30cd4 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/State.php @@ -0,0 +1,79 @@ +grafeas.v1.VulnerabilityAssessmentNote.Assessment.State + */ +class State +{ + /** + * No state is specified. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * This product is known to be affected by this vulnerability. + * + * Generated from protobuf enum AFFECTED = 1; + */ + const AFFECTED = 1; + /** + * This product is known to be not affected by this vulnerability. + * + * Generated from protobuf enum NOT_AFFECTED = 2; + */ + const NOT_AFFECTED = 2; + /** + * This product contains a fix for this vulnerability. + * + * Generated from protobuf enum FIXED = 3; + */ + const FIXED = 3; + /** + * It is not known yet whether these versions are or are not affected + * by the vulnerability. However, it is still under investigation. + * + * Generated from protobuf enum UNDER_INVESTIGATION = 4; + */ + const UNDER_INVESTIGATION = 4; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::AFFECTED => 'AFFECTED', + self::NOT_AFFECTED => 'NOT_AFFECTED', + self::FIXED => 'FIXED', + self::UNDER_INVESTIGATION => 'UNDER_INVESTIGATION', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(State::class, \Grafeas\V1\VulnerabilityAssessmentNote_Assessment_State::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Product.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Product.php new file mode 100644 index 00000000000..a7fad624e32 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Product.php @@ -0,0 +1,160 @@ +grafeas.v1.VulnerabilityAssessmentNote.Product + */ +class Product extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the product. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Token that identifies a product so that it can be referred to from other + * parts in the document. There is no predefined format as long as it + * uniquely identifies a group in the context of the current document. + * + * Generated from protobuf field string id = 2; + */ + protected $id = ''; + protected $identifier; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name of the product. + * @type string $id + * Token that identifies a product so that it can be referred to from other + * parts in the document. There is no predefined format as long as it + * uniquely identifies a group in the context of the current document. + * @type string $generic_uri + * Contains a URI which is vendor-specific. + * Example: The artifact repository URL of an image. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vex::initOnce(); + parent::__construct($data); + } + + /** + * Name of the product. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name of the product. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Token that identifies a product so that it can be referred to from other + * parts in the document. There is no predefined format as long as it + * uniquely identifies a group in the context of the current document. + * + * Generated from protobuf field string id = 2; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * Token that identifies a product so that it can be referred to from other + * parts in the document. There is no predefined format as long as it + * uniquely identifies a group in the context of the current document. + * + * Generated from protobuf field string id = 2; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * Contains a URI which is vendor-specific. + * Example: The artifact repository URL of an image. + * + * Generated from protobuf field string generic_uri = 3; + * @return string + */ + public function getGenericUri() + { + return $this->readOneof(3); + } + + public function hasGenericUri() + { + return $this->hasOneof(3); + } + + /** + * Contains a URI which is vendor-specific. + * Example: The artifact repository URL of an image. + * + * Generated from protobuf field string generic_uri = 3; + * @param string $var + * @return $this + */ + public function setGenericUri($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getIdentifier() + { + return $this->whichOneof("identifier"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Product::class, \Grafeas\V1\VulnerabilityAssessmentNote_Product::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Publisher.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Publisher.php new file mode 100644 index 00000000000..2801fd5a85c --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Publisher.php @@ -0,0 +1,165 @@ +grafeas.v1.VulnerabilityAssessmentNote.Publisher + */ +class Publisher extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the publisher. + * Examples: 'Google', 'Google Cloud Platform'. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Provides information about the authority of the issuing party to + * release the document, in particular, the party's constituency and + * responsibilities or other obligations. + * + * Generated from protobuf field string issuing_authority = 2; + */ + protected $issuing_authority = ''; + /** + * The context or namespace. + * Contains a URL which is under control of the issuing party and can + * be used as a globally unique identifier for that issuing party. + * Example: https://csaf.io + * + * Generated from protobuf field string publisher_namespace = 3; + */ + protected $publisher_namespace = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name of the publisher. + * Examples: 'Google', 'Google Cloud Platform'. + * @type string $issuing_authority + * Provides information about the authority of the issuing party to + * release the document, in particular, the party's constituency and + * responsibilities or other obligations. + * @type string $publisher_namespace + * The context or namespace. + * Contains a URL which is under control of the issuing party and can + * be used as a globally unique identifier for that issuing party. + * Example: https://csaf.io + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vex::initOnce(); + parent::__construct($data); + } + + /** + * Name of the publisher. + * Examples: 'Google', 'Google Cloud Platform'. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name of the publisher. + * Examples: 'Google', 'Google Cloud Platform'. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Provides information about the authority of the issuing party to + * release the document, in particular, the party's constituency and + * responsibilities or other obligations. + * + * Generated from protobuf field string issuing_authority = 2; + * @return string + */ + public function getIssuingAuthority() + { + return $this->issuing_authority; + } + + /** + * Provides information about the authority of the issuing party to + * release the document, in particular, the party's constituency and + * responsibilities or other obligations. + * + * Generated from protobuf field string issuing_authority = 2; + * @param string $var + * @return $this + */ + public function setIssuingAuthority($var) + { + GPBUtil::checkString($var, True); + $this->issuing_authority = $var; + + return $this; + } + + /** + * The context or namespace. + * Contains a URL which is under control of the issuing party and can + * be used as a globally unique identifier for that issuing party. + * Example: https://csaf.io + * + * Generated from protobuf field string publisher_namespace = 3; + * @return string + */ + public function getPublisherNamespace() + { + return $this->publisher_namespace; + } + + /** + * The context or namespace. + * Contains a URL which is under control of the issuing party and can + * be used as a globally unique identifier for that issuing party. + * Example: https://csaf.io + * + * Generated from protobuf field string publisher_namespace = 3; + * @param string $var + * @return $this + */ + public function setPublisherNamespace($var) + { + GPBUtil::checkString($var, True); + $this->publisher_namespace = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Publisher::class, \Grafeas\V1\VulnerabilityAssessmentNote_Publisher::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment.php new file mode 100644 index 00000000000..37855b2a096 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment.php @@ -0,0 +1,16 @@ +grafeas.v1.VulnerabilityNote + */ +class VulnerabilityNote extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field float cvss_score = 1; + */ + protected $cvss_score = 0.0; + /** + * The note provider assigned severity of this vulnerability. + * + * Generated from protobuf field .grafeas.v1.Severity severity = 2; + */ + protected $severity = 0; + /** + * Details of all known distros and packages affected by this vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.Detail details = 3; + */ + private $details; + /** + * The full description of the CVSSv3 for this vulnerability. + * + * Generated from protobuf field .grafeas.v1.CVSSv3 cvss_v3 = 4; + */ + protected $cvss_v3 = null; + /** + * Windows details get their own format because the information format and + * model don't match a normal detail. Specifically Windows updates are done as + * patches, thus Windows vulnerabilities really are a missing package, rather + * than a package being at an incorrect version. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.WindowsDetail windows_details = 5; + */ + private $windows_details; + /** + * The time this information was last changed at the source. This is an + * upstream timestamp from the underlying information source - e.g. Ubuntu + * security tracker. + * + * Generated from protobuf field .google.protobuf.Timestamp source_update_time = 6; + */ + protected $source_update_time = null; + /** + * CVSS version used to populate cvss_score and severity. + * + * Generated from protobuf field .grafeas.v1.CVSSVersion cvss_version = 7; + */ + protected $cvss_version = 0; + /** + * The full description of the v2 CVSS for this vulnerability. + * + * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 8; + */ + protected $cvss_v2 = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $cvss_score + * 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. + * @type int $severity + * The note provider assigned severity of this vulnerability. + * @type array<\Grafeas\V1\VulnerabilityNote\Detail>|\Google\Protobuf\Internal\RepeatedField $details + * Details of all known distros and packages affected by this vulnerability. + * @type \Grafeas\V1\CVSSv3 $cvss_v3 + * The full description of the CVSSv3 for this vulnerability. + * @type array<\Grafeas\V1\VulnerabilityNote\WindowsDetail>|\Google\Protobuf\Internal\RepeatedField $windows_details + * Windows details get their own format because the information format and + * model don't match a normal detail. Specifically Windows updates are done as + * patches, thus Windows vulnerabilities really are a missing package, rather + * than a package being at an incorrect version. + * @type \Google\Protobuf\Timestamp $source_update_time + * The time this information was last changed at the source. This is an + * upstream timestamp from the underlying information source - e.g. Ubuntu + * security tracker. + * @type int $cvss_version + * CVSS version used to populate cvss_score and severity. + * @type \Grafeas\V1\CVSS $cvss_v2 + * The full description of the v2 CVSS for this vulnerability. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field float cvss_score = 1; + * @return float + */ + public function getCvssScore() + { + return $this->cvss_score; + } + + /** + * 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. + * + * Generated from protobuf field float cvss_score = 1; + * @param float $var + * @return $this + */ + public function setCvssScore($var) + { + GPBUtil::checkFloat($var); + $this->cvss_score = $var; + + return $this; + } + + /** + * The note provider assigned severity of this vulnerability. + * + * Generated from protobuf field .grafeas.v1.Severity severity = 2; + * @return int + */ + public function getSeverity() + { + return $this->severity; + } + + /** + * The note provider assigned severity of this vulnerability. + * + * Generated from protobuf field .grafeas.v1.Severity severity = 2; + * @param int $var + * @return $this + */ + public function setSeverity($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\Severity::class); + $this->severity = $var; + + return $this; + } + + /** + * Details of all known distros and packages affected by this vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.Detail details = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDetails() + { + return $this->details; + } + + /** + * Details of all known distros and packages affected by this vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.Detail details = 3; + * @param array<\Grafeas\V1\VulnerabilityNote\Detail>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDetails($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\VulnerabilityNote\Detail::class); + $this->details = $arr; + + return $this; + } + + /** + * The full description of the CVSSv3 for this vulnerability. + * + * Generated from protobuf field .grafeas.v1.CVSSv3 cvss_v3 = 4; + * @return \Grafeas\V1\CVSSv3|null + */ + public function getCvssV3() + { + return $this->cvss_v3; + } + + public function hasCvssV3() + { + return isset($this->cvss_v3); + } + + public function clearCvssV3() + { + unset($this->cvss_v3); + } + + /** + * The full description of the CVSSv3 for this vulnerability. + * + * Generated from protobuf field .grafeas.v1.CVSSv3 cvss_v3 = 4; + * @param \Grafeas\V1\CVSSv3 $var + * @return $this + */ + public function setCvssV3($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\CVSSv3::class); + $this->cvss_v3 = $var; + + return $this; + } + + /** + * Windows details get their own format because the information format and + * model don't match a normal detail. Specifically Windows updates are done as + * patches, thus Windows vulnerabilities really are a missing package, rather + * than a package being at an incorrect version. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.WindowsDetail windows_details = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getWindowsDetails() + { + return $this->windows_details; + } + + /** + * Windows details get their own format because the information format and + * model don't match a normal detail. Specifically Windows updates are done as + * patches, thus Windows vulnerabilities really are a missing package, rather + * than a package being at an incorrect version. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.WindowsDetail windows_details = 5; + * @param array<\Grafeas\V1\VulnerabilityNote\WindowsDetail>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setWindowsDetails($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\VulnerabilityNote\WindowsDetail::class); + $this->windows_details = $arr; + + return $this; + } + + /** + * The time this information was last changed at the source. This is an + * upstream timestamp from the underlying information source - e.g. Ubuntu + * security tracker. + * + * Generated from protobuf field .google.protobuf.Timestamp source_update_time = 6; + * @return \Google\Protobuf\Timestamp|null + */ + public function getSourceUpdateTime() + { + return $this->source_update_time; + } + + public function hasSourceUpdateTime() + { + return isset($this->source_update_time); + } + + public function clearSourceUpdateTime() + { + unset($this->source_update_time); + } + + /** + * The time this information was last changed at the source. This is an + * upstream timestamp from the underlying information source - e.g. Ubuntu + * security tracker. + * + * Generated from protobuf field .google.protobuf.Timestamp source_update_time = 6; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setSourceUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->source_update_time = $var; + + return $this; + } + + /** + * CVSS version used to populate cvss_score and severity. + * + * Generated from protobuf field .grafeas.v1.CVSSVersion cvss_version = 7; + * @return int + */ + public function getCvssVersion() + { + return $this->cvss_version; + } + + /** + * CVSS version used to populate cvss_score and severity. + * + * Generated from protobuf field .grafeas.v1.CVSSVersion cvss_version = 7; + * @param int $var + * @return $this + */ + public function setCvssVersion($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSSVersion::class); + $this->cvss_version = $var; + + return $this; + } + + /** + * The full description of the v2 CVSS for this vulnerability. + * + * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 8; + * @return \Grafeas\V1\CVSS|null + */ + public function getCvssV2() + { + return $this->cvss_v2; + } + + public function hasCvssV2() + { + return isset($this->cvss_v2); + } + + public function clearCvssV2() + { + unset($this->cvss_v2); + } + + /** + * The full description of the v2 CVSS for this vulnerability. + * + * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 8; + * @param \Grafeas\V1\CVSS $var + * @return $this + */ + public function setCvssV2($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\CVSS::class); + $this->cvss_v2 = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/Detail.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/Detail.php new file mode 100644 index 00000000000..8bd53ea558d --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/Detail.php @@ -0,0 +1,645 @@ +grafeas.v1.VulnerabilityNote.Detail + */ +class Detail extends \Google\Protobuf\Internal\Message +{ + /** + * The distro assigned severity of this vulnerability. + * + * Generated from protobuf field string severity_name = 1; + */ + protected $severity_name = ''; + /** + * A vendor-specific description of this vulnerability. + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + /** + * The type of package; whether native or non native (e.g., ruby gems, + * node.js packages, etc.). + * + * Generated from protobuf field string package_type = 3; + */ + protected $package_type = ''; + /** + * Required. The [CPE URI](https://cpe.mitre.org/specification/) this + * vulnerability affects. + * + * Generated from protobuf field string affected_cpe_uri = 4; + */ + protected $affected_cpe_uri = ''; + /** + * Required. The package this vulnerability affects. + * + * Generated from protobuf field string affected_package = 5; + */ + protected $affected_package = ''; + /** + * The version number at the start of an interval in which this + * vulnerability exists. A vulnerability can affect a package between + * version numbers that are disjoint sets of intervals (example: + * [1.0.0-1.1.0], [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be + * represented in its own Detail. If a specific affected version is provided + * by a vulnerability database, affected_version_start and + * affected_version_end will be the same in that Detail. + * + * Generated from protobuf field .grafeas.v1.Version affected_version_start = 6; + */ + protected $affected_version_start = null; + /** + * The version number at the end of an interval in which this vulnerability + * exists. A vulnerability can affect a package between version numbers + * that are disjoint sets of intervals (example: [1.0.0-1.1.0], + * [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be represented in its + * own Detail. If a specific affected version is provided by a vulnerability + * database, affected_version_start and affected_version_end will be the + * same in that Detail. + * + * Generated from protobuf field .grafeas.v1.Version affected_version_end = 7; + */ + protected $affected_version_end = null; + /** + * The distro recommended [CPE URI](https://cpe.mitre.org/specification/) + * to update to that contains a fix for this vulnerability. It is possible + * for this to be different from the affected_cpe_uri. + * + * Generated from protobuf field string fixed_cpe_uri = 8; + */ + protected $fixed_cpe_uri = ''; + /** + * The distro recommended package to update to that contains a fix for this + * vulnerability. It is possible for this to be different from the + * affected_package. + * + * Generated from protobuf field string fixed_package = 9; + */ + protected $fixed_package = ''; + /** + * The distro recommended version to update to that contains a + * fix for this vulnerability. Setting this to VersionKind.MAXIMUM means no + * such version is yet available. + * + * Generated from protobuf field .grafeas.v1.Version fixed_version = 10; + */ + protected $fixed_version = null; + /** + * Whether this detail is obsolete. Occurrences are expected not to point to + * obsolete details. + * + * Generated from protobuf field bool is_obsolete = 11; + */ + protected $is_obsolete = false; + /** + * The time this information was last changed at the source. This is an + * upstream timestamp from the underlying information source - e.g. Ubuntu + * security tracker. + * + * Generated from protobuf field .google.protobuf.Timestamp source_update_time = 12; + */ + protected $source_update_time = null; + /** + * The source from which the information in this Detail was obtained. + * + * Generated from protobuf field string source = 13; + */ + protected $source = ''; + /** + * The name of the vendor of the product. + * + * Generated from protobuf field string vendor = 14; + */ + protected $vendor = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $severity_name + * The distro assigned severity of this vulnerability. + * @type string $description + * A vendor-specific description of this vulnerability. + * @type string $package_type + * The type of package; whether native or non native (e.g., ruby gems, + * node.js packages, etc.). + * @type string $affected_cpe_uri + * Required. The [CPE URI](https://cpe.mitre.org/specification/) this + * vulnerability affects. + * @type string $affected_package + * Required. The package this vulnerability affects. + * @type \Grafeas\V1\Version $affected_version_start + * The version number at the start of an interval in which this + * vulnerability exists. A vulnerability can affect a package between + * version numbers that are disjoint sets of intervals (example: + * [1.0.0-1.1.0], [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be + * represented in its own Detail. If a specific affected version is provided + * by a vulnerability database, affected_version_start and + * affected_version_end will be the same in that Detail. + * @type \Grafeas\V1\Version $affected_version_end + * The version number at the end of an interval in which this vulnerability + * exists. A vulnerability can affect a package between version numbers + * that are disjoint sets of intervals (example: [1.0.0-1.1.0], + * [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be represented in its + * own Detail. If a specific affected version is provided by a vulnerability + * database, affected_version_start and affected_version_end will be the + * same in that Detail. + * @type string $fixed_cpe_uri + * The distro recommended [CPE URI](https://cpe.mitre.org/specification/) + * to update to that contains a fix for this vulnerability. It is possible + * for this to be different from the affected_cpe_uri. + * @type string $fixed_package + * The distro recommended package to update to that contains a fix for this + * vulnerability. It is possible for this to be different from the + * affected_package. + * @type \Grafeas\V1\Version $fixed_version + * The distro recommended version to update to that contains a + * fix for this vulnerability. Setting this to VersionKind.MAXIMUM means no + * such version is yet available. + * @type bool $is_obsolete + * Whether this detail is obsolete. Occurrences are expected not to point to + * obsolete details. + * @type \Google\Protobuf\Timestamp $source_update_time + * The time this information was last changed at the source. This is an + * upstream timestamp from the underlying information source - e.g. Ubuntu + * security tracker. + * @type string $source + * The source from which the information in this Detail was obtained. + * @type string $vendor + * The name of the vendor of the product. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * The distro assigned severity of this vulnerability. + * + * Generated from protobuf field string severity_name = 1; + * @return string + */ + public function getSeverityName() + { + return $this->severity_name; + } + + /** + * The distro assigned severity of this vulnerability. + * + * Generated from protobuf field string severity_name = 1; + * @param string $var + * @return $this + */ + public function setSeverityName($var) + { + GPBUtil::checkString($var, True); + $this->severity_name = $var; + + return $this; + } + + /** + * A vendor-specific description of this vulnerability. + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * A vendor-specific description of this vulnerability. + * + * Generated from protobuf field string description = 2; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * The type of package; whether native or non native (e.g., ruby gems, + * node.js packages, etc.). + * + * Generated from protobuf field string package_type = 3; + * @return string + */ + public function getPackageType() + { + return $this->package_type; + } + + /** + * The type of package; whether native or non native (e.g., ruby gems, + * node.js packages, etc.). + * + * Generated from protobuf field string package_type = 3; + * @param string $var + * @return $this + */ + public function setPackageType($var) + { + GPBUtil::checkString($var, True); + $this->package_type = $var; + + return $this; + } + + /** + * Required. The [CPE URI](https://cpe.mitre.org/specification/) this + * vulnerability affects. + * + * Generated from protobuf field string affected_cpe_uri = 4; + * @return string + */ + public function getAffectedCpeUri() + { + return $this->affected_cpe_uri; + } + + /** + * Required. The [CPE URI](https://cpe.mitre.org/specification/) this + * vulnerability affects. + * + * Generated from protobuf field string affected_cpe_uri = 4; + * @param string $var + * @return $this + */ + public function setAffectedCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->affected_cpe_uri = $var; + + return $this; + } + + /** + * Required. The package this vulnerability affects. + * + * Generated from protobuf field string affected_package = 5; + * @return string + */ + public function getAffectedPackage() + { + return $this->affected_package; + } + + /** + * Required. The package this vulnerability affects. + * + * Generated from protobuf field string affected_package = 5; + * @param string $var + * @return $this + */ + public function setAffectedPackage($var) + { + GPBUtil::checkString($var, True); + $this->affected_package = $var; + + return $this; + } + + /** + * The version number at the start of an interval in which this + * vulnerability exists. A vulnerability can affect a package between + * version numbers that are disjoint sets of intervals (example: + * [1.0.0-1.1.0], [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be + * represented in its own Detail. If a specific affected version is provided + * by a vulnerability database, affected_version_start and + * affected_version_end will be the same in that Detail. + * + * Generated from protobuf field .grafeas.v1.Version affected_version_start = 6; + * @return \Grafeas\V1\Version|null + */ + public function getAffectedVersionStart() + { + return $this->affected_version_start; + } + + public function hasAffectedVersionStart() + { + return isset($this->affected_version_start); + } + + public function clearAffectedVersionStart() + { + unset($this->affected_version_start); + } + + /** + * The version number at the start of an interval in which this + * vulnerability exists. A vulnerability can affect a package between + * version numbers that are disjoint sets of intervals (example: + * [1.0.0-1.1.0], [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be + * represented in its own Detail. If a specific affected version is provided + * by a vulnerability database, affected_version_start and + * affected_version_end will be the same in that Detail. + * + * Generated from protobuf field .grafeas.v1.Version affected_version_start = 6; + * @param \Grafeas\V1\Version $var + * @return $this + */ + public function setAffectedVersionStart($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); + $this->affected_version_start = $var; + + return $this; + } + + /** + * The version number at the end of an interval in which this vulnerability + * exists. A vulnerability can affect a package between version numbers + * that are disjoint sets of intervals (example: [1.0.0-1.1.0], + * [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be represented in its + * own Detail. If a specific affected version is provided by a vulnerability + * database, affected_version_start and affected_version_end will be the + * same in that Detail. + * + * Generated from protobuf field .grafeas.v1.Version affected_version_end = 7; + * @return \Grafeas\V1\Version|null + */ + public function getAffectedVersionEnd() + { + return $this->affected_version_end; + } + + public function hasAffectedVersionEnd() + { + return isset($this->affected_version_end); + } + + public function clearAffectedVersionEnd() + { + unset($this->affected_version_end); + } + + /** + * The version number at the end of an interval in which this vulnerability + * exists. A vulnerability can affect a package between version numbers + * that are disjoint sets of intervals (example: [1.0.0-1.1.0], + * [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be represented in its + * own Detail. If a specific affected version is provided by a vulnerability + * database, affected_version_start and affected_version_end will be the + * same in that Detail. + * + * Generated from protobuf field .grafeas.v1.Version affected_version_end = 7; + * @param \Grafeas\V1\Version $var + * @return $this + */ + public function setAffectedVersionEnd($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); + $this->affected_version_end = $var; + + return $this; + } + + /** + * The distro recommended [CPE URI](https://cpe.mitre.org/specification/) + * to update to that contains a fix for this vulnerability. It is possible + * for this to be different from the affected_cpe_uri. + * + * Generated from protobuf field string fixed_cpe_uri = 8; + * @return string + */ + public function getFixedCpeUri() + { + return $this->fixed_cpe_uri; + } + + /** + * The distro recommended [CPE URI](https://cpe.mitre.org/specification/) + * to update to that contains a fix for this vulnerability. It is possible + * for this to be different from the affected_cpe_uri. + * + * Generated from protobuf field string fixed_cpe_uri = 8; + * @param string $var + * @return $this + */ + public function setFixedCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->fixed_cpe_uri = $var; + + return $this; + } + + /** + * The distro recommended package to update to that contains a fix for this + * vulnerability. It is possible for this to be different from the + * affected_package. + * + * Generated from protobuf field string fixed_package = 9; + * @return string + */ + public function getFixedPackage() + { + return $this->fixed_package; + } + + /** + * The distro recommended package to update to that contains a fix for this + * vulnerability. It is possible for this to be different from the + * affected_package. + * + * Generated from protobuf field string fixed_package = 9; + * @param string $var + * @return $this + */ + public function setFixedPackage($var) + { + GPBUtil::checkString($var, True); + $this->fixed_package = $var; + + return $this; + } + + /** + * The distro recommended version to update to that contains a + * fix for this vulnerability. Setting this to VersionKind.MAXIMUM means no + * such version is yet available. + * + * Generated from protobuf field .grafeas.v1.Version fixed_version = 10; + * @return \Grafeas\V1\Version|null + */ + public function getFixedVersion() + { + return $this->fixed_version; + } + + public function hasFixedVersion() + { + return isset($this->fixed_version); + } + + public function clearFixedVersion() + { + unset($this->fixed_version); + } + + /** + * The distro recommended version to update to that contains a + * fix for this vulnerability. Setting this to VersionKind.MAXIMUM means no + * such version is yet available. + * + * Generated from protobuf field .grafeas.v1.Version fixed_version = 10; + * @param \Grafeas\V1\Version $var + * @return $this + */ + public function setFixedVersion($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); + $this->fixed_version = $var; + + return $this; + } + + /** + * Whether this detail is obsolete. Occurrences are expected not to point to + * obsolete details. + * + * Generated from protobuf field bool is_obsolete = 11; + * @return bool + */ + public function getIsObsolete() + { + return $this->is_obsolete; + } + + /** + * Whether this detail is obsolete. Occurrences are expected not to point to + * obsolete details. + * + * Generated from protobuf field bool is_obsolete = 11; + * @param bool $var + * @return $this + */ + public function setIsObsolete($var) + { + GPBUtil::checkBool($var); + $this->is_obsolete = $var; + + return $this; + } + + /** + * The time this information was last changed at the source. This is an + * upstream timestamp from the underlying information source - e.g. Ubuntu + * security tracker. + * + * Generated from protobuf field .google.protobuf.Timestamp source_update_time = 12; + * @return \Google\Protobuf\Timestamp|null + */ + public function getSourceUpdateTime() + { + return $this->source_update_time; + } + + public function hasSourceUpdateTime() + { + return isset($this->source_update_time); + } + + public function clearSourceUpdateTime() + { + unset($this->source_update_time); + } + + /** + * The time this information was last changed at the source. This is an + * upstream timestamp from the underlying information source - e.g. Ubuntu + * security tracker. + * + * Generated from protobuf field .google.protobuf.Timestamp source_update_time = 12; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setSourceUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->source_update_time = $var; + + return $this; + } + + /** + * The source from which the information in this Detail was obtained. + * + * Generated from protobuf field string source = 13; + * @return string + */ + public function getSource() + { + return $this->source; + } + + /** + * The source from which the information in this Detail was obtained. + * + * Generated from protobuf field string source = 13; + * @param string $var + * @return $this + */ + public function setSource($var) + { + GPBUtil::checkString($var, True); + $this->source = $var; + + return $this; + } + + /** + * The name of the vendor of the product. + * + * Generated from protobuf field string vendor = 14; + * @return string + */ + public function getVendor() + { + return $this->vendor; + } + + /** + * The name of the vendor of the product. + * + * Generated from protobuf field string vendor = 14; + * @param string $var + * @return $this + */ + public function setVendor($var) + { + GPBUtil::checkString($var, True); + $this->vendor = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Detail::class, \Grafeas\V1\VulnerabilityNote_Detail::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail.php new file mode 100644 index 00000000000..e20cc151c87 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail.php @@ -0,0 +1,186 @@ +grafeas.v1.VulnerabilityNote.WindowsDetail + */ +class WindowsDetail extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The [CPE URI](https://cpe.mitre.org/specification/) this + * vulnerability affects. + * + * Generated from protobuf field string cpe_uri = 1; + */ + protected $cpe_uri = ''; + /** + * Required. The name of this vulnerability. + * + * Generated from protobuf field string name = 2; + */ + protected $name = ''; + /** + * The description of this vulnerability. + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * Required. The names of the KBs which have hotfixes to mitigate this + * vulnerability. Note that there may be multiple hotfixes (and thus + * multiple KBs) that mitigate a given vulnerability. Currently any listed + * KBs presence is considered a fix. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.WindowsDetail.KnowledgeBase fixing_kbs = 4; + */ + private $fixing_kbs; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $cpe_uri + * Required. The [CPE URI](https://cpe.mitre.org/specification/) this + * vulnerability affects. + * @type string $name + * Required. The name of this vulnerability. + * @type string $description + * The description of this vulnerability. + * @type array<\Grafeas\V1\VulnerabilityNote\WindowsDetail\KnowledgeBase>|\Google\Protobuf\Internal\RepeatedField $fixing_kbs + * Required. The names of the KBs which have hotfixes to mitigate this + * vulnerability. Note that there may be multiple hotfixes (and thus + * multiple KBs) that mitigate a given vulnerability. Currently any listed + * KBs presence is considered a fix. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * Required. The [CPE URI](https://cpe.mitre.org/specification/) this + * vulnerability affects. + * + * Generated from protobuf field string cpe_uri = 1; + * @return string + */ + public function getCpeUri() + { + return $this->cpe_uri; + } + + /** + * Required. The [CPE URI](https://cpe.mitre.org/specification/) this + * vulnerability affects. + * + * Generated from protobuf field string cpe_uri = 1; + * @param string $var + * @return $this + */ + public function setCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->cpe_uri = $var; + + return $this; + } + + /** + * Required. The name of this vulnerability. + * + * Generated from protobuf field string name = 2; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The name of this vulnerability. + * + * Generated from protobuf field string name = 2; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The description of this vulnerability. + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The description of this vulnerability. + * + * Generated from protobuf field string description = 3; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Required. The names of the KBs which have hotfixes to mitigate this + * vulnerability. Note that there may be multiple hotfixes (and thus + * multiple KBs) that mitigate a given vulnerability. Currently any listed + * KBs presence is considered a fix. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.WindowsDetail.KnowledgeBase fixing_kbs = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFixingKbs() + { + return $this->fixing_kbs; + } + + /** + * Required. The names of the KBs which have hotfixes to mitigate this + * vulnerability. Note that there may be multiple hotfixes (and thus + * multiple KBs) that mitigate a given vulnerability. Currently any listed + * KBs presence is considered a fix. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.WindowsDetail.KnowledgeBase fixing_kbs = 4; + * @param array<\Grafeas\V1\VulnerabilityNote\WindowsDetail\KnowledgeBase>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFixingKbs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\VulnerabilityNote\WindowsDetail\KnowledgeBase::class); + $this->fixing_kbs = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(WindowsDetail::class, \Grafeas\V1\VulnerabilityNote_WindowsDetail::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail/KnowledgeBase.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail/KnowledgeBase.php new file mode 100644 index 00000000000..26ec0c58b2f --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail/KnowledgeBase.php @@ -0,0 +1,106 @@ +grafeas.v1.VulnerabilityNote.WindowsDetail.KnowledgeBase + */ +class KnowledgeBase extends \Google\Protobuf\Internal\Message +{ + /** + * The KB name (generally of the form KB[0-9]+ (e.g., KB123456)). + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * A link to the KB in the [Windows update catalog] + * (https://www.catalog.update.microsoft.com/). + * + * Generated from protobuf field string url = 2; + */ + protected $url = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The KB name (generally of the form KB[0-9]+ (e.g., KB123456)). + * @type string $url + * A link to the KB in the [Windows update catalog] + * (https://www.catalog.update.microsoft.com/). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * The KB name (generally of the form KB[0-9]+ (e.g., KB123456)). + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The KB name (generally of the form KB[0-9]+ (e.g., KB123456)). + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * A link to the KB in the [Windows update catalog] + * (https://www.catalog.update.microsoft.com/). + * + * Generated from protobuf field string url = 2; + * @return string + */ + public function getUrl() + { + return $this->url; + } + + /** + * A link to the KB in the [Windows update catalog] + * (https://www.catalog.update.microsoft.com/). + * + * Generated from protobuf field string url = 2; + * @param string $var + * @return $this + */ + public function setUrl($var) + { + GPBUtil::checkString($var, True); + $this->url = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(KnowledgeBase::class, \Grafeas\V1\VulnerabilityNote_WindowsDetail_KnowledgeBase::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote_Detail.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote_Detail.php new file mode 100644 index 00000000000..3406384a9d4 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote_Detail.php @@ -0,0 +1,16 @@ +grafeas.v1.VulnerabilityOccurrence + */ +class VulnerabilityOccurrence extends \Google\Protobuf\Internal\Message +{ + /** + * The type of package; whether native or non native (e.g., ruby gems, node.js + * packages, etc.). + * + * Generated from protobuf field string type = 1; + */ + protected $type = ''; + /** + * Output only. The note provider assigned severity of this vulnerability. + * + * Generated from protobuf field .grafeas.v1.Severity severity = 2; + */ + protected $severity = 0; + /** + * 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. + * + * Generated from protobuf field float cvss_score = 3; + */ + protected $cvss_score = 0.0; + /** + * The cvss v3 score for the vulnerability. + * + * Generated from protobuf field .grafeas.v1.CVSS cvssv3 = 10; + */ + protected $cvssv3 = null; + /** + * Required. The set of affected locations and their fixes (if available) + * within the associated resource. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityOccurrence.PackageIssue package_issue = 4; + */ + private $package_issue; + /** + * Output only. A one sentence description of this vulnerability. + * + * Generated from protobuf field string short_description = 5; + */ + protected $short_description = ''; + /** + * Output only. A detailed description of this vulnerability. + * + * Generated from protobuf field string long_description = 6; + */ + protected $long_description = ''; + /** + * Output only. URLs related to this vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_urls = 7; + */ + private $related_urls; + /** + * The distro assigned severity for this vulnerability when it is available, + * otherwise this is the note provider assigned severity. + * When there are multiple PackageIssues for this vulnerability, they can have + * different effective severities because some might be provided by the distro + * while others are provided by the language ecosystem for a language pack. + * For this reason, it is advised to use the effective severity on the + * PackageIssue level. In the case where multiple PackageIssues have differing + * effective severities, this field should be the highest severity for any of + * the PackageIssues. + * + * Generated from protobuf field .grafeas.v1.Severity effective_severity = 8; + */ + protected $effective_severity = 0; + /** + * Output only. Whether at least one of the affected packages has a fix + * available. + * + * Generated from protobuf field bool fix_available = 9; + */ + protected $fix_available = false; + /** + * Output only. CVSS version used to populate cvss_score and severity. + * + * Generated from protobuf field .grafeas.v1.CVSSVersion cvss_version = 11; + */ + protected $cvss_version = 0; + /** + * The cvss v2 score for the vulnerability. + * + * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 12; + */ + protected $cvss_v2 = null; + /** + * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence.VexAssessment vex_assessment = 13; + */ + protected $vex_assessment = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $type + * The type of package; whether native or non native (e.g., ruby gems, node.js + * packages, etc.). + * @type int $severity + * Output only. The note provider assigned severity of this vulnerability. + * @type float $cvss_score + * 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. + * @type \Grafeas\V1\CVSS $cvssv3 + * The cvss v3 score for the vulnerability. + * @type array<\Grafeas\V1\VulnerabilityOccurrence\PackageIssue>|\Google\Protobuf\Internal\RepeatedField $package_issue + * Required. The set of affected locations and their fixes (if available) + * within the associated resource. + * @type string $short_description + * Output only. A one sentence description of this vulnerability. + * @type string $long_description + * Output only. A detailed description of this vulnerability. + * @type array<\Grafeas\V1\RelatedUrl>|\Google\Protobuf\Internal\RepeatedField $related_urls + * Output only. URLs related to this vulnerability. + * @type int $effective_severity + * The distro assigned severity for this vulnerability when it is available, + * otherwise this is the note provider assigned severity. + * When there are multiple PackageIssues for this vulnerability, they can have + * different effective severities because some might be provided by the distro + * while others are provided by the language ecosystem for a language pack. + * For this reason, it is advised to use the effective severity on the + * PackageIssue level. In the case where multiple PackageIssues have differing + * effective severities, this field should be the highest severity for any of + * the PackageIssues. + * @type bool $fix_available + * Output only. Whether at least one of the affected packages has a fix + * available. + * @type int $cvss_version + * Output only. CVSS version used to populate cvss_score and severity. + * @type \Grafeas\V1\CVSS $cvss_v2 + * The cvss v2 score for the vulnerability. + * @type \Grafeas\V1\VulnerabilityOccurrence\VexAssessment $vex_assessment + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * The type of package; whether native or non native (e.g., ruby gems, node.js + * packages, etc.). + * + * Generated from protobuf field string type = 1; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * The type of package; whether native or non native (e.g., ruby gems, node.js + * packages, etc.). + * + * Generated from protobuf field string type = 1; + * @param string $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkString($var, True); + $this->type = $var; + + return $this; + } + + /** + * Output only. The note provider assigned severity of this vulnerability. + * + * Generated from protobuf field .grafeas.v1.Severity severity = 2; + * @return int + */ + public function getSeverity() + { + return $this->severity; + } + + /** + * Output only. The note provider assigned severity of this vulnerability. + * + * Generated from protobuf field .grafeas.v1.Severity severity = 2; + * @param int $var + * @return $this + */ + public function setSeverity($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\Severity::class); + $this->severity = $var; + + 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. + * + * Generated from protobuf field float cvss_score = 3; + * @return float + */ + public function getCvssScore() + { + return $this->cvss_score; + } + + /** + * 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. + * + * Generated from protobuf field float cvss_score = 3; + * @param float $var + * @return $this + */ + public function setCvssScore($var) + { + GPBUtil::checkFloat($var); + $this->cvss_score = $var; + + return $this; + } + + /** + * The cvss v3 score for the vulnerability. + * + * Generated from protobuf field .grafeas.v1.CVSS cvssv3 = 10; + * @return \Grafeas\V1\CVSS|null + */ + public function getCvssv3() + { + return $this->cvssv3; + } + + public function hasCvssv3() + { + return isset($this->cvssv3); + } + + public function clearCvssv3() + { + unset($this->cvssv3); + } + + /** + * The cvss v3 score for the vulnerability. + * + * Generated from protobuf field .grafeas.v1.CVSS cvssv3 = 10; + * @param \Grafeas\V1\CVSS $var + * @return $this + */ + public function setCvssv3($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\CVSS::class); + $this->cvssv3 = $var; + + return $this; + } + + /** + * Required. The set of affected locations and their fixes (if available) + * within the associated resource. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityOccurrence.PackageIssue package_issue = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPackageIssue() + { + return $this->package_issue; + } + + /** + * Required. The set of affected locations and their fixes (if available) + * within the associated resource. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityOccurrence.PackageIssue package_issue = 4; + * @param array<\Grafeas\V1\VulnerabilityOccurrence\PackageIssue>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPackageIssue($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\VulnerabilityOccurrence\PackageIssue::class); + $this->package_issue = $arr; + + return $this; + } + + /** + * Output only. A one sentence description of this vulnerability. + * + * Generated from protobuf field string short_description = 5; + * @return string + */ + public function getShortDescription() + { + return $this->short_description; + } + + /** + * Output only. A one sentence description of this vulnerability. + * + * Generated from protobuf field string short_description = 5; + * @param string $var + * @return $this + */ + public function setShortDescription($var) + { + GPBUtil::checkString($var, True); + $this->short_description = $var; + + return $this; + } + + /** + * Output only. A detailed description of this vulnerability. + * + * Generated from protobuf field string long_description = 6; + * @return string + */ + public function getLongDescription() + { + return $this->long_description; + } + + /** + * Output only. A detailed description of this vulnerability. + * + * Generated from protobuf field string long_description = 6; + * @param string $var + * @return $this + */ + public function setLongDescription($var) + { + GPBUtil::checkString($var, True); + $this->long_description = $var; + + return $this; + } + + /** + * Output only. URLs related to this vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_urls = 7; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRelatedUrls() + { + return $this->related_urls; + } + + /** + * Output only. URLs related to this vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_urls = 7; + * @param array<\Grafeas\V1\RelatedUrl>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRelatedUrls($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\RelatedUrl::class); + $this->related_urls = $arr; + + return $this; + } + + /** + * The distro assigned severity for this vulnerability when it is available, + * otherwise this is the note provider assigned severity. + * When there are multiple PackageIssues for this vulnerability, they can have + * different effective severities because some might be provided by the distro + * while others are provided by the language ecosystem for a language pack. + * For this reason, it is advised to use the effective severity on the + * PackageIssue level. In the case where multiple PackageIssues have differing + * effective severities, this field should be the highest severity for any of + * the PackageIssues. + * + * Generated from protobuf field .grafeas.v1.Severity effective_severity = 8; + * @return int + */ + public function getEffectiveSeverity() + { + return $this->effective_severity; + } + + /** + * The distro assigned severity for this vulnerability when it is available, + * otherwise this is the note provider assigned severity. + * When there are multiple PackageIssues for this vulnerability, they can have + * different effective severities because some might be provided by the distro + * while others are provided by the language ecosystem for a language pack. + * For this reason, it is advised to use the effective severity on the + * PackageIssue level. In the case where multiple PackageIssues have differing + * effective severities, this field should be the highest severity for any of + * the PackageIssues. + * + * Generated from protobuf field .grafeas.v1.Severity effective_severity = 8; + * @param int $var + * @return $this + */ + public function setEffectiveSeverity($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\Severity::class); + $this->effective_severity = $var; + + return $this; + } + + /** + * Output only. Whether at least one of the affected packages has a fix + * available. + * + * Generated from protobuf field bool fix_available = 9; + * @return bool + */ + public function getFixAvailable() + { + return $this->fix_available; + } + + /** + * Output only. Whether at least one of the affected packages has a fix + * available. + * + * Generated from protobuf field bool fix_available = 9; + * @param bool $var + * @return $this + */ + public function setFixAvailable($var) + { + GPBUtil::checkBool($var); + $this->fix_available = $var; + + return $this; + } + + /** + * Output only. CVSS version used to populate cvss_score and severity. + * + * Generated from protobuf field .grafeas.v1.CVSSVersion cvss_version = 11; + * @return int + */ + public function getCvssVersion() + { + return $this->cvss_version; + } + + /** + * Output only. CVSS version used to populate cvss_score and severity. + * + * Generated from protobuf field .grafeas.v1.CVSSVersion cvss_version = 11; + * @param int $var + * @return $this + */ + public function setCvssVersion($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\CVSSVersion::class); + $this->cvss_version = $var; + + return $this; + } + + /** + * The cvss v2 score for the vulnerability. + * + * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 12; + * @return \Grafeas\V1\CVSS|null + */ + public function getCvssV2() + { + return $this->cvss_v2; + } + + public function hasCvssV2() + { + return isset($this->cvss_v2); + } + + public function clearCvssV2() + { + unset($this->cvss_v2); + } + + /** + * The cvss v2 score for the vulnerability. + * + * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 12; + * @param \Grafeas\V1\CVSS $var + * @return $this + */ + public function setCvssV2($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\CVSS::class); + $this->cvss_v2 = $var; + + return $this; + } + + /** + * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence.VexAssessment vex_assessment = 13; + * @return \Grafeas\V1\VulnerabilityOccurrence\VexAssessment|null + */ + public function getVexAssessment() + { + return $this->vex_assessment; + } + + public function hasVexAssessment() + { + return isset($this->vex_assessment); + } + + public function clearVexAssessment() + { + unset($this->vex_assessment); + } + + /** + * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence.VexAssessment vex_assessment = 13; + * @param \Grafeas\V1\VulnerabilityOccurrence\VexAssessment $var + * @return $this + */ + public function setVexAssessment($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityOccurrence\VexAssessment::class); + $this->vex_assessment = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/PackageIssue.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/PackageIssue.php new file mode 100644 index 00000000000..50eb18f7d2f --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/PackageIssue.php @@ -0,0 +1,429 @@ +grafeas.v1.VulnerabilityOccurrence.PackageIssue + */ +class PackageIssue extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The [CPE URI](https://cpe.mitre.org/specification/) this + * vulnerability was found in. + * + * Generated from protobuf field string affected_cpe_uri = 1; + */ + protected $affected_cpe_uri = ''; + /** + * Required. The package this vulnerability was found in. + * + * Generated from protobuf field string affected_package = 2; + */ + protected $affected_package = ''; + /** + * Required. The version of the package that is installed on the resource + * affected by this vulnerability. + * + * Generated from protobuf field .grafeas.v1.Version affected_version = 3; + */ + protected $affected_version = null; + /** + * The [CPE URI](https://cpe.mitre.org/specification/) this vulnerability + * was fixed in. It is possible for this to be different from the + * affected_cpe_uri. + * + * Generated from protobuf field string fixed_cpe_uri = 4; + */ + protected $fixed_cpe_uri = ''; + /** + * The package this vulnerability was fixed in. It is possible for this to + * be different from the affected_package. + * + * Generated from protobuf field string fixed_package = 5; + */ + protected $fixed_package = ''; + /** + * Required. The version of the package this vulnerability was fixed in. + * Setting this to VersionKind.MAXIMUM means no fix is yet available. + * + * Generated from protobuf field .grafeas.v1.Version fixed_version = 6; + */ + protected $fixed_version = null; + /** + * Output only. Whether a fix is available for this package. + * + * Generated from protobuf field bool fix_available = 7; + */ + protected $fix_available = false; + /** + * The type of package (e.g. OS, MAVEN, GO). + * + * Generated from protobuf field string package_type = 8; + */ + protected $package_type = ''; + /** + * The distro or language system assigned severity for this vulnerability + * when that is available and note provider assigned severity when it is not + * available. + * + * Generated from protobuf field .grafeas.v1.Severity effective_severity = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $effective_severity = 0; + /** + * The location at which this package was found. + * + * Generated from protobuf field repeated .grafeas.v1.FileLocation file_location = 10; + */ + private $file_location; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $affected_cpe_uri + * Required. The [CPE URI](https://cpe.mitre.org/specification/) this + * vulnerability was found in. + * @type string $affected_package + * Required. The package this vulnerability was found in. + * @type \Grafeas\V1\Version $affected_version + * Required. The version of the package that is installed on the resource + * affected by this vulnerability. + * @type string $fixed_cpe_uri + * The [CPE URI](https://cpe.mitre.org/specification/) this vulnerability + * was fixed in. It is possible for this to be different from the + * affected_cpe_uri. + * @type string $fixed_package + * The package this vulnerability was fixed in. It is possible for this to + * be different from the affected_package. + * @type \Grafeas\V1\Version $fixed_version + * Required. The version of the package this vulnerability was fixed in. + * Setting this to VersionKind.MAXIMUM means no fix is yet available. + * @type bool $fix_available + * Output only. Whether a fix is available for this package. + * @type string $package_type + * The type of package (e.g. OS, MAVEN, GO). + * @type int $effective_severity + * The distro or language system assigned severity for this vulnerability + * when that is available and note provider assigned severity when it is not + * available. + * @type array<\Grafeas\V1\FileLocation>|\Google\Protobuf\Internal\RepeatedField $file_location + * The location at which this package was found. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * Required. The [CPE URI](https://cpe.mitre.org/specification/) this + * vulnerability was found in. + * + * Generated from protobuf field string affected_cpe_uri = 1; + * @return string + */ + public function getAffectedCpeUri() + { + return $this->affected_cpe_uri; + } + + /** + * Required. The [CPE URI](https://cpe.mitre.org/specification/) this + * vulnerability was found in. + * + * Generated from protobuf field string affected_cpe_uri = 1; + * @param string $var + * @return $this + */ + public function setAffectedCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->affected_cpe_uri = $var; + + return $this; + } + + /** + * Required. The package this vulnerability was found in. + * + * Generated from protobuf field string affected_package = 2; + * @return string + */ + public function getAffectedPackage() + { + return $this->affected_package; + } + + /** + * Required. The package this vulnerability was found in. + * + * Generated from protobuf field string affected_package = 2; + * @param string $var + * @return $this + */ + public function setAffectedPackage($var) + { + GPBUtil::checkString($var, True); + $this->affected_package = $var; + + return $this; + } + + /** + * Required. The version of the package that is installed on the resource + * affected by this vulnerability. + * + * Generated from protobuf field .grafeas.v1.Version affected_version = 3; + * @return \Grafeas\V1\Version|null + */ + public function getAffectedVersion() + { + return $this->affected_version; + } + + public function hasAffectedVersion() + { + return isset($this->affected_version); + } + + public function clearAffectedVersion() + { + unset($this->affected_version); + } + + /** + * Required. The version of the package that is installed on the resource + * affected by this vulnerability. + * + * Generated from protobuf field .grafeas.v1.Version affected_version = 3; + * @param \Grafeas\V1\Version $var + * @return $this + */ + public function setAffectedVersion($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); + $this->affected_version = $var; + + return $this; + } + + /** + * The [CPE URI](https://cpe.mitre.org/specification/) this vulnerability + * was fixed in. It is possible for this to be different from the + * affected_cpe_uri. + * + * Generated from protobuf field string fixed_cpe_uri = 4; + * @return string + */ + public function getFixedCpeUri() + { + return $this->fixed_cpe_uri; + } + + /** + * The [CPE URI](https://cpe.mitre.org/specification/) this vulnerability + * was fixed in. It is possible for this to be different from the + * affected_cpe_uri. + * + * Generated from protobuf field string fixed_cpe_uri = 4; + * @param string $var + * @return $this + */ + public function setFixedCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->fixed_cpe_uri = $var; + + return $this; + } + + /** + * The package this vulnerability was fixed in. It is possible for this to + * be different from the affected_package. + * + * Generated from protobuf field string fixed_package = 5; + * @return string + */ + public function getFixedPackage() + { + return $this->fixed_package; + } + + /** + * The package this vulnerability was fixed in. It is possible for this to + * be different from the affected_package. + * + * Generated from protobuf field string fixed_package = 5; + * @param string $var + * @return $this + */ + public function setFixedPackage($var) + { + GPBUtil::checkString($var, True); + $this->fixed_package = $var; + + return $this; + } + + /** + * Required. The version of the package this vulnerability was fixed in. + * Setting this to VersionKind.MAXIMUM means no fix is yet available. + * + * Generated from protobuf field .grafeas.v1.Version fixed_version = 6; + * @return \Grafeas\V1\Version|null + */ + public function getFixedVersion() + { + return $this->fixed_version; + } + + public function hasFixedVersion() + { + return isset($this->fixed_version); + } + + public function clearFixedVersion() + { + unset($this->fixed_version); + } + + /** + * Required. The version of the package this vulnerability was fixed in. + * Setting this to VersionKind.MAXIMUM means no fix is yet available. + * + * Generated from protobuf field .grafeas.v1.Version fixed_version = 6; + * @param \Grafeas\V1\Version $var + * @return $this + */ + public function setFixedVersion($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); + $this->fixed_version = $var; + + return $this; + } + + /** + * Output only. Whether a fix is available for this package. + * + * Generated from protobuf field bool fix_available = 7; + * @return bool + */ + public function getFixAvailable() + { + return $this->fix_available; + } + + /** + * Output only. Whether a fix is available for this package. + * + * Generated from protobuf field bool fix_available = 7; + * @param bool $var + * @return $this + */ + public function setFixAvailable($var) + { + GPBUtil::checkBool($var); + $this->fix_available = $var; + + return $this; + } + + /** + * The type of package (e.g. OS, MAVEN, GO). + * + * Generated from protobuf field string package_type = 8; + * @return string + */ + public function getPackageType() + { + return $this->package_type; + } + + /** + * The type of package (e.g. OS, MAVEN, GO). + * + * Generated from protobuf field string package_type = 8; + * @param string $var + * @return $this + */ + public function setPackageType($var) + { + GPBUtil::checkString($var, True); + $this->package_type = $var; + + return $this; + } + + /** + * The distro or language system assigned severity for this vulnerability + * when that is available and note provider assigned severity when it is not + * available. + * + * Generated from protobuf field .grafeas.v1.Severity effective_severity = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getEffectiveSeverity() + { + return $this->effective_severity; + } + + /** + * The distro or language system assigned severity for this vulnerability + * when that is available and note provider assigned severity when it is not + * available. + * + * Generated from protobuf field .grafeas.v1.Severity effective_severity = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setEffectiveSeverity($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\Severity::class); + $this->effective_severity = $var; + + return $this; + } + + /** + * The location at which this package was found. + * + * Generated from protobuf field repeated .grafeas.v1.FileLocation file_location = 10; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFileLocation() + { + return $this->file_location; + } + + /** + * The location at which this package was found. + * + * Generated from protobuf field repeated .grafeas.v1.FileLocation file_location = 10; + * @param array<\Grafeas\V1\FileLocation>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFileLocation($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\FileLocation::class); + $this->file_location = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PackageIssue::class, \Grafeas\V1\VulnerabilityOccurrence_PackageIssue::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/VexAssessment.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/VexAssessment.php new file mode 100644 index 00000000000..da3e263a0a2 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/VexAssessment.php @@ -0,0 +1,317 @@ +grafeas.v1.VulnerabilityOccurrence.VexAssessment + */ +class VexAssessment extends \Google\Protobuf\Internal\Message +{ + /** + * Holds the MITRE standard Common Vulnerabilities and Exposures (CVE) + * tracking number for the vulnerability. + * + * Generated from protobuf field string cve = 1; + */ + protected $cve = ''; + /** + * Holds a list of references associated with this vulnerability item and + * assessment. + * + * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_uris = 2; + */ + private $related_uris; + /** + * The VulnerabilityAssessment note from which this VexAssessment was + * generated. + * This will be of the form: `projects/[PROJECT_ID]/notes/[NOTE_ID]`. + * (-- api-linter: core::0122::name-suffix=disabled + * aip.dev/not-precedent: The suffix is kept for consistency. --) + * + * Generated from protobuf field string note_name = 3; + */ + protected $note_name = ''; + /** + * Provides the state of this Vulnerability assessment. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.State state = 4; + */ + protected $state = 0; + /** + * Contains information about the impact of this vulnerability, + * this will change with time. + * + * Generated from protobuf field repeated string impacts = 5; + */ + private $impacts; + /** + * Specifies details on how to handle (and presumably, fix) a vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Remediation remediations = 6; + */ + private $remediations; + /** + * Justification provides the justification when the state of the + * assessment if NOT_AFFECTED. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification justification = 7; + */ + protected $justification = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $cve + * Holds the MITRE standard Common Vulnerabilities and Exposures (CVE) + * tracking number for the vulnerability. + * @type array<\Grafeas\V1\RelatedUrl>|\Google\Protobuf\Internal\RepeatedField $related_uris + * Holds a list of references associated with this vulnerability item and + * assessment. + * @type string $note_name + * The VulnerabilityAssessment note from which this VexAssessment was + * generated. + * This will be of the form: `projects/[PROJECT_ID]/notes/[NOTE_ID]`. + * (-- api-linter: core::0122::name-suffix=disabled + * aip.dev/not-precedent: The suffix is kept for consistency. --) + * @type int $state + * Provides the state of this Vulnerability assessment. + * @type array|\Google\Protobuf\Internal\RepeatedField $impacts + * Contains information about the impact of this vulnerability, + * this will change with time. + * @type array<\Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Remediation>|\Google\Protobuf\Internal\RepeatedField $remediations + * Specifies details on how to handle (and presumably, fix) a vulnerability. + * @type \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Justification $justification + * Justification provides the justification when the state of the + * assessment if NOT_AFFECTED. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * Holds the MITRE standard Common Vulnerabilities and Exposures (CVE) + * tracking number for the vulnerability. + * + * Generated from protobuf field string cve = 1; + * @return string + */ + public function getCve() + { + return $this->cve; + } + + /** + * Holds the MITRE standard Common Vulnerabilities and Exposures (CVE) + * tracking number for the vulnerability. + * + * Generated from protobuf field string cve = 1; + * @param string $var + * @return $this + */ + public function setCve($var) + { + GPBUtil::checkString($var, True); + $this->cve = $var; + + return $this; + } + + /** + * Holds a list of references associated with this vulnerability item and + * assessment. + * + * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_uris = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRelatedUris() + { + return $this->related_uris; + } + + /** + * Holds a list of references associated with this vulnerability item and + * assessment. + * + * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_uris = 2; + * @param array<\Grafeas\V1\RelatedUrl>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRelatedUris($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\RelatedUrl::class); + $this->related_uris = $arr; + + return $this; + } + + /** + * The VulnerabilityAssessment note from which this VexAssessment was + * generated. + * This will be of the form: `projects/[PROJECT_ID]/notes/[NOTE_ID]`. + * (-- api-linter: core::0122::name-suffix=disabled + * aip.dev/not-precedent: The suffix is kept for consistency. --) + * + * Generated from protobuf field string note_name = 3; + * @return string + */ + public function getNoteName() + { + return $this->note_name; + } + + /** + * The VulnerabilityAssessment note from which this VexAssessment was + * generated. + * This will be of the form: `projects/[PROJECT_ID]/notes/[NOTE_ID]`. + * (-- api-linter: core::0122::name-suffix=disabled + * aip.dev/not-precedent: The suffix is kept for consistency. --) + * + * Generated from protobuf field string note_name = 3; + * @param string $var + * @return $this + */ + public function setNoteName($var) + { + GPBUtil::checkString($var, True); + $this->note_name = $var; + + return $this; + } + + /** + * Provides the state of this Vulnerability assessment. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.State state = 4; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Provides the state of this Vulnerability assessment. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.State state = 4; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\State::class); + $this->state = $var; + + return $this; + } + + /** + * Contains information about the impact of this vulnerability, + * this will change with time. + * + * Generated from protobuf field repeated string impacts = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getImpacts() + { + return $this->impacts; + } + + /** + * Contains information about the impact of this vulnerability, + * this will change with time. + * + * Generated from protobuf field repeated string impacts = 5; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setImpacts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->impacts = $arr; + + return $this; + } + + /** + * Specifies details on how to handle (and presumably, fix) a vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Remediation remediations = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRemediations() + { + return $this->remediations; + } + + /** + * Specifies details on how to handle (and presumably, fix) a vulnerability. + * + * Generated from protobuf field repeated .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Remediation remediations = 6; + * @param array<\Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Remediation>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRemediations($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Remediation::class); + $this->remediations = $arr; + + return $this; + } + + /** + * Justification provides the justification when the state of the + * assessment if NOT_AFFECTED. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification justification = 7; + * @return \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Justification|null + */ + public function getJustification() + { + return $this->justification; + } + + public function hasJustification() + { + return isset($this->justification); + } + + public function clearJustification() + { + unset($this->justification); + } + + /** + * Justification provides the justification when the state of the + * assessment if NOT_AFFECTED. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification justification = 7; + * @param \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Justification $var + * @return $this + */ + public function setJustification($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityAssessmentNote\Assessment\Justification::class); + $this->justification = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(VexAssessment::class, \Grafeas\V1\VulnerabilityOccurrence_VexAssessment::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence_PackageIssue.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence_PackageIssue.php new file mode 100644 index 00000000000..cc29d1796f1 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence_PackageIssue.php @@ -0,0 +1,16 @@ +grafeas.v1.WindowsUpdate + */ +class WindowsUpdate extends \Google\Protobuf\Internal\Message +{ + /** + * Required - The unique identifier for the update. + * + * Generated from protobuf field .grafeas.v1.WindowsUpdate.Identity identity = 1; + */ + protected $identity = null; + /** + * The localized title of the update. + * + * Generated from protobuf field string title = 2; + */ + protected $title = ''; + /** + * The localized description of the update. + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * The list of categories to which the update belongs. + * + * Generated from protobuf field repeated .grafeas.v1.WindowsUpdate.Category categories = 4; + */ + private $categories; + /** + * The Microsoft Knowledge Base article IDs that are associated with the + * update. + * + * Generated from protobuf field repeated string kb_article_ids = 5; + */ + private $kb_article_ids; + /** + * The hyperlink to the support information for the update. + * + * Generated from protobuf field string support_url = 6; + */ + protected $support_url = ''; + /** + * The last published timestamp of the update. + * + * Generated from protobuf field .google.protobuf.Timestamp last_published_timestamp = 7; + */ + protected $last_published_timestamp = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Grafeas\V1\WindowsUpdate\Identity $identity + * Required - The unique identifier for the update. + * @type string $title + * The localized title of the update. + * @type string $description + * The localized description of the update. + * @type array<\Grafeas\V1\WindowsUpdate\Category>|\Google\Protobuf\Internal\RepeatedField $categories + * The list of categories to which the update belongs. + * @type array|\Google\Protobuf\Internal\RepeatedField $kb_article_ids + * The Microsoft Knowledge Base article IDs that are associated with the + * update. + * @type string $support_url + * The hyperlink to the support information for the update. + * @type \Google\Protobuf\Timestamp $last_published_timestamp + * The last published timestamp of the update. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Upgrade::initOnce(); + parent::__construct($data); + } + + /** + * Required - The unique identifier for the update. + * + * Generated from protobuf field .grafeas.v1.WindowsUpdate.Identity identity = 1; + * @return \Grafeas\V1\WindowsUpdate\Identity|null + */ + public function getIdentity() + { + return $this->identity; + } + + public function hasIdentity() + { + return isset($this->identity); + } + + public function clearIdentity() + { + unset($this->identity); + } + + /** + * Required - The unique identifier for the update. + * + * Generated from protobuf field .grafeas.v1.WindowsUpdate.Identity identity = 1; + * @param \Grafeas\V1\WindowsUpdate\Identity $var + * @return $this + */ + public function setIdentity($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\WindowsUpdate\Identity::class); + $this->identity = $var; + + return $this; + } + + /** + * The localized title of the update. + * + * Generated from protobuf field string title = 2; + * @return string + */ + public function getTitle() + { + return $this->title; + } + + /** + * The localized title of the update. + * + * Generated from protobuf field string title = 2; + * @param string $var + * @return $this + */ + public function setTitle($var) + { + GPBUtil::checkString($var, True); + $this->title = $var; + + return $this; + } + + /** + * The localized description of the update. + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The localized description of the update. + * + * Generated from protobuf field string description = 3; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * The list of categories to which the update belongs. + * + * Generated from protobuf field repeated .grafeas.v1.WindowsUpdate.Category categories = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getCategories() + { + return $this->categories; + } + + /** + * The list of categories to which the update belongs. + * + * Generated from protobuf field repeated .grafeas.v1.WindowsUpdate.Category categories = 4; + * @param array<\Grafeas\V1\WindowsUpdate\Category>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setCategories($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\WindowsUpdate\Category::class); + $this->categories = $arr; + + return $this; + } + + /** + * The Microsoft Knowledge Base article IDs that are associated with the + * update. + * + * Generated from protobuf field repeated string kb_article_ids = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getKbArticleIds() + { + return $this->kb_article_ids; + } + + /** + * The Microsoft Knowledge Base article IDs that are associated with the + * update. + * + * Generated from protobuf field repeated string kb_article_ids = 5; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setKbArticleIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->kb_article_ids = $arr; + + return $this; + } + + /** + * The hyperlink to the support information for the update. + * + * Generated from protobuf field string support_url = 6; + * @return string + */ + public function getSupportUrl() + { + return $this->support_url; + } + + /** + * The hyperlink to the support information for the update. + * + * Generated from protobuf field string support_url = 6; + * @param string $var + * @return $this + */ + public function setSupportUrl($var) + { + GPBUtil::checkString($var, True); + $this->support_url = $var; + + return $this; + } + + /** + * The last published timestamp of the update. + * + * Generated from protobuf field .google.protobuf.Timestamp last_published_timestamp = 7; + * @return \Google\Protobuf\Timestamp|null + */ + public function getLastPublishedTimestamp() + { + return $this->last_published_timestamp; + } + + public function hasLastPublishedTimestamp() + { + return isset($this->last_published_timestamp); + } + + public function clearLastPublishedTimestamp() + { + unset($this->last_published_timestamp); + } + + /** + * The last published timestamp of the update. + * + * Generated from protobuf field .google.protobuf.Timestamp last_published_timestamp = 7; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setLastPublishedTimestamp($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->last_published_timestamp = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Category.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Category.php new file mode 100644 index 00000000000..f3fc03d57a4 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Category.php @@ -0,0 +1,104 @@ +grafeas.v1.WindowsUpdate.Category + */ +class Category extends \Google\Protobuf\Internal\Message +{ + /** + * The identifier of the category. + * + * Generated from protobuf field string category_id = 1; + */ + protected $category_id = ''; + /** + * The localized name of the category. + * + * Generated from protobuf field string name = 2; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $category_id + * The identifier of the category. + * @type string $name + * The localized name of the category. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Upgrade::initOnce(); + parent::__construct($data); + } + + /** + * The identifier of the category. + * + * Generated from protobuf field string category_id = 1; + * @return string + */ + public function getCategoryId() + { + return $this->category_id; + } + + /** + * The identifier of the category. + * + * Generated from protobuf field string category_id = 1; + * @param string $var + * @return $this + */ + public function setCategoryId($var) + { + GPBUtil::checkString($var, True); + $this->category_id = $var; + + return $this; + } + + /** + * The localized name of the category. + * + * Generated from protobuf field string name = 2; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The localized name of the category. + * + * Generated from protobuf field string name = 2; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Category::class, \Grafeas\V1\WindowsUpdate_Category::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Identity.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Identity.php new file mode 100644 index 00000000000..8d4340a93fc --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Identity.php @@ -0,0 +1,104 @@ +grafeas.v1.WindowsUpdate.Identity + */ +class Identity extends \Google\Protobuf\Internal\Message +{ + /** + * The revision independent identifier of the update. + * + * Generated from protobuf field string update_id = 1; + */ + protected $update_id = ''; + /** + * The revision number of the update. + * + * Generated from protobuf field int32 revision = 2; + */ + protected $revision = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $update_id + * The revision independent identifier of the update. + * @type int $revision + * The revision number of the update. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Grafeas\V1\Upgrade::initOnce(); + parent::__construct($data); + } + + /** + * The revision independent identifier of the update. + * + * Generated from protobuf field string update_id = 1; + * @return string + */ + public function getUpdateId() + { + return $this->update_id; + } + + /** + * The revision independent identifier of the update. + * + * Generated from protobuf field string update_id = 1; + * @param string $var + * @return $this + */ + public function setUpdateId($var) + { + GPBUtil::checkString($var, True); + $this->update_id = $var; + + return $this; + } + + /** + * The revision number of the update. + * + * Generated from protobuf field int32 revision = 2; + * @return int + */ + public function getRevision() + { + return $this->revision; + } + + /** + * The revision number of the update. + * + * Generated from protobuf field int32 revision = 2; + * @param int $var + * @return $this + */ + public function setRevision($var) + { + GPBUtil::checkInt32($var); + $this->revision = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Identity::class, \Grafeas\V1\WindowsUpdate_Identity::class); + diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate_Category.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate_Category.php new file mode 100644 index 00000000000..4acf25cc639 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate_Category.php @@ -0,0 +1,16 @@ +batchCreateNotes($formattedParent, $notes); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = GrafeasClient::projectName('[PROJECT]'); + + batch_create_notes_sample($formattedParent); +} +// [END containeranalysis_v1_generated_Grafeas_BatchCreateNotes_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/batch_create_occurrences.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/batch_create_occurrences.php new file mode 100644 index 00000000000..fe167aa897c --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/batch_create_occurrences.php @@ -0,0 +1,71 @@ +batchCreateOccurrences($formattedParent, $occurrences); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = GrafeasClient::projectName('[PROJECT]'); + + batch_create_occurrences_sample($formattedParent); +} +// [END containeranalysis_v1_generated_Grafeas_BatchCreateOccurrences_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_note.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_note.php new file mode 100644 index 00000000000..23288a642b1 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_note.php @@ -0,0 +1,72 @@ +createNote($formattedParent, $noteId, $note); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = GrafeasClient::projectName('[PROJECT]'); + $noteId = '[NOTE_ID]'; + + create_note_sample($formattedParent, $noteId); +} +// [END containeranalysis_v1_generated_Grafeas_CreateNote_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_occurrence.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_occurrence.php new file mode 100644 index 00000000000..3ef0cf3be2f --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_occurrence.php @@ -0,0 +1,70 @@ +createOccurrence($formattedParent, $occurrence); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = GrafeasClient::projectName('[PROJECT]'); + + create_occurrence_sample($formattedParent); +} +// [END containeranalysis_v1_generated_Grafeas_CreateOccurrence_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_note.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_note.php new file mode 100644 index 00000000000..0f28ce4570e --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_note.php @@ -0,0 +1,65 @@ +deleteNote($formattedName); + printf('Call completed successfully.' . PHP_EOL); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = GrafeasClient::noteName('[PROJECT]', '[NOTE]'); + + delete_note_sample($formattedName); +} +// [END containeranalysis_v1_generated_Grafeas_DeleteNote_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_occurrence.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_occurrence.php new file mode 100644 index 00000000000..b5c45a1db5d --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_occurrence.php @@ -0,0 +1,67 @@ +deleteOccurrence($formattedName); + printf('Call completed successfully.' . PHP_EOL); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = GrafeasClient::occurrenceName('[PROJECT]', '[OCCURRENCE]'); + + delete_occurrence_sample($formattedName); +} +// [END containeranalysis_v1_generated_Grafeas_DeleteOccurrence_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_note.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_note.php new file mode 100644 index 00000000000..8e7f6b8a878 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_note.php @@ -0,0 +1,67 @@ +getNote($formattedName); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = GrafeasClient::noteName('[PROJECT]', '[NOTE]'); + + get_note_sample($formattedName); +} +// [END containeranalysis_v1_generated_Grafeas_GetNote_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence.php new file mode 100644 index 00000000000..e1c746d2eed --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence.php @@ -0,0 +1,67 @@ +getOccurrence($formattedName); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = GrafeasClient::occurrenceName('[PROJECT]', '[OCCURRENCE]'); + + get_occurrence_sample($formattedName); +} +// [END containeranalysis_v1_generated_Grafeas_GetOccurrence_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence_note.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence_note.php new file mode 100644 index 00000000000..f811ea3f799 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence_note.php @@ -0,0 +1,68 @@ +getOccurrenceNote($formattedName); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = GrafeasClient::occurrenceName('[PROJECT]', '[OCCURRENCE]'); + + get_occurrence_note_sample($formattedName); +} +// [END containeranalysis_v1_generated_Grafeas_GetOccurrenceNote_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_note_occurrences.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_note_occurrences.php new file mode 100644 index 00000000000..585f2c67bdd --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_note_occurrences.php @@ -0,0 +1,74 @@ +listNoteOccurrences($formattedName); + + /** @var Occurrence $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = GrafeasClient::noteName('[PROJECT]', '[NOTE]'); + + list_note_occurrences_sample($formattedName); +} +// [END containeranalysis_v1_generated_Grafeas_ListNoteOccurrences_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_notes.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_notes.php new file mode 100644 index 00000000000..e2efbce6d25 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_notes.php @@ -0,0 +1,72 @@ +listNotes($formattedParent); + + /** @var Note $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = GrafeasClient::projectName('[PROJECT]'); + + list_notes_sample($formattedParent); +} +// [END containeranalysis_v1_generated_Grafeas_ListNotes_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_occurrences.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_occurrences.php new file mode 100644 index 00000000000..f5fd4a42b07 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_occurrences.php @@ -0,0 +1,72 @@ +listOccurrences($formattedParent); + + /** @var Occurrence $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = GrafeasClient::projectName('[PROJECT]'); + + list_occurrences_sample($formattedParent); +} +// [END containeranalysis_v1_generated_Grafeas_ListOccurrences_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_note.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_note.php new file mode 100644 index 00000000000..a21bfab7faf --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_note.php @@ -0,0 +1,70 @@ +updateNote($formattedName, $note); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = GrafeasClient::noteName('[PROJECT]', '[NOTE]'); + + update_note_sample($formattedName); +} +// [END containeranalysis_v1_generated_Grafeas_UpdateNote_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_occurrence.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_occurrence.php new file mode 100644 index 00000000000..d6016829c69 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_occurrence.php @@ -0,0 +1,70 @@ +updateOccurrence($formattedName, $occurrence); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = GrafeasClient::occurrenceName('[PROJECT]', '[OCCURRENCE]'); + + update_occurrence_sample($formattedName); +} +// [END containeranalysis_v1_generated_Grafeas_UpdateOccurrence_sync] diff --git a/owl-bot-staging/Grafeas/v1/src/V1/Gapic/GrafeasGapicClient.php b/owl-bot-staging/Grafeas/v1/src/V1/Gapic/GrafeasGapicClient.php new file mode 100644 index 00000000000..23d79eb57ed --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/src/V1/Gapic/GrafeasGapicClient.php @@ -0,0 +1,1031 @@ +projectName('[PROJECT]'); + * $notes = []; + * $response = $grafeasClient->batchCreateNotes($formattedParent, $notes); + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * 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 parseName method to extract the individual identifiers + * contained within formatted names that are returned by the API. + */ +class GrafeasGapicClient +{ + use GapicClientTrait; + + /** The name of the service. */ + const SERVICE_NAME = 'grafeas.v1.Grafeas'; + + /** The default address of the service. */ + const SERVICE_ADDRESS = 'containeranalysis.googleapis.com'; + + /** The default port of the service. */ + const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + const CODEGEN_NAME = 'gapic'; + + /** The default scopes required by the service. */ + public static $serviceScopes = []; + + private static $noteNameTemplate; + + private static $occurrenceNameTemplate; + + private static $projectNameTemplate; + + private static $pathTemplateMap; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/grafeas_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/grafeas_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/grafeas_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/grafeas_rest_client_config.php', + ], + ], + ]; + } + + private static function getNoteNameTemplate() + { + if (self::$noteNameTemplate == null) { + self::$noteNameTemplate = new PathTemplate('projects/{project}/notes/{note}'); + } + + return self::$noteNameTemplate; + } + + private static function getOccurrenceNameTemplate() + { + if (self::$occurrenceNameTemplate == null) { + self::$occurrenceNameTemplate = new PathTemplate('projects/{project}/occurrences/{occurrence}'); + } + + return self::$occurrenceNameTemplate; + } + + private static function getProjectNameTemplate() + { + if (self::$projectNameTemplate == null) { + self::$projectNameTemplate = new PathTemplate('projects/{project}'); + } + + return self::$projectNameTemplate; + } + + private static function getPathTemplateMap() + { + if (self::$pathTemplateMap == null) { + self::$pathTemplateMap = [ + 'note' => self::getNoteNameTemplate(), + 'occurrence' => self::getOccurrenceNameTemplate(), + 'project' => self::getProjectNameTemplate(), + ]; + } + + return self::$pathTemplateMap; + } + + /** + * Formats a string containing the fully-qualified path to represent a note + * resource. + * + * @param string $project + * @param string $note + * + * @return string The formatted note resource. + */ + public static function noteName($project, $note) + { + return self::getNoteNameTemplate()->render([ + 'project' => $project, + 'note' => $note, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a occurrence + * resource. + * + * @param string $project + * @param string $occurrence + * + * @return string The formatted occurrence resource. + */ + public static function occurrenceName($project, $occurrence) + { + return self::getOccurrenceNameTemplate()->render([ + 'project' => $project, + 'occurrence' => $occurrence, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a project + * resource. + * + * @param string $project + * + * @return string The formatted project resource. + */ + public static function projectName($project) + { + return self::getProjectNameTemplate()->render([ + 'project' => $project, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - note: projects/{project}/notes/{note} + * - occurrence: projects/{project}/occurrences/{occurrence} + * - project: projects/{project} + * + * The optional $template argument can be supplied to specify a particular pattern, + * and must match one of the templates listed above. If no $template argument is + * provided, or if the $template argument does not match one of the templates + * listed, then parseName will check each of the supported templates, and return + * the first match. + * + * @param string $formattedName The formatted name string + * @param string $template Optional name of template to match + * + * @return array An associative array from name component IDs to component values. + * + * @throws ValidationException If $formattedName could not be matched. + */ + public static function parseName($formattedName, $template = null) + { + $templateMap = self::getPathTemplateMap(); + if ($template) { + if (!isset($templateMap[$template])) { + throw new ValidationException("Template name $template does not exist"); + } + + return $templateMap[$template]->match($formattedName); + } + + foreach ($templateMap as $templateName => $pathTemplate) { + try { + return $pathTemplate->match($formattedName); + } catch (ValidationException $ex) { + // Swallow the exception to continue trying other path templates + } + } + + throw new ValidationException("Input did not match any known format. Input: $formattedName"); + } + + /** + * Constructor. + * + * @param array $options { + * Optional. Options for configuring the service API wrapper. + * + * @type string $apiEndpoint + * The address of the API remote host. May optionally include the port, formatted + * as ":". Default 'containeranalysis.googleapis.com:443'. + * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials + * The credentials to be used by the client to authorize API calls. This option + * accepts either a path to a credentials file, or a decoded credentials file as a + * PHP array. + * *Advanced usage*: In addition, this option can also accept a pre-constructed + * {@see \Google\Auth\FetchAuthTokenInterface} object or + * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these + * objects are provided, any settings in $credentialsConfig will be ignored. + * @type array $credentialsConfig + * Options used to configure credentials, including auth token caching, for the + * client. For a full list of supporting configuration options, see + * {@see \Google\ApiCore\CredentialsWrapper::build()} . + * @type bool $disableRetries + * Determines whether or not retries defined by the client configuration should be + * disabled. Defaults to `false`. + * @type string|array $clientConfig + * Client method configuration, including retry settings. This option can be either + * a path to a JSON file, or a PHP array containing the decoded JSON data. By + * default this settings points to the default client config file, which is + * provided in the resources folder. + * @type string|TransportInterface $transport + * The transport used for executing network requests. May be either the string + * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. + * *Advanced usage*: Additionally, it is possible to pass in an already + * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note + * that when this object is provided, any settings in $transportConfig, and any + * $apiEndpoint setting, will be ignored. + * @type array $transportConfig + * Configuration options that will be used to construct the transport. Options for + * each supported transport type should be passed in a key for that transport. For + * example: + * $transportConfig = [ + * 'grpc' => [...], + * 'rest' => [...], + * ]; + * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and + * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the + * supported options. + * @type callable $clientCertSource + * A callable which returns the client cert as a string. This can be used to + * provide a certificate and private key to the transport layer for mTLS. + * } + * + * @throws ValidationException + */ + public function __construct(array $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + } + + /** + * Creates new notes in batch. + * + * Sample code: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedParent = $grafeasClient->projectName('[PROJECT]'); + * $notes = []; + * $response = $grafeasClient->batchCreateNotes($formattedParent, $notes); + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $parent The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the notes are to be created. + * @param array $notes The notes to create. Max allowed length is 1000. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Grafeas\V1\BatchCreateNotesResponse + * + * @throws ApiException if the remote call fails + */ + public function batchCreateNotes($parent, $notes, array $optionalArgs = []) + { + $request = new BatchCreateNotesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setNotes($notes); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('BatchCreateNotes', BatchCreateNotesResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates new occurrences in batch. + * + * Sample code: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedParent = $grafeasClient->projectName('[PROJECT]'); + * $occurrences = []; + * $response = $grafeasClient->batchCreateOccurrences($formattedParent, $occurrences); + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $parent The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the occurrences are to be created. + * @param Occurrence[] $occurrences The occurrences to create. Max allowed length is 1000. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Grafeas\V1\BatchCreateOccurrencesResponse + * + * @throws ApiException if the remote call fails + */ + public function batchCreateOccurrences($parent, $occurrences, array $optionalArgs = []) + { + $request = new BatchCreateOccurrencesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setOccurrences($occurrences); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('BatchCreateOccurrences', BatchCreateOccurrencesResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a new note. + * + * Sample code: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedParent = $grafeasClient->projectName('[PROJECT]'); + * $noteId = 'note_id'; + * $note = new Note(); + * $response = $grafeasClient->createNote($formattedParent, $noteId, $note); + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $parent The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the note is to be created. + * @param string $noteId The ID to use for this note. + * @param Note $note The note to create. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Grafeas\V1\Note + * + * @throws ApiException if the remote call fails + */ + public function createNote($parent, $noteId, $note, array $optionalArgs = []) + { + $request = new CreateNoteRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setNoteId($noteId); + $request->setNote($note); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateNote', Note::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a new occurrence. + * + * Sample code: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedParent = $grafeasClient->projectName('[PROJECT]'); + * $occurrence = new Occurrence(); + * $response = $grafeasClient->createOccurrence($formattedParent, $occurrence); + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $parent The name of the project in the form of `projects/[PROJECT_ID]`, under which + * the occurrence is to be created. + * @param Occurrence $occurrence The occurrence to create. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Grafeas\V1\Occurrence + * + * @throws ApiException if the remote call fails + */ + public function createOccurrence($parent, $occurrence, array $optionalArgs = []) + { + $request = new CreateOccurrenceRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setOccurrence($occurrence); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateOccurrence', Occurrence::class, $optionalArgs, $request)->wait(); + } + + /** + * Deletes the specified note. + * + * Sample code: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedName = $grafeasClient->noteName('[PROJECT]', '[NOTE]'); + * $grafeasClient->deleteNote($formattedName); + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $name The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException if the remote call fails + */ + public function deleteNote($name, array $optionalArgs = []) + { + $request = new DeleteNoteRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('DeleteNote', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * 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: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedName = $grafeasClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); + * $grafeasClient->deleteOccurrence($formattedName); + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $name The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException if the remote call fails + */ + public function deleteOccurrence($name, array $optionalArgs = []) + { + $request = new DeleteOccurrenceRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('DeleteOccurrence', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets the specified note. + * + * Sample code: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedName = $grafeasClient->noteName('[PROJECT]', '[NOTE]'); + * $response = $grafeasClient->getNote($formattedName); + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $name The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Grafeas\V1\Note + * + * @throws ApiException if the remote call fails + */ + public function getNote($name, array $optionalArgs = []) + { + $request = new GetNoteRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetNote', Note::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets the specified occurrence. + * + * Sample code: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedName = $grafeasClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); + * $response = $grafeasClient->getOccurrence($formattedName); + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $name The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Grafeas\V1\Occurrence + * + * @throws ApiException if the remote call fails + */ + public function getOccurrence($name, array $optionalArgs = []) + { + $request = new GetOccurrenceRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetOccurrence', Occurrence::class, $optionalArgs, $request)->wait(); + } + + /** + * 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: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedName = $grafeasClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); + * $response = $grafeasClient->getOccurrenceNote($formattedName); + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $name The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Grafeas\V1\Note + * + * @throws ApiException if the remote call fails + */ + public function getOccurrenceNote($name, array $optionalArgs = []) + { + $request = new GetOccurrenceNoteRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetOccurrenceNote', Note::class, $optionalArgs, $request)->wait(); + } + + /** + * 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: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedName = $grafeasClient->noteName('[PROJECT]', '[NOTE]'); + * // Iterate over pages of elements + * $pagedResponse = $grafeasClient->listNoteOccurrences($formattedName); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $grafeasClient->listNoteOccurrences($formattedName); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $name The name of the note to list occurrences for in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * The filter expression. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + */ + public function listNoteOccurrences($name, array $optionalArgs = []) + { + $request = new ListNoteOccurrencesRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListNoteOccurrences', $optionalArgs, ListNoteOccurrencesResponse::class, $request); + } + + /** + * Lists notes for the specified project. + * + * Sample code: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedParent = $grafeasClient->projectName('[PROJECT]'); + * // Iterate over pages of elements + * $pagedResponse = $grafeasClient->listNotes($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $grafeasClient->listNotes($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $parent The name of the project to list notes for in the form of + * `projects/[PROJECT_ID]`. + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * The filter expression. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + */ + public function listNotes($parent, array $optionalArgs = []) + { + $request = new ListNotesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListNotes', $optionalArgs, ListNotesResponse::class, $request); + } + + /** + * Lists occurrences for the specified project. + * + * Sample code: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedParent = $grafeasClient->projectName('[PROJECT]'); + * // Iterate over pages of elements + * $pagedResponse = $grafeasClient->listOccurrences($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $grafeasClient->listOccurrences($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $parent The name of the project to list occurrences for in the form of + * `projects/[PROJECT_ID]`. + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * The filter expression. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + */ + public function listOccurrences($parent, array $optionalArgs = []) + { + $request = new ListOccurrencesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListOccurrences', $optionalArgs, ListOccurrencesResponse::class, $request); + } + + /** + * Updates the specified note. + * + * Sample code: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedName = $grafeasClient->noteName('[PROJECT]', '[NOTE]'); + * $note = new Note(); + * $response = $grafeasClient->updateNote($formattedName, $note); + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $name The name of the note in the form of + * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. + * @param Note $note The updated note. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The fields to update. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Grafeas\V1\Note + * + * @throws ApiException if the remote call fails + */ + public function updateNote($name, $note, array $optionalArgs = []) + { + $request = new UpdateNoteRequest(); + $requestParamHeaders = []; + $request->setName($name); + $request->setNote($note); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateNote', Note::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates the specified occurrence. + * + * Sample code: + * ``` + * $grafeasClient = new GrafeasClient(); + * try { + * $formattedName = $grafeasClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); + * $occurrence = new Occurrence(); + * $response = $grafeasClient->updateOccurrence($formattedName, $occurrence); + * } finally { + * $grafeasClient->close(); + * } + * ``` + * + * @param string $name The name of the occurrence in the form of + * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. + * @param Occurrence $occurrence The updated occurrence. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The fields to update. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Grafeas\V1\Occurrence + * + * @throws ApiException if the remote call fails + */ + public function updateOccurrence($name, $occurrence, array $optionalArgs = []) + { + $request = new UpdateOccurrenceRequest(); + $requestParamHeaders = []; + $request->setName($name); + $request->setOccurrence($occurrence); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateOccurrence', Occurrence::class, $optionalArgs, $request)->wait(); + } +} diff --git a/owl-bot-staging/Grafeas/v1/src/V1/GrafeasClient.php b/owl-bot-staging/Grafeas/v1/src/V1/GrafeasClient.php new file mode 100644 index 00000000000..ec675d7f8cb --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/src/V1/GrafeasClient.php @@ -0,0 +1,34 @@ + [ + 'grafeas.v1.Grafeas' => [ + 'ListNoteOccurrences' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getOccurrences', + ], + ], + 'ListNotes' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getNotes', + ], + ], + 'ListOccurrences' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getOccurrences', + ], + ], + ], + ], +]; diff --git a/owl-bot-staging/Grafeas/v1/src/V1/resources/grafeas_rest_client_config.php b/owl-bot-staging/Grafeas/v1/src/V1/resources/grafeas_rest_client_config.php new file mode 100644 index 00000000000..30b86b499f1 --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/src/V1/resources/grafeas_rest_client_config.php @@ -0,0 +1,172 @@ + [ + 'grafeas.v1.Grafeas' => [ + 'BatchCreateNotes' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*}/notes:batchCreate', + 'body' => '*', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'BatchCreateOccurrences' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*}/occurrences:batchCreate', + 'body' => '*', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateNote' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*}/notes', + 'body' => 'note', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'note_id', + ], + ], + 'CreateOccurrence' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*}/occurrences', + 'body' => 'occurrence', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteNote' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/notes/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteOccurrence' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/occurrences/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetNote' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/notes/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetOccurrence' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/occurrences/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetOccurrenceNote' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/occurrences/*}/notes', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListNoteOccurrences' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/notes/*}/occurrences', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListNotes' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*}/notes', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListOccurrences' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*}/occurrences', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'UpdateNote' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{name=projects/*/notes/*}', + 'body' => 'note', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UpdateOccurrence' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{name=projects/*/occurrences/*}', + 'body' => 'occurrence', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + ], + ], + 'numericEnums' => true, +]; diff --git a/owl-bot-staging/Grafeas/v1/tests/Unit/V1/GrafeasClientTest.php b/owl-bot-staging/Grafeas/v1/tests/Unit/V1/GrafeasClientTest.php new file mode 100644 index 00000000000..8b715d081bc --- /dev/null +++ b/owl-bot-staging/Grafeas/v1/tests/Unit/V1/GrafeasClientTest.php @@ -0,0 +1,990 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return GrafeasClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new GrafeasClient($options); + } + + /** @test */ + public function batchCreateNotesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new BatchCreateNotesResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $notesValue = new Note(); + $notes = [ + 'notesKey' => $notesValue, + ]; + $response = $gapicClient->batchCreateNotes($formattedParent, $notes); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/BatchCreateNotes', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getNotes(); + $this->assertProtobufEquals($notes, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchCreateNotesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $notesValue = new Note(); + $notes = [ + 'notesKey' => $notesValue, + ]; + try { + $gapicClient->batchCreateNotes($formattedParent, $notes); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchCreateOccurrencesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new BatchCreateOccurrencesResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $occurrences = []; + $response = $gapicClient->batchCreateOccurrences($formattedParent, $occurrences); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/BatchCreateOccurrences', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getOccurrences(); + $this->assertProtobufEquals($occurrences, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchCreateOccurrencesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $occurrences = []; + try { + $gapicClient->batchCreateOccurrences($formattedParent, $occurrences); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createNoteTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $shortDescription = 'shortDescription-235369287'; + $longDescription = 'longDescription-1747792199'; + $expectedResponse = new Note(); + $expectedResponse->setName($name); + $expectedResponse->setShortDescription($shortDescription); + $expectedResponse->setLongDescription($longDescription); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $noteId = 'noteId2129224840'; + $note = new Note(); + $response = $gapicClient->createNote($formattedParent, $noteId, $note); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/CreateNote', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getNoteId(); + $this->assertProtobufEquals($noteId, $actualValue); + $actualValue = $actualRequestObject->getNote(); + $this->assertProtobufEquals($note, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createNoteExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $noteId = 'noteId2129224840'; + $note = new Note(); + try { + $gapicClient->createNote($formattedParent, $noteId, $note); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createOccurrenceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $resourceUri = 'resourceUri-384040517'; + $noteName = 'noteName1780787896'; + $remediation = 'remediation779381797'; + $expectedResponse = new Occurrence(); + $expectedResponse->setName($name); + $expectedResponse->setResourceUri($resourceUri); + $expectedResponse->setNoteName($noteName); + $expectedResponse->setRemediation($remediation); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $occurrence = new Occurrence(); + $response = $gapicClient->createOccurrence($formattedParent, $occurrence); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/CreateOccurrence', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getOccurrence(); + $this->assertProtobufEquals($occurrence, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createOccurrenceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $occurrence = new Occurrence(); + try { + $gapicClient->createOccurrence($formattedParent, $occurrence); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteNoteTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); + $gapicClient->deleteNote($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/DeleteNote', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteNoteExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); + try { + $gapicClient->deleteNote($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteOccurrenceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); + $gapicClient->deleteOccurrence($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/DeleteOccurrence', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteOccurrenceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); + try { + $gapicClient->deleteOccurrence($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNoteTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $shortDescription = 'shortDescription-235369287'; + $longDescription = 'longDescription-1747792199'; + $expectedResponse = new Note(); + $expectedResponse->setName($name2); + $expectedResponse->setShortDescription($shortDescription); + $expectedResponse->setLongDescription($longDescription); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); + $response = $gapicClient->getNote($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/GetNote', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNoteExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); + try { + $gapicClient->getNote($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getOccurrenceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $resourceUri = 'resourceUri-384040517'; + $noteName = 'noteName1780787896'; + $remediation = 'remediation779381797'; + $expectedResponse = new Occurrence(); + $expectedResponse->setName($name2); + $expectedResponse->setResourceUri($resourceUri); + $expectedResponse->setNoteName($noteName); + $expectedResponse->setRemediation($remediation); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); + $response = $gapicClient->getOccurrence($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/GetOccurrence', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getOccurrenceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); + try { + $gapicClient->getOccurrence($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getOccurrenceNoteTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $shortDescription = 'shortDescription-235369287'; + $longDescription = 'longDescription-1747792199'; + $expectedResponse = new Note(); + $expectedResponse->setName($name2); + $expectedResponse->setShortDescription($shortDescription); + $expectedResponse->setLongDescription($longDescription); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); + $response = $gapicClient->getOccurrenceNote($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/GetOccurrenceNote', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getOccurrenceNoteExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); + try { + $gapicClient->getOccurrenceNote($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNoteOccurrencesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $occurrencesElement = new Occurrence(); + $occurrences = [ + $occurrencesElement, + ]; + $expectedResponse = new ListNoteOccurrencesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setOccurrences($occurrences); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); + $response = $gapicClient->listNoteOccurrences($formattedName); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getOccurrences()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/ListNoteOccurrences', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNoteOccurrencesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); + try { + $gapicClient->listNoteOccurrences($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNotesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $notesElement = new Note(); + $notes = [ + $notesElement, + ]; + $expectedResponse = new ListNotesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setNotes($notes); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->listNotes($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getNotes()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/ListNotes', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNotesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + try { + $gapicClient->listNotes($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listOccurrencesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $occurrencesElement = new Occurrence(); + $occurrences = [ + $occurrencesElement, + ]; + $expectedResponse = new ListOccurrencesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setOccurrences($occurrences); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->listOccurrences($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getOccurrences()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/ListOccurrences', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listOccurrencesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + try { + $gapicClient->listOccurrences($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateNoteTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $shortDescription = 'shortDescription-235369287'; + $longDescription = 'longDescription-1747792199'; + $expectedResponse = new Note(); + $expectedResponse->setName($name2); + $expectedResponse->setShortDescription($shortDescription); + $expectedResponse->setLongDescription($longDescription); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); + $note = new Note(); + $response = $gapicClient->updateNote($formattedName, $note); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/UpdateNote', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getNote(); + $this->assertProtobufEquals($note, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateNoteExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); + $note = new Note(); + try { + $gapicClient->updateNote($formattedName, $note); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateOccurrenceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $resourceUri = 'resourceUri-384040517'; + $noteName = 'noteName1780787896'; + $remediation = 'remediation779381797'; + $expectedResponse = new Occurrence(); + $expectedResponse->setName($name2); + $expectedResponse->setResourceUri($resourceUri); + $expectedResponse->setNoteName($noteName); + $expectedResponse->setRemediation($remediation); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); + $occurrence = new Occurrence(); + $response = $gapicClient->updateOccurrence($formattedName, $occurrence); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/grafeas.v1.Grafeas/UpdateOccurrence', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getOccurrence(); + $this->assertProtobufEquals($occurrence, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateOccurrenceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); + $occurrence = new Occurrence(); + try { + $gapicClient->updateOccurrence($formattedName, $occurrence); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } +} From df8d417e61da27bc487876f5f879ed273c8fe595 Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Sat, 11 Mar 2023 00:07:05 +0000 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=A6=89=20Updates=20from=20OwlBot=20po?= =?UTF-8?q?st-processor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --- Grafeas/metadata/V1/Common.php | Bin 1213 -> 1243 bytes Grafeas/metadata/V1/Grafeas.php | Bin 8039 -> 8188 bytes .../Grafeas => Grafeas/metadata}/V1/Vex.php | Bin Grafeas/metadata/V1/Vulnerability.php | 20 +- Grafeas/src/V1/Note.php | 33 + Grafeas/src/V1/NoteKind.php | 7 + .../src}/V1/VulnerabilityAssessmentNote.php | 14 +- .../Assessment.php | 12 +- .../Assessment/Justification.php | 6 +- .../Justification/JustificationType.php | 2 - .../Assessment/Remediation.php | 8 +- .../Remediation/RemediationType.php | 2 - .../Assessment/State.php | 2 - .../VulnerabilityAssessmentNote/Product.php | 6 +- .../VulnerabilityAssessmentNote/Publisher.php | 8 +- Grafeas/src/V1/VulnerabilityOccurrence.php | 37 + .../VulnerabilityOccurrence/VexAssessment.php | 10 +- .../GPBMetadata/Grafeas/V1/Attestation.php | 40 - .../src/GPBMetadata/Grafeas/V1/Build.php | 39 - .../src/GPBMetadata/Grafeas/V1/Common.php | Bin 1243 -> 0 bytes .../src/GPBMetadata/Grafeas/V1/Compliance.php | Bin 1315 -> 0 bytes .../proto/src/GPBMetadata/Grafeas/V1/Cvss.php | Bin 3353 -> 0 bytes .../src/GPBMetadata/Grafeas/V1/Deployment.php | Bin 1084 -> 0 bytes .../src/GPBMetadata/Grafeas/V1/Discovery.php | Bin 1786 -> 0 bytes .../Grafeas/V1/DsseAttestation.php | Bin 1079 -> 0 bytes .../src/GPBMetadata/Grafeas/V1/Grafeas.php | Bin 8188 -> 0 bytes .../src/GPBMetadata/Grafeas/V1/Image.php | 44 - .../Grafeas/V1/IntotoProvenance.php | 54 - .../Grafeas/V1/IntotoStatement.php | Bin 1374 -> 0 bytes .../src/GPBMetadata/Grafeas/V1/Package.php | Bin 1945 -> 0 bytes .../src/GPBMetadata/Grafeas/V1/Provenance.php | Bin 2688 -> 0 bytes .../src/GPBMetadata/Grafeas/V1/Severity.php | Bin 744 -> 0 bytes .../GPBMetadata/Grafeas/V1/SlsaProvenance.php | 61 - .../Grafeas/V1/SlsaProvenanceZeroTwo.php | 71 -- .../src/GPBMetadata/Grafeas/V1/Upgrade.php | 60 - .../GPBMetadata/Grafeas/V1/Vulnerability.php | 106 -- .../v1/proto/src/Grafeas/V1/AliasContext.php | 101 -- .../src/Grafeas/V1/AliasContext/Kind.php | 72 -- .../src/Grafeas/V1/AliasContext_Kind.php | 16 - .../v1/proto/src/Grafeas/V1/Architecture.php | 61 - .../v1/proto/src/Grafeas/V1/Artifact.php | 159 --- .../proto/src/Grafeas/V1/AttestationNote.php | 84 -- .../src/Grafeas/V1/AttestationNote/Hint.php | 80 -- .../src/Grafeas/V1/AttestationNote_Hint.php | 16 - .../src/Grafeas/V1/AttestationOccurrence.php | 190 --- .../Grafeas/V1/BatchCreateNotesRequest.php | 105 -- .../Grafeas/V1/BatchCreateNotesResponse.php | 67 -- .../V1/BatchCreateOccurrencesRequest.php | 105 -- .../V1/BatchCreateOccurrencesResponse.php | 67 -- .../v1/proto/src/Grafeas/V1/BuildNote.php | 68 -- .../proto/src/Grafeas/V1/BuildOccurrence.php | 251 ---- .../proto/src/Grafeas/V1/BuildProvenance.php | 528 --------- .../v1/proto/src/Grafeas/V1/BuilderConfig.php | 58 - .../Grafeas/v1/proto/src/Grafeas/V1/CVSS.php | 382 ------ .../src/Grafeas/V1/CVSS/AttackComplexity.php | 56 - .../src/Grafeas/V1/CVSS/AttackVector.php | 66 -- .../src/Grafeas/V1/CVSS/Authentication.php | 61 - .../v1/proto/src/Grafeas/V1/CVSS/Impact.php | 61 - .../Grafeas/V1/CVSS/PrivilegesRequired.php | 61 - .../v1/proto/src/Grafeas/V1/CVSS/Scope.php | 56 - .../src/Grafeas/V1/CVSS/UserInteraction.php | 56 - .../v1/proto/src/Grafeas/V1/CVSSVersion.php | 55 - .../src/Grafeas/V1/CVSS_AttackComplexity.php | 16 - .../src/Grafeas/V1/CVSS_AttackVector.php | 16 - .../src/Grafeas/V1/CVSS_Authentication.php | 16 - .../v1/proto/src/Grafeas/V1/CVSS_Impact.php | 16 - .../Grafeas/V1/CVSS_PrivilegesRequired.php | 16 - .../v1/proto/src/Grafeas/V1/CVSS_Scope.php | 16 - .../src/Grafeas/V1/CVSS_UserInteraction.php | 16 - .../v1/proto/src/Grafeas/V1/CVSSv3.php | 353 ------ .../Grafeas/V1/CVSSv3/AttackComplexity.php | 56 - .../src/Grafeas/V1/CVSSv3/AttackVector.php | 66 -- .../v1/proto/src/Grafeas/V1/CVSSv3/Impact.php | 61 - .../Grafeas/V1/CVSSv3/PrivilegesRequired.php | 61 - .../v1/proto/src/Grafeas/V1/CVSSv3/Scope.php | 56 - .../src/Grafeas/V1/CVSSv3/UserInteraction.php | 56 - .../Grafeas/V1/CVSSv3_AttackComplexity.php | 16 - .../src/Grafeas/V1/CVSSv3_AttackVector.php | 16 - .../v1/proto/src/Grafeas/V1/CVSSv3_Impact.php | 16 - .../Grafeas/V1/CVSSv3_PrivilegesRequired.php | 16 - .../v1/proto/src/Grafeas/V1/CVSSv3_Scope.php | 16 - .../src/Grafeas/V1/CVSSv3_UserInteraction.php | 16 - .../src/Grafeas/V1/CloudRepoSourceContext.php | 153 --- .../v1/proto/src/Grafeas/V1/Command.php | 249 ---- .../v1/proto/src/Grafeas/V1/Completeness.php | 148 --- .../proto/src/Grafeas/V1/ComplianceNote.php | 272 ----- .../V1/ComplianceNote/CisBenchmark.php | 90 -- .../V1/ComplianceNote_CisBenchmark.php | 16 - .../src/Grafeas/V1/ComplianceOccurrence.php | 88 -- .../src/Grafeas/V1/ComplianceVersion.php | 148 --- .../src/Grafeas/V1/CreateNoteRequest.php | 149 --- .../Grafeas/V1/CreateOccurrenceRequest.php | 115 -- .../src/Grafeas/V1/DSSEAttestationNote.php | 75 -- .../V1/DSSEAttestationNote/DSSEHint.php | 80 -- .../V1/DSSEAttestationNote_DSSEHint.php | 16 - .../Grafeas/V1/DSSEAttestationOccurrence.php | 119 -- .../src/Grafeas/V1/DeleteNoteRequest.php | 71 -- .../Grafeas/V1/DeleteOccurrenceRequest.php | 71 -- .../proto/src/Grafeas/V1/DeploymentNote.php | 67 -- .../src/Grafeas/V1/DeploymentOccurrence.php | 295 ----- .../V1/DeploymentOccurrence/Platform.php | 71 -- .../V1/DeploymentOccurrence_Platform.php | 16 - .../v1/proto/src/Grafeas/V1/Digest.php | 101 -- .../v1/proto/src/Grafeas/V1/DiscoveryNote.php | 73 -- .../src/Grafeas/V1/DiscoveryOccurrence.php | 350 ------ .../DiscoveryOccurrence/AnalysisCompleted.php | 64 - .../V1/DiscoveryOccurrence/AnalysisStatus.php | 94 -- .../ContinuousAnalysis.php | 64 - .../DiscoveryOccurrence_AnalysisCompleted.php | 16 - .../V1/DiscoveryOccurrence_AnalysisStatus.php | 16 - ...DiscoveryOccurrence_ContinuousAnalysis.php | 16 - .../v1/proto/src/Grafeas/V1/Distribution.php | 256 ---- .../v1/proto/src/Grafeas/V1/Envelope.php | 116 -- .../src/Grafeas/V1/EnvelopeSignature.php | 85 -- .../v1/proto/src/Grafeas/V1/FileHashes.php | 68 -- .../v1/proto/src/Grafeas/V1/FileLocation.php | 71 -- .../v1/proto/src/Grafeas/V1/Fingerprint.php | 151 --- .../src/Grafeas/V1/GerritSourceContext.php | 184 --- .../proto/src/Grafeas/V1/GetNoteRequest.php | 71 -- .../Grafeas/V1/GetOccurrenceNoteRequest.php | 71 -- .../src/Grafeas/V1/GetOccurrenceRequest.php | 71 -- .../proto/src/Grafeas/V1/GitSourceContext.php | 102 -- .../src/Grafeas/V1/GrafeasGrpcClient.php | 263 ----- .../Grafeas/v1/proto/src/Grafeas/V1/Hash.php | 101 -- .../v1/proto/src/Grafeas/V1/ImageNote.php | 119 -- .../proto/src/Grafeas/V1/ImageOccurrence.php | 197 ---- .../proto/src/Grafeas/V1/InTotoProvenance.php | 214 ---- .../proto/src/Grafeas/V1/InTotoStatement.php | 224 ---- .../Grafeas/v1/proto/src/Grafeas/V1/Jwt.php | 73 -- .../Grafeas/v1/proto/src/Grafeas/V1/Layer.php | 105 -- .../v1/proto/src/Grafeas/V1/License.php | 117 -- .../Grafeas/V1/ListNoteOccurrencesRequest.php | 173 --- .../V1/ListNoteOccurrencesResponse.php | 101 -- .../proto/src/Grafeas/V1/ListNotesRequest.php | 177 --- .../src/Grafeas/V1/ListNotesResponse.php | 109 -- .../src/Grafeas/V1/ListOccurrencesRequest.php | 177 --- .../Grafeas/V1/ListOccurrencesResponse.php | 109 -- .../v1/proto/src/Grafeas/V1/Location.php | 154 --- .../v1/proto/src/Grafeas/V1/Metadata.php | 249 ---- .../proto/src/Grafeas/V1/NonCompliantFile.php | 135 --- .../Grafeas/v1/proto/src/Grafeas/V1/Note.php | 757 ------------ .../v1/proto/src/Grafeas/V1/NoteKind.php | 124 -- .../v1/proto/src/Grafeas/V1/Occurrence.php | 701 ----------- .../v1/proto/src/Grafeas/V1/PackageNote.php | 451 ------- .../src/Grafeas/V1/PackageOccurrence.php | 311 ----- .../v1/proto/src/Grafeas/V1/ProjectRepoId.php | 102 -- .../v1/proto/src/Grafeas/V1/Recipe.php | 273 ----- .../v1/proto/src/Grafeas/V1/RelatedUrl.php | 101 -- .../v1/proto/src/Grafeas/V1/RepoId.php | 108 -- .../v1/proto/src/Grafeas/V1/Severity.php | 82 -- .../v1/proto/src/Grafeas/V1/Signature.php | 192 --- .../proto/src/Grafeas/V1/SlsaProvenance.php | 214 ---- .../Grafeas/V1/SlsaProvenance/Material.php | 88 -- .../Grafeas/V1/SlsaProvenance/SlsaBuilder.php | 61 - .../V1/SlsaProvenance/SlsaCompleteness.php | 151 --- .../V1/SlsaProvenance/SlsaMetadata.php | 252 ---- .../Grafeas/V1/SlsaProvenance/SlsaRecipe.php | 296 ----- .../src/Grafeas/V1/SlsaProvenanceZeroTwo.php | 235 ---- .../V1/SlsaProvenanceZeroTwo/SlsaBuilder.php | 64 - .../SlsaCompleteness.php | 118 -- .../SlsaConfigSource.php | 118 -- .../SlsaProvenanceZeroTwo/SlsaInvocation.php | 147 --- .../V1/SlsaProvenanceZeroTwo/SlsaMaterial.php | 91 -- .../V1/SlsaProvenanceZeroTwo/SlsaMetadata.php | 201 ---- .../V1/SlsaProvenanceZeroTwo_SlsaBuilder.php | 16 - ...SlsaProvenanceZeroTwo_SlsaCompleteness.php | 16 - ...SlsaProvenanceZeroTwo_SlsaConfigSource.php | 16 - .../SlsaProvenanceZeroTwo_SlsaInvocation.php | 16 - .../V1/SlsaProvenanceZeroTwo_SlsaMaterial.php | 16 - .../V1/SlsaProvenanceZeroTwo_SlsaMetadata.php | 16 - .../Grafeas/V1/SlsaProvenance_Material.php | 16 - .../Grafeas/V1/SlsaProvenance_SlsaBuilder.php | 16 - .../V1/SlsaProvenance_SlsaCompleteness.php | 16 - .../V1/SlsaProvenance_SlsaMetadata.php | 16 - .../Grafeas/V1/SlsaProvenance_SlsaRecipe.php | 16 - .../v1/proto/src/Grafeas/V1/Source.php | 215 ---- .../v1/proto/src/Grafeas/V1/SourceContext.php | 176 --- .../v1/proto/src/Grafeas/V1/Subject.php | 104 -- .../src/Grafeas/V1/UpdateNoteRequest.php | 159 --- .../Grafeas/V1/UpdateOccurrenceRequest.php | 159 --- .../src/Grafeas/V1/UpgradeDistribution.php | 187 --- .../v1/proto/src/Grafeas/V1/UpgradeNote.php | 196 ---- .../src/Grafeas/V1/UpgradeOccurrence.php | 215 ---- .../v1/proto/src/Grafeas/V1/Version.php | 269 ----- .../src/Grafeas/V1/Version/VersionKind.php | 71 -- .../src/Grafeas/V1/Version_VersionKind.php | 16 - ...VulnerabilityAssessmentNote_Assessment.php | 16 - ...ssessmentNote_Assessment_Justification.php | 16 - ...ssment_Justification_JustificationType.php | 16 - ...yAssessmentNote_Assessment_Remediation.php | 16 - ...Assessment_Remediation_RemediationType.php | 16 - ...abilityAssessmentNote_Assessment_State.php | 16 - .../VulnerabilityAssessmentNote_Product.php | 16 - .../VulnerabilityAssessmentNote_Publisher.php | 16 - .../src/Grafeas/V1/VulnerabilityNote.php | 359 ------ .../Grafeas/V1/VulnerabilityNote/Detail.php | 645 ----------- .../V1/VulnerabilityNote/WindowsDetail.php | 186 --- .../WindowsDetail/KnowledgeBase.php | 106 -- .../Grafeas/V1/VulnerabilityNote_Detail.php | 16 - .../V1/VulnerabilityNote_WindowsDetail.php | 16 - ...bilityNote_WindowsDetail_KnowledgeBase.php | 16 - .../Grafeas/V1/VulnerabilityOccurrence.php | 550 --------- .../VulnerabilityOccurrence/PackageIssue.php | 429 ------- .../VulnerabilityOccurrence_PackageIssue.php | 16 - .../VulnerabilityOccurrence_VexAssessment.php | 16 - .../v1/proto/src/Grafeas/V1/WindowsUpdate.php | 298 ----- .../src/Grafeas/V1/WindowsUpdate/Category.php | 104 -- .../src/Grafeas/V1/WindowsUpdate/Identity.php | 104 -- .../src/Grafeas/V1/WindowsUpdate_Category.php | 16 - .../src/Grafeas/V1/WindowsUpdate_Identity.php | 16 - .../V1/GrafeasClient/batch_create_notes.php | 70 -- .../batch_create_occurrences.php | 71 -- .../samples/V1/GrafeasClient/create_note.php | 72 -- .../V1/GrafeasClient/create_occurrence.php | 70 -- .../samples/V1/GrafeasClient/delete_note.php | 65 -- .../V1/GrafeasClient/delete_occurrence.php | 67 -- .../v1/samples/V1/GrafeasClient/get_note.php | 67 -- .../V1/GrafeasClient/get_occurrence.php | 67 -- .../V1/GrafeasClient/get_occurrence_note.php | 68 -- .../GrafeasClient/list_note_occurrences.php | 74 -- .../samples/V1/GrafeasClient/list_notes.php | 72 -- .../V1/GrafeasClient/list_occurrences.php | 72 -- .../samples/V1/GrafeasClient/update_note.php | 70 -- .../V1/GrafeasClient/update_occurrence.php | 70 -- .../v1/src/V1/Gapic/GrafeasGapicClient.php | 1031 ----------------- .../Grafeas/v1/src/V1/GrafeasClient.php | 34 - .../Grafeas/v1/src/V1/gapic_metadata.json | 88 -- .../V1/resources/grafeas_client_config.json | 115 -- .../resources/grafeas_descriptor_config.php | 38 - .../resources/grafeas_rest_client_config.php | 172 --- .../v1/tests/Unit/V1/GrafeasClientTest.php | 990 ---------------- 231 files changed, 118 insertions(+), 25114 deletions(-) rename {owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas => Grafeas/metadata}/V1/Vex.php (100%) rename {owl-bot-staging/Grafeas/v1/proto/src/Grafeas => Grafeas/src}/V1/VulnerabilityAssessmentNote.php (97%) rename {owl-bot-staging/Grafeas/v1/proto/src/Grafeas => Grafeas/src}/V1/VulnerabilityAssessmentNote/Assessment.php (97%) rename {owl-bot-staging/Grafeas/v1/proto/src/Grafeas => Grafeas/src}/V1/VulnerabilityAssessmentNote/Assessment/Justification.php (91%) rename {owl-bot-staging/Grafeas/v1/proto/src/Grafeas => Grafeas/src}/V1/VulnerabilityAssessmentNote/Assessment/Justification/JustificationType.php (94%) rename {owl-bot-staging/Grafeas/v1/proto/src/Grafeas => Grafeas/src}/V1/VulnerabilityAssessmentNote/Assessment/Remediation.php (93%) rename {owl-bot-staging/Grafeas/v1/proto/src/Grafeas => Grafeas/src}/V1/VulnerabilityAssessmentNote/Assessment/Remediation/RemediationType.php (91%) rename {owl-bot-staging/Grafeas/v1/proto/src/Grafeas => Grafeas/src}/V1/VulnerabilityAssessmentNote/Assessment/State.php (92%) rename {owl-bot-staging/Grafeas/v1/proto/src/Grafeas => Grafeas/src}/V1/VulnerabilityAssessmentNote/Product.php (95%) rename {owl-bot-staging/Grafeas/v1/proto/src/Grafeas => Grafeas/src}/V1/VulnerabilityAssessmentNote/Publisher.php (94%) rename {owl-bot-staging/Grafeas/v1/proto/src/Grafeas => Grafeas/src}/V1/VulnerabilityOccurrence/VexAssessment.php (97%) delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Attestation.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Build.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Common.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Compliance.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Cvss.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Deployment.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Discovery.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/DsseAttestation.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Grafeas.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Image.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoProvenance.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoStatement.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Package.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Provenance.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Severity.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenance.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenanceZeroTwo.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Upgrade.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vulnerability.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext/Kind.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext_Kind.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Architecture.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Artifact.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote/Hint.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote_Hint.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationOccurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesResponse.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesResponse.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildNote.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildOccurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildProvenance.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuilderConfig.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackComplexity.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackVector.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Authentication.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Impact.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/PrivilegesRequired.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Scope.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/UserInteraction.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSVersion.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_AttackComplexity.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_AttackVector.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_Authentication.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_Impact.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_PrivilegesRequired.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_Scope.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_UserInteraction.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackComplexity.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackVector.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Impact.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/PrivilegesRequired.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Scope.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/UserInteraction.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_AttackComplexity.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_AttackVector.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_Impact.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_PrivilegesRequired.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_Scope.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_UserInteraction.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CloudRepoSourceContext.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Command.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Completeness.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote/CisBenchmark.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote_CisBenchmark.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceOccurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceVersion.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateNoteRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateOccurrenceRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote/DSSEHint.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote_DSSEHint.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationOccurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteNoteRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteOccurrenceRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentNote.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence/Platform.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence_Platform.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Digest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryNote.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisCompleted.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisStatus.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/ContinuousAnalysis.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence_AnalysisCompleted.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence_AnalysisStatus.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence_ContinuousAnalysis.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Distribution.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Envelope.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/EnvelopeSignature.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileHashes.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileLocation.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Fingerprint.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GerritSourceContext.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetNoteRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceNoteRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GitSourceContext.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GrafeasGrpcClient.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Hash.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageNote.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageOccurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoProvenance.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoStatement.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Jwt.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Layer.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/License.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesResponse.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesResponse.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesResponse.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Location.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Metadata.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NonCompliantFile.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Note.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NoteKind.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Occurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageNote.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageOccurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ProjectRepoId.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Recipe.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RelatedUrl.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RepoId.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Severity.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Signature.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/Material.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaBuilder.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaCompleteness.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaMetadata.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaRecipe.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaBuilder.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaCompleteness.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaConfigSource.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaInvocation.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMaterial.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMetadata.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaBuilder.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaCompleteness.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaConfigSource.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaInvocation.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaMaterial.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaMetadata.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance_Material.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance_SlsaBuilder.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance_SlsaCompleteness.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance_SlsaMetadata.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance_SlsaRecipe.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Source.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SourceContext.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Subject.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateNoteRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateOccurrenceRequest.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeDistribution.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeNote.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeOccurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version/VersionKind.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version_VersionKind.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment_Justification.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment_Justification_JustificationType.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment_Remediation.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment_Remediation_RemediationType.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Assessment_State.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Product.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote_Publisher.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/Detail.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail/KnowledgeBase.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote_Detail.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote_WindowsDetail.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote_WindowsDetail_KnowledgeBase.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/PackageIssue.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence_PackageIssue.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence_VexAssessment.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Category.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Identity.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate_Category.php delete mode 100644 owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate_Identity.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/batch_create_notes.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/batch_create_occurrences.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_note.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_occurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_note.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_occurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_note.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence_note.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_note_occurrences.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_notes.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_occurrences.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_note.php delete mode 100644 owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_occurrence.php delete mode 100644 owl-bot-staging/Grafeas/v1/src/V1/Gapic/GrafeasGapicClient.php delete mode 100644 owl-bot-staging/Grafeas/v1/src/V1/GrafeasClient.php delete mode 100644 owl-bot-staging/Grafeas/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/Grafeas/v1/src/V1/resources/grafeas_client_config.json delete mode 100644 owl-bot-staging/Grafeas/v1/src/V1/resources/grafeas_descriptor_config.php delete mode 100644 owl-bot-staging/Grafeas/v1/src/V1/resources/grafeas_rest_client_config.php delete mode 100644 owl-bot-staging/Grafeas/v1/tests/Unit/V1/GrafeasClientTest.php diff --git a/Grafeas/metadata/V1/Common.php b/Grafeas/metadata/V1/Common.php index 24ca668a48945347c6dbd5460f3868abca6a98ff..2cb169eb609aff4dd5e96630101b9eef5e0d7474 100644 GIT binary patch delta 55 zcmdnXd7E>?ZbrtNoA)p-WMsTEIgWY1oRAEcL|CYgpKFk#lc$eoNMyWYaIkA|u&=9M LhyeFwS(XI=A)67u delta 24 gcmcc3xtDXpZbru4oA)p-WMteoIgWY%WNVfM0Dqea$p8QV diff --git a/Grafeas/metadata/V1/Grafeas.php b/Grafeas/metadata/V1/Grafeas.php index 615aacacea69c0463f53b34aa3650d51827b3aaf..b3a2600042b595b1fb4b8704a5883e9b888a52d6 100644 GIT binary patch delta 133 zcmaEE_s4!iBr8*D#pH*~dXpnqgP3j@Z(hUtfstP%y(lp)HL+N~%uv59wPN#B_NB~B z``9r4}V7W#(j-RK_P37pE2%=ceYBNQfvfYH%CHsOv#Z&?__4 Q3qw}y2v@r~gYUlp0Dj0X)c^nh delta 37 vcmV+=0NVfjKj%KMSp}1d1yKU^GPB(U@By>q2c820@dmSl3o-+<0}uHSITH^I diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vex.php b/Grafeas/metadata/V1/Vex.php similarity index 100% rename from owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vex.php rename to Grafeas/metadata/V1/Vex.php diff --git a/Grafeas/metadata/V1/Vulnerability.php b/Grafeas/metadata/V1/Vulnerability.php index e33da459edc..8886bd996b0 100644 --- a/Grafeas/metadata/V1/Vulnerability.php +++ b/Grafeas/metadata/V1/Vulnerability.php @@ -20,11 +20,12 @@ public static function initOnce() { \GPBMetadata\Grafeas\V1\Cvss::initOnce(); \GPBMetadata\Grafeas\V1\Package::initOnce(); \GPBMetadata\Grafeas\V1\Severity::initOnce(); + \GPBMetadata\Grafeas\V1\Vex::initOnce(); $pool->internalAddGeneratedFile( ' -® +ø grafeas/v1/vulnerability.proto -grafeas.v1google/protobuf/timestamp.protografeas/v1/common.protografeas/v1/cvss.protografeas/v1/package.protografeas/v1/severity.proto"ì +grafeas.v1google/protobuf/timestamp.protografeas/v1/common.protografeas/v1/cvss.protografeas/v1/package.protografeas/v1/severity.protografeas/v1/vex.proto"ì VulnerabilityNote cvss_score (& @@ -59,7 +60,7 @@ public static function initOnce() { fixing_kbs ( 29.grafeas.v1.VulnerabilityNote.WindowsDetail.KnowledgeBase* KnowledgeBase name (  -url ( "¯ +url ( "ã VulnerabilityOccurrence type ( & severity (2.grafeas.v1.Severity @@ -74,7 +75,8 @@ public static function initOnce() { effective_severity (2.grafeas.v1.Severity fix_available (- cvss_version (2.grafeas.v1.CVSSVersion! -cvss_v2 ( 2.grafeas.v1.CVSSà +cvss_v2 ( 2.grafeas.v1.CVSSI +vex_assessment ( 21.grafeas.v1.VulnerabilityOccurrence.VexAssessmentà PackageIssue affected_cpe_uri (  affected_package ( - @@ -86,7 +88,15 @@ public static function initOnce() { package_type ( 5 effective_severity (2.grafeas.v1.SeverityBàA/ file_location - ( 2.grafeas.v1.FileLocationBQ + ( 2.grafeas.v1.FileLocationæ + VexAssessment +cve ( , + related_uris ( 2.grafeas.v1.RelatedUrl + note_name ( G +state (28.grafeas.v1.VulnerabilityAssessmentNote.Assessment.State +impacts ( T + remediations ( 2>.grafeas.v1.VulnerabilityAssessmentNote.Assessment.RemediationW + justification ( 2@.grafeas.v1.VulnerabilityAssessmentNote.Assessment.JustificationBQ io.grafeas.v1PZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' , true); diff --git a/Grafeas/src/V1/Note.php b/Grafeas/src/V1/Note.php index 711a5fde840..09e6e04559d 100644 --- a/Grafeas/src/V1/Note.php +++ b/Grafeas/src/V1/Note.php @@ -123,6 +123,8 @@ class Note extends \Google\Protobuf\Internal\Message * A note describing a compliance check. * @type \Grafeas\V1\DSSEAttestationNote $dsse_attestation * A note describing a dsse attestation note. + * @type \Grafeas\V1\VulnerabilityAssessmentNote $vulnerability_assessment + * A note describing a vulnerability assessment. * } */ public function __construct($data = NULL) { @@ -712,6 +714,37 @@ public function setDsseAttestation($var) return $this; } + /** + * A note describing a vulnerability assessment. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote vulnerability_assessment = 20; + * @return \Grafeas\V1\VulnerabilityAssessmentNote|null + */ + public function getVulnerabilityAssessment() + { + return $this->readOneof(20); + } + + public function hasVulnerabilityAssessment() + { + return $this->hasOneof(20); + } + + /** + * A note describing a vulnerability assessment. + * + * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote vulnerability_assessment = 20; + * @param \Grafeas\V1\VulnerabilityAssessmentNote $var + * @return $this + */ + public function setVulnerabilityAssessment($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityAssessmentNote::class); + $this->writeOneof(20, $var); + + return $this; + } + /** * @return string */ diff --git a/Grafeas/src/V1/NoteKind.php b/Grafeas/src/V1/NoteKind.php index 522f07bb21c..7616d7f290c 100644 --- a/Grafeas/src/V1/NoteKind.php +++ b/Grafeas/src/V1/NoteKind.php @@ -79,6 +79,12 @@ class NoteKind * Generated from protobuf enum DSSE_ATTESTATION = 10; */ const DSSE_ATTESTATION = 10; + /** + * This represents a Vulnerability Assessment. + * + * Generated from protobuf enum VULNERABILITY_ASSESSMENT = 11; + */ + const VULNERABILITY_ASSESSMENT = 11; private static $valueToName = [ self::NOTE_KIND_UNSPECIFIED => 'NOTE_KIND_UNSPECIFIED', @@ -92,6 +98,7 @@ class NoteKind self::UPGRADE => 'UPGRADE', self::COMPLIANCE => 'COMPLIANCE', self::DSSE_ATTESTATION => 'DSSE_ATTESTATION', + self::VULNERABILITY_ASSESSMENT => 'VULNERABILITY_ASSESSMENT', ]; public static function name($value) diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote.php b/Grafeas/src/V1/VulnerabilityAssessmentNote.php similarity index 97% rename from owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote.php rename to Grafeas/src/V1/VulnerabilityAssessmentNote.php index b0b4b7cd0c3..a386e04242c 100644 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote.php +++ b/Grafeas/src/V1/VulnerabilityAssessmentNote.php @@ -21,44 +21,44 @@ class VulnerabilityAssessmentNote extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string title = 1; */ - protected $title = ''; + private $title = ''; /** * A one sentence description of this Vex. * * Generated from protobuf field string short_description = 2; */ - protected $short_description = ''; + private $short_description = ''; /** * A detailed description of this Vex. * * Generated from protobuf field string long_description = 3; */ - protected $long_description = ''; + private $long_description = ''; /** * Identifies the language used by this document, * corresponding to IETF BCP 47 / RFC 5646. * * Generated from protobuf field string language_code = 4; */ - protected $language_code = ''; + private $language_code = ''; /** * Publisher details of this Note. * * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Publisher publisher = 5; */ - protected $publisher = null; + private $publisher = null; /** * The product affected by this vex. * * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Product product = 6; */ - protected $product = null; + private $product = null; /** * Represents a vulnerability assessment for the product. * * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment assessment = 7; */ - protected $assessment = null; + private $assessment = null; /** * Constructor. diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment.php b/Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment.php similarity index 97% rename from owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment.php rename to Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment.php index c7432ee84db..56c14cfb3d1 100644 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment.php +++ b/Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment.php @@ -22,19 +22,19 @@ class Assessment extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string cve = 1; */ - protected $cve = ''; + private $cve = ''; /** * A one sentence description of this Vex. * * Generated from protobuf field string short_description = 2; */ - protected $short_description = ''; + private $short_description = ''; /** * A detailed description of this Vex. * * Generated from protobuf field string long_description = 3; */ - protected $long_description = ''; + private $long_description = ''; /** * Holds a list of references associated with this vulnerability item and * assessment. These uris have additional information about the @@ -49,7 +49,7 @@ class Assessment extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.State state = 5; */ - protected $state = 0; + private $state = 0; /** * Contains information about the impact of this vulnerability, * this will change with time. @@ -63,7 +63,7 @@ class Assessment extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification justification = 7; */ - protected $justification = null; + private $justification = null; /** * Specifies details on how to handle (and presumably, fix) a vulnerability. * @@ -338,6 +338,4 @@ public function setRemediations($var) } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Assessment::class, \Grafeas\V1\VulnerabilityAssessmentNote_Assessment::class); diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification.php b/Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/Justification.php similarity index 91% rename from owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification.php rename to Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/Justification.php index fdb666012d6..92bb483d31a 100644 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification.php +++ b/Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/Justification.php @@ -21,13 +21,13 @@ class Justification extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification.JustificationType justification_type = 1; */ - protected $justification_type = 0; + private $justification_type = 0; /** * Additional details on why this justification was chosen. * * Generated from protobuf field string details = 2; */ - protected $details = ''; + private $details = ''; /** * Constructor. @@ -100,6 +100,4 @@ public function setDetails($var) } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Justification::class, \Grafeas\V1\VulnerabilityAssessmentNote_Assessment_Justification::class); diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification/JustificationType.php b/Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/Justification/JustificationType.php similarity index 94% rename from owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification/JustificationType.php rename to Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/Justification/JustificationType.php index 8d0a2417083..92babd236f7 100644 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Justification/JustificationType.php +++ b/Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/Justification/JustificationType.php @@ -89,6 +89,4 @@ public static function value($name) } } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(JustificationType::class, \Grafeas\V1\VulnerabilityAssessmentNote_Assessment_Justification_JustificationType::class); diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation.php b/Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/Remediation.php similarity index 93% rename from owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation.php rename to Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/Remediation.php index 43bea6f40ec..60c72a54fc7 100644 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation.php +++ b/Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/Remediation.php @@ -20,19 +20,19 @@ class Remediation extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Remediation.RemediationType remediation_type = 1; */ - protected $remediation_type = 0; + private $remediation_type = 0; /** * Contains a comprehensive human-readable discussion of the remediation. * * Generated from protobuf field string details = 2; */ - protected $details = ''; + private $details = ''; /** * Contains the URL where to obtain the remediation. * * Generated from protobuf field .grafeas.v1.RelatedUrl remediation_uri = 3; */ - protected $remediation_uri = null; + private $remediation_uri = null; /** * Constructor. @@ -143,6 +143,4 @@ public function setRemediationUri($var) } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Remediation::class, \Grafeas\V1\VulnerabilityAssessmentNote_Assessment_Remediation::class); diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation/RemediationType.php b/Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/Remediation/RemediationType.php similarity index 91% rename from owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation/RemediationType.php rename to Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/Remediation/RemediationType.php index 66c51c0be9f..61fabdf6de4 100644 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/Remediation/RemediationType.php +++ b/Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/Remediation/RemediationType.php @@ -80,6 +80,4 @@ public static function value($name) } } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RemediationType::class, \Grafeas\V1\VulnerabilityAssessmentNote_Assessment_Remediation_RemediationType::class); diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/State.php b/Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/State.php similarity index 92% rename from owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/State.php rename to Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/State.php index 69b81a30cd4..f4d4826a29e 100644 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Assessment/State.php +++ b/Grafeas/src/V1/VulnerabilityAssessmentNote/Assessment/State.php @@ -74,6 +74,4 @@ public static function value($name) } } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Grafeas\V1\VulnerabilityAssessmentNote_Assessment_State::class); diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Product.php b/Grafeas/src/V1/VulnerabilityAssessmentNote/Product.php similarity index 95% rename from owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Product.php rename to Grafeas/src/V1/VulnerabilityAssessmentNote/Product.php index a7fad624e32..7509e82a22a 100644 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Product.php +++ b/Grafeas/src/V1/VulnerabilityAssessmentNote/Product.php @@ -23,7 +23,7 @@ class Product extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string name = 1; */ - protected $name = ''; + private $name = ''; /** * Token that identifies a product so that it can be referred to from other * parts in the document. There is no predefined format as long as it @@ -31,7 +31,7 @@ class Product extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string id = 2; */ - protected $id = ''; + private $id = ''; protected $identifier; /** @@ -155,6 +155,4 @@ public function getIdentifier() } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Product::class, \Grafeas\V1\VulnerabilityAssessmentNote_Product::class); diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Publisher.php b/Grafeas/src/V1/VulnerabilityAssessmentNote/Publisher.php similarity index 94% rename from owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Publisher.php rename to Grafeas/src/V1/VulnerabilityAssessmentNote/Publisher.php index 2801fd5a85c..8100861cc8d 100644 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityAssessmentNote/Publisher.php +++ b/Grafeas/src/V1/VulnerabilityAssessmentNote/Publisher.php @@ -24,7 +24,7 @@ class Publisher extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string name = 1; */ - protected $name = ''; + private $name = ''; /** * Provides information about the authority of the issuing party to * release the document, in particular, the party's constituency and @@ -32,7 +32,7 @@ class Publisher extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string issuing_authority = 2; */ - protected $issuing_authority = ''; + private $issuing_authority = ''; /** * The context or namespace. * Contains a URL which is under control of the issuing party and can @@ -41,7 +41,7 @@ class Publisher extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string publisher_namespace = 3; */ - protected $publisher_namespace = ''; + private $publisher_namespace = ''; /** * Constructor. @@ -160,6 +160,4 @@ public function setPublisherNamespace($var) } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Publisher::class, \Grafeas\V1\VulnerabilityAssessmentNote_Publisher::class); diff --git a/Grafeas/src/V1/VulnerabilityOccurrence.php b/Grafeas/src/V1/VulnerabilityOccurrence.php index 5693a750709..6cb1628da39 100644 --- a/Grafeas/src/V1/VulnerabilityOccurrence.php +++ b/Grafeas/src/V1/VulnerabilityOccurrence.php @@ -100,6 +100,10 @@ class VulnerabilityOccurrence extends \Google\Protobuf\Internal\Message * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 12; */ private $cvss_v2 = null; + /** + * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence.VexAssessment vex_assessment = 13; + */ + private $vex_assessment = null; /** * Constructor. @@ -144,6 +148,7 @@ class VulnerabilityOccurrence extends \Google\Protobuf\Internal\Message * Output only. CVSS version used to populate cvss_score and severity. * @type \Grafeas\V1\CVSS $cvss_v2 * The cvss v2 score for the vulnerability. + * @type \Grafeas\V1\VulnerabilityOccurrence\VexAssessment $vex_assessment * } */ public function __construct($data = NULL) { @@ -509,5 +514,37 @@ public function setCvssV2($var) return $this; } + /** + * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence.VexAssessment vex_assessment = 13; + * @return \Grafeas\V1\VulnerabilityOccurrence\VexAssessment|null + */ + public function getVexAssessment() + { + return $this->vex_assessment; + } + + public function hasVexAssessment() + { + return isset($this->vex_assessment); + } + + public function clearVexAssessment() + { + unset($this->vex_assessment); + } + + /** + * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence.VexAssessment vex_assessment = 13; + * @param \Grafeas\V1\VulnerabilityOccurrence\VexAssessment $var + * @return $this + */ + public function setVexAssessment($var) + { + GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityOccurrence\VexAssessment::class); + $this->vex_assessment = $var; + + return $this; + } + } diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/VexAssessment.php b/Grafeas/src/V1/VulnerabilityOccurrence/VexAssessment.php similarity index 97% rename from owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/VexAssessment.php rename to Grafeas/src/V1/VulnerabilityOccurrence/VexAssessment.php index da3e263a0a2..ea2738e3830 100644 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/VexAssessment.php +++ b/Grafeas/src/V1/VulnerabilityOccurrence/VexAssessment.php @@ -22,7 +22,7 @@ class VexAssessment extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string cve = 1; */ - protected $cve = ''; + private $cve = ''; /** * Holds a list of references associated with this vulnerability item and * assessment. @@ -39,13 +39,13 @@ class VexAssessment extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string note_name = 3; */ - protected $note_name = ''; + private $note_name = ''; /** * Provides the state of this Vulnerability assessment. * * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.State state = 4; */ - protected $state = 0; + private $state = 0; /** * Contains information about the impact of this vulnerability, * this will change with time. @@ -65,7 +65,7 @@ class VexAssessment extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote.Assessment.Justification justification = 7; */ - protected $justification = null; + private $justification = null; /** * Constructor. @@ -312,6 +312,4 @@ public function setJustification($var) } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(VexAssessment::class, \Grafeas\V1\VulnerabilityOccurrence_VexAssessment::class); diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Attestation.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Attestation.php deleted file mode 100644 index 8db0f36078c..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Attestation.php +++ /dev/null @@ -1,40 +0,0 @@ -internalAddGeneratedFile( - ' -ˆ -grafeas/v1/attestation.proto -grafeas.v1"f -AttestationNote. -hint ( 2 .grafeas.v1.AttestationNote.Hint# -Hint -human_readable_name ( " -Jwt - compact_jwt ( "} -AttestationOccurrence -serialized_payload ( ) - -signatures ( 2.grafeas.v1.Signature -jwts ( 2.grafeas.v1.JwtBQ - io.grafeas.v1PZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Build.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Build.php deleted file mode 100644 index 6ab3907fa63..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Build.php +++ /dev/null @@ -1,39 +0,0 @@ -internalAddGeneratedFile( - ' -´ -grafeas/v1/build.proto -grafeas.v1!grafeas/v1/intoto_statement.protografeas/v1/provenance.proto"$ - BuildNote -builder_version ( "Ì -BuildOccurrence/ - -provenance ( 2.grafeas.v1.BuildProvenance -provenance_bytes ( 7 -intoto_provenance ( 2.grafeas.v1.InTotoProvenance5 -intoto_statement ( 2.grafeas.v1.InTotoStatementBQ - io.grafeas.v1PZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Common.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Common.php deleted file mode 100644 index 2cb169eb609aff4dd5e96630101b9eef5e0d7474..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1243 zcmZ`(e`^~@5Us5EhsJVqITGqZ3mZ2OB_t9~C=|I)IqNRsuq<6H$>1P3R(GTGlJ)L! zyE0XSzf8YXp&zDuKccvp=pXIuzBlvU&d&Y*M|zdQFQktGGpaEr^A*uoNYYGd8A(p& z%f$jS63Oe7am?C;xFa$gO^E0Elc$EN)&N+*S(o~zjXH11mFwH1ue;Jj>WI?$? zL%ok(EJdW56eK5%M1-vuq|BLPpQX~cIwrHelnKXKkQ+57XTH#w3Cd?KswiWrmRVq+ z-EM+qS*IPsbLdRch>Z?}V#ydmzg*!bms|f*Q-L=>vycu;l%N} z?0a+dtu-*GJ%@ib;fHVBxee7p`{wYV1#pf$@9i|>_AbHGu^-M?8cTHZ<-ax98A^?(OvLt&@Wf1w7oPeBq)mSK&L#SDN~)V&-SQV i{=HE*(&k$Q^zHNYQ-4)X(4B$%=CBpWa;|RS7T`Z@m0c$Q diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Compliance.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Compliance.php deleted file mode 100644 index 1927013074764e0c4a1300bbdeb543eee6bdecbb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1315 zcmaJ>T~8B16qS#HTqxKDVns>DN~9#Z4fvu(R0>*ofEFb@m`yg*+1qyFc4jj(OHvJg z#=qmg@RvBd-F_rR`_j$bbI(2Je(c-#Q8$8Tq>cg=H5iaqpO`L^NJ%4^3`r|)w^0!$ zdl3&&xrCfH$VKCdd^|n7dTLX(j1|Kw=_uMpsw+49l>{7eDj2#c4}hRO)DdM!>do3Y z8X8bTz4{=$ z?N~6wr65T{!-^^IkpX9d-HD`icSO9pl${X0W@6Zy_0EJrC1~iKqGpOmMyjTTR;wK} zqc$ax@?KUpq2p~*9%!sqr$inRqhg$_PKZJiD{+|WP6%#CPu|@v^1k8?DsKAK>e$dY zKlStS9naJs2f;|}Cp)V~7t)}Uhn(Ri#NrH@ zDK9zeupDIFvJEfJra>1Ltzex5=Ez)m`C!`}le%NV>jB6qz>-}-3#XQMe#on^hXGIH z#atTv0C{HDpoM~UdsKZdF4*w$fwy}%eWKSr;kq`&f4=8Df`VpL*j3VYGU=A+;-aNl z**b@nNwBjCdAq}H+d@CI0|-;cIp;at*V#N$yQ>EqljVoAsuf^ud=0+oM_9Uq!nFA{ zSY#3UvEo@vx4;=W^aIJ_9tvX{nY7!2hn-DZU5a31Oxa*8R?50X=MAh2Dg2=V<0n3} z6`YLY$)w;5DTWLt*%xOUHYZaV`pRB+I!h~|bOsNmQdVF-qNbY}cnE6&*HK9ON&Oxb zLADpGurNtgyM#QK6Iz-x-(GjpqjWnmq@v?W)v0t)q~DUt;1!Lyu8bG>FnjzpJ6Hd5 d+*(MXuXaaE|6*`~69@axV@;8RySjy2fWPu-lUe`( diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Cvss.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Cvss.php deleted file mode 100644 index 77a230e503ff8fc5b474543f37a7a7640f2968cb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3353 zcmeHK-BQ~|6t2xr%i+(6049ZIG08wWtrr*F_v5!S8^`#~ySHT|=&?dgSY& z?zVMP_jJ|Jet72Jw1Ggl9 zlVpP}!St|Wsz$4fUCq&L&vGOJEtUG%8^}~d^~32sv>)VHDkYLUL7p?f^i3S(ZvO33pY$-r;Pa`{=x-JQtgMo{JyR&7Tg zl2Y`s+jj7;1Kq*h{HHX+qm&5J2we}s%nQg3TjM%pC*84XZK3D6)=+78X;-^ zF48ktRfno>+?-;_TeyQ)c%OlV$RTaRCaWkc_p06GIYq3u8#P(tIpIv;%ehaOO<0S% zYrOJWtiQ@-nES9Eb+P3iSdOnLxh%5*t5IK7Q)Zh$eg7#g56`2zyJ{EZumT%15Ia{lcmdG$GuoxI`OxZ#mX2WJ)2S&J% zNSd)o%P=3>=}t4u5T(O9sZSOD0hsnx||a%rOSp+w&Co_iFPz4Zhk z=$hwuh~7qm7k0_vM9G^-dHNy2o5cDkcbDx@?*7QYQmn_mfctDiIVXxu1UN-kh>pel z7mcbS5EUjW;9m?;vMkgp#1)8t)D^zcA0_vHExBLHFz+jF6FV-ED*vkTf0DtVE+=mt z29_e;C!{IjwxeA3wAF$|-5OJZ(>b3<$8ah0^EZ7umKXb$p_=`o<@68w*rfj>4g!~I r>+Zqr;CmcC{*|4o)Y;A~g&ysVhUKq<8GLMHpE#~lWH6au!!^La2Pne9 diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Deployment.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Deployment.php deleted file mode 100644 index 4c9c49aad310e4ccf57902e664e90149b926943c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1084 zcmah|+fLg+5N#3~U??=Qc!=7UEkz|rt)tMF$|eV|o^KjsKh2)+dU!!P}w%maq6?poOxfw9~XkNFrUcknDIHy9Pu?deP=HnkH zlGRJ3(pcU4UWUy%aOk>;l&I4;41gp?ImRhvp$3;4t40&n@?{w-ZLD6_muq`Z%ph}} zFOQyyS-3V@u%7TmO69+l4XC<;`z)w0Wj!CmGW9&IJgz^?F7EoMrap`|tVAJIzL3-U zvc_%f?V9sA%s*K)?HOU~2v&ZbjXG@F#|NX{@a$xKae8idj|RO#w^MsyEJLOLp<62% zE3ni%?tZG3bw<^ri}TU&q*gin2}1XMpU%2z5Kw=xYTHc_avJqq)E{io@oz)ts`B@Ff+udO`!> z;{^=^OepFP&o8OOQ!KIDPZ93B)+qq-a2TRaj)V_@)GvsxJw{L{u~dIASU6!mlMH+8 zz0!JyX4ng5)-Tp-68ImHR>)8M!?)2qu%tK-ryzUqTOCqwIbOBEeabkH3Eqj!TqsU0dXDG`6#>(rWmGc^2LJt zn=wh_zx$D8Z8oOUqN_dSuSU^_xGOK=&mE}$zp*sP&h%xgel$;-)l4j>M%k2k#iS@N+S7yMx3E_j(&mzC-@qPL=C}=&5&vNRv{pi;#{S8nzS5z` zfxoD;n52+Ol6@0o7b+y6wFfHTk#++6YJtc}NU%SNCtur2fb~3AZVSD*2-*+u z7z=X4mNZ3de-3e8`Nyc#U&EJq-&VCgU2}%KRkBK|)JMk-Xd4Fh9FEL^J+kcaVC+l` z+qn46v7E`+c7|Qk>RH`R^$QJP+b~DgyKc3lJ%%02&fdz$f0tlCSCF;u2)-(4oRKk7 zv>&tW!oy+L?pSs|rE^Tfw&S<5b_ms;Wn0eA-Oj`rn`YN>s+BmUIk+5NbVptFb^uR` zn4V!>D1{HS8XOiMRkrbPIJg?AldXEWS~~v~_84C?&9L=y ynI7SQh0WE4Kg}NhDp&ef#`Sg*`u)pdNqn2G*0oI>dxwz?TR4eKcjX=20sIFWgfim* diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/DsseAttestation.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/DsseAttestation.php deleted file mode 100644 index ef80894effc944fe157dddad5b1351735c4cb183..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1079 zcmah|(QeZ)6r~$NnO0@T7x0NVNtH&d6M0JPbB@pPJ$d&bnn&ar^iiOq8aS zh=-_bfbI~khZE>^2a{7njb)-3IuI!8BaQ3JM%{~JoKmeZ)>LyT>`aXiK^GWDlp*v- zozJMLM>Tc(Inn*rXcEFg8pqHz0__c-{3KwWD4B(vK_<%JoX1lxxaKtEKaBAf_%w{s zXxzs7iD0P_NC`v1(7J$JGsT`q(gbaR+m|v3(H*7PO>TD}G%7(uw~H}TJknB)4AgM~ z)WwaZE7ryO*i?@DVC5bi=a$J9Xq903bO41qQKFgoP6bxQo4fs<+>dgxkiu~`aW?F` zI3|pVH8vB$1q!{LoL$As_k10^?RiDcPiFj9;Vku8BY$?u>3`>5C2NSiY#f*2<`m;- zn%-4rDX+=dk{ou&<6de0*HUBk4Y@xzjH3!vtb;;Mv-h!5_OdvX=tVkLn3I zoF@w^rV35@W+6_~PG*|>XTK`s=|56K#uBB_G^YBT?4ej`56o5R>v8uI_anlSdvh>7h4`=uIf8*ZD#oa#>=HD&OA*Sv&1OhExQ$R6#vJ wk^Ncqe2Ydru5ZTCT)+O_+3kOA&mLsZ*R^7VFY+puntNw!Gh|+|6G0qH_-3=NqyPCn^AOf~n;1G>8YR{C14(;yV z?j8$6tVA2-9wmoda@s?(e?^pQa?K_3DTkc+6Ov0_eRNmVe83Ef;*0Hi_3C}p`~B)w z*B4(!FCw^TZ_up4#^| z9z4B(s!7<1o3vuLV|SOjNqPTfS^in#ivR@f9!(;*N$t(;+9R5}EjM-Rn__}mv(=^G?lyI-rlHYP$%*|7b|}>TN^a;!-Ksc zYewZ`!%LdsK8=UkK20r2=m)3r!JgY5F}!WJ`Eq2XXA#m_YeY-W>8sH)|GeWf2Hx>} zZx9GLZ~gE~PqI|C)yhffK2q~?P9uy|uEIZVfhCE!hm#3NNooJ)VzJGcrtC&uxycDb z5clGeCfH@H(Abf*ASayFCd3l^Qglv=_z{5QTBZ!$QfPMz#p-*A;V#p;dYS=MPWV_0 z%~fcW(leTLhe1w`7qxLb(GXWsaLyD+@bnS3a)e0XqNdr(U?61|bQ#uq4@5tk_FA&K7A!eKha0^Did<&Ka&7k&1NT#De?t54ioIWwhDG(d73Q1 z@oZxoo!GO+_~<-L@+0!ESU4dplwKo$KZ8_L7#Q{h-V)$IF4{Tqi5=g5I>83atmhZ ztH{HP0h%8HpE{u5kIybZ3v|AV0TzK|G2}FqAU?;Dus-hwy8xmAECcK;`3UnX8O#L` zPwN@sFjw;gzytQ9@hJy=V zftN>`B&=_>7Wg9dt9m+&4X@^N#cGw$-d5LOHcL0cnvIjCK7bBTfKX8sbj#8=mJbJw;Ntd0GU@IxriHyqp}EkViBeKn*z*>Qq_$Q=Xh>`p>}4i zzlG6D@--}GJEP!}m&TB;eIT_p;ap$a|5JMVE7C*FO`9*&uIJ&6vhB63TE{remh@^J zus*+BCHI0fKH&Sm_$2__crip~VEiRLkasx*!@lcxsARmJ?X8U6E;#F8^_m(IP0k^l z*OdEg_9)r7VIDmqCq}2L42ar)1fL8t{{j2G_S-p_+7wL~IfN4iI}+p4Wr!s2E)Ha zFSZqqwV5SUIYao(K~1N6c_{3uI=vTbj8&2nWwZhS!GKXEVd+ z7-&{iepfr#4E%Z{)%DAEe=wvMW&BpO)w*paQW z-{d=lgND|}Z0AilbW1aLj7sdCBsb$Ocd_J%x*OinternalAddGeneratedFile( - ' -× -grafeas/v1/image.proto -grafeas.v1"- -Layer - directive (  - arguments ( "@ - Fingerprint -v1_name (  -v2_blob (  -v2_name ( "O - ImageNote - resource_url ( , - fingerprint ( 2.grafeas.v1.Fingerprint"“ -ImageOccurrence, - fingerprint ( 2.grafeas.v1.Fingerprint -distance (% - -layer_info ( 2.grafeas.v1.Layer -base_resource_url ( BQ - io.grafeas.v1PZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoProvenance.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoProvenance.php deleted file mode 100644 index 5861d7ce8a1..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoProvenance.php +++ /dev/null @@ -1,54 +0,0 @@ -internalAddGeneratedFile( - ' -Î -"grafeas/v1/intoto_provenance.proto -grafeas.v1google/protobuf/timestamp.proto"œ -Recipe -type (  -defined_in_material ( - entry_point ( \' - arguments ( 2.google.protobuf.Any) - environment ( 2.google.protobuf.Any"I - Completeness - arguments ( - environment ( - materials ("Ú -Metadata -build_invocation_id ( 4 -build_started_on ( 2.google.protobuf.Timestamp5 -build_finished_on ( 2.google.protobuf.Timestamp. - completeness ( 2.grafeas.v1.Completeness - reproducible (" - BuilderConfig - -id ( "¤ -InTotoProvenance1 -builder_config ( 2.grafeas.v1.BuilderConfig" -recipe ( 2.grafeas.v1.Recipe& -metadata ( 2.grafeas.v1.Metadata - materials ( Bh - io.grafeas.v1BInTotoProvenanceProtoPZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoStatement.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/IntotoStatement.php deleted file mode 100644 index 170908323f19bcfbdf0c0728f7e8fbe00f97ba7f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1374 zcmb_b(N5bi6s0W%aXW?-rm3nX%`ha2G*Xpm5(;AzRaxO-13|S16sdC4+u$wOk?jd_H>86cCDk|}{V~y(NJ1&J@I*lR(Qt^8 zc;YH#0ZN;Y_6hlV(j|xODZ9eQ;m-EK;%BrGQ#}ngh$knBX>BxsT@*3o{ap z&Jl8I>^RQU*p%lf^m(A@|G{3M6y0m_`0+`s+aFCcBq1IQ23cmGO)J$im$Bzf_*I6r zfA)|ClM;K>tmRuy8BaaaW|KhDj;n3u2xlsKH%5C;UyHPK{ZA2Aj(OL_nzfy^3iEm# zVzodD^`*0NFaEGLU{OW=@961jk(BC{omG3P$v#iFte5aSlsI6X8G!^>EyX0(4!~4p zb>94|?7Yeoq#CBzb2MkYhm{%e)p7!?<$?Ea)xZv+Is?l*R~Hie+SB;S%^uCQDzKC} zS-*zGJBQC;KAz_^9IF8f1LmW;3+44a>NFI)om3ohEyuNOsN_Da3Y31}ctW-e4{IKd{>m#;F zMS%dgct!%TM^LkO+9n*2F~@^uWIwn*JO;2F90aHr`N5xn#Lo{$4z*CgF&B@08VspR zImHhBL*#jaCfEsx@V#$430;d*&qdOq>sq9IfFew3yYG9Vt`jt9dYRbl8lZJBRpj8vC3Nl z+$`P(EBr*+nLZtyQ{s$I$rR72$7;1@RZEan*9EnMGjBHY+|T?I!4xsl;%Mi{s4PQN%*46=40ar$-GC40garcE(1b_+XfNq; z9UbX9zzmC$#h)-^Lq^r}poPpaHq~Me^5eMw5-KA%OI_Hy@GK!jk@Tarr1gEs-UXJa zJ`lJ78$RY!m0Pa#UmEhU+&dm8f{6_|CNT{eLBp-NDVZ22_%Z-#0)B;wH9iaR><#%R zpBQ;nQ6k}j+E^!eTkL*`;6#Bt4;Q$~>?0K^X11snYs~JdO@S?@oVWoo^!wNs(UD$) z%$VAu#m1hZKu@-|u1-pSrC~Rwv};)*V?<2;XNlGHC$Qzj{S@+&q&`j}E_(e9tP(1P zrBtdVwX0MlwX5kb*R(4&^#y7prvwL5ZfgR%b&nY&RXZKM!oozkWr@7?YGT~ zVoFSAw%zKq+E?vjS}n{EYN7q~1_~>efWS2SXTP;B8)uhS{l*$*7PJqqUkO0@^6KYe z`t%)aQ!i0UFZKItTV1&o+jFpMS3G7{ZQ`nrST#DrJ`JkN+wC}h{X4BS`{pR4OkX}- Y+?&s%+duKKc<@7^ETilE25tcU2e*VT&;S4c diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Provenance.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Provenance.php deleted file mode 100644 index 26eac47b31ced6d96f06119abcebb8a3b04a1c0e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2688 zcma)8ZFAE`5XO#i;&n`nLa7_t>7l?73Q;D80%J;A0i0NN44WB56)% zw`qqz&`+J|@TDL7Gy3bgcPHDj6QKTL>F(LR-DjWO(>ITkqXd>on?+1e$$WBnLgW!6 ziHK$F#UVND_j*haFFsCq$b>`4_8xh$cR+TwI|o!YhV=WR0+G8|b8?3LP@qk4% z@|dIj07Uedr3v*IY42}7XOj9<(r(+BbYHJO1n@$dreuF)3cmxvU(!Dexkpk-CH`IG zsmmiSISu)580{m{qhZR>{4}=Lk37lah$w?S3})pfF+LUcS`uS+k4U#2$3e)tc(9By z*={G2Ohh#7ZnM-AJdv^3M`)`RFgc=0t*qS4j#ch>kF1y&Tdh+;J|a@|S^jiF1e1Lc zJ=Ae42X9AD-3f}OqC4P7q@>45t2It*>_um_`Yq3L*zo;P$WO3*E2BfykvHJqI$Zfc z-7Ls9ox!^OX9*TI`#ki=C9(jD+;0>}VWnc>3l{rl=1CXVihAuj%%O0OY2>Gk88Wj{ zZ7w=vm(G^ivsPi@5Iswm3dwualWC)*(UPG?<*xiAh=w=a03qE}YoqG=Ns zDau--0ot>bPw|!RB}JtaJP4RjR93Z%ZKx@Zd^b*%sME&0W@t5UK2;t^zwa6RP9(*N z^{HXnN6!N$Qgqa)Dfdfv;Nod?6=vSBldQfqI6t6apPACOiVq6*yCRgckeA`guy}5Y zEkgt5W+^Kgj7083wTCKnk7#iu?09axw?b|U}l`TVQR%lQb#hMJdkfboj843*w6Ya~MD zT+bV;MD1lLsefx8O7bLOXK_An{{*wcmO-4FsTmFfWzj$rT2U^j2u#COEZp+BzRxcEbyjVDnWw6)ccx8l!AyX7qm0id z@LW!VzlL&14_P==#PvLW0_;4~IIX~?RjB4(6{{cWjLphOu=XDXnBNFFO^4jvg3=ov znX!4H`9=QxJkEKFAXQ9VXU)6)7)pBe64ak|UTnMHzj(F3v(dddE)0GH3E9%VYKilruw>egy=Vlt^xb$sg+s0udV zYH*CEye?V|FJzhy+byd_<9)g9p4$YN8+x+e6=3m<(kh7_#i`VT)J%}eaKWfU4N`U2 zm}xW}my$x|thiJgRGa@duDeigPbo-MzAwV8Cl=43!+r(jjIFz{FuW2csht=@`z8}( zgF)Bugy9W}M3vMXYu|&~1a9iOHSAo3iauwon9c8?#^YQW_6t8g$S%qt4rvrPu?W@z z7Ga<=UNc)X;py7=yWnB=_)l@B{c_{5tf6;qjJ_pqo6nov*U)>vgf!B8uDpe}0RI8H Cun3p{ diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Severity.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Severity.php deleted file mode 100644 index bd0c81933da82d252d670e0445a98d5e1628beae..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 744 zcmZ`%U2EGg6kVFG4R;#^vxn{Njuo1Y&7tgNB+Evcq^_a)Sd(^am=?vkb_K3vBstKH z{F(i<{gTOcmKI9&BB6WEx#u3~^Vjq`g}3ODAjJ$VaDI#CnlM$;$WSIY&!UJFhVmxm z2`Lw`KgQ8`hJ(I8dt<3uW-6o>#)?J6baQ#w)U+hU&8=Ig00?$NI%OfDH#r)TVGCwh z;FW~n;;;=6CQNIbu8Hs)(5^I_Cp<)Ln6cX)*H>I{!&$d zwz(XSuu*z!wH}!4pivp!?~bU*WJt0^efV2} z*N^7zz`Eov58quv?SHt=D|k5_Tnx_q*^jI9(R4EC`N#gCUw`5}gWaJ&@`v5idd1m= z>go70} z#I96vGbT}diDp@1Dc8+A|Lyhh&sNnt>&|xy=*Rud%IJe4cm*qfe}6pT A_y7O^ diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenance.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenance.php deleted file mode 100644 index 0a003210680..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenance.php +++ /dev/null @@ -1,61 +0,0 @@ -internalAddGeneratedFile( - ' -À - grafeas/v1/slsa_provenance.proto -grafeas.v1google/protobuf/timestamp.proto"þ -SlsaProvenance7 -builder ( 2&.grafeas.v1.SlsaProvenance.SlsaBuilder5 -recipe ( 2%.grafeas.v1.SlsaProvenance.SlsaRecipe9 -metadata ( 2\'.grafeas.v1.SlsaProvenance.SlsaMetadata6 - materials ( 2#.grafeas.v1.SlsaProvenance.Material  - -SlsaRecipe -type (  -defined_in_material ( - entry_point ( \' - arguments ( 2.google.protobuf.Any) - environment ( 2.google.protobuf.AnyM -SlsaCompleteness - arguments ( - environment ( - materials (ñ - SlsaMetadata -build_invocation_id ( 4 -build_started_on ( 2.google.protobuf.Timestamp5 -build_finished_on ( 2.google.protobuf.TimestampA - completeness ( 2+.grafeas.v1.SlsaProvenance.SlsaCompleteness - reproducible ( - SlsaBuilder - -id ( ‡ -Material -uri ( ? -digest ( 2/.grafeas.v1.SlsaProvenance.Material.DigestEntry- - DigestEntry -key (  -value ( :8Bf - io.grafeas.v1BSlsaProvenanceProtoPZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenanceZeroTwo.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenanceZeroTwo.php deleted file mode 100644 index 2df7242755b..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/SlsaProvenanceZeroTwo.php +++ /dev/null @@ -1,71 +0,0 @@ -internalAddGeneratedFile( - ' -¥ -)grafeas/v1/slsa_provenance_zero_two.proto -grafeas.v1google/protobuf/timestamp.proto"Ó -SlsaProvenanceZeroTwo> -builder ( 2-.grafeas.v1.SlsaProvenanceZeroTwo.SlsaBuilder - -build_type ( D - -invocation ( 20.grafeas.v1.SlsaProvenanceZeroTwo.SlsaInvocation- - build_config ( 2.google.protobuf.Struct@ -metadata ( 2..grafeas.v1.SlsaProvenanceZeroTwo.SlsaMetadataA - materials ( 2..grafeas.v1.SlsaProvenanceZeroTwo.SlsaMaterial - SlsaBuilder - -id ( – - SlsaMaterial -uri ( J -digest ( 2:.grafeas.v1.SlsaProvenanceZeroTwo.SlsaMaterial.DigestEntry- - DigestEntry -key (  -value ( :8¶ -SlsaInvocationI - config_source ( 22.grafeas.v1.SlsaProvenanceZeroTwo.SlsaConfigSource+ - -parameters ( 2.google.protobuf.Struct, - environment ( 2.google.protobuf.Struct³ -SlsaConfigSource -uri ( N -digest ( 2>.grafeas.v1.SlsaProvenanceZeroTwo.SlsaConfigSource.DigestEntry - entry_point ( - - DigestEntry -key (  -value ( :8ø - SlsaMetadata -build_invocation_id ( 4 -build_started_on ( 2.google.protobuf.Timestamp5 -build_finished_on ( 2.google.protobuf.TimestampH - completeness ( 22.grafeas.v1.SlsaProvenanceZeroTwo.SlsaCompleteness - reproducible (N -SlsaCompleteness - -parameters ( - environment ( - materials (Bm - io.grafeas.v1BSlsaProvenanceZeroTwoProtoPZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Upgrade.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Upgrade.php deleted file mode 100644 index ccca29a0b7e..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Upgrade.php +++ /dev/null @@ -1,60 +0,0 @@ -internalAddGeneratedFile( - ' -Ù -grafeas/v1/upgrade.proto -grafeas.v1grafeas/v1/package.proto"¯ - UpgradeNote -package ( $ -version ( 2.grafeas.v1.Version6 - distributions ( 2.grafeas.v1.UpgradeDistribution1 -windows_update ( 2.grafeas.v1.WindowsUpdate"] -UpgradeDistribution -cpe_uri (  -classification (  -severity (  -cve ( "ì - WindowsUpdate4 -identity ( 2".grafeas.v1.WindowsUpdate.Identity -title (  - description ( 6 - -categories ( 2".grafeas.v1.WindowsUpdate.Category -kb_article_ids (  - support_url ( < -last_published_timestamp ( 2.google.protobuf.Timestamp/ -Identity - update_id (  -revision (- -Category - category_id (  -name ( "» -UpgradeOccurrence -package ( + -parsed_version ( 2.grafeas.v1.Version5 - distribution ( 2.grafeas.v1.UpgradeDistribution1 -windows_update ( 2.grafeas.v1.WindowsUpdateBQ - io.grafeas.v1PZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vulnerability.php b/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vulnerability.php deleted file mode 100644 index 8886bd996b0..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/GPBMetadata/Grafeas/V1/Vulnerability.php +++ /dev/null @@ -1,106 +0,0 @@ -internalAddGeneratedFile( - ' -ø -grafeas/v1/vulnerability.proto -grafeas.v1google/protobuf/timestamp.protografeas/v1/common.protografeas/v1/cvss.protografeas/v1/package.protografeas/v1/severity.protografeas/v1/vex.proto"ì -VulnerabilityNote - -cvss_score (& -severity (2.grafeas.v1.Severity5 -details ( 2$.grafeas.v1.VulnerabilityNote.Detail# -cvss_v3 ( 2.grafeas.v1.CVSSv3D -windows_details ( 2+.grafeas.v1.VulnerabilityNote.WindowsDetail6 -source_update_time ( 2.google.protobuf.Timestamp- - cvss_version (2.grafeas.v1.CVSSVersion! -cvss_v2 ( 2.grafeas.v1.CVSS­ -Detail - severity_name (  - description (  - package_type (  -affected_cpe_uri (  -affected_package ( 3 -affected_version_start ( 2.grafeas.v1.Version1 -affected_version_end ( 2.grafeas.v1.Version - fixed_cpe_uri (  - fixed_package ( * - fixed_version - ( 2.grafeas.v1.Version - is_obsolete (6 -source_update_time ( 2.google.protobuf.Timestamp -source (  -vendor ( ¾ - WindowsDetail -cpe_uri (  -name (  - description ( M - -fixing_kbs ( 29.grafeas.v1.VulnerabilityNote.WindowsDetail.KnowledgeBase* - KnowledgeBase -name (  -url ( "ã -VulnerabilityOccurrence -type ( & -severity (2.grafeas.v1.Severity - -cvss_score ( -cvssv3 - ( 2.grafeas.v1.CVSSG - package_issue ( 20.grafeas.v1.VulnerabilityOccurrence.PackageIssue -short_description (  -long_description ( , - related_urls ( 2.grafeas.v1.RelatedUrl0 -effective_severity (2.grafeas.v1.Severity - fix_available (- - cvss_version (2.grafeas.v1.CVSSVersion! -cvss_v2 ( 2.grafeas.v1.CVSSI -vex_assessment ( 21.grafeas.v1.VulnerabilityOccurrence.VexAssessmentà - PackageIssue -affected_cpe_uri (  -affected_package ( - -affected_version ( 2.grafeas.v1.Version - fixed_cpe_uri (  - fixed_package ( * - fixed_version ( 2.grafeas.v1.Version - fix_available ( - package_type ( 5 -effective_severity (2.grafeas.v1.SeverityBàA/ - file_location - ( 2.grafeas.v1.FileLocationæ - VexAssessment -cve ( , - related_uris ( 2.grafeas.v1.RelatedUrl - note_name ( G -state (28.grafeas.v1.VulnerabilityAssessmentNote.Assessment.State -impacts ( T - remediations ( 2>.grafeas.v1.VulnerabilityAssessmentNote.Assessment.RemediationW - justification ( 2@.grafeas.v1.VulnerabilityAssessmentNote.Assessment.JustificationBQ - io.grafeas.v1PZ8google.golang.org/genproto/googleapis/grafeas/v1;grafeas¢GRAbproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext.php deleted file mode 100644 index 36f9800b4f7..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext.php +++ /dev/null @@ -1,101 +0,0 @@ -grafeas.v1.AliasContext - */ -class AliasContext extends \Google\Protobuf\Internal\Message -{ - /** - * The alias kind. - * - * Generated from protobuf field .grafeas.v1.AliasContext.Kind kind = 1; - */ - protected $kind = 0; - /** - * The alias name. - * - * Generated from protobuf field string name = 2; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $kind - * The alias kind. - * @type string $name - * The alias name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * The alias kind. - * - * Generated from protobuf field .grafeas.v1.AliasContext.Kind kind = 1; - * @return int - */ - public function getKind() - { - return $this->kind; - } - - /** - * The alias kind. - * - * Generated from protobuf field .grafeas.v1.AliasContext.Kind kind = 1; - * @param int $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\AliasContext\Kind::class); - $this->kind = $var; - - return $this; - } - - /** - * The alias name. - * - * Generated from protobuf field string name = 2; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The alias name. - * - * Generated from protobuf field string name = 2; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext/Kind.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext/Kind.php deleted file mode 100644 index f46137817ef..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext/Kind.php +++ /dev/null @@ -1,72 +0,0 @@ -grafeas.v1.AliasContext.Kind - */ -class Kind -{ - /** - * Unknown. - * - * Generated from protobuf enum KIND_UNSPECIFIED = 0; - */ - const KIND_UNSPECIFIED = 0; - /** - * Git tag. - * - * Generated from protobuf enum FIXED = 1; - */ - const FIXED = 1; - /** - * Git branch. - * - * Generated from protobuf enum MOVABLE = 2; - */ - const MOVABLE = 2; - /** - * Used to specify non-standard aliases. For example, if a Git repo has a - * ref named "refs/foo/bar". - * - * Generated from protobuf enum OTHER = 4; - */ - const OTHER = 4; - - private static $valueToName = [ - self::KIND_UNSPECIFIED => 'KIND_UNSPECIFIED', - self::FIXED => 'FIXED', - self::MOVABLE => 'MOVABLE', - self::OTHER => 'OTHER', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Kind::class, \Grafeas\V1\AliasContext_Kind::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext_Kind.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext_Kind.php deleted file mode 100644 index 823c2dd7488..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AliasContext_Kind.php +++ /dev/null @@ -1,16 +0,0 @@ -grafeas.v1.Architecture - */ -class Architecture -{ - /** - * Unknown architecture. - * - * Generated from protobuf enum ARCHITECTURE_UNSPECIFIED = 0; - */ - const ARCHITECTURE_UNSPECIFIED = 0; - /** - * X86 architecture. - * - * Generated from protobuf enum X86 = 1; - */ - const X86 = 1; - /** - * X64 architecture. - * - * Generated from protobuf enum X64 = 2; - */ - const X64 = 2; - - private static $valueToName = [ - self::ARCHITECTURE_UNSPECIFIED => 'ARCHITECTURE_UNSPECIFIED', - self::X86 => 'X86', - self::X64 => 'X64', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Artifact.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Artifact.php deleted file mode 100644 index ff6f4d0a38d..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Artifact.php +++ /dev/null @@ -1,159 +0,0 @@ -grafeas.v1.Artifact - */ -class Artifact extends \Google\Protobuf\Internal\Message -{ - /** - * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a - * container. - * - * Generated from protobuf field string checksum = 1; - */ - protected $checksum = ''; - /** - * Artifact ID, if any; for container images, this will be a URL by digest - * like `gcr.io/projectID/imagename@sha256:123456`. - * - * Generated from protobuf field string id = 2; - */ - protected $id = ''; - /** - * 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. - * - * Generated from protobuf field repeated string names = 3; - */ - private $names; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $checksum - * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a - * container. - * @type string $id - * Artifact ID, if any; for container images, this will be a URL by digest - * like `gcr.io/projectID/imagename@sha256:123456`. - * @type array|\Google\Protobuf\Internal\RepeatedField $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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a - * container. - * - * Generated from protobuf field string checksum = 1; - * @return string - */ - public function getChecksum() - { - return $this->checksum; - } - - /** - * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a - * container. - * - * Generated from protobuf field string checksum = 1; - * @param string $var - * @return $this - */ - public function setChecksum($var) - { - GPBUtil::checkString($var, True); - $this->checksum = $var; - - return $this; - } - - /** - * Artifact ID, if any; for container images, this will be a URL by digest - * like `gcr.io/projectID/imagename@sha256:123456`. - * - * Generated from protobuf field string id = 2; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Artifact ID, if any; for container images, this will be a URL by digest - * like `gcr.io/projectID/imagename@sha256:123456`. - * - * Generated from protobuf field string id = 2; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - 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. - * - * Generated from protobuf field repeated string names = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNames() - { - return $this->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. - * - * Generated from protobuf field repeated string names = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->names = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote.php deleted file mode 100644 index f6c61a7ac8f..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote.php +++ /dev/null @@ -1,84 +0,0 @@ -grafeas.v1.AttestationNote - */ -class AttestationNote extends \Google\Protobuf\Internal\Message -{ - /** - * Hint hints at the purpose of the attestation authority. - * - * Generated from protobuf field .grafeas.v1.AttestationNote.Hint hint = 1; - */ - protected $hint = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\AttestationNote\Hint $hint - * Hint hints at the purpose of the attestation authority. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Attestation::initOnce(); - parent::__construct($data); - } - - /** - * Hint hints at the purpose of the attestation authority. - * - * Generated from protobuf field .grafeas.v1.AttestationNote.Hint hint = 1; - * @return \Grafeas\V1\AttestationNote\Hint|null - */ - public function getHint() - { - return $this->hint; - } - - public function hasHint() - { - return isset($this->hint); - } - - public function clearHint() - { - unset($this->hint); - } - - /** - * Hint hints at the purpose of the attestation authority. - * - * Generated from protobuf field .grafeas.v1.AttestationNote.Hint hint = 1; - * @param \Grafeas\V1\AttestationNote\Hint $var - * @return $this - */ - public function setHint($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\AttestationNote\Hint::class); - $this->hint = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote/Hint.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote/Hint.php deleted file mode 100644 index a9646f50470..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote/Hint.php +++ /dev/null @@ -1,80 +0,0 @@ -grafeas.v1.AttestationNote.Hint - */ -class Hint extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The human readable name of this attestation authority, for - * example "qa". - * - * Generated from protobuf field string human_readable_name = 1; - */ - protected $human_readable_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $human_readable_name - * Required. The human readable name of this attestation authority, for - * example "qa". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Attestation::initOnce(); - parent::__construct($data); - } - - /** - * Required. The human readable name of this attestation authority, for - * example "qa". - * - * Generated from protobuf field string human_readable_name = 1; - * @return string - */ - public function getHumanReadableName() - { - return $this->human_readable_name; - } - - /** - * Required. The human readable name of this attestation authority, for - * example "qa". - * - * Generated from protobuf field string human_readable_name = 1; - * @param string $var - * @return $this - */ - public function setHumanReadableName($var) - { - GPBUtil::checkString($var, True); - $this->human_readable_name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Hint::class, \Grafeas\V1\AttestationNote_Hint::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote_Hint.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote_Hint.php deleted file mode 100644 index ce2b4bc895f..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/AttestationNote_Hint.php +++ /dev/null @@ -1,16 +0,0 @@ -grafeas.v1.AttestationOccurrence - */ -class AttestationOccurrence extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The serialized payload that is verified by one or more - * `signatures`. - * - * Generated from protobuf field bytes serialized_payload = 1; - */ - protected $serialized_payload = ''; - /** - * One or more signatures over `serialized_payload`. Verifier implementations - * should consider this attestation message verified if at least one - * `signature` verifies `serialized_payload`. See `Signature` in common.proto - * for more details on signature structure and verification. - * - * Generated from protobuf field repeated .grafeas.v1.Signature signatures = 2; - */ - private $signatures; - /** - * One or more JWTs encoding a self-contained attestation. - * Each JWT encodes the payload that it verifies within the JWT itself. - * Verifier implementation SHOULD ignore the `serialized_payload` field - * when verifying these JWTs. - * If only JWTs are present on this AttestationOccurrence, then the - * `serialized_payload` SHOULD be left empty. - * Each JWT SHOULD encode a claim specific to the `resource_uri` of this - * Occurrence, but this is not validated by Grafeas metadata API - * implementations. The JWT itself is opaque to Grafeas. - * - * Generated from protobuf field repeated .grafeas.v1.Jwt jwts = 3; - */ - private $jwts; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $serialized_payload - * Required. The serialized payload that is verified by one or more - * `signatures`. - * @type array<\Grafeas\V1\Signature>|\Google\Protobuf\Internal\RepeatedField $signatures - * One or more signatures over `serialized_payload`. Verifier implementations - * should consider this attestation message verified if at least one - * `signature` verifies `serialized_payload`. See `Signature` in common.proto - * for more details on signature structure and verification. - * @type array<\Grafeas\V1\Jwt>|\Google\Protobuf\Internal\RepeatedField $jwts - * One or more JWTs encoding a self-contained attestation. - * Each JWT encodes the payload that it verifies within the JWT itself. - * Verifier implementation SHOULD ignore the `serialized_payload` field - * when verifying these JWTs. - * If only JWTs are present on this AttestationOccurrence, then the - * `serialized_payload` SHOULD be left empty. - * Each JWT SHOULD encode a claim specific to the `resource_uri` of this - * Occurrence, but this is not validated by Grafeas metadata API - * implementations. The JWT itself is opaque to Grafeas. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Attestation::initOnce(); - parent::__construct($data); - } - - /** - * Required. The serialized payload that is verified by one or more - * `signatures`. - * - * Generated from protobuf field bytes serialized_payload = 1; - * @return string - */ - public function getSerializedPayload() - { - return $this->serialized_payload; - } - - /** - * Required. The serialized payload that is verified by one or more - * `signatures`. - * - * Generated from protobuf field bytes serialized_payload = 1; - * @param string $var - * @return $this - */ - public function setSerializedPayload($var) - { - GPBUtil::checkString($var, False); - $this->serialized_payload = $var; - - return $this; - } - - /** - * One or more signatures over `serialized_payload`. Verifier implementations - * should consider this attestation message verified if at least one - * `signature` verifies `serialized_payload`. See `Signature` in common.proto - * for more details on signature structure and verification. - * - * Generated from protobuf field repeated .grafeas.v1.Signature signatures = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSignatures() - { - return $this->signatures; - } - - /** - * One or more signatures over `serialized_payload`. Verifier implementations - * should consider this attestation message verified if at least one - * `signature` verifies `serialized_payload`. See `Signature` in common.proto - * for more details on signature structure and verification. - * - * Generated from protobuf field repeated .grafeas.v1.Signature signatures = 2; - * @param array<\Grafeas\V1\Signature>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSignatures($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Signature::class); - $this->signatures = $arr; - - return $this; - } - - /** - * One or more JWTs encoding a self-contained attestation. - * Each JWT encodes the payload that it verifies within the JWT itself. - * Verifier implementation SHOULD ignore the `serialized_payload` field - * when verifying these JWTs. - * If only JWTs are present on this AttestationOccurrence, then the - * `serialized_payload` SHOULD be left empty. - * Each JWT SHOULD encode a claim specific to the `resource_uri` of this - * Occurrence, but this is not validated by Grafeas metadata API - * implementations. The JWT itself is opaque to Grafeas. - * - * Generated from protobuf field repeated .grafeas.v1.Jwt jwts = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getJwts() - { - return $this->jwts; - } - - /** - * One or more JWTs encoding a self-contained attestation. - * Each JWT encodes the payload that it verifies within the JWT itself. - * Verifier implementation SHOULD ignore the `serialized_payload` field - * when verifying these JWTs. - * If only JWTs are present on this AttestationOccurrence, then the - * `serialized_payload` SHOULD be left empty. - * Each JWT SHOULD encode a claim specific to the `resource_uri` of this - * Occurrence, but this is not validated by Grafeas metadata API - * implementations. The JWT itself is opaque to Grafeas. - * - * Generated from protobuf field repeated .grafeas.v1.Jwt jwts = 3; - * @param array<\Grafeas\V1\Jwt>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setJwts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Jwt::class); - $this->jwts = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesRequest.php deleted file mode 100644 index 8a0a831cf9d..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesRequest.php +++ /dev/null @@ -1,105 +0,0 @@ -grafeas.v1.BatchCreateNotesRequest - */ -class BatchCreateNotesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the notes are to be created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The notes to create. Max allowed length is 1000. - * - * Generated from protobuf field map notes = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $notes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the notes are to be created. - * @type array|\Google\Protobuf\Internal\MapField $notes - * The notes to create. Max allowed length is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the notes are to be created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the notes are to be created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The notes to create. Max allowed length is 1000. - * - * Generated from protobuf field map notes = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getNotes() - { - return $this->notes; - } - - /** - * The notes to create. Max allowed length is 1000. - * - * Generated from protobuf field map notes = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setNotes($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Note::class); - $this->notes = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesResponse.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesResponse.php deleted file mode 100644 index da4f910330f..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateNotesResponse.php +++ /dev/null @@ -1,67 +0,0 @@ -grafeas.v1.BatchCreateNotesResponse - */ -class BatchCreateNotesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The notes that were created. - * - * Generated from protobuf field repeated .grafeas.v1.Note notes = 1; - */ - private $notes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Grafeas\V1\Note>|\Google\Protobuf\Internal\RepeatedField $notes - * The notes that were created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The notes that were created. - * - * Generated from protobuf field repeated .grafeas.v1.Note notes = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNotes() - { - return $this->notes; - } - - /** - * The notes that were created. - * - * Generated from protobuf field repeated .grafeas.v1.Note notes = 1; - * @param array<\Grafeas\V1\Note>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNotes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Note::class); - $this->notes = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesRequest.php deleted file mode 100644 index 4497973ea4c..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesRequest.php +++ /dev/null @@ -1,105 +0,0 @@ -grafeas.v1.BatchCreateOccurrencesRequest - */ -class BatchCreateOccurrencesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the occurrences are to be created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The occurrences to create. Max allowed length is 1000. - * - * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $occurrences; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the occurrences are to be created. - * @type array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $occurrences - * The occurrences to create. Max allowed length is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the occurrences are to be created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the occurrences are to be created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The occurrences to create. Max allowed length is 1000. - * - * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getOccurrences() - { - return $this->occurrences; - } - - /** - * The occurrences to create. Max allowed length is 1000. - * - * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setOccurrences($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Occurrence::class); - $this->occurrences = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesResponse.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesResponse.php deleted file mode 100644 index ff03d5abda4..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BatchCreateOccurrencesResponse.php +++ /dev/null @@ -1,67 +0,0 @@ -grafeas.v1.BatchCreateOccurrencesResponse - */ -class BatchCreateOccurrencesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The occurrences that were created. - * - * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; - */ - private $occurrences; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $occurrences - * The occurrences that were created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The occurrences that were created. - * - * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getOccurrences() - { - return $this->occurrences; - } - - /** - * The occurrences that were created. - * - * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; - * @param array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setOccurrences($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Occurrence::class); - $this->occurrences = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildNote.php deleted file mode 100644 index 033b8e22bb8..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildNote.php +++ /dev/null @@ -1,68 +0,0 @@ -grafeas.v1.BuildNote - */ -class BuildNote extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Immutable. Version of the builder which produced this build. - * - * Generated from protobuf field string builder_version = 1; - */ - protected $builder_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $builder_version - * Required. Immutable. Version of the builder which produced this build. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Build::initOnce(); - parent::__construct($data); - } - - /** - * Required. Immutable. Version of the builder which produced this build. - * - * Generated from protobuf field string builder_version = 1; - * @return string - */ - public function getBuilderVersion() - { - return $this->builder_version; - } - - /** - * Required. Immutable. Version of the builder which produced this build. - * - * Generated from protobuf field string builder_version = 1; - * @param string $var - * @return $this - */ - public function setBuilderVersion($var) - { - GPBUtil::checkString($var, True); - $this->builder_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildOccurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildOccurrence.php deleted file mode 100644 index 150d9122a82..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildOccurrence.php +++ /dev/null @@ -1,251 +0,0 @@ -grafeas.v1.BuildOccurrence - */ -class BuildOccurrence extends \Google\Protobuf\Internal\Message -{ - /** - * The actual provenance for the build. - * - * Generated from protobuf field .grafeas.v1.BuildProvenance provenance = 1; - */ - protected $provenance = null; - /** - * Serialized JSON representation of the provenance, used in generating the - * build signature in the corresponding build note. 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. - * - * Generated from protobuf field string provenance_bytes = 2; - */ - protected $provenance_bytes = ''; - /** - * Deprecated. See InTotoStatement for the replacement. - * In-toto Provenance representation as defined in spec. - * - * Generated from protobuf field .grafeas.v1.InTotoProvenance intoto_provenance = 3; - */ - protected $intoto_provenance = null; - /** - * In-toto Statement representation as defined in spec. - * The intoto_statement can contain any type of provenance. The serialized - * payload of the statement can be stored and signed in the Occurrence's - * envelope. - * - * Generated from protobuf field .grafeas.v1.InTotoStatement intoto_statement = 4; - */ - protected $intoto_statement = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\BuildProvenance $provenance - * The actual provenance for the build. - * @type string $provenance_bytes - * Serialized JSON representation of the provenance, used in generating the - * build signature in the corresponding build note. 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. - * @type \Grafeas\V1\InTotoProvenance $intoto_provenance - * Deprecated. See InTotoStatement for the replacement. - * In-toto Provenance representation as defined in spec. - * @type \Grafeas\V1\InTotoStatement $intoto_statement - * In-toto Statement representation as defined in spec. - * The intoto_statement can contain any type of provenance. The serialized - * payload of the statement can be stored and signed in the Occurrence's - * envelope. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Build::initOnce(); - parent::__construct($data); - } - - /** - * The actual provenance for the build. - * - * Generated from protobuf field .grafeas.v1.BuildProvenance provenance = 1; - * @return \Grafeas\V1\BuildProvenance|null - */ - public function getProvenance() - { - return $this->provenance; - } - - public function hasProvenance() - { - return isset($this->provenance); - } - - public function clearProvenance() - { - unset($this->provenance); - } - - /** - * The actual provenance for the build. - * - * Generated from protobuf field .grafeas.v1.BuildProvenance provenance = 1; - * @param \Grafeas\V1\BuildProvenance $var - * @return $this - */ - public function setProvenance($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\BuildProvenance::class); - $this->provenance = $var; - - return $this; - } - - /** - * Serialized JSON representation of the provenance, used in generating the - * build signature in the corresponding build note. 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. - * - * Generated from protobuf field string provenance_bytes = 2; - * @return string - */ - public function getProvenanceBytes() - { - return $this->provenance_bytes; - } - - /** - * Serialized JSON representation of the provenance, used in generating the - * build signature in the corresponding build note. 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. - * - * Generated from protobuf field string provenance_bytes = 2; - * @param string $var - * @return $this - */ - public function setProvenanceBytes($var) - { - GPBUtil::checkString($var, True); - $this->provenance_bytes = $var; - - return $this; - } - - /** - * Deprecated. See InTotoStatement for the replacement. - * In-toto Provenance representation as defined in spec. - * - * Generated from protobuf field .grafeas.v1.InTotoProvenance intoto_provenance = 3; - * @return \Grafeas\V1\InTotoProvenance|null - */ - public function getIntotoProvenance() - { - return $this->intoto_provenance; - } - - public function hasIntotoProvenance() - { - return isset($this->intoto_provenance); - } - - public function clearIntotoProvenance() - { - unset($this->intoto_provenance); - } - - /** - * Deprecated. See InTotoStatement for the replacement. - * In-toto Provenance representation as defined in spec. - * - * Generated from protobuf field .grafeas.v1.InTotoProvenance intoto_provenance = 3; - * @param \Grafeas\V1\InTotoProvenance $var - * @return $this - */ - public function setIntotoProvenance($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\InTotoProvenance::class); - $this->intoto_provenance = $var; - - return $this; - } - - /** - * In-toto Statement representation as defined in spec. - * The intoto_statement can contain any type of provenance. The serialized - * payload of the statement can be stored and signed in the Occurrence's - * envelope. - * - * Generated from protobuf field .grafeas.v1.InTotoStatement intoto_statement = 4; - * @return \Grafeas\V1\InTotoStatement|null - */ - public function getIntotoStatement() - { - return $this->intoto_statement; - } - - public function hasIntotoStatement() - { - return isset($this->intoto_statement); - } - - public function clearIntotoStatement() - { - unset($this->intoto_statement); - } - - /** - * In-toto Statement representation as defined in spec. - * The intoto_statement can contain any type of provenance. The serialized - * payload of the statement can be stored and signed in the Occurrence's - * envelope. - * - * Generated from protobuf field .grafeas.v1.InTotoStatement intoto_statement = 4; - * @param \Grafeas\V1\InTotoStatement $var - * @return $this - */ - public function setIntotoStatement($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\InTotoStatement::class); - $this->intoto_statement = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildProvenance.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildProvenance.php deleted file mode 100644 index 8e8c3289d1e..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuildProvenance.php +++ /dev/null @@ -1,528 +0,0 @@ -grafeas.v1.BuildProvenance - */ -class BuildProvenance extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Unique identifier of the build. - * - * Generated from protobuf field string id = 1; - */ - protected $id = ''; - /** - * ID of the project. - * - * Generated from protobuf field string project_id = 2; - */ - protected $project_id = ''; - /** - * Commands requested by the build. - * - * Generated from protobuf field repeated .grafeas.v1.Command commands = 3; - */ - private $commands; - /** - * Output of the build. - * - * Generated from protobuf field repeated .grafeas.v1.Artifact built_artifacts = 4; - */ - private $built_artifacts; - /** - * Time at which the build was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; - */ - protected $create_time = null; - /** - * Time at which execution of the build was started. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 6; - */ - protected $start_time = null; - /** - * Time at which execution of the build was finished. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 7; - */ - protected $end_time = null; - /** - * 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. - * - * Generated from protobuf field string creator = 8; - */ - protected $creator = ''; - /** - * URI where any logs for this provenance were written. - * - * Generated from protobuf field string logs_uri = 9; - */ - protected $logs_uri = ''; - /** - * Details of the Source input to the build. - * - * Generated from protobuf field .grafeas.v1.Source source_provenance = 10; - */ - protected $source_provenance = null; - /** - * Trigger identifier if the build was triggered automatically; empty if not. - * - * Generated from protobuf field string trigger_id = 11; - */ - protected $trigger_id = ''; - /** - * Special options applied to this build. This is a catch-all field where - * build providers can enter any desired additional details. - * - * Generated from protobuf field map build_options = 12; - */ - private $build_options; - /** - * Version string of the builder at the time this build was executed. - * - * Generated from protobuf field string builder_version = 13; - */ - protected $builder_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $id - * Required. Unique identifier of the build. - * @type string $project_id - * ID of the project. - * @type array<\Grafeas\V1\Command>|\Google\Protobuf\Internal\RepeatedField $commands - * Commands requested by the build. - * @type array<\Grafeas\V1\Artifact>|\Google\Protobuf\Internal\RepeatedField $built_artifacts - * Output of the build. - * @type \Google\Protobuf\Timestamp $create_time - * Time at which the build was created. - * @type \Google\Protobuf\Timestamp $start_time - * Time at which execution of the build was started. - * @type \Google\Protobuf\Timestamp $end_time - * Time at which execution of the build was finished. - * @type string $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. - * @type string $logs_uri - * URI where any logs for this provenance were written. - * @type \Grafeas\V1\Source $source_provenance - * Details of the Source input to the build. - * @type string $trigger_id - * Trigger identifier if the build was triggered automatically; empty if not. - * @type array|\Google\Protobuf\Internal\MapField $build_options - * Special options applied to this build. This is a catch-all field where - * build providers can enter any desired additional details. - * @type string $builder_version - * Version string of the builder at the time this build was executed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * Required. Unique identifier of the build. - * - * Generated from protobuf field string id = 1; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Required. Unique identifier of the build. - * - * Generated from protobuf field string id = 1; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * ID of the project. - * - * Generated from protobuf field string project_id = 2; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * ID of the project. - * - * Generated from protobuf field string project_id = 2; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Commands requested by the build. - * - * Generated from protobuf field repeated .grafeas.v1.Command commands = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCommands() - { - return $this->commands; - } - - /** - * Commands requested by the build. - * - * Generated from protobuf field repeated .grafeas.v1.Command commands = 3; - * @param array<\Grafeas\V1\Command>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCommands($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Command::class); - $this->commands = $arr; - - return $this; - } - - /** - * Output of the build. - * - * Generated from protobuf field repeated .grafeas.v1.Artifact built_artifacts = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBuiltArtifacts() - { - return $this->built_artifacts; - } - - /** - * Output of the build. - * - * Generated from protobuf field repeated .grafeas.v1.Artifact built_artifacts = 4; - * @param array<\Grafeas\V1\Artifact>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBuiltArtifacts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Artifact::class); - $this->built_artifacts = $arr; - - return $this; - } - - /** - * Time at which the build was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Time at which the build was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Time at which execution of the build was started. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 6; - * @return \Google\Protobuf\Timestamp|null - */ - public function getStartTime() - { - return $this->start_time; - } - - public function hasStartTime() - { - return isset($this->start_time); - } - - public function clearStartTime() - { - unset($this->start_time); - } - - /** - * Time at which execution of the build was started. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 6; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - - /** - * Time at which execution of the build was finished. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 7; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Time at which execution of the build was finished. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 7; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - 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. - * - * Generated from protobuf field string creator = 8; - * @return string - */ - public function getCreator() - { - return $this->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. - * - * Generated from protobuf field string creator = 8; - * @param string $var - * @return $this - */ - public function setCreator($var) - { - GPBUtil::checkString($var, True); - $this->creator = $var; - - return $this; - } - - /** - * URI where any logs for this provenance were written. - * - * Generated from protobuf field string logs_uri = 9; - * @return string - */ - public function getLogsUri() - { - return $this->logs_uri; - } - - /** - * URI where any logs for this provenance were written. - * - * Generated from protobuf field string logs_uri = 9; - * @param string $var - * @return $this - */ - public function setLogsUri($var) - { - GPBUtil::checkString($var, True); - $this->logs_uri = $var; - - return $this; - } - - /** - * Details of the Source input to the build. - * - * Generated from protobuf field .grafeas.v1.Source source_provenance = 10; - * @return \Grafeas\V1\Source|null - */ - public function getSourceProvenance() - { - return $this->source_provenance; - } - - public function hasSourceProvenance() - { - return isset($this->source_provenance); - } - - public function clearSourceProvenance() - { - unset($this->source_provenance); - } - - /** - * Details of the Source input to the build. - * - * Generated from protobuf field .grafeas.v1.Source source_provenance = 10; - * @param \Grafeas\V1\Source $var - * @return $this - */ - public function setSourceProvenance($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Source::class); - $this->source_provenance = $var; - - return $this; - } - - /** - * Trigger identifier if the build was triggered automatically; empty if not. - * - * Generated from protobuf field string trigger_id = 11; - * @return string - */ - public function getTriggerId() - { - return $this->trigger_id; - } - - /** - * Trigger identifier if the build was triggered automatically; empty if not. - * - * Generated from protobuf field string trigger_id = 11; - * @param string $var - * @return $this - */ - public function setTriggerId($var) - { - GPBUtil::checkString($var, True); - $this->trigger_id = $var; - - return $this; - } - - /** - * Special options applied to this build. This is a catch-all field where - * build providers can enter any desired additional details. - * - * Generated from protobuf field map build_options = 12; - * @return \Google\Protobuf\Internal\MapField - */ - public function getBuildOptions() - { - return $this->build_options; - } - - /** - * Special options applied to this build. This is a catch-all field where - * build providers can enter any desired additional details. - * - * Generated from protobuf field map build_options = 12; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setBuildOptions($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->build_options = $arr; - - return $this; - } - - /** - * Version string of the builder at the time this build was executed. - * - * Generated from protobuf field string builder_version = 13; - * @return string - */ - public function getBuilderVersion() - { - return $this->builder_version; - } - - /** - * Version string of the builder at the time this build was executed. - * - * Generated from protobuf field string builder_version = 13; - * @param string $var - * @return $this - */ - public function setBuilderVersion($var) - { - GPBUtil::checkString($var, True); - $this->builder_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuilderConfig.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuilderConfig.php deleted file mode 100644 index 97732fb870d..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/BuilderConfig.php +++ /dev/null @@ -1,58 +0,0 @@ -grafeas.v1.BuilderConfig - */ -class BuilderConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field string id = 1; - */ - protected $id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $id - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\IntotoProvenance::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field string id = 1; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Generated from protobuf field string id = 1; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS.php deleted file mode 100644 index eed433379f3..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS.php +++ /dev/null @@ -1,382 +0,0 @@ -grafeas.v1.CVSS - */ -class CVSS extends \Google\Protobuf\Internal\Message -{ - /** - * The base score is a function of the base metric scores. - * - * Generated from protobuf field float base_score = 1; - */ - protected $base_score = 0.0; - /** - * Generated from protobuf field float exploitability_score = 2; - */ - protected $exploitability_score = 0.0; - /** - * Generated from protobuf field float impact_score = 3; - */ - protected $impact_score = 0.0; - /** - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * - * Generated from protobuf field .grafeas.v1.CVSS.AttackVector attack_vector = 4; - */ - protected $attack_vector = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSS.AttackComplexity attack_complexity = 5; - */ - protected $attack_complexity = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSS.Authentication authentication = 6; - */ - protected $authentication = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSS.PrivilegesRequired privileges_required = 7; - */ - protected $privileges_required = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSS.UserInteraction user_interaction = 8; - */ - protected $user_interaction = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSS.Scope scope = 9; - */ - protected $scope = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSS.Impact confidentiality_impact = 10; - */ - protected $confidentiality_impact = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSS.Impact integrity_impact = 11; - */ - protected $integrity_impact = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSS.Impact availability_impact = 12; - */ - protected $availability_impact = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $base_score - * The base score is a function of the base metric scores. - * @type float $exploitability_score - * @type float $impact_score - * @type int $attack_vector - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * @type int $attack_complexity - * @type int $authentication - * @type int $privileges_required - * @type int $user_interaction - * @type int $scope - * @type int $confidentiality_impact - * @type int $integrity_impact - * @type int $availability_impact - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Cvss::initOnce(); - parent::__construct($data); - } - - /** - * The base score is a function of the base metric scores. - * - * Generated from protobuf field float base_score = 1; - * @return float - */ - public function getBaseScore() - { - return $this->base_score; - } - - /** - * The base score is a function of the base metric scores. - * - * Generated from protobuf field float base_score = 1; - * @param float $var - * @return $this - */ - public function setBaseScore($var) - { - GPBUtil::checkFloat($var); - $this->base_score = $var; - - return $this; - } - - /** - * Generated from protobuf field float exploitability_score = 2; - * @return float - */ - public function getExploitabilityScore() - { - return $this->exploitability_score; - } - - /** - * Generated from protobuf field float exploitability_score = 2; - * @param float $var - * @return $this - */ - public function setExploitabilityScore($var) - { - GPBUtil::checkFloat($var); - $this->exploitability_score = $var; - - return $this; - } - - /** - * Generated from protobuf field float impact_score = 3; - * @return float - */ - public function getImpactScore() - { - return $this->impact_score; - } - - /** - * Generated from protobuf field float impact_score = 3; - * @param float $var - * @return $this - */ - public function setImpactScore($var) - { - GPBUtil::checkFloat($var); - $this->impact_score = $var; - - return $this; - } - - /** - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * - * Generated from protobuf field .grafeas.v1.CVSS.AttackVector attack_vector = 4; - * @return int - */ - public function getAttackVector() - { - return $this->attack_vector; - } - - /** - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * - * Generated from protobuf field .grafeas.v1.CVSS.AttackVector attack_vector = 4; - * @param int $var - * @return $this - */ - public function setAttackVector($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\AttackVector::class); - $this->attack_vector = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.AttackComplexity attack_complexity = 5; - * @return int - */ - public function getAttackComplexity() - { - return $this->attack_complexity; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.AttackComplexity attack_complexity = 5; - * @param int $var - * @return $this - */ - public function setAttackComplexity($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\AttackComplexity::class); - $this->attack_complexity = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.Authentication authentication = 6; - * @return int - */ - public function getAuthentication() - { - return $this->authentication; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.Authentication authentication = 6; - * @param int $var - * @return $this - */ - public function setAuthentication($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\Authentication::class); - $this->authentication = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.PrivilegesRequired privileges_required = 7; - * @return int - */ - public function getPrivilegesRequired() - { - return $this->privileges_required; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.PrivilegesRequired privileges_required = 7; - * @param int $var - * @return $this - */ - public function setPrivilegesRequired($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\PrivilegesRequired::class); - $this->privileges_required = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.UserInteraction user_interaction = 8; - * @return int - */ - public function getUserInteraction() - { - return $this->user_interaction; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.UserInteraction user_interaction = 8; - * @param int $var - * @return $this - */ - public function setUserInteraction($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\UserInteraction::class); - $this->user_interaction = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.Scope scope = 9; - * @return int - */ - public function getScope() - { - return $this->scope; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.Scope scope = 9; - * @param int $var - * @return $this - */ - public function setScope($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\Scope::class); - $this->scope = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.Impact confidentiality_impact = 10; - * @return int - */ - public function getConfidentialityImpact() - { - return $this->confidentiality_impact; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.Impact confidentiality_impact = 10; - * @param int $var - * @return $this - */ - public function setConfidentialityImpact($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\Impact::class); - $this->confidentiality_impact = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.Impact integrity_impact = 11; - * @return int - */ - public function getIntegrityImpact() - { - return $this->integrity_impact; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.Impact integrity_impact = 11; - * @param int $var - * @return $this - */ - public function setIntegrityImpact($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\Impact::class); - $this->integrity_impact = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.Impact availability_impact = 12; - * @return int - */ - public function getAvailabilityImpact() - { - return $this->availability_impact; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSS.Impact availability_impact = 12; - * @param int $var - * @return $this - */ - public function setAvailabilityImpact($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSS\Impact::class); - $this->availability_impact = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackComplexity.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackComplexity.php deleted file mode 100644 index 5921b034341..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackComplexity.php +++ /dev/null @@ -1,56 +0,0 @@ -grafeas.v1.CVSS.AttackComplexity - */ -class AttackComplexity -{ - /** - * Generated from protobuf enum ATTACK_COMPLEXITY_UNSPECIFIED = 0; - */ - const ATTACK_COMPLEXITY_UNSPECIFIED = 0; - /** - * Generated from protobuf enum ATTACK_COMPLEXITY_LOW = 1; - */ - const ATTACK_COMPLEXITY_LOW = 1; - /** - * Generated from protobuf enum ATTACK_COMPLEXITY_HIGH = 2; - */ - const ATTACK_COMPLEXITY_HIGH = 2; - - private static $valueToName = [ - self::ATTACK_COMPLEXITY_UNSPECIFIED => 'ATTACK_COMPLEXITY_UNSPECIFIED', - self::ATTACK_COMPLEXITY_LOW => 'ATTACK_COMPLEXITY_LOW', - self::ATTACK_COMPLEXITY_HIGH => 'ATTACK_COMPLEXITY_HIGH', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AttackComplexity::class, \Grafeas\V1\CVSS_AttackComplexity::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackVector.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackVector.php deleted file mode 100644 index e012b40cdfd..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/AttackVector.php +++ /dev/null @@ -1,66 +0,0 @@ -grafeas.v1.CVSS.AttackVector - */ -class AttackVector -{ - /** - * Generated from protobuf enum ATTACK_VECTOR_UNSPECIFIED = 0; - */ - const ATTACK_VECTOR_UNSPECIFIED = 0; - /** - * Generated from protobuf enum ATTACK_VECTOR_NETWORK = 1; - */ - const ATTACK_VECTOR_NETWORK = 1; - /** - * Generated from protobuf enum ATTACK_VECTOR_ADJACENT = 2; - */ - const ATTACK_VECTOR_ADJACENT = 2; - /** - * Generated from protobuf enum ATTACK_VECTOR_LOCAL = 3; - */ - const ATTACK_VECTOR_LOCAL = 3; - /** - * Generated from protobuf enum ATTACK_VECTOR_PHYSICAL = 4; - */ - const ATTACK_VECTOR_PHYSICAL = 4; - - private static $valueToName = [ - self::ATTACK_VECTOR_UNSPECIFIED => 'ATTACK_VECTOR_UNSPECIFIED', - self::ATTACK_VECTOR_NETWORK => 'ATTACK_VECTOR_NETWORK', - self::ATTACK_VECTOR_ADJACENT => 'ATTACK_VECTOR_ADJACENT', - self::ATTACK_VECTOR_LOCAL => 'ATTACK_VECTOR_LOCAL', - self::ATTACK_VECTOR_PHYSICAL => 'ATTACK_VECTOR_PHYSICAL', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AttackVector::class, \Grafeas\V1\CVSS_AttackVector::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Authentication.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Authentication.php deleted file mode 100644 index 3e49c8c45e1..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Authentication.php +++ /dev/null @@ -1,61 +0,0 @@ -grafeas.v1.CVSS.Authentication - */ -class Authentication -{ - /** - * Generated from protobuf enum AUTHENTICATION_UNSPECIFIED = 0; - */ - const AUTHENTICATION_UNSPECIFIED = 0; - /** - * Generated from protobuf enum AUTHENTICATION_MULTIPLE = 1; - */ - const AUTHENTICATION_MULTIPLE = 1; - /** - * Generated from protobuf enum AUTHENTICATION_SINGLE = 2; - */ - const AUTHENTICATION_SINGLE = 2; - /** - * Generated from protobuf enum AUTHENTICATION_NONE = 3; - */ - const AUTHENTICATION_NONE = 3; - - private static $valueToName = [ - self::AUTHENTICATION_UNSPECIFIED => 'AUTHENTICATION_UNSPECIFIED', - self::AUTHENTICATION_MULTIPLE => 'AUTHENTICATION_MULTIPLE', - self::AUTHENTICATION_SINGLE => 'AUTHENTICATION_SINGLE', - self::AUTHENTICATION_NONE => 'AUTHENTICATION_NONE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Authentication::class, \Grafeas\V1\CVSS_Authentication::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Impact.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Impact.php deleted file mode 100644 index ea32fc11f66..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Impact.php +++ /dev/null @@ -1,61 +0,0 @@ -grafeas.v1.CVSS.Impact - */ -class Impact -{ - /** - * Generated from protobuf enum IMPACT_UNSPECIFIED = 0; - */ - const IMPACT_UNSPECIFIED = 0; - /** - * Generated from protobuf enum IMPACT_HIGH = 1; - */ - const IMPACT_HIGH = 1; - /** - * Generated from protobuf enum IMPACT_LOW = 2; - */ - const IMPACT_LOW = 2; - /** - * Generated from protobuf enum IMPACT_NONE = 3; - */ - const IMPACT_NONE = 3; - - private static $valueToName = [ - self::IMPACT_UNSPECIFIED => 'IMPACT_UNSPECIFIED', - self::IMPACT_HIGH => 'IMPACT_HIGH', - self::IMPACT_LOW => 'IMPACT_LOW', - self::IMPACT_NONE => 'IMPACT_NONE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Impact::class, \Grafeas\V1\CVSS_Impact::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/PrivilegesRequired.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/PrivilegesRequired.php deleted file mode 100644 index b3f593d0689..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/PrivilegesRequired.php +++ /dev/null @@ -1,61 +0,0 @@ -grafeas.v1.CVSS.PrivilegesRequired - */ -class PrivilegesRequired -{ - /** - * Generated from protobuf enum PRIVILEGES_REQUIRED_UNSPECIFIED = 0; - */ - const PRIVILEGES_REQUIRED_UNSPECIFIED = 0; - /** - * Generated from protobuf enum PRIVILEGES_REQUIRED_NONE = 1; - */ - const PRIVILEGES_REQUIRED_NONE = 1; - /** - * Generated from protobuf enum PRIVILEGES_REQUIRED_LOW = 2; - */ - const PRIVILEGES_REQUIRED_LOW = 2; - /** - * Generated from protobuf enum PRIVILEGES_REQUIRED_HIGH = 3; - */ - const PRIVILEGES_REQUIRED_HIGH = 3; - - private static $valueToName = [ - self::PRIVILEGES_REQUIRED_UNSPECIFIED => 'PRIVILEGES_REQUIRED_UNSPECIFIED', - self::PRIVILEGES_REQUIRED_NONE => 'PRIVILEGES_REQUIRED_NONE', - self::PRIVILEGES_REQUIRED_LOW => 'PRIVILEGES_REQUIRED_LOW', - self::PRIVILEGES_REQUIRED_HIGH => 'PRIVILEGES_REQUIRED_HIGH', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PrivilegesRequired::class, \Grafeas\V1\CVSS_PrivilegesRequired::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Scope.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Scope.php deleted file mode 100644 index 44ac100792e..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/Scope.php +++ /dev/null @@ -1,56 +0,0 @@ -grafeas.v1.CVSS.Scope - */ -class Scope -{ - /** - * Generated from protobuf enum SCOPE_UNSPECIFIED = 0; - */ - const SCOPE_UNSPECIFIED = 0; - /** - * Generated from protobuf enum SCOPE_UNCHANGED = 1; - */ - const SCOPE_UNCHANGED = 1; - /** - * Generated from protobuf enum SCOPE_CHANGED = 2; - */ - const SCOPE_CHANGED = 2; - - private static $valueToName = [ - self::SCOPE_UNSPECIFIED => 'SCOPE_UNSPECIFIED', - self::SCOPE_UNCHANGED => 'SCOPE_UNCHANGED', - self::SCOPE_CHANGED => 'SCOPE_CHANGED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Scope::class, \Grafeas\V1\CVSS_Scope::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/UserInteraction.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/UserInteraction.php deleted file mode 100644 index 2e0e911d1c8..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS/UserInteraction.php +++ /dev/null @@ -1,56 +0,0 @@ -grafeas.v1.CVSS.UserInteraction - */ -class UserInteraction -{ - /** - * Generated from protobuf enum USER_INTERACTION_UNSPECIFIED = 0; - */ - const USER_INTERACTION_UNSPECIFIED = 0; - /** - * Generated from protobuf enum USER_INTERACTION_NONE = 1; - */ - const USER_INTERACTION_NONE = 1; - /** - * Generated from protobuf enum USER_INTERACTION_REQUIRED = 2; - */ - const USER_INTERACTION_REQUIRED = 2; - - private static $valueToName = [ - self::USER_INTERACTION_UNSPECIFIED => 'USER_INTERACTION_UNSPECIFIED', - self::USER_INTERACTION_NONE => 'USER_INTERACTION_NONE', - self::USER_INTERACTION_REQUIRED => 'USER_INTERACTION_REQUIRED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(UserInteraction::class, \Grafeas\V1\CVSS_UserInteraction::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSVersion.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSVersion.php deleted file mode 100644 index 8c25036f4ff..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSVersion.php +++ /dev/null @@ -1,55 +0,0 @@ -grafeas.v1.CVSSVersion - */ -class CVSSVersion -{ - /** - * Generated from protobuf enum CVSS_VERSION_UNSPECIFIED = 0; - */ - const CVSS_VERSION_UNSPECIFIED = 0; - /** - * Generated from protobuf enum CVSS_VERSION_2 = 1; - */ - const CVSS_VERSION_2 = 1; - /** - * Generated from protobuf enum CVSS_VERSION_3 = 2; - */ - const CVSS_VERSION_3 = 2; - - private static $valueToName = [ - self::CVSS_VERSION_UNSPECIFIED => 'CVSS_VERSION_UNSPECIFIED', - self::CVSS_VERSION_2 => 'CVSS_VERSION_2', - self::CVSS_VERSION_3 => 'CVSS_VERSION_3', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_AttackComplexity.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_AttackComplexity.php deleted file mode 100644 index f53fa0e2874..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSS_AttackComplexity.php +++ /dev/null @@ -1,16 +0,0 @@ -grafeas.v1.CVSSv3 - */ -class CVSSv3 extends \Google\Protobuf\Internal\Message -{ - /** - * The base score is a function of the base metric scores. - * - * Generated from protobuf field float base_score = 1; - */ - protected $base_score = 0.0; - /** - * Generated from protobuf field float exploitability_score = 2; - */ - protected $exploitability_score = 0.0; - /** - * Generated from protobuf field float impact_score = 3; - */ - protected $impact_score = 0.0; - /** - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * - * Generated from protobuf field .grafeas.v1.CVSSv3.AttackVector attack_vector = 5; - */ - protected $attack_vector = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.AttackComplexity attack_complexity = 6; - */ - protected $attack_complexity = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.PrivilegesRequired privileges_required = 7; - */ - protected $privileges_required = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.UserInteraction user_interaction = 8; - */ - protected $user_interaction = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.Scope scope = 9; - */ - protected $scope = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.Impact confidentiality_impact = 10; - */ - protected $confidentiality_impact = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.Impact integrity_impact = 11; - */ - protected $integrity_impact = 0; - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.Impact availability_impact = 12; - */ - protected $availability_impact = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $base_score - * The base score is a function of the base metric scores. - * @type float $exploitability_score - * @type float $impact_score - * @type int $attack_vector - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * @type int $attack_complexity - * @type int $privileges_required - * @type int $user_interaction - * @type int $scope - * @type int $confidentiality_impact - * @type int $integrity_impact - * @type int $availability_impact - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Cvss::initOnce(); - parent::__construct($data); - } - - /** - * The base score is a function of the base metric scores. - * - * Generated from protobuf field float base_score = 1; - * @return float - */ - public function getBaseScore() - { - return $this->base_score; - } - - /** - * The base score is a function of the base metric scores. - * - * Generated from protobuf field float base_score = 1; - * @param float $var - * @return $this - */ - public function setBaseScore($var) - { - GPBUtil::checkFloat($var); - $this->base_score = $var; - - return $this; - } - - /** - * Generated from protobuf field float exploitability_score = 2; - * @return float - */ - public function getExploitabilityScore() - { - return $this->exploitability_score; - } - - /** - * Generated from protobuf field float exploitability_score = 2; - * @param float $var - * @return $this - */ - public function setExploitabilityScore($var) - { - GPBUtil::checkFloat($var); - $this->exploitability_score = $var; - - return $this; - } - - /** - * Generated from protobuf field float impact_score = 3; - * @return float - */ - public function getImpactScore() - { - return $this->impact_score; - } - - /** - * Generated from protobuf field float impact_score = 3; - * @param float $var - * @return $this - */ - public function setImpactScore($var) - { - GPBUtil::checkFloat($var); - $this->impact_score = $var; - - return $this; - } - - /** - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * - * Generated from protobuf field .grafeas.v1.CVSSv3.AttackVector attack_vector = 5; - * @return int - */ - public function getAttackVector() - { - return $this->attack_vector; - } - - /** - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * - * Generated from protobuf field .grafeas.v1.CVSSv3.AttackVector attack_vector = 5; - * @param int $var - * @return $this - */ - public function setAttackVector($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\AttackVector::class); - $this->attack_vector = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.AttackComplexity attack_complexity = 6; - * @return int - */ - public function getAttackComplexity() - { - return $this->attack_complexity; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.AttackComplexity attack_complexity = 6; - * @param int $var - * @return $this - */ - public function setAttackComplexity($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\AttackComplexity::class); - $this->attack_complexity = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.PrivilegesRequired privileges_required = 7; - * @return int - */ - public function getPrivilegesRequired() - { - return $this->privileges_required; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.PrivilegesRequired privileges_required = 7; - * @param int $var - * @return $this - */ - public function setPrivilegesRequired($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\PrivilegesRequired::class); - $this->privileges_required = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.UserInteraction user_interaction = 8; - * @return int - */ - public function getUserInteraction() - { - return $this->user_interaction; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.UserInteraction user_interaction = 8; - * @param int $var - * @return $this - */ - public function setUserInteraction($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\UserInteraction::class); - $this->user_interaction = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.Scope scope = 9; - * @return int - */ - public function getScope() - { - return $this->scope; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.Scope scope = 9; - * @param int $var - * @return $this - */ - public function setScope($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\Scope::class); - $this->scope = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.Impact confidentiality_impact = 10; - * @return int - */ - public function getConfidentialityImpact() - { - return $this->confidentiality_impact; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.Impact confidentiality_impact = 10; - * @param int $var - * @return $this - */ - public function setConfidentialityImpact($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\Impact::class); - $this->confidentiality_impact = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.Impact integrity_impact = 11; - * @return int - */ - public function getIntegrityImpact() - { - return $this->integrity_impact; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.Impact integrity_impact = 11; - * @param int $var - * @return $this - */ - public function setIntegrityImpact($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\Impact::class); - $this->integrity_impact = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.Impact availability_impact = 12; - * @return int - */ - public function getAvailabilityImpact() - { - return $this->availability_impact; - } - - /** - * Generated from protobuf field .grafeas.v1.CVSSv3.Impact availability_impact = 12; - * @param int $var - * @return $this - */ - public function setAvailabilityImpact($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSSv3\Impact::class); - $this->availability_impact = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackComplexity.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackComplexity.php deleted file mode 100644 index 6086d84dc98..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackComplexity.php +++ /dev/null @@ -1,56 +0,0 @@ -grafeas.v1.CVSSv3.AttackComplexity - */ -class AttackComplexity -{ - /** - * Generated from protobuf enum ATTACK_COMPLEXITY_UNSPECIFIED = 0; - */ - const ATTACK_COMPLEXITY_UNSPECIFIED = 0; - /** - * Generated from protobuf enum ATTACK_COMPLEXITY_LOW = 1; - */ - const ATTACK_COMPLEXITY_LOW = 1; - /** - * Generated from protobuf enum ATTACK_COMPLEXITY_HIGH = 2; - */ - const ATTACK_COMPLEXITY_HIGH = 2; - - private static $valueToName = [ - self::ATTACK_COMPLEXITY_UNSPECIFIED => 'ATTACK_COMPLEXITY_UNSPECIFIED', - self::ATTACK_COMPLEXITY_LOW => 'ATTACK_COMPLEXITY_LOW', - self::ATTACK_COMPLEXITY_HIGH => 'ATTACK_COMPLEXITY_HIGH', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AttackComplexity::class, \Grafeas\V1\CVSSv3_AttackComplexity::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackVector.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackVector.php deleted file mode 100644 index 9f089274962..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/AttackVector.php +++ /dev/null @@ -1,66 +0,0 @@ -grafeas.v1.CVSSv3.AttackVector - */ -class AttackVector -{ - /** - * Generated from protobuf enum ATTACK_VECTOR_UNSPECIFIED = 0; - */ - const ATTACK_VECTOR_UNSPECIFIED = 0; - /** - * Generated from protobuf enum ATTACK_VECTOR_NETWORK = 1; - */ - const ATTACK_VECTOR_NETWORK = 1; - /** - * Generated from protobuf enum ATTACK_VECTOR_ADJACENT = 2; - */ - const ATTACK_VECTOR_ADJACENT = 2; - /** - * Generated from protobuf enum ATTACK_VECTOR_LOCAL = 3; - */ - const ATTACK_VECTOR_LOCAL = 3; - /** - * Generated from protobuf enum ATTACK_VECTOR_PHYSICAL = 4; - */ - const ATTACK_VECTOR_PHYSICAL = 4; - - private static $valueToName = [ - self::ATTACK_VECTOR_UNSPECIFIED => 'ATTACK_VECTOR_UNSPECIFIED', - self::ATTACK_VECTOR_NETWORK => 'ATTACK_VECTOR_NETWORK', - self::ATTACK_VECTOR_ADJACENT => 'ATTACK_VECTOR_ADJACENT', - self::ATTACK_VECTOR_LOCAL => 'ATTACK_VECTOR_LOCAL', - self::ATTACK_VECTOR_PHYSICAL => 'ATTACK_VECTOR_PHYSICAL', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AttackVector::class, \Grafeas\V1\CVSSv3_AttackVector::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Impact.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Impact.php deleted file mode 100644 index d933d36fe7f..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Impact.php +++ /dev/null @@ -1,61 +0,0 @@ -grafeas.v1.CVSSv3.Impact - */ -class Impact -{ - /** - * Generated from protobuf enum IMPACT_UNSPECIFIED = 0; - */ - const IMPACT_UNSPECIFIED = 0; - /** - * Generated from protobuf enum IMPACT_HIGH = 1; - */ - const IMPACT_HIGH = 1; - /** - * Generated from protobuf enum IMPACT_LOW = 2; - */ - const IMPACT_LOW = 2; - /** - * Generated from protobuf enum IMPACT_NONE = 3; - */ - const IMPACT_NONE = 3; - - private static $valueToName = [ - self::IMPACT_UNSPECIFIED => 'IMPACT_UNSPECIFIED', - self::IMPACT_HIGH => 'IMPACT_HIGH', - self::IMPACT_LOW => 'IMPACT_LOW', - self::IMPACT_NONE => 'IMPACT_NONE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Impact::class, \Grafeas\V1\CVSSv3_Impact::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/PrivilegesRequired.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/PrivilegesRequired.php deleted file mode 100644 index dff9206db9b..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/PrivilegesRequired.php +++ /dev/null @@ -1,61 +0,0 @@ -grafeas.v1.CVSSv3.PrivilegesRequired - */ -class PrivilegesRequired -{ - /** - * Generated from protobuf enum PRIVILEGES_REQUIRED_UNSPECIFIED = 0; - */ - const PRIVILEGES_REQUIRED_UNSPECIFIED = 0; - /** - * Generated from protobuf enum PRIVILEGES_REQUIRED_NONE = 1; - */ - const PRIVILEGES_REQUIRED_NONE = 1; - /** - * Generated from protobuf enum PRIVILEGES_REQUIRED_LOW = 2; - */ - const PRIVILEGES_REQUIRED_LOW = 2; - /** - * Generated from protobuf enum PRIVILEGES_REQUIRED_HIGH = 3; - */ - const PRIVILEGES_REQUIRED_HIGH = 3; - - private static $valueToName = [ - self::PRIVILEGES_REQUIRED_UNSPECIFIED => 'PRIVILEGES_REQUIRED_UNSPECIFIED', - self::PRIVILEGES_REQUIRED_NONE => 'PRIVILEGES_REQUIRED_NONE', - self::PRIVILEGES_REQUIRED_LOW => 'PRIVILEGES_REQUIRED_LOW', - self::PRIVILEGES_REQUIRED_HIGH => 'PRIVILEGES_REQUIRED_HIGH', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PrivilegesRequired::class, \Grafeas\V1\CVSSv3_PrivilegesRequired::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Scope.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Scope.php deleted file mode 100644 index fc48b6eed3d..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/Scope.php +++ /dev/null @@ -1,56 +0,0 @@ -grafeas.v1.CVSSv3.Scope - */ -class Scope -{ - /** - * Generated from protobuf enum SCOPE_UNSPECIFIED = 0; - */ - const SCOPE_UNSPECIFIED = 0; - /** - * Generated from protobuf enum SCOPE_UNCHANGED = 1; - */ - const SCOPE_UNCHANGED = 1; - /** - * Generated from protobuf enum SCOPE_CHANGED = 2; - */ - const SCOPE_CHANGED = 2; - - private static $valueToName = [ - self::SCOPE_UNSPECIFIED => 'SCOPE_UNSPECIFIED', - self::SCOPE_UNCHANGED => 'SCOPE_UNCHANGED', - self::SCOPE_CHANGED => 'SCOPE_CHANGED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Scope::class, \Grafeas\V1\CVSSv3_Scope::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/UserInteraction.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/UserInteraction.php deleted file mode 100644 index 2348d20766d..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3/UserInteraction.php +++ /dev/null @@ -1,56 +0,0 @@ -grafeas.v1.CVSSv3.UserInteraction - */ -class UserInteraction -{ - /** - * Generated from protobuf enum USER_INTERACTION_UNSPECIFIED = 0; - */ - const USER_INTERACTION_UNSPECIFIED = 0; - /** - * Generated from protobuf enum USER_INTERACTION_NONE = 1; - */ - const USER_INTERACTION_NONE = 1; - /** - * Generated from protobuf enum USER_INTERACTION_REQUIRED = 2; - */ - const USER_INTERACTION_REQUIRED = 2; - - private static $valueToName = [ - self::USER_INTERACTION_UNSPECIFIED => 'USER_INTERACTION_UNSPECIFIED', - self::USER_INTERACTION_NONE => 'USER_INTERACTION_NONE', - self::USER_INTERACTION_REQUIRED => 'USER_INTERACTION_REQUIRED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(UserInteraction::class, \Grafeas\V1\CVSSv3_UserInteraction::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_AttackComplexity.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_AttackComplexity.php deleted file mode 100644 index 5194d471da3..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CVSSv3_AttackComplexity.php +++ /dev/null @@ -1,16 +0,0 @@ -grafeas.v1.CloudRepoSourceContext - */ -class CloudRepoSourceContext extends \Google\Protobuf\Internal\Message -{ - /** - * The ID of the repo. - * - * Generated from protobuf field .grafeas.v1.RepoId repo_id = 1; - */ - protected $repo_id = null; - protected $revision; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\RepoId $repo_id - * The ID of the repo. - * @type string $revision_id - * A revision ID. - * @type \Grafeas\V1\AliasContext $alias_context - * An alias, which may be a branch or tag. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * The ID of the repo. - * - * Generated from protobuf field .grafeas.v1.RepoId repo_id = 1; - * @return \Grafeas\V1\RepoId|null - */ - public function getRepoId() - { - return $this->repo_id; - } - - public function hasRepoId() - { - return isset($this->repo_id); - } - - public function clearRepoId() - { - unset($this->repo_id); - } - - /** - * The ID of the repo. - * - * Generated from protobuf field .grafeas.v1.RepoId repo_id = 1; - * @param \Grafeas\V1\RepoId $var - * @return $this - */ - public function setRepoId($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\RepoId::class); - $this->repo_id = $var; - - return $this; - } - - /** - * A revision ID. - * - * Generated from protobuf field string revision_id = 2; - * @return string - */ - public function getRevisionId() - { - return $this->readOneof(2); - } - - public function hasRevisionId() - { - return $this->hasOneof(2); - } - - /** - * A revision ID. - * - * Generated from protobuf field string revision_id = 2; - * @param string $var - * @return $this - */ - public function setRevisionId($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * An alias, which may be a branch or tag. - * - * Generated from protobuf field .grafeas.v1.AliasContext alias_context = 3; - * @return \Grafeas\V1\AliasContext|null - */ - public function getAliasContext() - { - return $this->readOneof(3); - } - - public function hasAliasContext() - { - return $this->hasOneof(3); - } - - /** - * An alias, which may be a branch or tag. - * - * Generated from protobuf field .grafeas.v1.AliasContext alias_context = 3; - * @param \Grafeas\V1\AliasContext $var - * @return $this - */ - public function setAliasContext($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\AliasContext::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getRevision() - { - return $this->whichOneof("revision"); - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Command.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Command.php deleted file mode 100644 index 40d507cfd67..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Command.php +++ /dev/null @@ -1,249 +0,0 @@ -grafeas.v1.Command - */ -class Command extends \Google\Protobuf\Internal\Message -{ - /** - * Required. 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`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Environment variables set before running this command. - * - * Generated from protobuf field repeated string env = 2; - */ - private $env; - /** - * Command-line arguments used when executing this command. - * - * Generated from protobuf field repeated string args = 3; - */ - private $args; - /** - * Working directory (relative to project source root) used when running this - * command. - * - * Generated from protobuf field string dir = 4; - */ - protected $dir = ''; - /** - * Optional unique identifier for this command, used in wait_for to reference - * this command as a dependency. - * - * Generated from protobuf field string id = 5; - */ - protected $id = ''; - /** - * The ID(s) of the command(s) that this command depends on. - * - * Generated from protobuf field repeated string wait_for = 6; - */ - private $wait_for; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. 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`. - * @type array|\Google\Protobuf\Internal\RepeatedField $env - * Environment variables set before running this command. - * @type array|\Google\Protobuf\Internal\RepeatedField $args - * Command-line arguments used when executing this command. - * @type string $dir - * Working directory (relative to project source root) used when running this - * command. - * @type string $id - * Optional unique identifier for this command, used in wait_for to reference - * this command as a dependency. - * @type array|\Google\Protobuf\Internal\RepeatedField $wait_for - * The ID(s) of the command(s) that this command depends on. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * Required. 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`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. 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`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Environment variables set before running this command. - * - * Generated from protobuf field repeated string env = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getEnv() - { - return $this->env; - } - - /** - * Environment variables set before running this command. - * - * Generated from protobuf field repeated string env = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setEnv($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->env = $arr; - - return $this; - } - - /** - * Command-line arguments used when executing this command. - * - * Generated from protobuf field repeated string args = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getArgs() - { - return $this->args; - } - - /** - * Command-line arguments used when executing this command. - * - * Generated from protobuf field repeated string args = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setArgs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->args = $arr; - - return $this; - } - - /** - * Working directory (relative to project source root) used when running this - * command. - * - * Generated from protobuf field string dir = 4; - * @return string - */ - public function getDir() - { - return $this->dir; - } - - /** - * Working directory (relative to project source root) used when running this - * command. - * - * Generated from protobuf field string dir = 4; - * @param string $var - * @return $this - */ - public function setDir($var) - { - GPBUtil::checkString($var, True); - $this->dir = $var; - - return $this; - } - - /** - * Optional unique identifier for this command, used in wait_for to reference - * this command as a dependency. - * - * Generated from protobuf field string id = 5; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Optional unique identifier for this command, used in wait_for to reference - * this command as a dependency. - * - * Generated from protobuf field string id = 5; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * The ID(s) of the command(s) that this command depends on. - * - * Generated from protobuf field repeated string wait_for = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getWaitFor() - { - return $this->wait_for; - } - - /** - * The ID(s) of the command(s) that this command depends on. - * - * Generated from protobuf field repeated string wait_for = 6; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setWaitFor($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->wait_for = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Completeness.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Completeness.php deleted file mode 100644 index d5cd151e9b5..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Completeness.php +++ /dev/null @@ -1,148 +0,0 @@ -grafeas.v1.Completeness - */ -class Completeness extends \Google\Protobuf\Internal\Message -{ - /** - * If true, the builder claims that recipe.arguments is complete, meaning that - * all external inputs are properly captured in the recipe. - * - * Generated from protobuf field bool arguments = 1; - */ - protected $arguments = false; - /** - * If true, the builder claims that recipe.environment is claimed to be - * complete. - * - * Generated from protobuf field bool environment = 2; - */ - protected $environment = false; - /** - * If true, the builder claims that materials are complete, usually through - * some controls to prevent network access. Sometimes called "hermetic". - * - * Generated from protobuf field bool materials = 3; - */ - protected $materials = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $arguments - * If true, the builder claims that recipe.arguments is complete, meaning that - * all external inputs are properly captured in the recipe. - * @type bool $environment - * If true, the builder claims that recipe.environment is claimed to be - * complete. - * @type bool $materials - * If true, the builder claims that materials are complete, usually through - * some controls to prevent network access. Sometimes called "hermetic". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\IntotoProvenance::initOnce(); - parent::__construct($data); - } - - /** - * If true, the builder claims that recipe.arguments is complete, meaning that - * all external inputs are properly captured in the recipe. - * - * Generated from protobuf field bool arguments = 1; - * @return bool - */ - public function getArguments() - { - return $this->arguments; - } - - /** - * If true, the builder claims that recipe.arguments is complete, meaning that - * all external inputs are properly captured in the recipe. - * - * Generated from protobuf field bool arguments = 1; - * @param bool $var - * @return $this - */ - public function setArguments($var) - { - GPBUtil::checkBool($var); - $this->arguments = $var; - - return $this; - } - - /** - * If true, the builder claims that recipe.environment is claimed to be - * complete. - * - * Generated from protobuf field bool environment = 2; - * @return bool - */ - public function getEnvironment() - { - return $this->environment; - } - - /** - * If true, the builder claims that recipe.environment is claimed to be - * complete. - * - * Generated from protobuf field bool environment = 2; - * @param bool $var - * @return $this - */ - public function setEnvironment($var) - { - GPBUtil::checkBool($var); - $this->environment = $var; - - return $this; - } - - /** - * If true, the builder claims that materials are complete, usually through - * some controls to prevent network access. Sometimes called "hermetic". - * - * Generated from protobuf field bool materials = 3; - * @return bool - */ - public function getMaterials() - { - return $this->materials; - } - - /** - * If true, the builder claims that materials are complete, usually through - * some controls to prevent network access. Sometimes called "hermetic". - * - * Generated from protobuf field bool materials = 3; - * @param bool $var - * @return $this - */ - public function setMaterials($var) - { - GPBUtil::checkBool($var); - $this->materials = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote.php deleted file mode 100644 index 651c3573ec4..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote.php +++ /dev/null @@ -1,272 +0,0 @@ -grafeas.v1.ComplianceNote - */ -class ComplianceNote extends \Google\Protobuf\Internal\Message -{ - /** - * The title that identifies this compliance check. - * - * Generated from protobuf field string title = 1; - */ - protected $title = ''; - /** - * A description about this compliance check. - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - /** - * The OS and config versions the benchmark applies to. - * - * Generated from protobuf field repeated .grafeas.v1.ComplianceVersion version = 3; - */ - private $version; - /** - * A rationale for the existence of this compliance check. - * - * Generated from protobuf field string rationale = 4; - */ - protected $rationale = ''; - /** - * A description of remediation steps if the compliance check fails. - * - * Generated from protobuf field string remediation = 5; - */ - protected $remediation = ''; - /** - * Serialized scan instructions with a predefined format. - * - * Generated from protobuf field bytes scan_instructions = 7; - */ - protected $scan_instructions = ''; - protected $compliance_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $title - * The title that identifies this compliance check. - * @type string $description - * A description about this compliance check. - * @type array<\Grafeas\V1\ComplianceVersion>|\Google\Protobuf\Internal\RepeatedField $version - * The OS and config versions the benchmark applies to. - * @type string $rationale - * A rationale for the existence of this compliance check. - * @type string $remediation - * A description of remediation steps if the compliance check fails. - * @type \Grafeas\V1\ComplianceNote\CisBenchmark $cis_benchmark - * @type string $scan_instructions - * Serialized scan instructions with a predefined format. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Compliance::initOnce(); - parent::__construct($data); - } - - /** - * The title that identifies this compliance check. - * - * Generated from protobuf field string title = 1; - * @return string - */ - public function getTitle() - { - return $this->title; - } - - /** - * The title that identifies this compliance check. - * - * Generated from protobuf field string title = 1; - * @param string $var - * @return $this - */ - public function setTitle($var) - { - GPBUtil::checkString($var, True); - $this->title = $var; - - return $this; - } - - /** - * A description about this compliance check. - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * A description about this compliance check. - * - * Generated from protobuf field string description = 2; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The OS and config versions the benchmark applies to. - * - * Generated from protobuf field repeated .grafeas.v1.ComplianceVersion version = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getVersion() - { - return $this->version; - } - - /** - * The OS and config versions the benchmark applies to. - * - * Generated from protobuf field repeated .grafeas.v1.ComplianceVersion version = 3; - * @param array<\Grafeas\V1\ComplianceVersion>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setVersion($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\ComplianceVersion::class); - $this->version = $arr; - - return $this; - } - - /** - * A rationale for the existence of this compliance check. - * - * Generated from protobuf field string rationale = 4; - * @return string - */ - public function getRationale() - { - return $this->rationale; - } - - /** - * A rationale for the existence of this compliance check. - * - * Generated from protobuf field string rationale = 4; - * @param string $var - * @return $this - */ - public function setRationale($var) - { - GPBUtil::checkString($var, True); - $this->rationale = $var; - - return $this; - } - - /** - * A description of remediation steps if the compliance check fails. - * - * Generated from protobuf field string remediation = 5; - * @return string - */ - public function getRemediation() - { - return $this->remediation; - } - - /** - * A description of remediation steps if the compliance check fails. - * - * Generated from protobuf field string remediation = 5; - * @param string $var - * @return $this - */ - public function setRemediation($var) - { - GPBUtil::checkString($var, True); - $this->remediation = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.ComplianceNote.CisBenchmark cis_benchmark = 6; - * @return \Grafeas\V1\ComplianceNote\CisBenchmark|null - */ - public function getCisBenchmark() - { - return $this->readOneof(6); - } - - public function hasCisBenchmark() - { - return $this->hasOneof(6); - } - - /** - * Generated from protobuf field .grafeas.v1.ComplianceNote.CisBenchmark cis_benchmark = 6; - * @param \Grafeas\V1\ComplianceNote\CisBenchmark $var - * @return $this - */ - public function setCisBenchmark($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\ComplianceNote\CisBenchmark::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * Serialized scan instructions with a predefined format. - * - * Generated from protobuf field bytes scan_instructions = 7; - * @return string - */ - public function getScanInstructions() - { - return $this->scan_instructions; - } - - /** - * Serialized scan instructions with a predefined format. - * - * Generated from protobuf field bytes scan_instructions = 7; - * @param string $var - * @return $this - */ - public function setScanInstructions($var) - { - GPBUtil::checkString($var, False); - $this->scan_instructions = $var; - - return $this; - } - - /** - * @return string - */ - public function getComplianceType() - { - return $this->whichOneof("compliance_type"); - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote/CisBenchmark.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote/CisBenchmark.php deleted file mode 100644 index be70e77b166..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote/CisBenchmark.php +++ /dev/null @@ -1,90 +0,0 @@ -grafeas.v1.ComplianceNote.CisBenchmark - */ -class CisBenchmark extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field int32 profile_level = 1; - */ - protected $profile_level = 0; - /** - * Generated from protobuf field .grafeas.v1.Severity severity = 2; - */ - protected $severity = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $profile_level - * @type int $severity - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Compliance::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field int32 profile_level = 1; - * @return int - */ - public function getProfileLevel() - { - return $this->profile_level; - } - - /** - * Generated from protobuf field int32 profile_level = 1; - * @param int $var - * @return $this - */ - public function setProfileLevel($var) - { - GPBUtil::checkInt32($var); - $this->profile_level = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.Severity severity = 2; - * @return int - */ - public function getSeverity() - { - return $this->severity; - } - - /** - * Generated from protobuf field .grafeas.v1.Severity severity = 2; - * @param int $var - * @return $this - */ - public function setSeverity($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\Severity::class); - $this->severity = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(CisBenchmark::class, \Grafeas\V1\ComplianceNote_CisBenchmark::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote_CisBenchmark.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote_CisBenchmark.php deleted file mode 100644 index 05b17cf4e1c..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceNote_CisBenchmark.php +++ /dev/null @@ -1,16 +0,0 @@ -grafeas.v1.ComplianceOccurrence - */ -class ComplianceOccurrence extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field repeated .grafeas.v1.NonCompliantFile non_compliant_files = 2; - */ - private $non_compliant_files; - /** - * Generated from protobuf field string non_compliance_reason = 3; - */ - protected $non_compliance_reason = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Grafeas\V1\NonCompliantFile>|\Google\Protobuf\Internal\RepeatedField $non_compliant_files - * @type string $non_compliance_reason - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Compliance::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field repeated .grafeas.v1.NonCompliantFile non_compliant_files = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNonCompliantFiles() - { - return $this->non_compliant_files; - } - - /** - * Generated from protobuf field repeated .grafeas.v1.NonCompliantFile non_compliant_files = 2; - * @param array<\Grafeas\V1\NonCompliantFile>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNonCompliantFiles($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\NonCompliantFile::class); - $this->non_compliant_files = $arr; - - return $this; - } - - /** - * Generated from protobuf field string non_compliance_reason = 3; - * @return string - */ - public function getNonComplianceReason() - { - return $this->non_compliance_reason; - } - - /** - * Generated from protobuf field string non_compliance_reason = 3; - * @param string $var - * @return $this - */ - public function setNonComplianceReason($var) - { - GPBUtil::checkString($var, True); - $this->non_compliance_reason = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceVersion.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceVersion.php deleted file mode 100644 index 19d19abd80b..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ComplianceVersion.php +++ /dev/null @@ -1,148 +0,0 @@ -grafeas.v1.ComplianceVersion - */ -class ComplianceVersion extends \Google\Protobuf\Internal\Message -{ - /** - * The CPE URI (https://cpe.mitre.org/specification/) this benchmark is - * applicable to. - * - * Generated from protobuf field string cpe_uri = 1; - */ - protected $cpe_uri = ''; - /** - * The name of the document that defines this benchmark, e.g. "CIS - * Container-Optimized OS". - * - * Generated from protobuf field string benchmark_document = 3; - */ - protected $benchmark_document = ''; - /** - * The version of the benchmark. This is set to the version of the OS-specific - * CIS document the benchmark is defined in. - * - * Generated from protobuf field string version = 2; - */ - protected $version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $cpe_uri - * The CPE URI (https://cpe.mitre.org/specification/) this benchmark is - * applicable to. - * @type string $benchmark_document - * The name of the document that defines this benchmark, e.g. "CIS - * Container-Optimized OS". - * @type string $version - * The version of the benchmark. This is set to the version of the OS-specific - * CIS document the benchmark is defined in. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Compliance::initOnce(); - parent::__construct($data); - } - - /** - * The CPE URI (https://cpe.mitre.org/specification/) this benchmark is - * applicable to. - * - * Generated from protobuf field string cpe_uri = 1; - * @return string - */ - public function getCpeUri() - { - return $this->cpe_uri; - } - - /** - * The CPE URI (https://cpe.mitre.org/specification/) this benchmark is - * applicable to. - * - * Generated from protobuf field string cpe_uri = 1; - * @param string $var - * @return $this - */ - public function setCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->cpe_uri = $var; - - return $this; - } - - /** - * The name of the document that defines this benchmark, e.g. "CIS - * Container-Optimized OS". - * - * Generated from protobuf field string benchmark_document = 3; - * @return string - */ - public function getBenchmarkDocument() - { - return $this->benchmark_document; - } - - /** - * The name of the document that defines this benchmark, e.g. "CIS - * Container-Optimized OS". - * - * Generated from protobuf field string benchmark_document = 3; - * @param string $var - * @return $this - */ - public function setBenchmarkDocument($var) - { - GPBUtil::checkString($var, True); - $this->benchmark_document = $var; - - return $this; - } - - /** - * The version of the benchmark. This is set to the version of the OS-specific - * CIS document the benchmark is defined in. - * - * Generated from protobuf field string version = 2; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * The version of the benchmark. This is set to the version of the OS-specific - * CIS document the benchmark is defined in. - * - * Generated from protobuf field string version = 2; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateNoteRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateNoteRequest.php deleted file mode 100644 index 65774554b46..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateNoteRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -grafeas.v1.CreateNoteRequest - */ -class CreateNoteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the note is to be created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The ID to use for this note. - * - * Generated from protobuf field string note_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $note_id = ''; - /** - * The note to create. - * - * Generated from protobuf field .grafeas.v1.Note note = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $note = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the note is to be created. - * @type string $note_id - * The ID to use for this note. - * @type \Grafeas\V1\Note $note - * The note to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the note is to be created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the note is to be created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The ID to use for this note. - * - * Generated from protobuf field string note_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getNoteId() - { - return $this->note_id; - } - - /** - * The ID to use for this note. - * - * Generated from protobuf field string note_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setNoteId($var) - { - GPBUtil::checkString($var, True); - $this->note_id = $var; - - return $this; - } - - /** - * The note to create. - * - * Generated from protobuf field .grafeas.v1.Note note = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Grafeas\V1\Note|null - */ - public function getNote() - { - return $this->note; - } - - public function hasNote() - { - return isset($this->note); - } - - public function clearNote() - { - unset($this->note); - } - - /** - * The note to create. - * - * Generated from protobuf field .grafeas.v1.Note note = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Grafeas\V1\Note $var - * @return $this - */ - public function setNote($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Note::class); - $this->note = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateOccurrenceRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateOccurrenceRequest.php deleted file mode 100644 index 406afefc2f6..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/CreateOccurrenceRequest.php +++ /dev/null @@ -1,115 +0,0 @@ -grafeas.v1.CreateOccurrenceRequest - */ -class CreateOccurrenceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the occurrence is to be created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The occurrence to create. - * - * Generated from protobuf field .grafeas.v1.Occurrence occurrence = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $occurrence = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the occurrence is to be created. - * @type \Grafeas\V1\Occurrence $occurrence - * The occurrence to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the occurrence is to be created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the occurrence is to be created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The occurrence to create. - * - * Generated from protobuf field .grafeas.v1.Occurrence occurrence = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Grafeas\V1\Occurrence|null - */ - public function getOccurrence() - { - return $this->occurrence; - } - - public function hasOccurrence() - { - return isset($this->occurrence); - } - - public function clearOccurrence() - { - unset($this->occurrence); - } - - /** - * The occurrence to create. - * - * Generated from protobuf field .grafeas.v1.Occurrence occurrence = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Grafeas\V1\Occurrence $var - * @return $this - */ - public function setOccurrence($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Occurrence::class); - $this->occurrence = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote.php deleted file mode 100644 index b40b73c92c3..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote.php +++ /dev/null @@ -1,75 +0,0 @@ -grafeas.v1.DSSEAttestationNote - */ -class DSSEAttestationNote extends \Google\Protobuf\Internal\Message -{ - /** - * DSSEHint hints at the purpose of the attestation authority. - * - * Generated from protobuf field .grafeas.v1.DSSEAttestationNote.DSSEHint hint = 1; - */ - protected $hint = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\DSSEAttestationNote\DSSEHint $hint - * DSSEHint hints at the purpose of the attestation authority. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\DsseAttestation::initOnce(); - parent::__construct($data); - } - - /** - * DSSEHint hints at the purpose of the attestation authority. - * - * Generated from protobuf field .grafeas.v1.DSSEAttestationNote.DSSEHint hint = 1; - * @return \Grafeas\V1\DSSEAttestationNote\DSSEHint|null - */ - public function getHint() - { - return $this->hint; - } - - public function hasHint() - { - return isset($this->hint); - } - - public function clearHint() - { - unset($this->hint); - } - - /** - * DSSEHint hints at the purpose of the attestation authority. - * - * Generated from protobuf field .grafeas.v1.DSSEAttestationNote.DSSEHint hint = 1; - * @param \Grafeas\V1\DSSEAttestationNote\DSSEHint $var - * @return $this - */ - public function setHint($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\DSSEAttestationNote\DSSEHint::class); - $this->hint = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote/DSSEHint.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote/DSSEHint.php deleted file mode 100644 index 972f8428516..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote/DSSEHint.php +++ /dev/null @@ -1,80 +0,0 @@ -grafeas.v1.DSSEAttestationNote.DSSEHint - */ -class DSSEHint extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The human readable name of this attestation authority, for - * example "cloudbuild-prod". - * - * Generated from protobuf field string human_readable_name = 1; - */ - protected $human_readable_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $human_readable_name - * Required. The human readable name of this attestation authority, for - * example "cloudbuild-prod". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\DsseAttestation::initOnce(); - parent::__construct($data); - } - - /** - * Required. The human readable name of this attestation authority, for - * example "cloudbuild-prod". - * - * Generated from protobuf field string human_readable_name = 1; - * @return string - */ - public function getHumanReadableName() - { - return $this->human_readable_name; - } - - /** - * Required. The human readable name of this attestation authority, for - * example "cloudbuild-prod". - * - * Generated from protobuf field string human_readable_name = 1; - * @param string $var - * @return $this - */ - public function setHumanReadableName($var) - { - GPBUtil::checkString($var, True); - $this->human_readable_name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DSSEHint::class, \Grafeas\V1\DSSEAttestationNote_DSSEHint::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote_DSSEHint.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote_DSSEHint.php deleted file mode 100644 index 59c6d41f948..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DSSEAttestationNote_DSSEHint.php +++ /dev/null @@ -1,16 +0,0 @@ -grafeas.v1.DSSEAttestationOccurrence - */ -class DSSEAttestationOccurrence extends \Google\Protobuf\Internal\Message -{ - /** - * If doing something security critical, make sure to verify the signatures in - * this metadata. - * - * Generated from protobuf field .grafeas.v1.Envelope envelope = 1; - */ - protected $envelope = null; - protected $decoded_payload; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\Envelope $envelope - * If doing something security critical, make sure to verify the signatures in - * this metadata. - * @type \Grafeas\V1\InTotoStatement $statement - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\DsseAttestation::initOnce(); - parent::__construct($data); - } - - /** - * If doing something security critical, make sure to verify the signatures in - * this metadata. - * - * Generated from protobuf field .grafeas.v1.Envelope envelope = 1; - * @return \Grafeas\V1\Envelope|null - */ - public function getEnvelope() - { - return $this->envelope; - } - - public function hasEnvelope() - { - return isset($this->envelope); - } - - public function clearEnvelope() - { - unset($this->envelope); - } - - /** - * If doing something security critical, make sure to verify the signatures in - * this metadata. - * - * Generated from protobuf field .grafeas.v1.Envelope envelope = 1; - * @param \Grafeas\V1\Envelope $var - * @return $this - */ - public function setEnvelope($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Envelope::class); - $this->envelope = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.InTotoStatement statement = 2; - * @return \Grafeas\V1\InTotoStatement|null - */ - public function getStatement() - { - return $this->readOneof(2); - } - - public function hasStatement() - { - return $this->hasOneof(2); - } - - /** - * Generated from protobuf field .grafeas.v1.InTotoStatement statement = 2; - * @param \Grafeas\V1\InTotoStatement $var - * @return $this - */ - public function setStatement($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\InTotoStatement::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getDecodedPayload() - { - return $this->whichOneof("decoded_payload"); - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteNoteRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteNoteRequest.php deleted file mode 100644 index 776c3531767..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteNoteRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -grafeas.v1.DeleteNoteRequest - */ -class DeleteNoteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteOccurrenceRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteOccurrenceRequest.php deleted file mode 100644 index 78bc19ab372..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeleteOccurrenceRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -grafeas.v1.DeleteOccurrenceRequest - */ -class DeleteOccurrenceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentNote.php deleted file mode 100644 index d934670e3bb..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentNote.php +++ /dev/null @@ -1,67 +0,0 @@ -grafeas.v1.DeploymentNote - */ -class DeploymentNote extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource URI for the artifact being deployed. - * - * Generated from protobuf field repeated string resource_uri = 1; - */ - private $resource_uri; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $resource_uri - * Required. Resource URI for the artifact being deployed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Deployment::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource URI for the artifact being deployed. - * - * Generated from protobuf field repeated string resource_uri = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getResourceUri() - { - return $this->resource_uri; - } - - /** - * Required. Resource URI for the artifact being deployed. - * - * Generated from protobuf field repeated string resource_uri = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setResourceUri($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->resource_uri = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence.php deleted file mode 100644 index 9971d3eb3d4..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence.php +++ /dev/null @@ -1,295 +0,0 @@ -grafeas.v1.DeploymentOccurrence - */ -class DeploymentOccurrence extends \Google\Protobuf\Internal\Message -{ - /** - * Identity of the user that triggered this deployment. - * - * Generated from protobuf field string user_email = 1; - */ - protected $user_email = ''; - /** - * Required. Beginning of the lifetime of this deployment. - * - * Generated from protobuf field .google.protobuf.Timestamp deploy_time = 2; - */ - protected $deploy_time = null; - /** - * End of the lifetime of this deployment. - * - * Generated from protobuf field .google.protobuf.Timestamp undeploy_time = 3; - */ - protected $undeploy_time = null; - /** - * Configuration used to create this deployment. - * - * Generated from protobuf field string config = 4; - */ - protected $config = ''; - /** - * Address of the runtime element hosting this deployment. - * - * Generated from protobuf field string address = 5; - */ - protected $address = ''; - /** - * Output only. Resource URI for the artifact being deployed taken from - * the deployable field with the same name. - * - * Generated from protobuf field repeated string resource_uri = 6; - */ - private $resource_uri; - /** - * Platform hosting this deployment. - * - * Generated from protobuf field .grafeas.v1.DeploymentOccurrence.Platform platform = 7; - */ - protected $platform = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $user_email - * Identity of the user that triggered this deployment. - * @type \Google\Protobuf\Timestamp $deploy_time - * Required. Beginning of the lifetime of this deployment. - * @type \Google\Protobuf\Timestamp $undeploy_time - * End of the lifetime of this deployment. - * @type string $config - * Configuration used to create this deployment. - * @type string $address - * Address of the runtime element hosting this deployment. - * @type array|\Google\Protobuf\Internal\RepeatedField $resource_uri - * Output only. Resource URI for the artifact being deployed taken from - * the deployable field with the same name. - * @type int $platform - * Platform hosting this deployment. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Deployment::initOnce(); - parent::__construct($data); - } - - /** - * Identity of the user that triggered this deployment. - * - * Generated from protobuf field string user_email = 1; - * @return string - */ - public function getUserEmail() - { - return $this->user_email; - } - - /** - * Identity of the user that triggered this deployment. - * - * Generated from protobuf field string user_email = 1; - * @param string $var - * @return $this - */ - public function setUserEmail($var) - { - GPBUtil::checkString($var, True); - $this->user_email = $var; - - return $this; - } - - /** - * Required. Beginning of the lifetime of this deployment. - * - * Generated from protobuf field .google.protobuf.Timestamp deploy_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getDeployTime() - { - return $this->deploy_time; - } - - public function hasDeployTime() - { - return isset($this->deploy_time); - } - - public function clearDeployTime() - { - unset($this->deploy_time); - } - - /** - * Required. Beginning of the lifetime of this deployment. - * - * Generated from protobuf field .google.protobuf.Timestamp deploy_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setDeployTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->deploy_time = $var; - - return $this; - } - - /** - * End of the lifetime of this deployment. - * - * Generated from protobuf field .google.protobuf.Timestamp undeploy_time = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUndeployTime() - { - return $this->undeploy_time; - } - - public function hasUndeployTime() - { - return isset($this->undeploy_time); - } - - public function clearUndeployTime() - { - unset($this->undeploy_time); - } - - /** - * End of the lifetime of this deployment. - * - * Generated from protobuf field .google.protobuf.Timestamp undeploy_time = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUndeployTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->undeploy_time = $var; - - return $this; - } - - /** - * Configuration used to create this deployment. - * - * Generated from protobuf field string config = 4; - * @return string - */ - public function getConfig() - { - return $this->config; - } - - /** - * Configuration used to create this deployment. - * - * Generated from protobuf field string config = 4; - * @param string $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkString($var, True); - $this->config = $var; - - return $this; - } - - /** - * Address of the runtime element hosting this deployment. - * - * Generated from protobuf field string address = 5; - * @return string - */ - public function getAddress() - { - return $this->address; - } - - /** - * Address of the runtime element hosting this deployment. - * - * Generated from protobuf field string address = 5; - * @param string $var - * @return $this - */ - public function setAddress($var) - { - GPBUtil::checkString($var, True); - $this->address = $var; - - return $this; - } - - /** - * Output only. Resource URI for the artifact being deployed taken from - * the deployable field with the same name. - * - * Generated from protobuf field repeated string resource_uri = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getResourceUri() - { - return $this->resource_uri; - } - - /** - * Output only. Resource URI for the artifact being deployed taken from - * the deployable field with the same name. - * - * Generated from protobuf field repeated string resource_uri = 6; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setResourceUri($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->resource_uri = $arr; - - return $this; - } - - /** - * Platform hosting this deployment. - * - * Generated from protobuf field .grafeas.v1.DeploymentOccurrence.Platform platform = 7; - * @return int - */ - public function getPlatform() - { - return $this->platform; - } - - /** - * Platform hosting this deployment. - * - * Generated from protobuf field .grafeas.v1.DeploymentOccurrence.Platform platform = 7; - * @param int $var - * @return $this - */ - public function setPlatform($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\DeploymentOccurrence\Platform::class); - $this->platform = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence/Platform.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence/Platform.php deleted file mode 100644 index 35b13b4c785..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence/Platform.php +++ /dev/null @@ -1,71 +0,0 @@ -grafeas.v1.DeploymentOccurrence.Platform - */ -class Platform -{ - /** - * Unknown. - * - * Generated from protobuf enum PLATFORM_UNSPECIFIED = 0; - */ - const PLATFORM_UNSPECIFIED = 0; - /** - * Google Container Engine. - * - * Generated from protobuf enum GKE = 1; - */ - const GKE = 1; - /** - * Google App Engine: Flexible Environment. - * - * Generated from protobuf enum FLEX = 2; - */ - const FLEX = 2; - /** - * Custom user-defined platform. - * - * Generated from protobuf enum CUSTOM = 3; - */ - const CUSTOM = 3; - - private static $valueToName = [ - self::PLATFORM_UNSPECIFIED => 'PLATFORM_UNSPECIFIED', - self::GKE => 'GKE', - self::FLEX => 'FLEX', - self::CUSTOM => 'CUSTOM', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Platform::class, \Grafeas\V1\DeploymentOccurrence_Platform::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence_Platform.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence_Platform.php deleted file mode 100644 index 411764953ea..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DeploymentOccurrence_Platform.php +++ /dev/null @@ -1,16 +0,0 @@ -grafeas.v1.Digest - */ -class Digest extends \Google\Protobuf\Internal\Message -{ - /** - * `SHA1`, `SHA512` etc. - * - * Generated from protobuf field string algo = 1; - */ - protected $algo = ''; - /** - * Value of the digest. - * - * Generated from protobuf field bytes digest_bytes = 2; - */ - protected $digest_bytes = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $algo - * `SHA1`, `SHA512` etc. - * @type string $digest_bytes - * Value of the digest. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Common::initOnce(); - parent::__construct($data); - } - - /** - * `SHA1`, `SHA512` etc. - * - * Generated from protobuf field string algo = 1; - * @return string - */ - public function getAlgo() - { - return $this->algo; - } - - /** - * `SHA1`, `SHA512` etc. - * - * Generated from protobuf field string algo = 1; - * @param string $var - * @return $this - */ - public function setAlgo($var) - { - GPBUtil::checkString($var, True); - $this->algo = $var; - - return $this; - } - - /** - * Value of the digest. - * - * Generated from protobuf field bytes digest_bytes = 2; - * @return string - */ - public function getDigestBytes() - { - return $this->digest_bytes; - } - - /** - * Value of the digest. - * - * Generated from protobuf field bytes digest_bytes = 2; - * @param string $var - * @return $this - */ - public function setDigestBytes($var) - { - GPBUtil::checkString($var, False); - $this->digest_bytes = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryNote.php deleted file mode 100644 index d1fa446c046..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryNote.php +++ /dev/null @@ -1,73 +0,0 @@ -grafeas.v1.DiscoveryNote - */ -class DiscoveryNote extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Immutable. The kind of analysis that is handled by this - * discovery. - * - * Generated from protobuf field .grafeas.v1.NoteKind analysis_kind = 1; - */ - protected $analysis_kind = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $analysis_kind - * Required. Immutable. The kind of analysis that is handled by this - * discovery. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Discovery::initOnce(); - parent::__construct($data); - } - - /** - * Required. Immutable. The kind of analysis that is handled by this - * discovery. - * - * Generated from protobuf field .grafeas.v1.NoteKind analysis_kind = 1; - * @return int - */ - public function getAnalysisKind() - { - return $this->analysis_kind; - } - - /** - * Required. Immutable. The kind of analysis that is handled by this - * discovery. - * - * Generated from protobuf field .grafeas.v1.NoteKind analysis_kind = 1; - * @param int $var - * @return $this - */ - public function setAnalysisKind($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\NoteKind::class); - $this->analysis_kind = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence.php deleted file mode 100644 index e1710bb863e..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence.php +++ /dev/null @@ -1,350 +0,0 @@ -grafeas.v1.DiscoveryOccurrence - */ -class DiscoveryOccurrence extends \Google\Protobuf\Internal\Message -{ - /** - * Whether the resource is continuously analyzed. - * - * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.ContinuousAnalysis continuous_analysis = 1; - */ - protected $continuous_analysis = 0; - /** - * The status of discovery for the resource. - * - * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.AnalysisStatus analysis_status = 2; - */ - protected $analysis_status = 0; - /** - * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.AnalysisCompleted analysis_completed = 7; - */ - protected $analysis_completed = null; - /** - * Indicates any errors encountered during analysis of a resource. There - * could be 0 or more of these errors. - * - * Generated from protobuf field repeated .google.rpc.Status analysis_error = 8; - */ - private $analysis_error; - /** - * 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. - * - * Generated from protobuf field .google.rpc.Status analysis_status_error = 3; - */ - protected $analysis_status_error = null; - /** - * The CPE of the resource being scanned. - * - * Generated from protobuf field string cpe = 4; - */ - protected $cpe = ''; - /** - * The last time this resource was scanned. - * - * Generated from protobuf field .google.protobuf.Timestamp last_scan_time = 5; - */ - protected $last_scan_time = null; - /** - * The time occurrences related to this discovery occurrence were archived. - * - * Generated from protobuf field .google.protobuf.Timestamp archive_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $archive_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $continuous_analysis - * Whether the resource is continuously analyzed. - * @type int $analysis_status - * The status of discovery for the resource. - * @type \Grafeas\V1\DiscoveryOccurrence\AnalysisCompleted $analysis_completed - * @type array<\Google\Rpc\Status>|\Google\Protobuf\Internal\RepeatedField $analysis_error - * Indicates any errors encountered during analysis of a resource. There - * could be 0 or more of these errors. - * @type \Google\Rpc\Status $analysis_status_error - * 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. - * @type string $cpe - * The CPE of the resource being scanned. - * @type \Google\Protobuf\Timestamp $last_scan_time - * The last time this resource was scanned. - * @type \Google\Protobuf\Timestamp $archive_time - * The time occurrences related to this discovery occurrence were archived. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Discovery::initOnce(); - parent::__construct($data); - } - - /** - * Whether the resource is continuously analyzed. - * - * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.ContinuousAnalysis continuous_analysis = 1; - * @return int - */ - public function getContinuousAnalysis() - { - return $this->continuous_analysis; - } - - /** - * Whether the resource is continuously analyzed. - * - * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.ContinuousAnalysis continuous_analysis = 1; - * @param int $var - * @return $this - */ - public function setContinuousAnalysis($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\DiscoveryOccurrence\ContinuousAnalysis::class); - $this->continuous_analysis = $var; - - return $this; - } - - /** - * The status of discovery for the resource. - * - * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.AnalysisStatus analysis_status = 2; - * @return int - */ - public function getAnalysisStatus() - { - return $this->analysis_status; - } - - /** - * The status of discovery for the resource. - * - * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.AnalysisStatus analysis_status = 2; - * @param int $var - * @return $this - */ - public function setAnalysisStatus($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\DiscoveryOccurrence\AnalysisStatus::class); - $this->analysis_status = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.AnalysisCompleted analysis_completed = 7; - * @return \Grafeas\V1\DiscoveryOccurrence\AnalysisCompleted|null - */ - public function getAnalysisCompleted() - { - return $this->analysis_completed; - } - - public function hasAnalysisCompleted() - { - return isset($this->analysis_completed); - } - - public function clearAnalysisCompleted() - { - unset($this->analysis_completed); - } - - /** - * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence.AnalysisCompleted analysis_completed = 7; - * @param \Grafeas\V1\DiscoveryOccurrence\AnalysisCompleted $var - * @return $this - */ - public function setAnalysisCompleted($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\DiscoveryOccurrence\AnalysisCompleted::class); - $this->analysis_completed = $var; - - return $this; - } - - /** - * Indicates any errors encountered during analysis of a resource. There - * could be 0 or more of these errors. - * - * Generated from protobuf field repeated .google.rpc.Status analysis_error = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAnalysisError() - { - return $this->analysis_error; - } - - /** - * Indicates any errors encountered during analysis of a resource. There - * could be 0 or more of these errors. - * - * Generated from protobuf field repeated .google.rpc.Status analysis_error = 8; - * @param array<\Google\Rpc\Status>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAnalysisError($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Rpc\Status::class); - $this->analysis_error = $arr; - - 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. - * - * Generated from protobuf field .google.rpc.Status analysis_status_error = 3; - * @return \Google\Rpc\Status|null - */ - public function getAnalysisStatusError() - { - return $this->analysis_status_error; - } - - public function hasAnalysisStatusError() - { - return isset($this->analysis_status_error); - } - - public function clearAnalysisStatusError() - { - unset($this->analysis_status_error); - } - - /** - * 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. - * - * Generated from protobuf field .google.rpc.Status analysis_status_error = 3; - * @param \Google\Rpc\Status $var - * @return $this - */ - public function setAnalysisStatusError($var) - { - GPBUtil::checkMessage($var, \Google\Rpc\Status::class); - $this->analysis_status_error = $var; - - return $this; - } - - /** - * The CPE of the resource being scanned. - * - * Generated from protobuf field string cpe = 4; - * @return string - */ - public function getCpe() - { - return $this->cpe; - } - - /** - * The CPE of the resource being scanned. - * - * Generated from protobuf field string cpe = 4; - * @param string $var - * @return $this - */ - public function setCpe($var) - { - GPBUtil::checkString($var, True); - $this->cpe = $var; - - return $this; - } - - /** - * The last time this resource was scanned. - * - * Generated from protobuf field .google.protobuf.Timestamp last_scan_time = 5; - * @return \Google\Protobuf\Timestamp|null - */ - public function getLastScanTime() - { - return $this->last_scan_time; - } - - public function hasLastScanTime() - { - return isset($this->last_scan_time); - } - - public function clearLastScanTime() - { - unset($this->last_scan_time); - } - - /** - * The last time this resource was scanned. - * - * Generated from protobuf field .google.protobuf.Timestamp last_scan_time = 5; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setLastScanTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->last_scan_time = $var; - - return $this; - } - - /** - * The time occurrences related to this discovery occurrence were archived. - * - * Generated from protobuf field .google.protobuf.Timestamp archive_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getArchiveTime() - { - return $this->archive_time; - } - - public function hasArchiveTime() - { - return isset($this->archive_time); - } - - public function clearArchiveTime() - { - unset($this->archive_time); - } - - /** - * The time occurrences related to this discovery occurrence were archived. - * - * Generated from protobuf field .google.protobuf.Timestamp archive_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setArchiveTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->archive_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisCompleted.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisCompleted.php deleted file mode 100644 index 5d1e7201fb2..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisCompleted.php +++ /dev/null @@ -1,64 +0,0 @@ -grafeas.v1.DiscoveryOccurrence.AnalysisCompleted - */ -class AnalysisCompleted extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field repeated string analysis_type = 1; - */ - private $analysis_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $analysis_type - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Discovery::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field repeated string analysis_type = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAnalysisType() - { - return $this->analysis_type; - } - - /** - * Generated from protobuf field repeated string analysis_type = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAnalysisType($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->analysis_type = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AnalysisCompleted::class, \Grafeas\V1\DiscoveryOccurrence_AnalysisCompleted::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisStatus.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisStatus.php deleted file mode 100644 index fcef24fb33a..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/AnalysisStatus.php +++ /dev/null @@ -1,94 +0,0 @@ -grafeas.v1.DiscoveryOccurrence.AnalysisStatus - */ -class AnalysisStatus -{ - /** - * Unknown. - * - * Generated from protobuf enum ANALYSIS_STATUS_UNSPECIFIED = 0; - */ - const ANALYSIS_STATUS_UNSPECIFIED = 0; - /** - * Resource is known but no action has been taken yet. - * - * Generated from protobuf enum PENDING = 1; - */ - const PENDING = 1; - /** - * Resource is being analyzed. - * - * Generated from protobuf enum SCANNING = 2; - */ - const SCANNING = 2; - /** - * Analysis has finished successfully. - * - * Generated from protobuf enum FINISHED_SUCCESS = 3; - */ - const FINISHED_SUCCESS = 3; - /** - * Analysis has completed. - * - * Generated from protobuf enum COMPLETE = 3; - */ - const COMPLETE = 3; - /** - * Analysis has finished unsuccessfully, the analysis itself is in a bad - * state. - * - * Generated from protobuf enum FINISHED_FAILED = 4; - */ - const FINISHED_FAILED = 4; - /** - * The resource is known not to be supported. - * - * Generated from protobuf enum FINISHED_UNSUPPORTED = 5; - */ - const FINISHED_UNSUPPORTED = 5; - - private static $valueToName = [ - self::ANALYSIS_STATUS_UNSPECIFIED => 'ANALYSIS_STATUS_UNSPECIFIED', - self::PENDING => 'PENDING', - self::SCANNING => 'SCANNING', - self::FINISHED_SUCCESS => 'FINISHED_SUCCESS', - self::COMPLETE => 'COMPLETE', - self::FINISHED_FAILED => 'FINISHED_FAILED', - self::FINISHED_UNSUPPORTED => 'FINISHED_UNSUPPORTED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AnalysisStatus::class, \Grafeas\V1\DiscoveryOccurrence_AnalysisStatus::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/ContinuousAnalysis.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/ContinuousAnalysis.php deleted file mode 100644 index 350c2fb7590..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence/ContinuousAnalysis.php +++ /dev/null @@ -1,64 +0,0 @@ -grafeas.v1.DiscoveryOccurrence.ContinuousAnalysis - */ -class ContinuousAnalysis -{ - /** - * Unknown. - * - * Generated from protobuf enum CONTINUOUS_ANALYSIS_UNSPECIFIED = 0; - */ - const CONTINUOUS_ANALYSIS_UNSPECIFIED = 0; - /** - * The resource is continuously analyzed. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The resource is ignored for continuous analysis. - * - * Generated from protobuf enum INACTIVE = 2; - */ - const INACTIVE = 2; - - private static $valueToName = [ - self::CONTINUOUS_ANALYSIS_UNSPECIFIED => 'CONTINUOUS_ANALYSIS_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::INACTIVE => 'INACTIVE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ContinuousAnalysis::class, \Grafeas\V1\DiscoveryOccurrence_ContinuousAnalysis::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence_AnalysisCompleted.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence_AnalysisCompleted.php deleted file mode 100644 index 8fb46b02d27..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/DiscoveryOccurrence_AnalysisCompleted.php +++ /dev/null @@ -1,16 +0,0 @@ -grafeas.v1.Distribution - */ -class Distribution extends \Google\Protobuf\Internal\Message -{ - /** - * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) - * denoting the package manager version distributing a package. - * - * Generated from protobuf field string cpe_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $cpe_uri = ''; - /** - * The CPU architecture for which packages in this distribution channel were - * built. - * - * Generated from protobuf field .grafeas.v1.Architecture architecture = 2; - */ - protected $architecture = 0; - /** - * The latest available version of this package in this distribution channel. - * - * Generated from protobuf field .grafeas.v1.Version latest_version = 3; - */ - protected $latest_version = null; - /** - * A freeform string denoting the maintainer of this package. - * - * Generated from protobuf field string maintainer = 4; - */ - protected $maintainer = ''; - /** - * The distribution channel-specific homepage for this package. - * - * Generated from protobuf field string url = 5; - */ - protected $url = ''; - /** - * The distribution channel-specific description of this package. - * - * Generated from protobuf field string description = 6; - */ - protected $description = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $cpe_uri - * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) - * denoting the package manager version distributing a package. - * @type int $architecture - * The CPU architecture for which packages in this distribution channel were - * built. - * @type \Grafeas\V1\Version $latest_version - * The latest available version of this package in this distribution channel. - * @type string $maintainer - * A freeform string denoting the maintainer of this package. - * @type string $url - * The distribution channel-specific homepage for this package. - * @type string $description - * The distribution channel-specific description of this package. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Package::initOnce(); - parent::__construct($data); - } - - /** - * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) - * denoting the package manager version distributing a package. - * - * Generated from protobuf field string cpe_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCpeUri() - { - return $this->cpe_uri; - } - - /** - * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) - * denoting the package manager version distributing a package. - * - * Generated from protobuf field string cpe_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->cpe_uri = $var; - - return $this; - } - - /** - * The CPU architecture for which packages in this distribution channel were - * built. - * - * Generated from protobuf field .grafeas.v1.Architecture architecture = 2; - * @return int - */ - public function getArchitecture() - { - return $this->architecture; - } - - /** - * The CPU architecture for which packages in this distribution channel were - * built. - * - * Generated from protobuf field .grafeas.v1.Architecture architecture = 2; - * @param int $var - * @return $this - */ - public function setArchitecture($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\Architecture::class); - $this->architecture = $var; - - return $this; - } - - /** - * The latest available version of this package in this distribution channel. - * - * Generated from protobuf field .grafeas.v1.Version latest_version = 3; - * @return \Grafeas\V1\Version|null - */ - public function getLatestVersion() - { - return $this->latest_version; - } - - public function hasLatestVersion() - { - return isset($this->latest_version); - } - - public function clearLatestVersion() - { - unset($this->latest_version); - } - - /** - * The latest available version of this package in this distribution channel. - * - * Generated from protobuf field .grafeas.v1.Version latest_version = 3; - * @param \Grafeas\V1\Version $var - * @return $this - */ - public function setLatestVersion($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); - $this->latest_version = $var; - - return $this; - } - - /** - * A freeform string denoting the maintainer of this package. - * - * Generated from protobuf field string maintainer = 4; - * @return string - */ - public function getMaintainer() - { - return $this->maintainer; - } - - /** - * A freeform string denoting the maintainer of this package. - * - * Generated from protobuf field string maintainer = 4; - * @param string $var - * @return $this - */ - public function setMaintainer($var) - { - GPBUtil::checkString($var, True); - $this->maintainer = $var; - - return $this; - } - - /** - * The distribution channel-specific homepage for this package. - * - * Generated from protobuf field string url = 5; - * @return string - */ - public function getUrl() - { - return $this->url; - } - - /** - * The distribution channel-specific homepage for this package. - * - * Generated from protobuf field string url = 5; - * @param string $var - * @return $this - */ - public function setUrl($var) - { - GPBUtil::checkString($var, True); - $this->url = $var; - - return $this; - } - - /** - * The distribution channel-specific description of this package. - * - * Generated from protobuf field string description = 6; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The distribution channel-specific description of this package. - * - * Generated from protobuf field string description = 6; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Envelope.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Envelope.php deleted file mode 100644 index 17bcc1346ae..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Envelope.php +++ /dev/null @@ -1,116 +0,0 @@ -grafeas.v1.Envelope - */ -class Envelope extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field bytes payload = 1; - */ - protected $payload = ''; - /** - * Generated from protobuf field string payload_type = 2; - */ - protected $payload_type = ''; - /** - * Generated from protobuf field repeated .grafeas.v1.EnvelopeSignature signatures = 3; - */ - private $signatures; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $payload - * @type string $payload_type - * @type array<\Grafeas\V1\EnvelopeSignature>|\Google\Protobuf\Internal\RepeatedField $signatures - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Common::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field bytes payload = 1; - * @return string - */ - public function getPayload() - { - return $this->payload; - } - - /** - * Generated from protobuf field bytes payload = 1; - * @param string $var - * @return $this - */ - public function setPayload($var) - { - GPBUtil::checkString($var, False); - $this->payload = $var; - - return $this; - } - - /** - * Generated from protobuf field string payload_type = 2; - * @return string - */ - public function getPayloadType() - { - return $this->payload_type; - } - - /** - * Generated from protobuf field string payload_type = 2; - * @param string $var - * @return $this - */ - public function setPayloadType($var) - { - GPBUtil::checkString($var, True); - $this->payload_type = $var; - - return $this; - } - - /** - * Generated from protobuf field repeated .grafeas.v1.EnvelopeSignature signatures = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSignatures() - { - return $this->signatures; - } - - /** - * Generated from protobuf field repeated .grafeas.v1.EnvelopeSignature signatures = 3; - * @param array<\Grafeas\V1\EnvelopeSignature>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSignatures($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\EnvelopeSignature::class); - $this->signatures = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/EnvelopeSignature.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/EnvelopeSignature.php deleted file mode 100644 index 61ebdc60fbc..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/EnvelopeSignature.php +++ /dev/null @@ -1,85 +0,0 @@ -grafeas.v1.EnvelopeSignature - */ -class EnvelopeSignature extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field bytes sig = 1; - */ - protected $sig = ''; - /** - * Generated from protobuf field string keyid = 2; - */ - protected $keyid = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $sig - * @type string $keyid - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Common::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field bytes sig = 1; - * @return string - */ - public function getSig() - { - return $this->sig; - } - - /** - * Generated from protobuf field bytes sig = 1; - * @param string $var - * @return $this - */ - public function setSig($var) - { - GPBUtil::checkString($var, False); - $this->sig = $var; - - return $this; - } - - /** - * Generated from protobuf field string keyid = 2; - * @return string - */ - public function getKeyid() - { - return $this->keyid; - } - - /** - * Generated from protobuf field string keyid = 2; - * @param string $var - * @return $this - */ - public function setKeyid($var) - { - GPBUtil::checkString($var, True); - $this->keyid = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileHashes.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileHashes.php deleted file mode 100644 index a24ab1da840..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileHashes.php +++ /dev/null @@ -1,68 +0,0 @@ -grafeas.v1.FileHashes - */ -class FileHashes extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Collection of file hashes. - * - * Generated from protobuf field repeated .grafeas.v1.Hash file_hash = 1; - */ - private $file_hash; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Grafeas\V1\Hash>|\Google\Protobuf\Internal\RepeatedField $file_hash - * Required. Collection of file hashes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * Required. Collection of file hashes. - * - * Generated from protobuf field repeated .grafeas.v1.Hash file_hash = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFileHash() - { - return $this->file_hash; - } - - /** - * Required. Collection of file hashes. - * - * Generated from protobuf field repeated .grafeas.v1.Hash file_hash = 1; - * @param array<\Grafeas\V1\Hash>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFileHash($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Hash::class); - $this->file_hash = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileLocation.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileLocation.php deleted file mode 100644 index c7f6d9e7ccc..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/FileLocation.php +++ /dev/null @@ -1,71 +0,0 @@ -grafeas.v1.FileLocation - */ -class FileLocation extends \Google\Protobuf\Internal\Message -{ - /** - * For jars that are contained inside .war files, this filepath - * can indicate the path to war file combined with the path to jar file. - * - * Generated from protobuf field string file_path = 1; - */ - protected $file_path = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $file_path - * For jars that are contained inside .war files, this filepath - * can indicate the path to war file combined with the path to jar file. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Common::initOnce(); - parent::__construct($data); - } - - /** - * For jars that are contained inside .war files, this filepath - * can indicate the path to war file combined with the path to jar file. - * - * Generated from protobuf field string file_path = 1; - * @return string - */ - public function getFilePath() - { - return $this->file_path; - } - - /** - * For jars that are contained inside .war files, this filepath - * can indicate the path to war file combined with the path to jar file. - * - * Generated from protobuf field string file_path = 1; - * @param string $var - * @return $this - */ - public function setFilePath($var) - { - GPBUtil::checkString($var, True); - $this->file_path = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Fingerprint.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Fingerprint.php deleted file mode 100644 index 7191d7383ef..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Fingerprint.php +++ /dev/null @@ -1,151 +0,0 @@ -grafeas.v1.Fingerprint - */ -class Fingerprint extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The layer ID of the final layer in the Docker image's v1 - * representation. - * - * Generated from protobuf field string v1_name = 1; - */ - protected $v1_name = ''; - /** - * Required. The ordered list of v2 blobs that represent a given image. - * - * Generated from protobuf field repeated string v2_blob = 2; - */ - private $v2_blob; - /** - * 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. - * - * Generated from protobuf field string v2_name = 3; - */ - protected $v2_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $v1_name - * Required. The layer ID of the final layer in the Docker image's v1 - * representation. - * @type array|\Google\Protobuf\Internal\RepeatedField $v2_blob - * Required. The ordered list of v2 blobs that represent a given image. - * @type string $v2_name - * 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Image::initOnce(); - parent::__construct($data); - } - - /** - * Required. The layer ID of the final layer in the Docker image's v1 - * representation. - * - * Generated from protobuf field string v1_name = 1; - * @return string - */ - public function getV1Name() - { - return $this->v1_name; - } - - /** - * Required. The layer ID of the final layer in the Docker image's v1 - * representation. - * - * Generated from protobuf field string v1_name = 1; - * @param string $var - * @return $this - */ - public function setV1Name($var) - { - GPBUtil::checkString($var, True); - $this->v1_name = $var; - - return $this; - } - - /** - * Required. The ordered list of v2 blobs that represent a given image. - * - * Generated from protobuf field repeated string v2_blob = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getV2Blob() - { - return $this->v2_blob; - } - - /** - * Required. The ordered list of v2 blobs that represent a given image. - * - * Generated from protobuf field repeated string v2_blob = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setV2Blob($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->v2_blob = $arr; - - 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. - * - * Generated from protobuf field string v2_name = 3; - * @return string - */ - public function getV2Name() - { - return $this->v2_name; - } - - /** - * 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. - * - * Generated from protobuf field string v2_name = 3; - * @param string $var - * @return $this - */ - public function setV2Name($var) - { - GPBUtil::checkString($var, True); - $this->v2_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GerritSourceContext.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GerritSourceContext.php deleted file mode 100644 index 616fb62984a..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GerritSourceContext.php +++ /dev/null @@ -1,184 +0,0 @@ -grafeas.v1.GerritSourceContext - */ -class GerritSourceContext extends \Google\Protobuf\Internal\Message -{ - /** - * The URI of a running Gerrit instance. - * - * Generated from protobuf field string host_uri = 1; - */ - protected $host_uri = ''; - /** - * 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. - * - * Generated from protobuf field string gerrit_project = 2; - */ - protected $gerrit_project = ''; - protected $revision; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $host_uri - * The URI of a running Gerrit instance. - * @type string $gerrit_project - * 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. - * @type string $revision_id - * A revision (commit) ID. - * @type \Grafeas\V1\AliasContext $alias_context - * An alias, which may be a branch or tag. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * The URI of a running Gerrit instance. - * - * Generated from protobuf field string host_uri = 1; - * @return string - */ - public function getHostUri() - { - return $this->host_uri; - } - - /** - * The URI of a running Gerrit instance. - * - * Generated from protobuf field string host_uri = 1; - * @param string $var - * @return $this - */ - public function setHostUri($var) - { - GPBUtil::checkString($var, True); - $this->host_uri = $var; - - 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. - * - * Generated from protobuf field string gerrit_project = 2; - * @return string - */ - public function getGerritProject() - { - return $this->gerrit_project; - } - - /** - * 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. - * - * Generated from protobuf field string gerrit_project = 2; - * @param string $var - * @return $this - */ - public function setGerritProject($var) - { - GPBUtil::checkString($var, True); - $this->gerrit_project = $var; - - return $this; - } - - /** - * A revision (commit) ID. - * - * Generated from protobuf field string revision_id = 3; - * @return string - */ - public function getRevisionId() - { - return $this->readOneof(3); - } - - public function hasRevisionId() - { - return $this->hasOneof(3); - } - - /** - * A revision (commit) ID. - * - * Generated from protobuf field string revision_id = 3; - * @param string $var - * @return $this - */ - public function setRevisionId($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * An alias, which may be a branch or tag. - * - * Generated from protobuf field .grafeas.v1.AliasContext alias_context = 4; - * @return \Grafeas\V1\AliasContext|null - */ - public function getAliasContext() - { - return $this->readOneof(4); - } - - public function hasAliasContext() - { - return $this->hasOneof(4); - } - - /** - * An alias, which may be a branch or tag. - * - * Generated from protobuf field .grafeas.v1.AliasContext alias_context = 4; - * @param \Grafeas\V1\AliasContext $var - * @return $this - */ - public function setAliasContext($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\AliasContext::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getRevision() - { - return $this->whichOneof("revision"); - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetNoteRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetNoteRequest.php deleted file mode 100644 index 1f34634c9e3..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetNoteRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -grafeas.v1.GetNoteRequest - */ -class GetNoteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceNoteRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceNoteRequest.php deleted file mode 100644 index 16072c0db57..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceNoteRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -grafeas.v1.GetOccurrenceNoteRequest - */ -class GetOccurrenceNoteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceRequest.php deleted file mode 100644 index 44e659ea0b8..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GetOccurrenceRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -grafeas.v1.GetOccurrenceRequest - */ -class GetOccurrenceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GitSourceContext.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GitSourceContext.php deleted file mode 100644 index 6eb31ad84fe..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GitSourceContext.php +++ /dev/null @@ -1,102 +0,0 @@ -grafeas.v1.GitSourceContext - */ -class GitSourceContext extends \Google\Protobuf\Internal\Message -{ - /** - * Git repository URL. - * - * Generated from protobuf field string url = 1; - */ - protected $url = ''; - /** - * Git commit hash. - * - * Generated from protobuf field string revision_id = 2; - */ - protected $revision_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $url - * Git repository URL. - * @type string $revision_id - * Git commit hash. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * Git repository URL. - * - * Generated from protobuf field string url = 1; - * @return string - */ - public function getUrl() - { - return $this->url; - } - - /** - * Git repository URL. - * - * Generated from protobuf field string url = 1; - * @param string $var - * @return $this - */ - public function setUrl($var) - { - GPBUtil::checkString($var, True); - $this->url = $var; - - return $this; - } - - /** - * Git commit hash. - * - * Generated from protobuf field string revision_id = 2; - * @return string - */ - public function getRevisionId() - { - return $this->revision_id; - } - - /** - * Git commit hash. - * - * Generated from protobuf field string revision_id = 2; - * @param string $var - * @return $this - */ - public function setRevisionId($var) - { - GPBUtil::checkString($var, True); - $this->revision_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GrafeasGrpcClient.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GrafeasGrpcClient.php deleted file mode 100644 index 5c3784661a8..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/GrafeasGrpcClient.php +++ /dev/null @@ -1,263 +0,0 @@ -_simpleRequest('/grafeas.v1.Grafeas/GetOccurrence', - $argument, - ['\Grafeas\V1\Occurrence', 'decode'], - $metadata, $options); - } - - /** - * Lists occurrences for the specified project. - * @param \Grafeas\V1\ListOccurrencesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListOccurrences(\Grafeas\V1\ListOccurrencesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/ListOccurrences', - $argument, - ['\Grafeas\V1\ListOccurrencesResponse', 'decode'], - $metadata, $options); - } - - /** - * Deletes the specified occurrence. For example, use this method to delete an - * occurrence when the occurrence is no longer applicable for the given - * resource. - * @param \Grafeas\V1\DeleteOccurrenceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteOccurrence(\Grafeas\V1\DeleteOccurrenceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/DeleteOccurrence', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Creates a new occurrence. - * @param \Grafeas\V1\CreateOccurrenceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateOccurrence(\Grafeas\V1\CreateOccurrenceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/CreateOccurrence', - $argument, - ['\Grafeas\V1\Occurrence', 'decode'], - $metadata, $options); - } - - /** - * Creates new occurrences in batch. - * @param \Grafeas\V1\BatchCreateOccurrencesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function BatchCreateOccurrences(\Grafeas\V1\BatchCreateOccurrencesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/BatchCreateOccurrences', - $argument, - ['\Grafeas\V1\BatchCreateOccurrencesResponse', 'decode'], - $metadata, $options); - } - - /** - * Updates the specified occurrence. - * @param \Grafeas\V1\UpdateOccurrenceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateOccurrence(\Grafeas\V1\UpdateOccurrenceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/UpdateOccurrence', - $argument, - ['\Grafeas\V1\Occurrence', 'decode'], - $metadata, $options); - } - - /** - * Gets the note attached to the specified occurrence. Consumer projects can - * use this method to get a note that belongs to a provider project. - * @param \Grafeas\V1\GetOccurrenceNoteRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetOccurrenceNote(\Grafeas\V1\GetOccurrenceNoteRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/GetOccurrenceNote', - $argument, - ['\Grafeas\V1\Note', 'decode'], - $metadata, $options); - } - - /** - * Gets the specified note. - * @param \Grafeas\V1\GetNoteRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetNote(\Grafeas\V1\GetNoteRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/GetNote', - $argument, - ['\Grafeas\V1\Note', 'decode'], - $metadata, $options); - } - - /** - * Lists notes for the specified project. - * @param \Grafeas\V1\ListNotesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListNotes(\Grafeas\V1\ListNotesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/ListNotes', - $argument, - ['\Grafeas\V1\ListNotesResponse', 'decode'], - $metadata, $options); - } - - /** - * Deletes the specified note. - * @param \Grafeas\V1\DeleteNoteRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteNote(\Grafeas\V1\DeleteNoteRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/DeleteNote', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Creates a new note. - * @param \Grafeas\V1\CreateNoteRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateNote(\Grafeas\V1\CreateNoteRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/CreateNote', - $argument, - ['\Grafeas\V1\Note', 'decode'], - $metadata, $options); - } - - /** - * Creates new notes in batch. - * @param \Grafeas\V1\BatchCreateNotesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function BatchCreateNotes(\Grafeas\V1\BatchCreateNotesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/BatchCreateNotes', - $argument, - ['\Grafeas\V1\BatchCreateNotesResponse', 'decode'], - $metadata, $options); - } - - /** - * Updates the specified note. - * @param \Grafeas\V1\UpdateNoteRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateNote(\Grafeas\V1\UpdateNoteRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/UpdateNote', - $argument, - ['\Grafeas\V1\Note', 'decode'], - $metadata, $options); - } - - /** - * Lists occurrences referencing the specified note. Provider projects can use - * this method to get all occurrences across consumer projects referencing the - * specified note. - * @param \Grafeas\V1\ListNoteOccurrencesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListNoteOccurrences(\Grafeas\V1\ListNoteOccurrencesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/grafeas.v1.Grafeas/ListNoteOccurrences', - $argument, - ['\Grafeas\V1\ListNoteOccurrencesResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Hash.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Hash.php deleted file mode 100644 index a6f6d1b8ae0..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Hash.php +++ /dev/null @@ -1,101 +0,0 @@ -grafeas.v1.Hash - */ -class Hash extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The type of hash that was performed, e.g. "SHA-256". - * - * Generated from protobuf field string type = 1; - */ - protected $type = ''; - /** - * Required. The hash value. - * - * Generated from protobuf field bytes value = 2; - */ - protected $value = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $type - * Required. The type of hash that was performed, e.g. "SHA-256". - * @type string $value - * Required. The hash value. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * Required. The type of hash that was performed, e.g. "SHA-256". - * - * Generated from protobuf field string type = 1; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * Required. The type of hash that was performed, e.g. "SHA-256". - * - * Generated from protobuf field string type = 1; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Required. The hash value. - * - * Generated from protobuf field bytes value = 2; - * @return string - */ - public function getValue() - { - return $this->value; - } - - /** - * Required. The hash value. - * - * Generated from protobuf field bytes value = 2; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, False); - $this->value = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageNote.php deleted file mode 100644 index 661c9908716..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageNote.php +++ /dev/null @@ -1,119 +0,0 @@ - - * Or an equivalent reference, e.g., a tag of the resource_url. - * - * Generated from protobuf message grafeas.v1.ImageNote - */ -class ImageNote extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Immutable. The resource_url for the resource representing the - * basis of associated occurrence images. - * - * Generated from protobuf field string resource_url = 1; - */ - protected $resource_url = ''; - /** - * Required. Immutable. The fingerprint of the base image. - * - * Generated from protobuf field .grafeas.v1.Fingerprint fingerprint = 2; - */ - protected $fingerprint = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $resource_url - * Required. Immutable. The resource_url for the resource representing the - * basis of associated occurrence images. - * @type \Grafeas\V1\Fingerprint $fingerprint - * Required. Immutable. The fingerprint of the base image. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Image::initOnce(); - parent::__construct($data); - } - - /** - * Required. Immutable. The resource_url for the resource representing the - * basis of associated occurrence images. - * - * Generated from protobuf field string resource_url = 1; - * @return string - */ - public function getResourceUrl() - { - return $this->resource_url; - } - - /** - * Required. Immutable. The resource_url for the resource representing the - * basis of associated occurrence images. - * - * Generated from protobuf field string resource_url = 1; - * @param string $var - * @return $this - */ - public function setResourceUrl($var) - { - GPBUtil::checkString($var, True); - $this->resource_url = $var; - - return $this; - } - - /** - * Required. Immutable. The fingerprint of the base image. - * - * Generated from protobuf field .grafeas.v1.Fingerprint fingerprint = 2; - * @return \Grafeas\V1\Fingerprint|null - */ - public function getFingerprint() - { - return $this->fingerprint; - } - - public function hasFingerprint() - { - return isset($this->fingerprint); - } - - public function clearFingerprint() - { - unset($this->fingerprint); - } - - /** - * Required. Immutable. The fingerprint of the base image. - * - * Generated from protobuf field .grafeas.v1.Fingerprint fingerprint = 2; - * @param \Grafeas\V1\Fingerprint $var - * @return $this - */ - public function setFingerprint($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Fingerprint::class); - $this->fingerprint = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageOccurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageOccurrence.php deleted file mode 100644 index e6c64fc037e..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ImageOccurrence.php +++ /dev/null @@ -1,197 +0,0 @@ -. - * - * Generated from protobuf message grafeas.v1.ImageOccurrence - */ -class ImageOccurrence extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The fingerprint of the derived image. - * - * Generated from protobuf field .grafeas.v1.Fingerprint fingerprint = 1; - */ - protected $fingerprint = null; - /** - * Output only. The number of layers by which this image differs from the - * associated image basis. - * - * Generated from protobuf field int32 distance = 2; - */ - protected $distance = 0; - /** - * 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. - * - * Generated from protobuf field repeated .grafeas.v1.Layer layer_info = 3; - */ - private $layer_info; - /** - * Output only. This contains the base image URL for the derived image - * occurrence. - * - * Generated from protobuf field string base_resource_url = 4; - */ - protected $base_resource_url = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\Fingerprint $fingerprint - * Required. The fingerprint of the derived image. - * @type int $distance - * Output only. The number of layers by which this image differs from the - * associated image basis. - * @type array<\Grafeas\V1\Layer>|\Google\Protobuf\Internal\RepeatedField $layer_info - * 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. - * @type string $base_resource_url - * Output only. This contains the base image URL for the derived image - * occurrence. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Image::initOnce(); - parent::__construct($data); - } - - /** - * Required. The fingerprint of the derived image. - * - * Generated from protobuf field .grafeas.v1.Fingerprint fingerprint = 1; - * @return \Grafeas\V1\Fingerprint|null - */ - public function getFingerprint() - { - return $this->fingerprint; - } - - public function hasFingerprint() - { - return isset($this->fingerprint); - } - - public function clearFingerprint() - { - unset($this->fingerprint); - } - - /** - * Required. The fingerprint of the derived image. - * - * Generated from protobuf field .grafeas.v1.Fingerprint fingerprint = 1; - * @param \Grafeas\V1\Fingerprint $var - * @return $this - */ - public function setFingerprint($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Fingerprint::class); - $this->fingerprint = $var; - - return $this; - } - - /** - * Output only. The number of layers by which this image differs from the - * associated image basis. - * - * Generated from protobuf field int32 distance = 2; - * @return int - */ - public function getDistance() - { - return $this->distance; - } - - /** - * Output only. The number of layers by which this image differs from the - * associated image basis. - * - * Generated from protobuf field int32 distance = 2; - * @param int $var - * @return $this - */ - public function setDistance($var) - { - GPBUtil::checkInt32($var); - $this->distance = $var; - - 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. - * - * Generated from protobuf field repeated .grafeas.v1.Layer layer_info = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLayerInfo() - { - return $this->layer_info; - } - - /** - * 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. - * - * Generated from protobuf field repeated .grafeas.v1.Layer layer_info = 3; - * @param array<\Grafeas\V1\Layer>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLayerInfo($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Layer::class); - $this->layer_info = $arr; - - return $this; - } - - /** - * Output only. This contains the base image URL for the derived image - * occurrence. - * - * Generated from protobuf field string base_resource_url = 4; - * @return string - */ - public function getBaseResourceUrl() - { - return $this->base_resource_url; - } - - /** - * Output only. This contains the base image URL for the derived image - * occurrence. - * - * Generated from protobuf field string base_resource_url = 4; - * @param string $var - * @return $this - */ - public function setBaseResourceUrl($var) - { - GPBUtil::checkString($var, True); - $this->base_resource_url = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoProvenance.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoProvenance.php deleted file mode 100644 index 74cc83a629c..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoProvenance.php +++ /dev/null @@ -1,214 +0,0 @@ -grafeas.v1.InTotoProvenance - */ -class InTotoProvenance extends \Google\Protobuf\Internal\Message -{ - /** - * required - * - * Generated from protobuf field .grafeas.v1.BuilderConfig builder_config = 1; - */ - protected $builder_config = null; - /** - * Identifies the configuration used for the build. - * When combined with materials, this SHOULD fully describe the build, - * such that re-running this recipe results in bit-for-bit identical output - * (if the build is reproducible). - * - * Generated from protobuf field .grafeas.v1.Recipe recipe = 2; - */ - protected $recipe = null; - /** - * Generated from protobuf field .grafeas.v1.Metadata metadata = 3; - */ - protected $metadata = null; - /** - * The collection of artifacts that influenced the build including sources, - * dependencies, build tools, base images, and so on. This is considered to be - * incomplete unless metadata.completeness.materials is true. Unset or null is - * equivalent to empty. - * - * Generated from protobuf field repeated string materials = 4; - */ - private $materials; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\BuilderConfig $builder_config - * required - * @type \Grafeas\V1\Recipe $recipe - * Identifies the configuration used for the build. - * When combined with materials, this SHOULD fully describe the build, - * such that re-running this recipe results in bit-for-bit identical output - * (if the build is reproducible). - * @type \Grafeas\V1\Metadata $metadata - * @type array|\Google\Protobuf\Internal\RepeatedField $materials - * The collection of artifacts that influenced the build including sources, - * dependencies, build tools, base images, and so on. This is considered to be - * incomplete unless metadata.completeness.materials is true. Unset or null is - * equivalent to empty. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\IntotoProvenance::initOnce(); - parent::__construct($data); - } - - /** - * required - * - * Generated from protobuf field .grafeas.v1.BuilderConfig builder_config = 1; - * @return \Grafeas\V1\BuilderConfig|null - */ - public function getBuilderConfig() - { - return $this->builder_config; - } - - public function hasBuilderConfig() - { - return isset($this->builder_config); - } - - public function clearBuilderConfig() - { - unset($this->builder_config); - } - - /** - * required - * - * Generated from protobuf field .grafeas.v1.BuilderConfig builder_config = 1; - * @param \Grafeas\V1\BuilderConfig $var - * @return $this - */ - public function setBuilderConfig($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\BuilderConfig::class); - $this->builder_config = $var; - - return $this; - } - - /** - * Identifies the configuration used for the build. - * When combined with materials, this SHOULD fully describe the build, - * such that re-running this recipe results in bit-for-bit identical output - * (if the build is reproducible). - * - * Generated from protobuf field .grafeas.v1.Recipe recipe = 2; - * @return \Grafeas\V1\Recipe|null - */ - public function getRecipe() - { - return $this->recipe; - } - - public function hasRecipe() - { - return isset($this->recipe); - } - - public function clearRecipe() - { - unset($this->recipe); - } - - /** - * Identifies the configuration used for the build. - * When combined with materials, this SHOULD fully describe the build, - * such that re-running this recipe results in bit-for-bit identical output - * (if the build is reproducible). - * - * Generated from protobuf field .grafeas.v1.Recipe recipe = 2; - * @param \Grafeas\V1\Recipe $var - * @return $this - */ - public function setRecipe($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Recipe::class); - $this->recipe = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.Metadata metadata = 3; - * @return \Grafeas\V1\Metadata|null - */ - public function getMetadata() - { - return $this->metadata; - } - - public function hasMetadata() - { - return isset($this->metadata); - } - - public function clearMetadata() - { - unset($this->metadata); - } - - /** - * Generated from protobuf field .grafeas.v1.Metadata metadata = 3; - * @param \Grafeas\V1\Metadata $var - * @return $this - */ - public function setMetadata($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Metadata::class); - $this->metadata = $var; - - return $this; - } - - /** - * The collection of artifacts that influenced the build including sources, - * dependencies, build tools, base images, and so on. This is considered to be - * incomplete unless metadata.completeness.materials is true. Unset or null is - * equivalent to empty. - * - * Generated from protobuf field repeated string materials = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMaterials() - { - return $this->materials; - } - - /** - * The collection of artifacts that influenced the build including sources, - * dependencies, build tools, base images, and so on. This is considered to be - * incomplete unless metadata.completeness.materials is true. Unset or null is - * equivalent to empty. - * - * Generated from protobuf field repeated string materials = 4; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMaterials($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->materials = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoStatement.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoStatement.php deleted file mode 100644 index 93a86b0dd50..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/InTotoStatement.php +++ /dev/null @@ -1,224 +0,0 @@ -grafeas.v1.InTotoStatement - */ -class InTotoStatement extends \Google\Protobuf\Internal\Message -{ - /** - * Always `https://in-toto.io/Statement/v0.1`. - * - * Generated from protobuf field string type = 1 [json_name = "_type"]; - */ - protected $type = ''; - /** - * Generated from protobuf field repeated .grafeas.v1.Subject subject = 2; - */ - private $subject; - /** - * `https://slsa.dev/provenance/v0.1` for SlsaProvenance. - * - * Generated from protobuf field string predicate_type = 3; - */ - protected $predicate_type = ''; - protected $predicate; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $type - * Always `https://in-toto.io/Statement/v0.1`. - * @type array<\Grafeas\V1\Subject>|\Google\Protobuf\Internal\RepeatedField $subject - * @type string $predicate_type - * `https://slsa.dev/provenance/v0.1` for SlsaProvenance. - * @type \Grafeas\V1\InTotoProvenance $provenance - * @type \Grafeas\V1\SlsaProvenance $slsa_provenance - * @type \Grafeas\V1\SlsaProvenanceZeroTwo $slsa_provenance_zero_two - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\IntotoStatement::initOnce(); - parent::__construct($data); - } - - /** - * Always `https://in-toto.io/Statement/v0.1`. - * - * Generated from protobuf field string type = 1 [json_name = "_type"]; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * Always `https://in-toto.io/Statement/v0.1`. - * - * Generated from protobuf field string type = 1 [json_name = "_type"]; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Generated from protobuf field repeated .grafeas.v1.Subject subject = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSubject() - { - return $this->subject; - } - - /** - * Generated from protobuf field repeated .grafeas.v1.Subject subject = 2; - * @param array<\Grafeas\V1\Subject>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSubject($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Subject::class); - $this->subject = $arr; - - return $this; - } - - /** - * `https://slsa.dev/provenance/v0.1` for SlsaProvenance. - * - * Generated from protobuf field string predicate_type = 3; - * @return string - */ - public function getPredicateType() - { - return $this->predicate_type; - } - - /** - * `https://slsa.dev/provenance/v0.1` for SlsaProvenance. - * - * Generated from protobuf field string predicate_type = 3; - * @param string $var - * @return $this - */ - public function setPredicateType($var) - { - GPBUtil::checkString($var, True); - $this->predicate_type = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.InTotoProvenance provenance = 4; - * @return \Grafeas\V1\InTotoProvenance|null - */ - public function getProvenance() - { - return $this->readOneof(4); - } - - public function hasProvenance() - { - return $this->hasOneof(4); - } - - /** - * Generated from protobuf field .grafeas.v1.InTotoProvenance provenance = 4; - * @param \Grafeas\V1\InTotoProvenance $var - * @return $this - */ - public function setProvenance($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\InTotoProvenance::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenance slsa_provenance = 5; - * @return \Grafeas\V1\SlsaProvenance|null - */ - public function getSlsaProvenance() - { - return $this->readOneof(5); - } - - public function hasSlsaProvenance() - { - return $this->hasOneof(5); - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenance slsa_provenance = 5; - * @param \Grafeas\V1\SlsaProvenance $var - * @return $this - */ - public function setSlsaProvenance($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenance::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo slsa_provenance_zero_two = 6; - * @return \Grafeas\V1\SlsaProvenanceZeroTwo|null - */ - public function getSlsaProvenanceZeroTwo() - { - return $this->readOneof(6); - } - - public function hasSlsaProvenanceZeroTwo() - { - return $this->hasOneof(6); - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo slsa_provenance_zero_two = 6; - * @param \Grafeas\V1\SlsaProvenanceZeroTwo $var - * @return $this - */ - public function setSlsaProvenanceZeroTwo($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenanceZeroTwo::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * @return string - */ - public function getPredicate() - { - return $this->whichOneof("predicate"); - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Jwt.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Jwt.php deleted file mode 100644 index 3b9e9a5ece4..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Jwt.php +++ /dev/null @@ -1,73 +0,0 @@ -grafeas.v1.Jwt - */ -class Jwt extends \Google\Protobuf\Internal\Message -{ - /** - * The compact encoding of a JWS, which is always three base64 encoded strings - * joined by periods. For details, see: - * https://tools.ietf.org/html/rfc7515.html#section-3.1 - * - * Generated from protobuf field string compact_jwt = 1; - */ - protected $compact_jwt = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $compact_jwt - * The compact encoding of a JWS, which is always three base64 encoded strings - * joined by periods. For details, see: - * https://tools.ietf.org/html/rfc7515.html#section-3.1 - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Attestation::initOnce(); - parent::__construct($data); - } - - /** - * The compact encoding of a JWS, which is always three base64 encoded strings - * joined by periods. For details, see: - * https://tools.ietf.org/html/rfc7515.html#section-3.1 - * - * Generated from protobuf field string compact_jwt = 1; - * @return string - */ - public function getCompactJwt() - { - return $this->compact_jwt; - } - - /** - * The compact encoding of a JWS, which is always three base64 encoded strings - * joined by periods. For details, see: - * https://tools.ietf.org/html/rfc7515.html#section-3.1 - * - * Generated from protobuf field string compact_jwt = 1; - * @param string $var - * @return $this - */ - public function setCompactJwt($var) - { - GPBUtil::checkString($var, True); - $this->compact_jwt = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Layer.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Layer.php deleted file mode 100644 index 429ce63f2c3..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Layer.php +++ /dev/null @@ -1,105 +0,0 @@ -grafeas.v1.Layer - */ -class Layer extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The recovered Dockerfile directive used to construct this layer. - * See https://docs.docker.com/engine/reference/builder/ for more information. - * - * Generated from protobuf field string directive = 1; - */ - protected $directive = ''; - /** - * The recovered arguments to the Dockerfile directive. - * - * Generated from protobuf field string arguments = 2; - */ - protected $arguments = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $directive - * Required. The recovered Dockerfile directive used to construct this layer. - * See https://docs.docker.com/engine/reference/builder/ for more information. - * @type string $arguments - * The recovered arguments to the Dockerfile directive. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Image::initOnce(); - parent::__construct($data); - } - - /** - * Required. The recovered Dockerfile directive used to construct this layer. - * See https://docs.docker.com/engine/reference/builder/ for more information. - * - * Generated from protobuf field string directive = 1; - * @return string - */ - public function getDirective() - { - return $this->directive; - } - - /** - * Required. The recovered Dockerfile directive used to construct this layer. - * See https://docs.docker.com/engine/reference/builder/ for more information. - * - * Generated from protobuf field string directive = 1; - * @param string $var - * @return $this - */ - public function setDirective($var) - { - GPBUtil::checkString($var, True); - $this->directive = $var; - - return $this; - } - - /** - * The recovered arguments to the Dockerfile directive. - * - * Generated from protobuf field string arguments = 2; - * @return string - */ - public function getArguments() - { - return $this->arguments; - } - - /** - * The recovered arguments to the Dockerfile directive. - * - * Generated from protobuf field string arguments = 2; - * @param string $var - * @return $this - */ - public function setArguments($var) - { - GPBUtil::checkString($var, True); - $this->arguments = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/License.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/License.php deleted file mode 100644 index cf2409f0739..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/License.php +++ /dev/null @@ -1,117 +0,0 @@ -grafeas.v1.License - */ -class License extends \Google\Protobuf\Internal\Message -{ - /** - * Often a single license can be used to represent the licensing terms. - * Sometimes it is necessary to include a choice of one or more licenses - * or some combination of license identifiers. - * Examples: "LGPL-2.1-only OR MIT", "LGPL-2.1-only AND MIT", - * "GPL-2.0-or-later WITH Bison-exception-2.2". - * - * Generated from protobuf field string expression = 1; - */ - protected $expression = ''; - /** - * Comments - * - * Generated from protobuf field string comments = 2; - */ - protected $comments = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $expression - * Often a single license can be used to represent the licensing terms. - * Sometimes it is necessary to include a choice of one or more licenses - * or some combination of license identifiers. - * Examples: "LGPL-2.1-only OR MIT", "LGPL-2.1-only AND MIT", - * "GPL-2.0-or-later WITH Bison-exception-2.2". - * @type string $comments - * Comments - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Common::initOnce(); - parent::__construct($data); - } - - /** - * Often a single license can be used to represent the licensing terms. - * Sometimes it is necessary to include a choice of one or more licenses - * or some combination of license identifiers. - * Examples: "LGPL-2.1-only OR MIT", "LGPL-2.1-only AND MIT", - * "GPL-2.0-or-later WITH Bison-exception-2.2". - * - * Generated from protobuf field string expression = 1; - * @return string - */ - public function getExpression() - { - return $this->expression; - } - - /** - * Often a single license can be used to represent the licensing terms. - * Sometimes it is necessary to include a choice of one or more licenses - * or some combination of license identifiers. - * Examples: "LGPL-2.1-only OR MIT", "LGPL-2.1-only AND MIT", - * "GPL-2.0-or-later WITH Bison-exception-2.2". - * - * Generated from protobuf field string expression = 1; - * @param string $var - * @return $this - */ - public function setExpression($var) - { - GPBUtil::checkString($var, True); - $this->expression = $var; - - return $this; - } - - /** - * Comments - * - * Generated from protobuf field string comments = 2; - * @return string - */ - public function getComments() - { - return $this->comments; - } - - /** - * Comments - * - * Generated from protobuf field string comments = 2; - * @param string $var - * @return $this - */ - public function setComments($var) - { - GPBUtil::checkString($var, True); - $this->comments = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesRequest.php deleted file mode 100644 index 2a4ff134f9e..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesRequest.php +++ /dev/null @@ -1,173 +0,0 @@ -grafeas.v1.ListNoteOccurrencesRequest - */ -class ListNoteOccurrencesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the note to list occurrences for in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * The filter expression. - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Number of occurrences to return in the list. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string page_token = 4; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the note to list occurrences for in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @type string $filter - * The filter expression. - * @type int $page_size - * Number of occurrences to return in the list. - * @type string $page_token - * Token to provide to skip to a particular spot in the list. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the note to list occurrences for in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the note to list occurrences for in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The filter expression. - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * The filter expression. - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Number of occurrences to return in the list. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Number of occurrences to return in the list. - * - * Generated from protobuf field int32 page_size = 3; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string page_token = 4; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string page_token = 4; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesResponse.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesResponse.php deleted file mode 100644 index d76a8a59df9..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNoteOccurrencesResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -grafeas.v1.ListNoteOccurrencesResponse - */ -class ListNoteOccurrencesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The occurrences attached to the specified note. - * - * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; - */ - private $occurrences; - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $occurrences - * The occurrences attached to the specified note. - * @type string $next_page_token - * Token to provide to skip to a particular spot in the list. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The occurrences attached to the specified note. - * - * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getOccurrences() - { - return $this->occurrences; - } - - /** - * The occurrences attached to the specified note. - * - * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; - * @param array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setOccurrences($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Occurrence::class); - $this->occurrences = $arr; - - return $this; - } - - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesRequest.php deleted file mode 100644 index 79a61227145..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesRequest.php +++ /dev/null @@ -1,177 +0,0 @@ -grafeas.v1.ListNotesRequest - */ -class ListNotesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the project to list notes for in the form of - * `projects/[PROJECT_ID]`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The filter expression. - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Number of notes to return in the list. Must be positive. Max allowed page - * size is 1000. If not specified, page size defaults to 20. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string page_token = 4; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * The name of the project to list notes for in the form of - * `projects/[PROJECT_ID]`. - * @type string $filter - * The filter expression. - * @type int $page_size - * Number of notes to return in the list. Must be positive. Max allowed page - * size is 1000. If not specified, page size defaults to 20. - * @type string $page_token - * Token to provide to skip to a particular spot in the list. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the project to list notes for in the form of - * `projects/[PROJECT_ID]`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The name of the project to list notes for in the form of - * `projects/[PROJECT_ID]`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The filter expression. - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * The filter expression. - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Number of notes to return in the list. Must be positive. Max allowed page - * size is 1000. If not specified, page size defaults to 20. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Number of notes to return in the list. Must be positive. Max allowed page - * size is 1000. If not specified, page size defaults to 20. - * - * Generated from protobuf field int32 page_size = 3; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string page_token = 4; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string page_token = 4; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesResponse.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesResponse.php deleted file mode 100644 index 22c8bc22a25..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListNotesResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -grafeas.v1.ListNotesResponse - */ -class ListNotesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The notes requested. - * - * Generated from protobuf field repeated .grafeas.v1.Note notes = 1; - */ - private $notes; - /** - * 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. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Grafeas\V1\Note>|\Google\Protobuf\Internal\RepeatedField $notes - * The notes requested. - * @type string $next_page_token - * 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The notes requested. - * - * Generated from protobuf field repeated .grafeas.v1.Note notes = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNotes() - { - return $this->notes; - } - - /** - * The notes requested. - * - * Generated from protobuf field repeated .grafeas.v1.Note notes = 1; - * @param array<\Grafeas\V1\Note>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNotes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Note::class); - $this->notes = $arr; - - 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. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * 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. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesRequest.php deleted file mode 100644 index e6fb4083763..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesRequest.php +++ /dev/null @@ -1,177 +0,0 @@ -grafeas.v1.ListOccurrencesRequest - */ -class ListOccurrencesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the project to list occurrences for in the form of - * `projects/[PROJECT_ID]`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The filter expression. - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Number of occurrences to return in the list. Must be positive. Max allowed - * page size is 1000. If not specified, page size defaults to 20. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string page_token = 4; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * The name of the project to list occurrences for in the form of - * `projects/[PROJECT_ID]`. - * @type string $filter - * The filter expression. - * @type int $page_size - * Number of occurrences to return in the list. Must be positive. Max allowed - * page size is 1000. If not specified, page size defaults to 20. - * @type string $page_token - * Token to provide to skip to a particular spot in the list. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the project to list occurrences for in the form of - * `projects/[PROJECT_ID]`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The name of the project to list occurrences for in the form of - * `projects/[PROJECT_ID]`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The filter expression. - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * The filter expression. - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Number of occurrences to return in the list. Must be positive. Max allowed - * page size is 1000. If not specified, page size defaults to 20. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Number of occurrences to return in the list. Must be positive. Max allowed - * page size is 1000. If not specified, page size defaults to 20. - * - * Generated from protobuf field int32 page_size = 3; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string page_token = 4; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string page_token = 4; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesResponse.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesResponse.php deleted file mode 100644 index c698cc7476a..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ListOccurrencesResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -grafeas.v1.ListOccurrencesResponse - */ -class ListOccurrencesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The occurrences requested. - * - * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; - */ - private $occurrences; - /** - * 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. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $occurrences - * The occurrences requested. - * @type string $next_page_token - * 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The occurrences requested. - * - * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getOccurrences() - { - return $this->occurrences; - } - - /** - * The occurrences requested. - * - * Generated from protobuf field repeated .grafeas.v1.Occurrence occurrences = 1; - * @param array<\Grafeas\V1\Occurrence>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setOccurrences($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Occurrence::class); - $this->occurrences = $arr; - - 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. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * 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. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Location.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Location.php deleted file mode 100644 index b8381eca4d4..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Location.php +++ /dev/null @@ -1,154 +0,0 @@ -grafeas.v1.Location - */ -class Location extends \Google\Protobuf\Internal\Message -{ - /** - * Deprecated. - * The CPE URI in [CPE format](https://cpe.mitre.org/specification/) - * - * Generated from protobuf field string cpe_uri = 1; - */ - protected $cpe_uri = ''; - /** - * Deprecated. - * The version installed at this location. - * - * Generated from protobuf field .grafeas.v1.Version version = 2; - */ - protected $version = null; - /** - * The path from which we gathered that this package/version is installed. - * - * Generated from protobuf field string path = 3; - */ - protected $path = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $cpe_uri - * Deprecated. - * The CPE URI in [CPE format](https://cpe.mitre.org/specification/) - * @type \Grafeas\V1\Version $version - * Deprecated. - * The version installed at this location. - * @type string $path - * The path from which we gathered that this package/version is installed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Package::initOnce(); - parent::__construct($data); - } - - /** - * Deprecated. - * The CPE URI in [CPE format](https://cpe.mitre.org/specification/) - * - * Generated from protobuf field string cpe_uri = 1; - * @return string - */ - public function getCpeUri() - { - return $this->cpe_uri; - } - - /** - * Deprecated. - * The CPE URI in [CPE format](https://cpe.mitre.org/specification/) - * - * Generated from protobuf field string cpe_uri = 1; - * @param string $var - * @return $this - */ - public function setCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->cpe_uri = $var; - - return $this; - } - - /** - * Deprecated. - * The version installed at this location. - * - * Generated from protobuf field .grafeas.v1.Version version = 2; - * @return \Grafeas\V1\Version|null - */ - public function getVersion() - { - return $this->version; - } - - public function hasVersion() - { - return isset($this->version); - } - - public function clearVersion() - { - unset($this->version); - } - - /** - * Deprecated. - * The version installed at this location. - * - * Generated from protobuf field .grafeas.v1.Version version = 2; - * @param \Grafeas\V1\Version $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); - $this->version = $var; - - return $this; - } - - /** - * The path from which we gathered that this package/version is installed. - * - * Generated from protobuf field string path = 3; - * @return string - */ - public function getPath() - { - return $this->path; - } - - /** - * The path from which we gathered that this package/version is installed. - * - * Generated from protobuf field string path = 3; - * @param string $var - * @return $this - */ - public function setPath($var) - { - GPBUtil::checkString($var, True); - $this->path = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Metadata.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Metadata.php deleted file mode 100644 index 496b347e8c5..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Metadata.php +++ /dev/null @@ -1,249 +0,0 @@ -grafeas.v1.Metadata - */ -class Metadata extends \Google\Protobuf\Internal\Message -{ - /** - * Identifies the particular build invocation, which can be useful for finding - * associated logs or other ad-hoc analysis. The value SHOULD be globally - * unique, per in-toto Provenance spec. - * - * Generated from protobuf field string build_invocation_id = 1; - */ - protected $build_invocation_id = ''; - /** - * The timestamp of when the build started. - * - * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; - */ - protected $build_started_on = null; - /** - * The timestamp of when the build completed. - * - * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; - */ - protected $build_finished_on = null; - /** - * Indicates that the builder claims certain fields in this message to be - * complete. - * - * Generated from protobuf field .grafeas.v1.Completeness completeness = 4; - */ - protected $completeness = null; - /** - * If true, the builder claims that running the recipe on materials will - * produce bit-for-bit identical output. - * - * Generated from protobuf field bool reproducible = 5; - */ - protected $reproducible = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $build_invocation_id - * Identifies the particular build invocation, which can be useful for finding - * associated logs or other ad-hoc analysis. The value SHOULD be globally - * unique, per in-toto Provenance spec. - * @type \Google\Protobuf\Timestamp $build_started_on - * The timestamp of when the build started. - * @type \Google\Protobuf\Timestamp $build_finished_on - * The timestamp of when the build completed. - * @type \Grafeas\V1\Completeness $completeness - * Indicates that the builder claims certain fields in this message to be - * complete. - * @type bool $reproducible - * If true, the builder claims that running the recipe on materials will - * produce bit-for-bit identical output. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\IntotoProvenance::initOnce(); - parent::__construct($data); - } - - /** - * Identifies the particular build invocation, which can be useful for finding - * associated logs or other ad-hoc analysis. The value SHOULD be globally - * unique, per in-toto Provenance spec. - * - * Generated from protobuf field string build_invocation_id = 1; - * @return string - */ - public function getBuildInvocationId() - { - return $this->build_invocation_id; - } - - /** - * Identifies the particular build invocation, which can be useful for finding - * associated logs or other ad-hoc analysis. The value SHOULD be globally - * unique, per in-toto Provenance spec. - * - * Generated from protobuf field string build_invocation_id = 1; - * @param string $var - * @return $this - */ - public function setBuildInvocationId($var) - { - GPBUtil::checkString($var, True); - $this->build_invocation_id = $var; - - return $this; - } - - /** - * The timestamp of when the build started. - * - * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getBuildStartedOn() - { - return $this->build_started_on; - } - - public function hasBuildStartedOn() - { - return isset($this->build_started_on); - } - - public function clearBuildStartedOn() - { - unset($this->build_started_on); - } - - /** - * The timestamp of when the build started. - * - * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setBuildStartedOn($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->build_started_on = $var; - - return $this; - } - - /** - * The timestamp of when the build completed. - * - * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getBuildFinishedOn() - { - return $this->build_finished_on; - } - - public function hasBuildFinishedOn() - { - return isset($this->build_finished_on); - } - - public function clearBuildFinishedOn() - { - unset($this->build_finished_on); - } - - /** - * The timestamp of when the build completed. - * - * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setBuildFinishedOn($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->build_finished_on = $var; - - return $this; - } - - /** - * Indicates that the builder claims certain fields in this message to be - * complete. - * - * Generated from protobuf field .grafeas.v1.Completeness completeness = 4; - * @return \Grafeas\V1\Completeness|null - */ - public function getCompleteness() - { - return $this->completeness; - } - - public function hasCompleteness() - { - return isset($this->completeness); - } - - public function clearCompleteness() - { - unset($this->completeness); - } - - /** - * Indicates that the builder claims certain fields in this message to be - * complete. - * - * Generated from protobuf field .grafeas.v1.Completeness completeness = 4; - * @param \Grafeas\V1\Completeness $var - * @return $this - */ - public function setCompleteness($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Completeness::class); - $this->completeness = $var; - - return $this; - } - - /** - * If true, the builder claims that running the recipe on materials will - * produce bit-for-bit identical output. - * - * Generated from protobuf field bool reproducible = 5; - * @return bool - */ - public function getReproducible() - { - return $this->reproducible; - } - - /** - * If true, the builder claims that running the recipe on materials will - * produce bit-for-bit identical output. - * - * Generated from protobuf field bool reproducible = 5; - * @param bool $var - * @return $this - */ - public function setReproducible($var) - { - GPBUtil::checkBool($var); - $this->reproducible = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NonCompliantFile.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NonCompliantFile.php deleted file mode 100644 index db2f7ae1e2f..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NonCompliantFile.php +++ /dev/null @@ -1,135 +0,0 @@ -grafeas.v1.NonCompliantFile - */ -class NonCompliantFile extends \Google\Protobuf\Internal\Message -{ - /** - * Empty if `display_command` is set. - * - * Generated from protobuf field string path = 1; - */ - protected $path = ''; - /** - * Command to display the non-compliant files. - * - * Generated from protobuf field string display_command = 2; - */ - protected $display_command = ''; - /** - * Explains why a file is non compliant for a CIS check. - * - * Generated from protobuf field string reason = 3; - */ - protected $reason = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $path - * Empty if `display_command` is set. - * @type string $display_command - * Command to display the non-compliant files. - * @type string $reason - * Explains why a file is non compliant for a CIS check. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Compliance::initOnce(); - parent::__construct($data); - } - - /** - * Empty if `display_command` is set. - * - * Generated from protobuf field string path = 1; - * @return string - */ - public function getPath() - { - return $this->path; - } - - /** - * Empty if `display_command` is set. - * - * Generated from protobuf field string path = 1; - * @param string $var - * @return $this - */ - public function setPath($var) - { - GPBUtil::checkString($var, True); - $this->path = $var; - - return $this; - } - - /** - * Command to display the non-compliant files. - * - * Generated from protobuf field string display_command = 2; - * @return string - */ - public function getDisplayCommand() - { - return $this->display_command; - } - - /** - * Command to display the non-compliant files. - * - * Generated from protobuf field string display_command = 2; - * @param string $var - * @return $this - */ - public function setDisplayCommand($var) - { - GPBUtil::checkString($var, True); - $this->display_command = $var; - - return $this; - } - - /** - * Explains why a file is non compliant for a CIS check. - * - * Generated from protobuf field string reason = 3; - * @return string - */ - public function getReason() - { - return $this->reason; - } - - /** - * Explains why a file is non compliant for a CIS check. - * - * Generated from protobuf field string reason = 3; - * @param string $var - * @return $this - */ - public function setReason($var) - { - GPBUtil::checkString($var, True); - $this->reason = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Note.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Note.php deleted file mode 100644 index 1ca897a111f..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Note.php +++ /dev/null @@ -1,757 +0,0 @@ -grafeas.v1.Note - */ -class Note extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * A one sentence description of this note. - * - * Generated from protobuf field string short_description = 2; - */ - protected $short_description = ''; - /** - * A detailed description of this note. - * - * Generated from protobuf field string long_description = 3; - */ - protected $long_description = ''; - /** - * Output only. The type of analysis. This field can be used as a filter in - * list requests. - * - * Generated from protobuf field .grafeas.v1.NoteKind kind = 4; - */ - protected $kind = 0; - /** - * URLs associated with this note. - * - * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_url = 5; - */ - private $related_url; - /** - * Time of expiration for this note. Empty if note does not expire. - * - * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 6; - */ - protected $expiration_time = null; - /** - * Output only. The time this note was created. This field can be used as a - * filter in list requests. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7; - */ - protected $create_time = null; - /** - * Output only. The time this note was last updated. This field can be used as - * a filter in list requests. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 8; - */ - protected $update_time = null; - /** - * Other notes related to this note. - * - * Generated from protobuf field repeated string related_note_names = 9; - */ - private $related_note_names; - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @type string $short_description - * A one sentence description of this note. - * @type string $long_description - * A detailed description of this note. - * @type int $kind - * Output only. The type of analysis. This field can be used as a filter in - * list requests. - * @type array<\Grafeas\V1\RelatedUrl>|\Google\Protobuf\Internal\RepeatedField $related_url - * URLs associated with this note. - * @type \Google\Protobuf\Timestamp $expiration_time - * Time of expiration for this note. Empty if note does not expire. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time this note was created. This field can be used as a - * filter in list requests. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The time this note was last updated. This field can be used as - * a filter in list requests. - * @type array|\Google\Protobuf\Internal\RepeatedField $related_note_names - * Other notes related to this note. - * @type \Grafeas\V1\VulnerabilityNote $vulnerability - * A note describing a package vulnerability. - * @type \Grafeas\V1\BuildNote $build - * A note describing build provenance for a verifiable build. - * @type \Grafeas\V1\ImageNote $image - * A note describing a base image. - * @type \Grafeas\V1\PackageNote $package - * A note describing a package hosted by various package managers. - * @type \Grafeas\V1\DeploymentNote $deployment - * A note describing something that can be deployed. - * @type \Grafeas\V1\DiscoveryNote $discovery - * A note describing the initial analysis of a resource. - * @type \Grafeas\V1\AttestationNote $attestation - * A note describing an attestation role. - * @type \Grafeas\V1\UpgradeNote $upgrade - * A note describing available package upgrades. - * @type \Grafeas\V1\ComplianceNote $compliance - * A note describing a compliance check. - * @type \Grafeas\V1\DSSEAttestationNote $dsse_attestation - * A note describing a dsse attestation note. - * @type \Grafeas\V1\VulnerabilityAssessmentNote $vulnerability_assessment - * A note describing a vulnerability assessment. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * A one sentence description of this note. - * - * Generated from protobuf field string short_description = 2; - * @return string - */ - public function getShortDescription() - { - return $this->short_description; - } - - /** - * A one sentence description of this note. - * - * Generated from protobuf field string short_description = 2; - * @param string $var - * @return $this - */ - public function setShortDescription($var) - { - GPBUtil::checkString($var, True); - $this->short_description = $var; - - return $this; - } - - /** - * A detailed description of this note. - * - * Generated from protobuf field string long_description = 3; - * @return string - */ - public function getLongDescription() - { - return $this->long_description; - } - - /** - * A detailed description of this note. - * - * Generated from protobuf field string long_description = 3; - * @param string $var - * @return $this - */ - public function setLongDescription($var) - { - GPBUtil::checkString($var, True); - $this->long_description = $var; - - return $this; - } - - /** - * Output only. The type of analysis. This field can be used as a filter in - * list requests. - * - * Generated from protobuf field .grafeas.v1.NoteKind kind = 4; - * @return int - */ - public function getKind() - { - return $this->kind; - } - - /** - * Output only. The type of analysis. This field can be used as a filter in - * list requests. - * - * Generated from protobuf field .grafeas.v1.NoteKind kind = 4; - * @param int $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\NoteKind::class); - $this->kind = $var; - - return $this; - } - - /** - * URLs associated with this note. - * - * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_url = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRelatedUrl() - { - return $this->related_url; - } - - /** - * URLs associated with this note. - * - * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_url = 5; - * @param array<\Grafeas\V1\RelatedUrl>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRelatedUrl($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\RelatedUrl::class); - $this->related_url = $arr; - - return $this; - } - - /** - * Time of expiration for this note. Empty if note does not expire. - * - * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 6; - * @return \Google\Protobuf\Timestamp|null - */ - public function getExpirationTime() - { - return $this->expiration_time; - } - - public function hasExpirationTime() - { - return isset($this->expiration_time); - } - - public function clearExpirationTime() - { - unset($this->expiration_time); - } - - /** - * Time of expiration for this note. Empty if note does not expire. - * - * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 6; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setExpirationTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->expiration_time = $var; - - return $this; - } - - /** - * Output only. The time this note was created. This field can be used as a - * filter in list requests. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time this note was created. This field can be used as a - * filter in list requests. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time this note was last updated. This field can be used as - * a filter in list requests. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 8; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The time this note was last updated. This field can be used as - * a filter in list requests. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 8; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Other notes related to this note. - * - * Generated from protobuf field repeated string related_note_names = 9; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRelatedNoteNames() - { - return $this->related_note_names; - } - - /** - * Other notes related to this note. - * - * Generated from protobuf field repeated string related_note_names = 9; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRelatedNoteNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->related_note_names = $arr; - - return $this; - } - - /** - * A note describing a package vulnerability. - * - * Generated from protobuf field .grafeas.v1.VulnerabilityNote vulnerability = 10; - * @return \Grafeas\V1\VulnerabilityNote|null - */ - public function getVulnerability() - { - return $this->readOneof(10); - } - - public function hasVulnerability() - { - return $this->hasOneof(10); - } - - /** - * A note describing a package vulnerability. - * - * Generated from protobuf field .grafeas.v1.VulnerabilityNote vulnerability = 10; - * @param \Grafeas\V1\VulnerabilityNote $var - * @return $this - */ - public function setVulnerability($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityNote::class); - $this->writeOneof(10, $var); - - return $this; - } - - /** - * A note describing build provenance for a verifiable build. - * - * Generated from protobuf field .grafeas.v1.BuildNote build = 11; - * @return \Grafeas\V1\BuildNote|null - */ - public function getBuild() - { - return $this->readOneof(11); - } - - public function hasBuild() - { - return $this->hasOneof(11); - } - - /** - * A note describing build provenance for a verifiable build. - * - * Generated from protobuf field .grafeas.v1.BuildNote build = 11; - * @param \Grafeas\V1\BuildNote $var - * @return $this - */ - public function setBuild($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\BuildNote::class); - $this->writeOneof(11, $var); - - return $this; - } - - /** - * A note describing a base image. - * - * Generated from protobuf field .grafeas.v1.ImageNote image = 12; - * @return \Grafeas\V1\ImageNote|null - */ - public function getImage() - { - return $this->readOneof(12); - } - - public function hasImage() - { - return $this->hasOneof(12); - } - - /** - * A note describing a base image. - * - * Generated from protobuf field .grafeas.v1.ImageNote image = 12; - * @param \Grafeas\V1\ImageNote $var - * @return $this - */ - public function setImage($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\ImageNote::class); - $this->writeOneof(12, $var); - - return $this; - } - - /** - * A note describing a package hosted by various package managers. - * - * Generated from protobuf field .grafeas.v1.PackageNote package = 13; - * @return \Grafeas\V1\PackageNote|null - */ - public function getPackage() - { - return $this->readOneof(13); - } - - public function hasPackage() - { - return $this->hasOneof(13); - } - - /** - * A note describing a package hosted by various package managers. - * - * Generated from protobuf field .grafeas.v1.PackageNote package = 13; - * @param \Grafeas\V1\PackageNote $var - * @return $this - */ - public function setPackage($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\PackageNote::class); - $this->writeOneof(13, $var); - - return $this; - } - - /** - * A note describing something that can be deployed. - * - * Generated from protobuf field .grafeas.v1.DeploymentNote deployment = 14; - * @return \Grafeas\V1\DeploymentNote|null - */ - public function getDeployment() - { - return $this->readOneof(14); - } - - public function hasDeployment() - { - return $this->hasOneof(14); - } - - /** - * A note describing something that can be deployed. - * - * Generated from protobuf field .grafeas.v1.DeploymentNote deployment = 14; - * @param \Grafeas\V1\DeploymentNote $var - * @return $this - */ - public function setDeployment($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\DeploymentNote::class); - $this->writeOneof(14, $var); - - return $this; - } - - /** - * A note describing the initial analysis of a resource. - * - * Generated from protobuf field .grafeas.v1.DiscoveryNote discovery = 15; - * @return \Grafeas\V1\DiscoveryNote|null - */ - public function getDiscovery() - { - return $this->readOneof(15); - } - - public function hasDiscovery() - { - return $this->hasOneof(15); - } - - /** - * A note describing the initial analysis of a resource. - * - * Generated from protobuf field .grafeas.v1.DiscoveryNote discovery = 15; - * @param \Grafeas\V1\DiscoveryNote $var - * @return $this - */ - public function setDiscovery($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\DiscoveryNote::class); - $this->writeOneof(15, $var); - - return $this; - } - - /** - * A note describing an attestation role. - * - * Generated from protobuf field .grafeas.v1.AttestationNote attestation = 16; - * @return \Grafeas\V1\AttestationNote|null - */ - public function getAttestation() - { - return $this->readOneof(16); - } - - public function hasAttestation() - { - return $this->hasOneof(16); - } - - /** - * A note describing an attestation role. - * - * Generated from protobuf field .grafeas.v1.AttestationNote attestation = 16; - * @param \Grafeas\V1\AttestationNote $var - * @return $this - */ - public function setAttestation($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\AttestationNote::class); - $this->writeOneof(16, $var); - - return $this; - } - - /** - * A note describing available package upgrades. - * - * Generated from protobuf field .grafeas.v1.UpgradeNote upgrade = 17; - * @return \Grafeas\V1\UpgradeNote|null - */ - public function getUpgrade() - { - return $this->readOneof(17); - } - - public function hasUpgrade() - { - return $this->hasOneof(17); - } - - /** - * A note describing available package upgrades. - * - * Generated from protobuf field .grafeas.v1.UpgradeNote upgrade = 17; - * @param \Grafeas\V1\UpgradeNote $var - * @return $this - */ - public function setUpgrade($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\UpgradeNote::class); - $this->writeOneof(17, $var); - - return $this; - } - - /** - * A note describing a compliance check. - * - * Generated from protobuf field .grafeas.v1.ComplianceNote compliance = 18; - * @return \Grafeas\V1\ComplianceNote|null - */ - public function getCompliance() - { - return $this->readOneof(18); - } - - public function hasCompliance() - { - return $this->hasOneof(18); - } - - /** - * A note describing a compliance check. - * - * Generated from protobuf field .grafeas.v1.ComplianceNote compliance = 18; - * @param \Grafeas\V1\ComplianceNote $var - * @return $this - */ - public function setCompliance($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\ComplianceNote::class); - $this->writeOneof(18, $var); - - return $this; - } - - /** - * A note describing a dsse attestation note. - * - * Generated from protobuf field .grafeas.v1.DSSEAttestationNote dsse_attestation = 19; - * @return \Grafeas\V1\DSSEAttestationNote|null - */ - public function getDsseAttestation() - { - return $this->readOneof(19); - } - - public function hasDsseAttestation() - { - return $this->hasOneof(19); - } - - /** - * A note describing a dsse attestation note. - * - * Generated from protobuf field .grafeas.v1.DSSEAttestationNote dsse_attestation = 19; - * @param \Grafeas\V1\DSSEAttestationNote $var - * @return $this - */ - public function setDsseAttestation($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\DSSEAttestationNote::class); - $this->writeOneof(19, $var); - - return $this; - } - - /** - * A note describing a vulnerability assessment. - * - * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote vulnerability_assessment = 20; - * @return \Grafeas\V1\VulnerabilityAssessmentNote|null - */ - public function getVulnerabilityAssessment() - { - return $this->readOneof(20); - } - - public function hasVulnerabilityAssessment() - { - return $this->hasOneof(20); - } - - /** - * A note describing a vulnerability assessment. - * - * Generated from protobuf field .grafeas.v1.VulnerabilityAssessmentNote vulnerability_assessment = 20; - * @param \Grafeas\V1\VulnerabilityAssessmentNote $var - * @return $this - */ - public function setVulnerabilityAssessment($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityAssessmentNote::class); - $this->writeOneof(20, $var); - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NoteKind.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NoteKind.php deleted file mode 100644 index 7616d7f290c..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/NoteKind.php +++ /dev/null @@ -1,124 +0,0 @@ -grafeas.v1.NoteKind - */ -class NoteKind -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum NOTE_KIND_UNSPECIFIED = 0; - */ - const NOTE_KIND_UNSPECIFIED = 0; - /** - * The note and occurrence represent a package vulnerability. - * - * Generated from protobuf enum VULNERABILITY = 1; - */ - const VULNERABILITY = 1; - /** - * The note and occurrence assert build provenance. - * - * Generated from protobuf enum BUILD = 2; - */ - const BUILD = 2; - /** - * This represents an image basis relationship. - * - * Generated from protobuf enum IMAGE = 3; - */ - const IMAGE = 3; - /** - * This represents a package installed via a package manager. - * - * Generated from protobuf enum PACKAGE = 4; - */ - const PACKAGE = 4; - /** - * The note and occurrence track deployment events. - * - * Generated from protobuf enum DEPLOYMENT = 5; - */ - const DEPLOYMENT = 5; - /** - * The note and occurrence track the initial discovery status of a resource. - * - * Generated from protobuf enum DISCOVERY = 6; - */ - const DISCOVERY = 6; - /** - * This represents a logical "role" that can attest to artifacts. - * - * Generated from protobuf enum ATTESTATION = 7; - */ - const ATTESTATION = 7; - /** - * This represents an available package upgrade. - * - * Generated from protobuf enum UPGRADE = 8; - */ - const UPGRADE = 8; - /** - * This represents a Compliance Note - * - * Generated from protobuf enum COMPLIANCE = 9; - */ - const COMPLIANCE = 9; - /** - * This represents a DSSE attestation Note - * - * Generated from protobuf enum DSSE_ATTESTATION = 10; - */ - const DSSE_ATTESTATION = 10; - /** - * This represents a Vulnerability Assessment. - * - * Generated from protobuf enum VULNERABILITY_ASSESSMENT = 11; - */ - const VULNERABILITY_ASSESSMENT = 11; - - private static $valueToName = [ - self::NOTE_KIND_UNSPECIFIED => 'NOTE_KIND_UNSPECIFIED', - self::VULNERABILITY => 'VULNERABILITY', - self::BUILD => 'BUILD', - self::IMAGE => 'IMAGE', - self::PACKAGE => 'PACKAGE', - self::DEPLOYMENT => 'DEPLOYMENT', - self::DISCOVERY => 'DISCOVERY', - self::ATTESTATION => 'ATTESTATION', - self::UPGRADE => 'UPGRADE', - self::COMPLIANCE => 'COMPLIANCE', - self::DSSE_ATTESTATION => 'DSSE_ATTESTATION', - self::VULNERABILITY_ASSESSMENT => 'VULNERABILITY_ASSESSMENT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Occurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Occurrence.php deleted file mode 100644 index afc520226b1..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Occurrence.php +++ /dev/null @@ -1,701 +0,0 @@ -grafeas.v1.Occurrence - */ -class Occurrence extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Required. Immutable. A URI that represents the resource for which the - * occurrence applies. For example, - * `https://gcr.io/project/image@sha256:123abc` for a Docker image. - * - * Generated from protobuf field string resource_uri = 2; - */ - protected $resource_uri = ''; - /** - * 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. - * - * Generated from protobuf field string note_name = 3; - */ - protected $note_name = ''; - /** - * Output only. This explicitly denotes which of the occurrence details are - * specified. This field can be used as a filter in list requests. - * - * Generated from protobuf field .grafeas.v1.NoteKind kind = 4; - */ - protected $kind = 0; - /** - * A description of actions that can be taken to remedy the note. - * - * Generated from protobuf field string remediation = 5; - */ - protected $remediation = ''; - /** - * Output only. The time this occurrence was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; - */ - protected $create_time = null; - /** - * Output only. The time this occurrence was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 7; - */ - protected $update_time = null; - /** - * https://github.com/secure-systems-lab/dsse - * - * Generated from protobuf field .grafeas.v1.Envelope envelope = 18; - */ - protected $envelope = null; - protected $details; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @type string $resource_uri - * Required. Immutable. A URI that represents the resource for which the - * occurrence applies. For example, - * `https://gcr.io/project/image@sha256:123abc` for a Docker image. - * @type string $note_name - * 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. - * @type 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. - * @type string $remediation - * A description of actions that can be taken to remedy the note. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time this occurrence was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The time this occurrence was last updated. - * @type \Grafeas\V1\VulnerabilityOccurrence $vulnerability - * Describes a security vulnerability. - * @type \Grafeas\V1\BuildOccurrence $build - * Describes a verifiable build. - * @type \Grafeas\V1\ImageOccurrence $image - * Describes how this resource derives from the basis in the associated - * note. - * @type \Grafeas\V1\PackageOccurrence $package - * Describes the installation of a package on the linked resource. - * @type \Grafeas\V1\DeploymentOccurrence $deployment - * Describes the deployment of an artifact on a runtime. - * @type \Grafeas\V1\DiscoveryOccurrence $discovery - * Describes when a resource was discovered. - * @type \Grafeas\V1\AttestationOccurrence $attestation - * Describes an attestation of an artifact. - * @type \Grafeas\V1\UpgradeOccurrence $upgrade - * Describes an available package upgrade on the linked resource. - * @type \Grafeas\V1\ComplianceOccurrence $compliance - * Describes a compliance violation on a linked resource. - * @type \Grafeas\V1\DSSEAttestationOccurrence $dsse_attestation - * Describes an attestation of an artifact using dsse. - * @type \Grafeas\V1\Envelope $envelope - * https://github.com/secure-systems-lab/dsse - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. Immutable. A URI that represents the resource for which the - * occurrence applies. For example, - * `https://gcr.io/project/image@sha256:123abc` for a Docker image. - * - * Generated from protobuf field string resource_uri = 2; - * @return string - */ - public function getResourceUri() - { - return $this->resource_uri; - } - - /** - * Required. Immutable. A URI that represents the resource for which the - * occurrence applies. For example, - * `https://gcr.io/project/image@sha256:123abc` for a Docker image. - * - * Generated from protobuf field string resource_uri = 2; - * @param string $var - * @return $this - */ - public function setResourceUri($var) - { - GPBUtil::checkString($var, True); - $this->resource_uri = $var; - - 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. - * - * Generated from protobuf field string note_name = 3; - * @return string - */ - public function getNoteName() - { - return $this->note_name; - } - - /** - * 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. - * - * Generated from protobuf field string note_name = 3; - * @param string $var - * @return $this - */ - public function setNoteName($var) - { - GPBUtil::checkString($var, True); - $this->note_name = $var; - - 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. - * - * Generated from protobuf field .grafeas.v1.NoteKind kind = 4; - * @return int - */ - public function getKind() - { - return $this->kind; - } - - /** - * Output only. This explicitly denotes which of the occurrence details are - * specified. This field can be used as a filter in list requests. - * - * Generated from protobuf field .grafeas.v1.NoteKind kind = 4; - * @param int $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\NoteKind::class); - $this->kind = $var; - - return $this; - } - - /** - * A description of actions that can be taken to remedy the note. - * - * Generated from protobuf field string remediation = 5; - * @return string - */ - public function getRemediation() - { - return $this->remediation; - } - - /** - * A description of actions that can be taken to remedy the note. - * - * Generated from protobuf field string remediation = 5; - * @param string $var - * @return $this - */ - public function setRemediation($var) - { - GPBUtil::checkString($var, True); - $this->remediation = $var; - - return $this; - } - - /** - * Output only. The time this occurrence was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time this occurrence was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time this occurrence was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 7; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The time this occurrence was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 7; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Describes a security vulnerability. - * - * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence vulnerability = 8; - * @return \Grafeas\V1\VulnerabilityOccurrence|null - */ - public function getVulnerability() - { - return $this->readOneof(8); - } - - public function hasVulnerability() - { - return $this->hasOneof(8); - } - - /** - * Describes a security vulnerability. - * - * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence vulnerability = 8; - * @param \Grafeas\V1\VulnerabilityOccurrence $var - * @return $this - */ - public function setVulnerability($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityOccurrence::class); - $this->writeOneof(8, $var); - - return $this; - } - - /** - * Describes a verifiable build. - * - * Generated from protobuf field .grafeas.v1.BuildOccurrence build = 9; - * @return \Grafeas\V1\BuildOccurrence|null - */ - public function getBuild() - { - return $this->readOneof(9); - } - - public function hasBuild() - { - return $this->hasOneof(9); - } - - /** - * Describes a verifiable build. - * - * Generated from protobuf field .grafeas.v1.BuildOccurrence build = 9; - * @param \Grafeas\V1\BuildOccurrence $var - * @return $this - */ - public function setBuild($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\BuildOccurrence::class); - $this->writeOneof(9, $var); - - return $this; - } - - /** - * Describes how this resource derives from the basis in the associated - * note. - * - * Generated from protobuf field .grafeas.v1.ImageOccurrence image = 10; - * @return \Grafeas\V1\ImageOccurrence|null - */ - public function getImage() - { - return $this->readOneof(10); - } - - public function hasImage() - { - return $this->hasOneof(10); - } - - /** - * Describes how this resource derives from the basis in the associated - * note. - * - * Generated from protobuf field .grafeas.v1.ImageOccurrence image = 10; - * @param \Grafeas\V1\ImageOccurrence $var - * @return $this - */ - public function setImage($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\ImageOccurrence::class); - $this->writeOneof(10, $var); - - return $this; - } - - /** - * Describes the installation of a package on the linked resource. - * - * Generated from protobuf field .grafeas.v1.PackageOccurrence package = 11; - * @return \Grafeas\V1\PackageOccurrence|null - */ - public function getPackage() - { - return $this->readOneof(11); - } - - public function hasPackage() - { - return $this->hasOneof(11); - } - - /** - * Describes the installation of a package on the linked resource. - * - * Generated from protobuf field .grafeas.v1.PackageOccurrence package = 11; - * @param \Grafeas\V1\PackageOccurrence $var - * @return $this - */ - public function setPackage($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\PackageOccurrence::class); - $this->writeOneof(11, $var); - - return $this; - } - - /** - * Describes the deployment of an artifact on a runtime. - * - * Generated from protobuf field .grafeas.v1.DeploymentOccurrence deployment = 12; - * @return \Grafeas\V1\DeploymentOccurrence|null - */ - public function getDeployment() - { - return $this->readOneof(12); - } - - public function hasDeployment() - { - return $this->hasOneof(12); - } - - /** - * Describes the deployment of an artifact on a runtime. - * - * Generated from protobuf field .grafeas.v1.DeploymentOccurrence deployment = 12; - * @param \Grafeas\V1\DeploymentOccurrence $var - * @return $this - */ - public function setDeployment($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\DeploymentOccurrence::class); - $this->writeOneof(12, $var); - - return $this; - } - - /** - * Describes when a resource was discovered. - * - * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence discovery = 13; - * @return \Grafeas\V1\DiscoveryOccurrence|null - */ - public function getDiscovery() - { - return $this->readOneof(13); - } - - public function hasDiscovery() - { - return $this->hasOneof(13); - } - - /** - * Describes when a resource was discovered. - * - * Generated from protobuf field .grafeas.v1.DiscoveryOccurrence discovery = 13; - * @param \Grafeas\V1\DiscoveryOccurrence $var - * @return $this - */ - public function setDiscovery($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\DiscoveryOccurrence::class); - $this->writeOneof(13, $var); - - return $this; - } - - /** - * Describes an attestation of an artifact. - * - * Generated from protobuf field .grafeas.v1.AttestationOccurrence attestation = 14; - * @return \Grafeas\V1\AttestationOccurrence|null - */ - public function getAttestation() - { - return $this->readOneof(14); - } - - public function hasAttestation() - { - return $this->hasOneof(14); - } - - /** - * Describes an attestation of an artifact. - * - * Generated from protobuf field .grafeas.v1.AttestationOccurrence attestation = 14; - * @param \Grafeas\V1\AttestationOccurrence $var - * @return $this - */ - public function setAttestation($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\AttestationOccurrence::class); - $this->writeOneof(14, $var); - - return $this; - } - - /** - * Describes an available package upgrade on the linked resource. - * - * Generated from protobuf field .grafeas.v1.UpgradeOccurrence upgrade = 15; - * @return \Grafeas\V1\UpgradeOccurrence|null - */ - public function getUpgrade() - { - return $this->readOneof(15); - } - - public function hasUpgrade() - { - return $this->hasOneof(15); - } - - /** - * Describes an available package upgrade on the linked resource. - * - * Generated from protobuf field .grafeas.v1.UpgradeOccurrence upgrade = 15; - * @param \Grafeas\V1\UpgradeOccurrence $var - * @return $this - */ - public function setUpgrade($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\UpgradeOccurrence::class); - $this->writeOneof(15, $var); - - return $this; - } - - /** - * Describes a compliance violation on a linked resource. - * - * Generated from protobuf field .grafeas.v1.ComplianceOccurrence compliance = 16; - * @return \Grafeas\V1\ComplianceOccurrence|null - */ - public function getCompliance() - { - return $this->readOneof(16); - } - - public function hasCompliance() - { - return $this->hasOneof(16); - } - - /** - * Describes a compliance violation on a linked resource. - * - * Generated from protobuf field .grafeas.v1.ComplianceOccurrence compliance = 16; - * @param \Grafeas\V1\ComplianceOccurrence $var - * @return $this - */ - public function setCompliance($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\ComplianceOccurrence::class); - $this->writeOneof(16, $var); - - return $this; - } - - /** - * Describes an attestation of an artifact using dsse. - * - * Generated from protobuf field .grafeas.v1.DSSEAttestationOccurrence dsse_attestation = 17; - * @return \Grafeas\V1\DSSEAttestationOccurrence|null - */ - public function getDsseAttestation() - { - return $this->readOneof(17); - } - - public function hasDsseAttestation() - { - return $this->hasOneof(17); - } - - /** - * Describes an attestation of an artifact using dsse. - * - * Generated from protobuf field .grafeas.v1.DSSEAttestationOccurrence dsse_attestation = 17; - * @param \Grafeas\V1\DSSEAttestationOccurrence $var - * @return $this - */ - public function setDsseAttestation($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\DSSEAttestationOccurrence::class); - $this->writeOneof(17, $var); - - return $this; - } - - /** - * https://github.com/secure-systems-lab/dsse - * - * Generated from protobuf field .grafeas.v1.Envelope envelope = 18; - * @return \Grafeas\V1\Envelope|null - */ - public function getEnvelope() - { - return $this->envelope; - } - - public function hasEnvelope() - { - return isset($this->envelope); - } - - public function clearEnvelope() - { - unset($this->envelope); - } - - /** - * https://github.com/secure-systems-lab/dsse - * - * Generated from protobuf field .grafeas.v1.Envelope envelope = 18; - * @param \Grafeas\V1\Envelope $var - * @return $this - */ - public function setEnvelope($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Envelope::class); - $this->envelope = $var; - - return $this; - } - - /** - * @return string - */ - public function getDetails() - { - return $this->whichOneof("details"); - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageNote.php deleted file mode 100644 index a7295d29168..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageNote.php +++ /dev/null @@ -1,451 +0,0 @@ -grafeas.v1.PackageNote - */ -class PackageNote extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the package. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $name = ''; - /** - * Deprecated. - * The various channels by which a package is distributed. - * - * Generated from protobuf field repeated .grafeas.v1.Distribution distribution = 10; - */ - private $distribution; - /** - * The type of package; whether native or non native (e.g., ruby gems, - * node.js packages, etc.). - * - * Generated from protobuf field string package_type = 11; - */ - protected $package_type = ''; - /** - * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) - * denoting the package manager version distributing a package. - * The cpe_uri will be blank for language packages. - * - * Generated from protobuf field string cpe_uri = 12; - */ - protected $cpe_uri = ''; - /** - * The CPU architecture for which packages in this distribution channel were - * built. Architecture will be blank for language packages. - * - * Generated from protobuf field .grafeas.v1.Architecture architecture = 13; - */ - protected $architecture = 0; - /** - * The version of the package. - * - * Generated from protobuf field .grafeas.v1.Version version = 14; - */ - protected $version = null; - /** - * A freeform text denoting the maintainer of this package. - * - * Generated from protobuf field string maintainer = 15; - */ - protected $maintainer = ''; - /** - * The homepage for this package. - * - * Generated from protobuf field string url = 16; - */ - protected $url = ''; - /** - * The description of this package. - * - * Generated from protobuf field string description = 17; - */ - protected $description = ''; - /** - * Licenses that have been declared by the authors of the package. - * - * Generated from protobuf field .grafeas.v1.License license = 18; - */ - protected $license = null; - /** - * Hash value, typically a file digest, that allows unique - * identification a specific package. - * - * Generated from protobuf field repeated .grafeas.v1.Digest digest = 19; - */ - private $digest; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the package. - * @type array<\Grafeas\V1\Distribution>|\Google\Protobuf\Internal\RepeatedField $distribution - * Deprecated. - * The various channels by which a package is distributed. - * @type string $package_type - * The type of package; whether native or non native (e.g., ruby gems, - * node.js packages, etc.). - * @type string $cpe_uri - * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) - * denoting the package manager version distributing a package. - * The cpe_uri will be blank for language packages. - * @type int $architecture - * The CPU architecture for which packages in this distribution channel were - * built. Architecture will be blank for language packages. - * @type \Grafeas\V1\Version $version - * The version of the package. - * @type string $maintainer - * A freeform text denoting the maintainer of this package. - * @type string $url - * The homepage for this package. - * @type string $description - * The description of this package. - * @type \Grafeas\V1\License $license - * Licenses that have been declared by the authors of the package. - * @type array<\Grafeas\V1\Digest>|\Google\Protobuf\Internal\RepeatedField $digest - * Hash value, typically a file digest, that allows unique - * identification a specific package. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Package::initOnce(); - parent::__construct($data); - } - - /** - * The name of the package. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the package. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Deprecated. - * The various channels by which a package is distributed. - * - * Generated from protobuf field repeated .grafeas.v1.Distribution distribution = 10; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDistribution() - { - return $this->distribution; - } - - /** - * Deprecated. - * The various channels by which a package is distributed. - * - * Generated from protobuf field repeated .grafeas.v1.Distribution distribution = 10; - * @param array<\Grafeas\V1\Distribution>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDistribution($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Distribution::class); - $this->distribution = $arr; - - return $this; - } - - /** - * The type of package; whether native or non native (e.g., ruby gems, - * node.js packages, etc.). - * - * Generated from protobuf field string package_type = 11; - * @return string - */ - public function getPackageType() - { - return $this->package_type; - } - - /** - * The type of package; whether native or non native (e.g., ruby gems, - * node.js packages, etc.). - * - * Generated from protobuf field string package_type = 11; - * @param string $var - * @return $this - */ - public function setPackageType($var) - { - GPBUtil::checkString($var, True); - $this->package_type = $var; - - return $this; - } - - /** - * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) - * denoting the package manager version distributing a package. - * The cpe_uri will be blank for language packages. - * - * Generated from protobuf field string cpe_uri = 12; - * @return string - */ - public function getCpeUri() - { - return $this->cpe_uri; - } - - /** - * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) - * denoting the package manager version distributing a package. - * The cpe_uri will be blank for language packages. - * - * Generated from protobuf field string cpe_uri = 12; - * @param string $var - * @return $this - */ - public function setCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->cpe_uri = $var; - - return $this; - } - - /** - * The CPU architecture for which packages in this distribution channel were - * built. Architecture will be blank for language packages. - * - * Generated from protobuf field .grafeas.v1.Architecture architecture = 13; - * @return int - */ - public function getArchitecture() - { - return $this->architecture; - } - - /** - * The CPU architecture for which packages in this distribution channel were - * built. Architecture will be blank for language packages. - * - * Generated from protobuf field .grafeas.v1.Architecture architecture = 13; - * @param int $var - * @return $this - */ - public function setArchitecture($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\Architecture::class); - $this->architecture = $var; - - return $this; - } - - /** - * The version of the package. - * - * Generated from protobuf field .grafeas.v1.Version version = 14; - * @return \Grafeas\V1\Version|null - */ - public function getVersion() - { - return $this->version; - } - - public function hasVersion() - { - return isset($this->version); - } - - public function clearVersion() - { - unset($this->version); - } - - /** - * The version of the package. - * - * Generated from protobuf field .grafeas.v1.Version version = 14; - * @param \Grafeas\V1\Version $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); - $this->version = $var; - - return $this; - } - - /** - * A freeform text denoting the maintainer of this package. - * - * Generated from protobuf field string maintainer = 15; - * @return string - */ - public function getMaintainer() - { - return $this->maintainer; - } - - /** - * A freeform text denoting the maintainer of this package. - * - * Generated from protobuf field string maintainer = 15; - * @param string $var - * @return $this - */ - public function setMaintainer($var) - { - GPBUtil::checkString($var, True); - $this->maintainer = $var; - - return $this; - } - - /** - * The homepage for this package. - * - * Generated from protobuf field string url = 16; - * @return string - */ - public function getUrl() - { - return $this->url; - } - - /** - * The homepage for this package. - * - * Generated from protobuf field string url = 16; - * @param string $var - * @return $this - */ - public function setUrl($var) - { - GPBUtil::checkString($var, True); - $this->url = $var; - - return $this; - } - - /** - * The description of this package. - * - * Generated from protobuf field string description = 17; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The description of this package. - * - * Generated from protobuf field string description = 17; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Licenses that have been declared by the authors of the package. - * - * Generated from protobuf field .grafeas.v1.License license = 18; - * @return \Grafeas\V1\License|null - */ - public function getLicense() - { - return $this->license; - } - - public function hasLicense() - { - return isset($this->license); - } - - public function clearLicense() - { - unset($this->license); - } - - /** - * Licenses that have been declared by the authors of the package. - * - * Generated from protobuf field .grafeas.v1.License license = 18; - * @param \Grafeas\V1\License $var - * @return $this - */ - public function setLicense($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\License::class); - $this->license = $var; - - return $this; - } - - /** - * Hash value, typically a file digest, that allows unique - * identification a specific package. - * - * Generated from protobuf field repeated .grafeas.v1.Digest digest = 19; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDigest() - { - return $this->digest; - } - - /** - * Hash value, typically a file digest, that allows unique - * identification a specific package. - * - * Generated from protobuf field repeated .grafeas.v1.Digest digest = 19; - * @param array<\Grafeas\V1\Digest>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDigest($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Digest::class); - $this->digest = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageOccurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageOccurrence.php deleted file mode 100644 index dafa0769a93..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/PackageOccurrence.php +++ /dev/null @@ -1,311 +0,0 @@ -grafeas.v1.PackageOccurrence - */ -class PackageOccurrence extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the installed package. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * All of the places within the filesystem versions of this package - * have been found. - * - * Generated from protobuf field repeated .grafeas.v1.Location location = 2; - */ - private $location; - /** - * The type of package; whether native or non native (e.g., ruby gems, - * node.js packages, etc.). - * - * Generated from protobuf field string package_type = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $package_type = ''; - /** - * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) - * denoting the package manager version distributing a package. - * The cpe_uri will be blank for language packages. - * - * Generated from protobuf field string cpe_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $cpe_uri = ''; - /** - * The CPU architecture for which packages in this distribution channel were - * built. Architecture will be blank for language packages. - * - * Generated from protobuf field .grafeas.v1.Architecture architecture = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $architecture = 0; - /** - * Licenses that have been declared by the authors of the package. - * - * Generated from protobuf field .grafeas.v1.License license = 6; - */ - protected $license = null; - /** - * The version of the package. - * - * Generated from protobuf field .grafeas.v1.Version version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $version = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the installed package. - * @type array<\Grafeas\V1\Location>|\Google\Protobuf\Internal\RepeatedField $location - * All of the places within the filesystem versions of this package - * have been found. - * @type string $package_type - * The type of package; whether native or non native (e.g., ruby gems, - * node.js packages, etc.). - * @type string $cpe_uri - * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) - * denoting the package manager version distributing a package. - * The cpe_uri will be blank for language packages. - * @type int $architecture - * The CPU architecture for which packages in this distribution channel were - * built. Architecture will be blank for language packages. - * @type \Grafeas\V1\License $license - * Licenses that have been declared by the authors of the package. - * @type \Grafeas\V1\Version $version - * The version of the package. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Package::initOnce(); - parent::__construct($data); - } - - /** - * The name of the installed package. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the installed package. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * All of the places within the filesystem versions of this package - * have been found. - * - * Generated from protobuf field repeated .grafeas.v1.Location location = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLocation() - { - return $this->location; - } - - /** - * All of the places within the filesystem versions of this package - * have been found. - * - * Generated from protobuf field repeated .grafeas.v1.Location location = 2; - * @param array<\Grafeas\V1\Location>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLocation($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\Location::class); - $this->location = $arr; - - return $this; - } - - /** - * The type of package; whether native or non native (e.g., ruby gems, - * node.js packages, etc.). - * - * Generated from protobuf field string package_type = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getPackageType() - { - return $this->package_type; - } - - /** - * The type of package; whether native or non native (e.g., ruby gems, - * node.js packages, etc.). - * - * Generated from protobuf field string package_type = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setPackageType($var) - { - GPBUtil::checkString($var, True); - $this->package_type = $var; - - return $this; - } - - /** - * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) - * denoting the package manager version distributing a package. - * The cpe_uri will be blank for language packages. - * - * Generated from protobuf field string cpe_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getCpeUri() - { - return $this->cpe_uri; - } - - /** - * The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) - * denoting the package manager version distributing a package. - * The cpe_uri will be blank for language packages. - * - * Generated from protobuf field string cpe_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->cpe_uri = $var; - - return $this; - } - - /** - * The CPU architecture for which packages in this distribution channel were - * built. Architecture will be blank for language packages. - * - * Generated from protobuf field .grafeas.v1.Architecture architecture = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getArchitecture() - { - return $this->architecture; - } - - /** - * The CPU architecture for which packages in this distribution channel were - * built. Architecture will be blank for language packages. - * - * Generated from protobuf field .grafeas.v1.Architecture architecture = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setArchitecture($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\Architecture::class); - $this->architecture = $var; - - return $this; - } - - /** - * Licenses that have been declared by the authors of the package. - * - * Generated from protobuf field .grafeas.v1.License license = 6; - * @return \Grafeas\V1\License|null - */ - public function getLicense() - { - return $this->license; - } - - public function hasLicense() - { - return isset($this->license); - } - - public function clearLicense() - { - unset($this->license); - } - - /** - * Licenses that have been declared by the authors of the package. - * - * Generated from protobuf field .grafeas.v1.License license = 6; - * @param \Grafeas\V1\License $var - * @return $this - */ - public function setLicense($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\License::class); - $this->license = $var; - - return $this; - } - - /** - * The version of the package. - * - * Generated from protobuf field .grafeas.v1.Version version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Grafeas\V1\Version|null - */ - public function getVersion() - { - return $this->version; - } - - public function hasVersion() - { - return isset($this->version); - } - - public function clearVersion() - { - unset($this->version); - } - - /** - * The version of the package. - * - * Generated from protobuf field .grafeas.v1.Version version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Grafeas\V1\Version $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); - $this->version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ProjectRepoId.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ProjectRepoId.php deleted file mode 100644 index d2c9475a063..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/ProjectRepoId.php +++ /dev/null @@ -1,102 +0,0 @@ -grafeas.v1.ProjectRepoId - */ -class ProjectRepoId extends \Google\Protobuf\Internal\Message -{ - /** - * The ID of the project. - * - * Generated from protobuf field string project_id = 1; - */ - protected $project_id = ''; - /** - * The name of the repo. Leave empty for the default repo. - * - * Generated from protobuf field string repo_name = 2; - */ - protected $repo_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $project_id - * The ID of the project. - * @type string $repo_name - * The name of the repo. Leave empty for the default repo. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * The ID of the project. - * - * Generated from protobuf field string project_id = 1; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * The ID of the project. - * - * Generated from protobuf field string project_id = 1; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * The name of the repo. Leave empty for the default repo. - * - * Generated from protobuf field string repo_name = 2; - * @return string - */ - public function getRepoName() - { - return $this->repo_name; - } - - /** - * The name of the repo. Leave empty for the default repo. - * - * Generated from protobuf field string repo_name = 2; - * @param string $var - * @return $this - */ - public function setRepoName($var) - { - GPBUtil::checkString($var, True); - $this->repo_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Recipe.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Recipe.php deleted file mode 100644 index 0806a1ed630..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Recipe.php +++ /dev/null @@ -1,273 +0,0 @@ -grafeas.v1.Recipe - */ -class Recipe extends \Google\Protobuf\Internal\Message -{ - /** - * URI indicating what type of recipe was performed. It determines the meaning - * of recipe.entryPoint, recipe.arguments, recipe.environment, and materials. - * - * Generated from protobuf field string type = 1; - */ - protected $type = ''; - /** - * Index in materials containing the recipe steps that are not implied by - * recipe.type. For example, if the recipe type were "make", then this would - * point to the source containing the Makefile, not the make program itself. - * Set to -1 if the recipe doesn't come from a material, as zero is default - * unset value for int64. - * - * Generated from protobuf field int64 defined_in_material = 2; - */ - protected $defined_in_material = 0; - /** - * String identifying the entry point into the build. - * This is often a path to a configuration file and/or a target label within - * that file. The syntax and meaning are defined by recipe.type. For example, - * if the recipe type were "make", then this would reference the directory in - * which to run make as well as which target to use. - * - * Generated from protobuf field string entry_point = 3; - */ - protected $entry_point = ''; - /** - * Collection of all external inputs that influenced the build on top of - * recipe.definedInMaterial and recipe.entryPoint. For example, if the recipe - * type were "make", then this might be the flags passed to make aside from - * the target, which is captured in recipe.entryPoint. Since the arguments - * field can greatly vary in structure, depending on the builder and recipe - * type, this is of form "Any". - * - * Generated from protobuf field repeated .google.protobuf.Any arguments = 4; - */ - private $arguments; - /** - * Any other builder-controlled inputs necessary for correctly evaluating the - * recipe. Usually only needed for reproducing the build but not evaluated as - * part of policy. Since the environment field can greatly vary in structure, - * depending on the builder and recipe type, this is of form "Any". - * - * Generated from protobuf field repeated .google.protobuf.Any environment = 5; - */ - private $environment; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $type - * URI indicating what type of recipe was performed. It determines the meaning - * of recipe.entryPoint, recipe.arguments, recipe.environment, and materials. - * @type int|string $defined_in_material - * Index in materials containing the recipe steps that are not implied by - * recipe.type. For example, if the recipe type were "make", then this would - * point to the source containing the Makefile, not the make program itself. - * Set to -1 if the recipe doesn't come from a material, as zero is default - * unset value for int64. - * @type string $entry_point - * String identifying the entry point into the build. - * This is often a path to a configuration file and/or a target label within - * that file. The syntax and meaning are defined by recipe.type. For example, - * if the recipe type were "make", then this would reference the directory in - * which to run make as well as which target to use. - * @type array<\Google\Protobuf\Any>|\Google\Protobuf\Internal\RepeatedField $arguments - * Collection of all external inputs that influenced the build on top of - * recipe.definedInMaterial and recipe.entryPoint. For example, if the recipe - * type were "make", then this might be the flags passed to make aside from - * the target, which is captured in recipe.entryPoint. Since the arguments - * field can greatly vary in structure, depending on the builder and recipe - * type, this is of form "Any". - * @type array<\Google\Protobuf\Any>|\Google\Protobuf\Internal\RepeatedField $environment - * Any other builder-controlled inputs necessary for correctly evaluating the - * recipe. Usually only needed for reproducing the build but not evaluated as - * part of policy. Since the environment field can greatly vary in structure, - * depending on the builder and recipe type, this is of form "Any". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\IntotoProvenance::initOnce(); - parent::__construct($data); - } - - /** - * URI indicating what type of recipe was performed. It determines the meaning - * of recipe.entryPoint, recipe.arguments, recipe.environment, and materials. - * - * Generated from protobuf field string type = 1; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * URI indicating what type of recipe was performed. It determines the meaning - * of recipe.entryPoint, recipe.arguments, recipe.environment, and materials. - * - * Generated from protobuf field string type = 1; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Index in materials containing the recipe steps that are not implied by - * recipe.type. For example, if the recipe type were "make", then this would - * point to the source containing the Makefile, not the make program itself. - * Set to -1 if the recipe doesn't come from a material, as zero is default - * unset value for int64. - * - * Generated from protobuf field int64 defined_in_material = 2; - * @return int|string - */ - public function getDefinedInMaterial() - { - return $this->defined_in_material; - } - - /** - * Index in materials containing the recipe steps that are not implied by - * recipe.type. For example, if the recipe type were "make", then this would - * point to the source containing the Makefile, not the make program itself. - * Set to -1 if the recipe doesn't come from a material, as zero is default - * unset value for int64. - * - * Generated from protobuf field int64 defined_in_material = 2; - * @param int|string $var - * @return $this - */ - public function setDefinedInMaterial($var) - { - GPBUtil::checkInt64($var); - $this->defined_in_material = $var; - - return $this; - } - - /** - * String identifying the entry point into the build. - * This is often a path to a configuration file and/or a target label within - * that file. The syntax and meaning are defined by recipe.type. For example, - * if the recipe type were "make", then this would reference the directory in - * which to run make as well as which target to use. - * - * Generated from protobuf field string entry_point = 3; - * @return string - */ - public function getEntryPoint() - { - return $this->entry_point; - } - - /** - * String identifying the entry point into the build. - * This is often a path to a configuration file and/or a target label within - * that file. The syntax and meaning are defined by recipe.type. For example, - * if the recipe type were "make", then this would reference the directory in - * which to run make as well as which target to use. - * - * Generated from protobuf field string entry_point = 3; - * @param string $var - * @return $this - */ - public function setEntryPoint($var) - { - GPBUtil::checkString($var, True); - $this->entry_point = $var; - - return $this; - } - - /** - * Collection of all external inputs that influenced the build on top of - * recipe.definedInMaterial and recipe.entryPoint. For example, if the recipe - * type were "make", then this might be the flags passed to make aside from - * the target, which is captured in recipe.entryPoint. Since the arguments - * field can greatly vary in structure, depending on the builder and recipe - * type, this is of form "Any". - * - * Generated from protobuf field repeated .google.protobuf.Any arguments = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getArguments() - { - return $this->arguments; - } - - /** - * Collection of all external inputs that influenced the build on top of - * recipe.definedInMaterial and recipe.entryPoint. For example, if the recipe - * type were "make", then this might be the flags passed to make aside from - * the target, which is captured in recipe.entryPoint. Since the arguments - * field can greatly vary in structure, depending on the builder and recipe - * type, this is of form "Any". - * - * Generated from protobuf field repeated .google.protobuf.Any arguments = 4; - * @param array<\Google\Protobuf\Any>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setArguments($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Any::class); - $this->arguments = $arr; - - return $this; - } - - /** - * Any other builder-controlled inputs necessary for correctly evaluating the - * recipe. Usually only needed for reproducing the build but not evaluated as - * part of policy. Since the environment field can greatly vary in structure, - * depending on the builder and recipe type, this is of form "Any". - * - * Generated from protobuf field repeated .google.protobuf.Any environment = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getEnvironment() - { - return $this->environment; - } - - /** - * Any other builder-controlled inputs necessary for correctly evaluating the - * recipe. Usually only needed for reproducing the build but not evaluated as - * part of policy. Since the environment field can greatly vary in structure, - * depending on the builder and recipe type, this is of form "Any". - * - * Generated from protobuf field repeated .google.protobuf.Any environment = 5; - * @param array<\Google\Protobuf\Any>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setEnvironment($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Any::class); - $this->environment = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RelatedUrl.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RelatedUrl.php deleted file mode 100644 index c407db0064b..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RelatedUrl.php +++ /dev/null @@ -1,101 +0,0 @@ -grafeas.v1.RelatedUrl - */ -class RelatedUrl extends \Google\Protobuf\Internal\Message -{ - /** - * Specific URL associated with the resource. - * - * Generated from protobuf field string url = 1; - */ - protected $url = ''; - /** - * Label to describe usage of the URL. - * - * Generated from protobuf field string label = 2; - */ - protected $label = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $url - * Specific URL associated with the resource. - * @type string $label - * Label to describe usage of the URL. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Common::initOnce(); - parent::__construct($data); - } - - /** - * Specific URL associated with the resource. - * - * Generated from protobuf field string url = 1; - * @return string - */ - public function getUrl() - { - return $this->url; - } - - /** - * Specific URL associated with the resource. - * - * Generated from protobuf field string url = 1; - * @param string $var - * @return $this - */ - public function setUrl($var) - { - GPBUtil::checkString($var, True); - $this->url = $var; - - return $this; - } - - /** - * Label to describe usage of the URL. - * - * Generated from protobuf field string label = 2; - * @return string - */ - public function getLabel() - { - return $this->label; - } - - /** - * Label to describe usage of the URL. - * - * Generated from protobuf field string label = 2; - * @param string $var - * @return $this - */ - public function setLabel($var) - { - GPBUtil::checkString($var, True); - $this->label = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RepoId.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RepoId.php deleted file mode 100644 index 5643c66c7c2..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/RepoId.php +++ /dev/null @@ -1,108 +0,0 @@ -grafeas.v1.RepoId - */ -class RepoId extends \Google\Protobuf\Internal\Message -{ - protected $id; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\ProjectRepoId $project_repo_id - * A combination of a project ID and a repo name. - * @type string $uid - * A server-assigned, globally unique identifier. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * A combination of a project ID and a repo name. - * - * Generated from protobuf field .grafeas.v1.ProjectRepoId project_repo_id = 1; - * @return \Grafeas\V1\ProjectRepoId|null - */ - public function getProjectRepoId() - { - return $this->readOneof(1); - } - - public function hasProjectRepoId() - { - return $this->hasOneof(1); - } - - /** - * A combination of a project ID and a repo name. - * - * Generated from protobuf field .grafeas.v1.ProjectRepoId project_repo_id = 1; - * @param \Grafeas\V1\ProjectRepoId $var - * @return $this - */ - public function setProjectRepoId($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\ProjectRepoId::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * A server-assigned, globally unique identifier. - * - * Generated from protobuf field string uid = 2; - * @return string - */ - public function getUid() - { - return $this->readOneof(2); - } - - public function hasUid() - { - return $this->hasOneof(2); - } - - /** - * A server-assigned, globally unique identifier. - * - * Generated from protobuf field string uid = 2; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getId() - { - return $this->whichOneof("id"); - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Severity.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Severity.php deleted file mode 100644 index 698112c5460..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Severity.php +++ /dev/null @@ -1,82 +0,0 @@ -grafeas.v1.Severity - */ -class Severity -{ - /** - * Unknown. - * - * Generated from protobuf enum SEVERITY_UNSPECIFIED = 0; - */ - const SEVERITY_UNSPECIFIED = 0; - /** - * Minimal severity. - * - * Generated from protobuf enum MINIMAL = 1; - */ - const MINIMAL = 1; - /** - * Low severity. - * - * Generated from protobuf enum LOW = 2; - */ - const LOW = 2; - /** - * Medium severity. - * - * Generated from protobuf enum MEDIUM = 3; - */ - const MEDIUM = 3; - /** - * High severity. - * - * Generated from protobuf enum HIGH = 4; - */ - const HIGH = 4; - /** - * Critical severity. - * - * Generated from protobuf enum CRITICAL = 5; - */ - const CRITICAL = 5; - - private static $valueToName = [ - self::SEVERITY_UNSPECIFIED => 'SEVERITY_UNSPECIFIED', - self::MINIMAL => 'MINIMAL', - self::LOW => 'LOW', - self::MEDIUM => 'MEDIUM', - self::HIGH => 'HIGH', - self::CRITICAL => 'CRITICAL', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Signature.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Signature.php deleted file mode 100644 index de57d7bfe08..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Signature.php +++ /dev/null @@ -1,192 +0,0 @@ -grafeas.v1.Signature - */ -class Signature extends \Google\Protobuf\Internal\Message -{ - /** - * The content of the signature, an opaque bytestring. - * The payload that this signature verifies MUST be unambiguously provided - * with the Signature during verification. A wrapper message might provide - * the payload explicitly. Alternatively, a message might have a canonical - * serialization that can always be unambiguously computed to derive the - * payload. - * - * Generated from protobuf field bytes signature = 1; - */ - protected $signature = ''; - /** - * The identifier for the public key that verifies this signature. - * * The `public_key_id` is required. - * * The `public_key_id` SHOULD be an RFC3986 conformant URI. - * * When possible, the `public_key_id` SHOULD be an immutable reference, - * such as a cryptographic digest. - * Examples of valid `public_key_id`s: - * OpenPGP V4 public key fingerprint: - * * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" - * See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more - * details on this scheme. - * RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER - * serialization): - * * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" - * * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" - * - * Generated from protobuf field string public_key_id = 2; - */ - protected $public_key_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $signature - * The content of the signature, an opaque bytestring. - * The payload that this signature verifies MUST be unambiguously provided - * with the Signature during verification. A wrapper message might provide - * the payload explicitly. Alternatively, a message might have a canonical - * serialization that can always be unambiguously computed to derive the - * payload. - * @type string $public_key_id - * The identifier for the public key that verifies this signature. - * * The `public_key_id` is required. - * * The `public_key_id` SHOULD be an RFC3986 conformant URI. - * * When possible, the `public_key_id` SHOULD be an immutable reference, - * such as a cryptographic digest. - * Examples of valid `public_key_id`s: - * OpenPGP V4 public key fingerprint: - * * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" - * See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more - * details on this scheme. - * RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER - * serialization): - * * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" - * * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Common::initOnce(); - parent::__construct($data); - } - - /** - * The content of the signature, an opaque bytestring. - * The payload that this signature verifies MUST be unambiguously provided - * with the Signature during verification. A wrapper message might provide - * the payload explicitly. Alternatively, a message might have a canonical - * serialization that can always be unambiguously computed to derive the - * payload. - * - * Generated from protobuf field bytes signature = 1; - * @return string - */ - public function getSignature() - { - return $this->signature; - } - - /** - * The content of the signature, an opaque bytestring. - * The payload that this signature verifies MUST be unambiguously provided - * with the Signature during verification. A wrapper message might provide - * the payload explicitly. Alternatively, a message might have a canonical - * serialization that can always be unambiguously computed to derive the - * payload. - * - * Generated from protobuf field bytes signature = 1; - * @param string $var - * @return $this - */ - public function setSignature($var) - { - GPBUtil::checkString($var, False); - $this->signature = $var; - - return $this; - } - - /** - * The identifier for the public key that verifies this signature. - * * The `public_key_id` is required. - * * The `public_key_id` SHOULD be an RFC3986 conformant URI. - * * When possible, the `public_key_id` SHOULD be an immutable reference, - * such as a cryptographic digest. - * Examples of valid `public_key_id`s: - * OpenPGP V4 public key fingerprint: - * * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" - * See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more - * details on this scheme. - * RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER - * serialization): - * * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" - * * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" - * - * Generated from protobuf field string public_key_id = 2; - * @return string - */ - public function getPublicKeyId() - { - return $this->public_key_id; - } - - /** - * The identifier for the public key that verifies this signature. - * * The `public_key_id` is required. - * * The `public_key_id` SHOULD be an RFC3986 conformant URI. - * * When possible, the `public_key_id` SHOULD be an immutable reference, - * such as a cryptographic digest. - * Examples of valid `public_key_id`s: - * OpenPGP V4 public key fingerprint: - * * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" - * See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more - * details on this scheme. - * RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER - * serialization): - * * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" - * * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" - * - * Generated from protobuf field string public_key_id = 2; - * @param string $var - * @return $this - */ - public function setPublicKeyId($var) - { - GPBUtil::checkString($var, True); - $this->public_key_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance.php deleted file mode 100644 index 0113d091326..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance.php +++ /dev/null @@ -1,214 +0,0 @@ -grafeas.v1.SlsaProvenance - */ -class SlsaProvenance extends \Google\Protobuf\Internal\Message -{ - /** - * required - * - * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaBuilder builder = 1; - */ - protected $builder = null; - /** - * Identifies the configuration used for the build. - * When combined with materials, this SHOULD fully describe the build, - * such that re-running this recipe results in bit-for-bit identical output - * (if the build is reproducible). - * - * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaRecipe recipe = 2; - */ - protected $recipe = null; - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaMetadata metadata = 3; - */ - protected $metadata = null; - /** - * The collection of artifacts that influenced the build including sources, - * dependencies, build tools, base images, and so on. This is considered to be - * incomplete unless metadata.completeness.materials is true. Unset or null is - * equivalent to empty. - * - * Generated from protobuf field repeated .grafeas.v1.SlsaProvenance.Material materials = 4; - */ - private $materials; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\SlsaProvenance\SlsaBuilder $builder - * required - * @type \Grafeas\V1\SlsaProvenance\SlsaRecipe $recipe - * Identifies the configuration used for the build. - * When combined with materials, this SHOULD fully describe the build, - * such that re-running this recipe results in bit-for-bit identical output - * (if the build is reproducible). - * @type \Grafeas\V1\SlsaProvenance\SlsaMetadata $metadata - * @type array<\Grafeas\V1\SlsaProvenance\Material>|\Google\Protobuf\Internal\RepeatedField $materials - * The collection of artifacts that influenced the build including sources, - * dependencies, build tools, base images, and so on. This is considered to be - * incomplete unless metadata.completeness.materials is true. Unset or null is - * equivalent to empty. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenance::initOnce(); - parent::__construct($data); - } - - /** - * required - * - * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaBuilder builder = 1; - * @return \Grafeas\V1\SlsaProvenance\SlsaBuilder|null - */ - public function getBuilder() - { - return $this->builder; - } - - public function hasBuilder() - { - return isset($this->builder); - } - - public function clearBuilder() - { - unset($this->builder); - } - - /** - * required - * - * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaBuilder builder = 1; - * @param \Grafeas\V1\SlsaProvenance\SlsaBuilder $var - * @return $this - */ - public function setBuilder($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenance\SlsaBuilder::class); - $this->builder = $var; - - return $this; - } - - /** - * Identifies the configuration used for the build. - * When combined with materials, this SHOULD fully describe the build, - * such that re-running this recipe results in bit-for-bit identical output - * (if the build is reproducible). - * - * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaRecipe recipe = 2; - * @return \Grafeas\V1\SlsaProvenance\SlsaRecipe|null - */ - public function getRecipe() - { - return $this->recipe; - } - - public function hasRecipe() - { - return isset($this->recipe); - } - - public function clearRecipe() - { - unset($this->recipe); - } - - /** - * Identifies the configuration used for the build. - * When combined with materials, this SHOULD fully describe the build, - * such that re-running this recipe results in bit-for-bit identical output - * (if the build is reproducible). - * - * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaRecipe recipe = 2; - * @param \Grafeas\V1\SlsaProvenance\SlsaRecipe $var - * @return $this - */ - public function setRecipe($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenance\SlsaRecipe::class); - $this->recipe = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaMetadata metadata = 3; - * @return \Grafeas\V1\SlsaProvenance\SlsaMetadata|null - */ - public function getMetadata() - { - return $this->metadata; - } - - public function hasMetadata() - { - return isset($this->metadata); - } - - public function clearMetadata() - { - unset($this->metadata); - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaMetadata metadata = 3; - * @param \Grafeas\V1\SlsaProvenance\SlsaMetadata $var - * @return $this - */ - public function setMetadata($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenance\SlsaMetadata::class); - $this->metadata = $var; - - return $this; - } - - /** - * The collection of artifacts that influenced the build including sources, - * dependencies, build tools, base images, and so on. This is considered to be - * incomplete unless metadata.completeness.materials is true. Unset or null is - * equivalent to empty. - * - * Generated from protobuf field repeated .grafeas.v1.SlsaProvenance.Material materials = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMaterials() - { - return $this->materials; - } - - /** - * The collection of artifacts that influenced the build including sources, - * dependencies, build tools, base images, and so on. This is considered to be - * incomplete unless metadata.completeness.materials is true. Unset or null is - * equivalent to empty. - * - * Generated from protobuf field repeated .grafeas.v1.SlsaProvenance.Material materials = 4; - * @param array<\Grafeas\V1\SlsaProvenance\Material>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMaterials($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\SlsaProvenance\Material::class); - $this->materials = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/Material.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/Material.php deleted file mode 100644 index d2165056a94..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/Material.php +++ /dev/null @@ -1,88 +0,0 @@ -grafeas.v1.SlsaProvenance.Material - */ -class Material extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field string uri = 1; - */ - protected $uri = ''; - /** - * Generated from protobuf field map digest = 2; - */ - private $digest; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $uri - * @type array|\Google\Protobuf\Internal\MapField $digest - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenance::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field string uri = 1; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * Generated from protobuf field string uri = 1; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Generated from protobuf field map digest = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getDigest() - { - return $this->digest; - } - - /** - * Generated from protobuf field map digest = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setDigest($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->digest = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Material::class, \Grafeas\V1\SlsaProvenance_Material::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaBuilder.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaBuilder.php deleted file mode 100644 index 455fa4993f0..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaBuilder.php +++ /dev/null @@ -1,61 +0,0 @@ -grafeas.v1.SlsaProvenance.SlsaBuilder - */ -class SlsaBuilder extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field string id = 1; - */ - protected $id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $id - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenance::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field string id = 1; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Generated from protobuf field string id = 1; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SlsaBuilder::class, \Grafeas\V1\SlsaProvenance_SlsaBuilder::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaCompleteness.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaCompleteness.php deleted file mode 100644 index 15d1ba47810..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaCompleteness.php +++ /dev/null @@ -1,151 +0,0 @@ -grafeas.v1.SlsaProvenance.SlsaCompleteness - */ -class SlsaCompleteness extends \Google\Protobuf\Internal\Message -{ - /** - * If true, the builder claims that recipe.arguments is complete, meaning - * that all external inputs are properly captured in the recipe. - * - * Generated from protobuf field bool arguments = 1; - */ - protected $arguments = false; - /** - * If true, the builder claims that recipe.environment is claimed to be - * complete. - * - * Generated from protobuf field bool environment = 2; - */ - protected $environment = false; - /** - * If true, the builder claims that materials are complete, usually through - * some controls to prevent network access. Sometimes called "hermetic". - * - * Generated from protobuf field bool materials = 3; - */ - protected $materials = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $arguments - * If true, the builder claims that recipe.arguments is complete, meaning - * that all external inputs are properly captured in the recipe. - * @type bool $environment - * If true, the builder claims that recipe.environment is claimed to be - * complete. - * @type bool $materials - * If true, the builder claims that materials are complete, usually through - * some controls to prevent network access. Sometimes called "hermetic". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenance::initOnce(); - parent::__construct($data); - } - - /** - * If true, the builder claims that recipe.arguments is complete, meaning - * that all external inputs are properly captured in the recipe. - * - * Generated from protobuf field bool arguments = 1; - * @return bool - */ - public function getArguments() - { - return $this->arguments; - } - - /** - * If true, the builder claims that recipe.arguments is complete, meaning - * that all external inputs are properly captured in the recipe. - * - * Generated from protobuf field bool arguments = 1; - * @param bool $var - * @return $this - */ - public function setArguments($var) - { - GPBUtil::checkBool($var); - $this->arguments = $var; - - return $this; - } - - /** - * If true, the builder claims that recipe.environment is claimed to be - * complete. - * - * Generated from protobuf field bool environment = 2; - * @return bool - */ - public function getEnvironment() - { - return $this->environment; - } - - /** - * If true, the builder claims that recipe.environment is claimed to be - * complete. - * - * Generated from protobuf field bool environment = 2; - * @param bool $var - * @return $this - */ - public function setEnvironment($var) - { - GPBUtil::checkBool($var); - $this->environment = $var; - - return $this; - } - - /** - * If true, the builder claims that materials are complete, usually through - * some controls to prevent network access. Sometimes called "hermetic". - * - * Generated from protobuf field bool materials = 3; - * @return bool - */ - public function getMaterials() - { - return $this->materials; - } - - /** - * If true, the builder claims that materials are complete, usually through - * some controls to prevent network access. Sometimes called "hermetic". - * - * Generated from protobuf field bool materials = 3; - * @param bool $var - * @return $this - */ - public function setMaterials($var) - { - GPBUtil::checkBool($var); - $this->materials = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SlsaCompleteness::class, \Grafeas\V1\SlsaProvenance_SlsaCompleteness::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaMetadata.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaMetadata.php deleted file mode 100644 index 05447be11b5..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaMetadata.php +++ /dev/null @@ -1,252 +0,0 @@ -grafeas.v1.SlsaProvenance.SlsaMetadata - */ -class SlsaMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Identifies the particular build invocation, which can be useful for - * finding associated logs or other ad-hoc analysis. The value SHOULD be - * globally unique, per in-toto Provenance spec. - * - * Generated from protobuf field string build_invocation_id = 1; - */ - protected $build_invocation_id = ''; - /** - * The timestamp of when the build started. - * - * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; - */ - protected $build_started_on = null; - /** - * The timestamp of when the build completed. - * - * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; - */ - protected $build_finished_on = null; - /** - * Indicates that the builder claims certain fields in this message to be - * complete. - * - * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaCompleteness completeness = 4; - */ - protected $completeness = null; - /** - * If true, the builder claims that running the recipe on materials will - * produce bit-for-bit identical output. - * - * Generated from protobuf field bool reproducible = 5; - */ - protected $reproducible = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $build_invocation_id - * Identifies the particular build invocation, which can be useful for - * finding associated logs or other ad-hoc analysis. The value SHOULD be - * globally unique, per in-toto Provenance spec. - * @type \Google\Protobuf\Timestamp $build_started_on - * The timestamp of when the build started. - * @type \Google\Protobuf\Timestamp $build_finished_on - * The timestamp of when the build completed. - * @type \Grafeas\V1\SlsaProvenance\SlsaCompleteness $completeness - * Indicates that the builder claims certain fields in this message to be - * complete. - * @type bool $reproducible - * If true, the builder claims that running the recipe on materials will - * produce bit-for-bit identical output. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenance::initOnce(); - parent::__construct($data); - } - - /** - * Identifies the particular build invocation, which can be useful for - * finding associated logs or other ad-hoc analysis. The value SHOULD be - * globally unique, per in-toto Provenance spec. - * - * Generated from protobuf field string build_invocation_id = 1; - * @return string - */ - public function getBuildInvocationId() - { - return $this->build_invocation_id; - } - - /** - * Identifies the particular build invocation, which can be useful for - * finding associated logs or other ad-hoc analysis. The value SHOULD be - * globally unique, per in-toto Provenance spec. - * - * Generated from protobuf field string build_invocation_id = 1; - * @param string $var - * @return $this - */ - public function setBuildInvocationId($var) - { - GPBUtil::checkString($var, True); - $this->build_invocation_id = $var; - - return $this; - } - - /** - * The timestamp of when the build started. - * - * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getBuildStartedOn() - { - return $this->build_started_on; - } - - public function hasBuildStartedOn() - { - return isset($this->build_started_on); - } - - public function clearBuildStartedOn() - { - unset($this->build_started_on); - } - - /** - * The timestamp of when the build started. - * - * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setBuildStartedOn($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->build_started_on = $var; - - return $this; - } - - /** - * The timestamp of when the build completed. - * - * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getBuildFinishedOn() - { - return $this->build_finished_on; - } - - public function hasBuildFinishedOn() - { - return isset($this->build_finished_on); - } - - public function clearBuildFinishedOn() - { - unset($this->build_finished_on); - } - - /** - * The timestamp of when the build completed. - * - * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setBuildFinishedOn($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->build_finished_on = $var; - - return $this; - } - - /** - * Indicates that the builder claims certain fields in this message to be - * complete. - * - * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaCompleteness completeness = 4; - * @return \Grafeas\V1\SlsaProvenance\SlsaCompleteness|null - */ - public function getCompleteness() - { - return $this->completeness; - } - - public function hasCompleteness() - { - return isset($this->completeness); - } - - public function clearCompleteness() - { - unset($this->completeness); - } - - /** - * Indicates that the builder claims certain fields in this message to be - * complete. - * - * Generated from protobuf field .grafeas.v1.SlsaProvenance.SlsaCompleteness completeness = 4; - * @param \Grafeas\V1\SlsaProvenance\SlsaCompleteness $var - * @return $this - */ - public function setCompleteness($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenance\SlsaCompleteness::class); - $this->completeness = $var; - - return $this; - } - - /** - * If true, the builder claims that running the recipe on materials will - * produce bit-for-bit identical output. - * - * Generated from protobuf field bool reproducible = 5; - * @return bool - */ - public function getReproducible() - { - return $this->reproducible; - } - - /** - * If true, the builder claims that running the recipe on materials will - * produce bit-for-bit identical output. - * - * Generated from protobuf field bool reproducible = 5; - * @param bool $var - * @return $this - */ - public function setReproducible($var) - { - GPBUtil::checkBool($var); - $this->reproducible = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SlsaMetadata::class, \Grafeas\V1\SlsaProvenance_SlsaMetadata::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaRecipe.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaRecipe.php deleted file mode 100644 index a448a91e95f..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenance/SlsaRecipe.php +++ /dev/null @@ -1,296 +0,0 @@ -grafeas.v1.SlsaProvenance.SlsaRecipe - */ -class SlsaRecipe extends \Google\Protobuf\Internal\Message -{ - /** - * URI indicating what type of recipe was performed. It determines the - * meaning of recipe.entryPoint, recipe.arguments, recipe.environment, and - * materials. - * - * Generated from protobuf field string type = 1; - */ - protected $type = ''; - /** - * Index in materials containing the recipe steps that are not implied by - * recipe.type. For example, if the recipe type were "make", then this would - * point to the source containing the Makefile, not the make program itself. - * Set to -1 if the recipe doesn't come from a material, as zero is default - * unset value for int64. - * - * Generated from protobuf field int64 defined_in_material = 2; - */ - protected $defined_in_material = 0; - /** - * String identifying the entry point into the build. - * This is often a path to a configuration file and/or a target label within - * that file. The syntax and meaning are defined by recipe.type. For - * example, if the recipe type were "make", then this would reference the - * directory in which to run make as well as which target to use. - * - * Generated from protobuf field string entry_point = 3; - */ - protected $entry_point = ''; - /** - * Collection of all external inputs that influenced the build on top of - * recipe.definedInMaterial and recipe.entryPoint. For example, if the - * recipe type were "make", then this might be the flags passed to make - * aside from the target, which is captured in recipe.entryPoint. Depending - * on the recipe Type, the structure may be different. - * - * Generated from protobuf field .google.protobuf.Any arguments = 4; - */ - protected $arguments = null; - /** - * Any other builder-controlled inputs necessary for correctly evaluating - * the recipe. Usually only needed for reproducing the build but not - * evaluated as part of policy. Depending on the recipe Type, the structure - * may be different. - * - * Generated from protobuf field .google.protobuf.Any environment = 5; - */ - protected $environment = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $type - * URI indicating what type of recipe was performed. It determines the - * meaning of recipe.entryPoint, recipe.arguments, recipe.environment, and - * materials. - * @type int|string $defined_in_material - * Index in materials containing the recipe steps that are not implied by - * recipe.type. For example, if the recipe type were "make", then this would - * point to the source containing the Makefile, not the make program itself. - * Set to -1 if the recipe doesn't come from a material, as zero is default - * unset value for int64. - * @type string $entry_point - * String identifying the entry point into the build. - * This is often a path to a configuration file and/or a target label within - * that file. The syntax and meaning are defined by recipe.type. For - * example, if the recipe type were "make", then this would reference the - * directory in which to run make as well as which target to use. - * @type \Google\Protobuf\Any $arguments - * Collection of all external inputs that influenced the build on top of - * recipe.definedInMaterial and recipe.entryPoint. For example, if the - * recipe type were "make", then this might be the flags passed to make - * aside from the target, which is captured in recipe.entryPoint. Depending - * on the recipe Type, the structure may be different. - * @type \Google\Protobuf\Any $environment - * Any other builder-controlled inputs necessary for correctly evaluating - * the recipe. Usually only needed for reproducing the build but not - * evaluated as part of policy. Depending on the recipe Type, the structure - * may be different. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenance::initOnce(); - parent::__construct($data); - } - - /** - * URI indicating what type of recipe was performed. It determines the - * meaning of recipe.entryPoint, recipe.arguments, recipe.environment, and - * materials. - * - * Generated from protobuf field string type = 1; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * URI indicating what type of recipe was performed. It determines the - * meaning of recipe.entryPoint, recipe.arguments, recipe.environment, and - * materials. - * - * Generated from protobuf field string type = 1; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Index in materials containing the recipe steps that are not implied by - * recipe.type. For example, if the recipe type were "make", then this would - * point to the source containing the Makefile, not the make program itself. - * Set to -1 if the recipe doesn't come from a material, as zero is default - * unset value for int64. - * - * Generated from protobuf field int64 defined_in_material = 2; - * @return int|string - */ - public function getDefinedInMaterial() - { - return $this->defined_in_material; - } - - /** - * Index in materials containing the recipe steps that are not implied by - * recipe.type. For example, if the recipe type were "make", then this would - * point to the source containing the Makefile, not the make program itself. - * Set to -1 if the recipe doesn't come from a material, as zero is default - * unset value for int64. - * - * Generated from protobuf field int64 defined_in_material = 2; - * @param int|string $var - * @return $this - */ - public function setDefinedInMaterial($var) - { - GPBUtil::checkInt64($var); - $this->defined_in_material = $var; - - return $this; - } - - /** - * String identifying the entry point into the build. - * This is often a path to a configuration file and/or a target label within - * that file. The syntax and meaning are defined by recipe.type. For - * example, if the recipe type were "make", then this would reference the - * directory in which to run make as well as which target to use. - * - * Generated from protobuf field string entry_point = 3; - * @return string - */ - public function getEntryPoint() - { - return $this->entry_point; - } - - /** - * String identifying the entry point into the build. - * This is often a path to a configuration file and/or a target label within - * that file. The syntax and meaning are defined by recipe.type. For - * example, if the recipe type were "make", then this would reference the - * directory in which to run make as well as which target to use. - * - * Generated from protobuf field string entry_point = 3; - * @param string $var - * @return $this - */ - public function setEntryPoint($var) - { - GPBUtil::checkString($var, True); - $this->entry_point = $var; - - return $this; - } - - /** - * Collection of all external inputs that influenced the build on top of - * recipe.definedInMaterial and recipe.entryPoint. For example, if the - * recipe type were "make", then this might be the flags passed to make - * aside from the target, which is captured in recipe.entryPoint. Depending - * on the recipe Type, the structure may be different. - * - * Generated from protobuf field .google.protobuf.Any arguments = 4; - * @return \Google\Protobuf\Any|null - */ - public function getArguments() - { - return $this->arguments; - } - - public function hasArguments() - { - return isset($this->arguments); - } - - public function clearArguments() - { - unset($this->arguments); - } - - /** - * Collection of all external inputs that influenced the build on top of - * recipe.definedInMaterial and recipe.entryPoint. For example, if the - * recipe type were "make", then this might be the flags passed to make - * aside from the target, which is captured in recipe.entryPoint. Depending - * on the recipe Type, the structure may be different. - * - * Generated from protobuf field .google.protobuf.Any arguments = 4; - * @param \Google\Protobuf\Any $var - * @return $this - */ - public function setArguments($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Any::class); - $this->arguments = $var; - - return $this; - } - - /** - * Any other builder-controlled inputs necessary for correctly evaluating - * the recipe. Usually only needed for reproducing the build but not - * evaluated as part of policy. Depending on the recipe Type, the structure - * may be different. - * - * Generated from protobuf field .google.protobuf.Any environment = 5; - * @return \Google\Protobuf\Any|null - */ - public function getEnvironment() - { - return $this->environment; - } - - public function hasEnvironment() - { - return isset($this->environment); - } - - public function clearEnvironment() - { - unset($this->environment); - } - - /** - * Any other builder-controlled inputs necessary for correctly evaluating - * the recipe. Usually only needed for reproducing the build but not - * evaluated as part of policy. Depending on the recipe Type, the structure - * may be different. - * - * Generated from protobuf field .google.protobuf.Any environment = 5; - * @param \Google\Protobuf\Any $var - * @return $this - */ - public function setEnvironment($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Any::class); - $this->environment = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SlsaRecipe::class, \Grafeas\V1\SlsaProvenance_SlsaRecipe::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo.php deleted file mode 100644 index c066b7a6521..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo.php +++ /dev/null @@ -1,235 +0,0 @@ -grafeas.v1.SlsaProvenanceZeroTwo - */ -class SlsaProvenanceZeroTwo extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaBuilder builder = 1; - */ - protected $builder = null; - /** - * Generated from protobuf field string build_type = 2; - */ - protected $build_type = ''; - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaInvocation invocation = 3; - */ - protected $invocation = null; - /** - * Generated from protobuf field .google.protobuf.Struct build_config = 4; - */ - protected $build_config = null; - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaMetadata metadata = 5; - */ - protected $metadata = null; - /** - * Generated from protobuf field repeated .grafeas.v1.SlsaProvenanceZeroTwo.SlsaMaterial materials = 6; - */ - private $materials; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaBuilder $builder - * @type string $build_type - * @type \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaInvocation $invocation - * @type \Google\Protobuf\Struct $build_config - * @type \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMetadata $metadata - * @type array<\Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMaterial>|\Google\Protobuf\Internal\RepeatedField $materials - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaBuilder builder = 1; - * @return \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaBuilder|null - */ - public function getBuilder() - { - return $this->builder; - } - - public function hasBuilder() - { - return isset($this->builder); - } - - public function clearBuilder() - { - unset($this->builder); - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaBuilder builder = 1; - * @param \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaBuilder $var - * @return $this - */ - public function setBuilder($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaBuilder::class); - $this->builder = $var; - - return $this; - } - - /** - * Generated from protobuf field string build_type = 2; - * @return string - */ - public function getBuildType() - { - return $this->build_type; - } - - /** - * Generated from protobuf field string build_type = 2; - * @param string $var - * @return $this - */ - public function setBuildType($var) - { - GPBUtil::checkString($var, True); - $this->build_type = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaInvocation invocation = 3; - * @return \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaInvocation|null - */ - public function getInvocation() - { - return $this->invocation; - } - - public function hasInvocation() - { - return isset($this->invocation); - } - - public function clearInvocation() - { - unset($this->invocation); - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaInvocation invocation = 3; - * @param \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaInvocation $var - * @return $this - */ - public function setInvocation($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaInvocation::class); - $this->invocation = $var; - - return $this; - } - - /** - * Generated from protobuf field .google.protobuf.Struct build_config = 4; - * @return \Google\Protobuf\Struct|null - */ - public function getBuildConfig() - { - return $this->build_config; - } - - public function hasBuildConfig() - { - return isset($this->build_config); - } - - public function clearBuildConfig() - { - unset($this->build_config); - } - - /** - * Generated from protobuf field .google.protobuf.Struct build_config = 4; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setBuildConfig($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->build_config = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaMetadata metadata = 5; - * @return \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMetadata|null - */ - public function getMetadata() - { - return $this->metadata; - } - - public function hasMetadata() - { - return isset($this->metadata); - } - - public function clearMetadata() - { - unset($this->metadata); - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaMetadata metadata = 5; - * @param \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMetadata $var - * @return $this - */ - public function setMetadata($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMetadata::class); - $this->metadata = $var; - - return $this; - } - - /** - * Generated from protobuf field repeated .grafeas.v1.SlsaProvenanceZeroTwo.SlsaMaterial materials = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMaterials() - { - return $this->materials; - } - - /** - * Generated from protobuf field repeated .grafeas.v1.SlsaProvenanceZeroTwo.SlsaMaterial materials = 6; - * @param array<\Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMaterial>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMaterials($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaMaterial::class); - $this->materials = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaBuilder.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaBuilder.php deleted file mode 100644 index 8029c7d4c11..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaBuilder.php +++ /dev/null @@ -1,64 +0,0 @@ -grafeas.v1.SlsaProvenanceZeroTwo.SlsaBuilder - */ -class SlsaBuilder extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field string id = 1; - */ - protected $id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $id - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field string id = 1; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Generated from protobuf field string id = 1; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SlsaBuilder::class, \Grafeas\V1\SlsaProvenanceZeroTwo_SlsaBuilder::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaCompleteness.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaCompleteness.php deleted file mode 100644 index dcb6e0a819c..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaCompleteness.php +++ /dev/null @@ -1,118 +0,0 @@ -grafeas.v1.SlsaProvenanceZeroTwo.SlsaCompleteness - */ -class SlsaCompleteness extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field bool parameters = 1; - */ - protected $parameters = false; - /** - * Generated from protobuf field bool environment = 2; - */ - protected $environment = false; - /** - * Generated from protobuf field bool materials = 3; - */ - protected $materials = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $parameters - * @type bool $environment - * @type bool $materials - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field bool parameters = 1; - * @return bool - */ - public function getParameters() - { - return $this->parameters; - } - - /** - * Generated from protobuf field bool parameters = 1; - * @param bool $var - * @return $this - */ - public function setParameters($var) - { - GPBUtil::checkBool($var); - $this->parameters = $var; - - return $this; - } - - /** - * Generated from protobuf field bool environment = 2; - * @return bool - */ - public function getEnvironment() - { - return $this->environment; - } - - /** - * Generated from protobuf field bool environment = 2; - * @param bool $var - * @return $this - */ - public function setEnvironment($var) - { - GPBUtil::checkBool($var); - $this->environment = $var; - - return $this; - } - - /** - * Generated from protobuf field bool materials = 3; - * @return bool - */ - public function getMaterials() - { - return $this->materials; - } - - /** - * Generated from protobuf field bool materials = 3; - * @param bool $var - * @return $this - */ - public function setMaterials($var) - { - GPBUtil::checkBool($var); - $this->materials = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SlsaCompleteness::class, \Grafeas\V1\SlsaProvenanceZeroTwo_SlsaCompleteness::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaConfigSource.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaConfigSource.php deleted file mode 100644 index 236b9d68539..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaConfigSource.php +++ /dev/null @@ -1,118 +0,0 @@ -grafeas.v1.SlsaProvenanceZeroTwo.SlsaConfigSource - */ -class SlsaConfigSource extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field string uri = 1; - */ - protected $uri = ''; - /** - * Generated from protobuf field map digest = 2; - */ - private $digest; - /** - * Generated from protobuf field string entry_point = 3; - */ - protected $entry_point = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $uri - * @type array|\Google\Protobuf\Internal\MapField $digest - * @type string $entry_point - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field string uri = 1; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * Generated from protobuf field string uri = 1; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Generated from protobuf field map digest = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getDigest() - { - return $this->digest; - } - - /** - * Generated from protobuf field map digest = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setDigest($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->digest = $arr; - - return $this; - } - - /** - * Generated from protobuf field string entry_point = 3; - * @return string - */ - public function getEntryPoint() - { - return $this->entry_point; - } - - /** - * Generated from protobuf field string entry_point = 3; - * @param string $var - * @return $this - */ - public function setEntryPoint($var) - { - GPBUtil::checkString($var, True); - $this->entry_point = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SlsaConfigSource::class, \Grafeas\V1\SlsaProvenanceZeroTwo_SlsaConfigSource::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaInvocation.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaInvocation.php deleted file mode 100644 index 14076ccc465..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaInvocation.php +++ /dev/null @@ -1,147 +0,0 @@ -grafeas.v1.SlsaProvenanceZeroTwo.SlsaInvocation - */ -class SlsaInvocation extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaConfigSource config_source = 1; - */ - protected $config_source = null; - /** - * Generated from protobuf field .google.protobuf.Struct parameters = 2; - */ - protected $parameters = null; - /** - * Generated from protobuf field .google.protobuf.Struct environment = 3; - */ - protected $environment = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaConfigSource $config_source - * @type \Google\Protobuf\Struct $parameters - * @type \Google\Protobuf\Struct $environment - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaConfigSource config_source = 1; - * @return \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaConfigSource|null - */ - public function getConfigSource() - { - return $this->config_source; - } - - public function hasConfigSource() - { - return isset($this->config_source); - } - - public function clearConfigSource() - { - unset($this->config_source); - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaConfigSource config_source = 1; - * @param \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaConfigSource $var - * @return $this - */ - public function setConfigSource($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaConfigSource::class); - $this->config_source = $var; - - return $this; - } - - /** - * Generated from protobuf field .google.protobuf.Struct parameters = 2; - * @return \Google\Protobuf\Struct|null - */ - public function getParameters() - { - return $this->parameters; - } - - public function hasParameters() - { - return isset($this->parameters); - } - - public function clearParameters() - { - unset($this->parameters); - } - - /** - * Generated from protobuf field .google.protobuf.Struct parameters = 2; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setParameters($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->parameters = $var; - - return $this; - } - - /** - * Generated from protobuf field .google.protobuf.Struct environment = 3; - * @return \Google\Protobuf\Struct|null - */ - public function getEnvironment() - { - return $this->environment; - } - - public function hasEnvironment() - { - return isset($this->environment); - } - - public function clearEnvironment() - { - unset($this->environment); - } - - /** - * Generated from protobuf field .google.protobuf.Struct environment = 3; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setEnvironment($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->environment = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SlsaInvocation::class, \Grafeas\V1\SlsaProvenanceZeroTwo_SlsaInvocation::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMaterial.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMaterial.php deleted file mode 100644 index e25c459a24c..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMaterial.php +++ /dev/null @@ -1,91 +0,0 @@ -grafeas.v1.SlsaProvenanceZeroTwo.SlsaMaterial - */ -class SlsaMaterial extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field string uri = 1; - */ - protected $uri = ''; - /** - * Generated from protobuf field map digest = 2; - */ - private $digest; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $uri - * @type array|\Google\Protobuf\Internal\MapField $digest - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field string uri = 1; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * Generated from protobuf field string uri = 1; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Generated from protobuf field map digest = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getDigest() - { - return $this->digest; - } - - /** - * Generated from protobuf field map digest = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setDigest($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->digest = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SlsaMaterial::class, \Grafeas\V1\SlsaProvenanceZeroTwo_SlsaMaterial::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMetadata.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMetadata.php deleted file mode 100644 index 611a1e27205..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo/SlsaMetadata.php +++ /dev/null @@ -1,201 +0,0 @@ -grafeas.v1.SlsaProvenanceZeroTwo.SlsaMetadata - */ -class SlsaMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field string build_invocation_id = 1; - */ - protected $build_invocation_id = ''; - /** - * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; - */ - protected $build_started_on = null; - /** - * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; - */ - protected $build_finished_on = null; - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaCompleteness completeness = 4; - */ - protected $completeness = null; - /** - * Generated from protobuf field bool reproducible = 5; - */ - protected $reproducible = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $build_invocation_id - * @type \Google\Protobuf\Timestamp $build_started_on - * @type \Google\Protobuf\Timestamp $build_finished_on - * @type \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaCompleteness $completeness - * @type bool $reproducible - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\SlsaProvenanceZeroTwo::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field string build_invocation_id = 1; - * @return string - */ - public function getBuildInvocationId() - { - return $this->build_invocation_id; - } - - /** - * Generated from protobuf field string build_invocation_id = 1; - * @param string $var - * @return $this - */ - public function setBuildInvocationId($var) - { - GPBUtil::checkString($var, True); - $this->build_invocation_id = $var; - - return $this; - } - - /** - * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getBuildStartedOn() - { - return $this->build_started_on; - } - - public function hasBuildStartedOn() - { - return isset($this->build_started_on); - } - - public function clearBuildStartedOn() - { - unset($this->build_started_on); - } - - /** - * Generated from protobuf field .google.protobuf.Timestamp build_started_on = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setBuildStartedOn($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->build_started_on = $var; - - return $this; - } - - /** - * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getBuildFinishedOn() - { - return $this->build_finished_on; - } - - public function hasBuildFinishedOn() - { - return isset($this->build_finished_on); - } - - public function clearBuildFinishedOn() - { - unset($this->build_finished_on); - } - - /** - * Generated from protobuf field .google.protobuf.Timestamp build_finished_on = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setBuildFinishedOn($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->build_finished_on = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaCompleteness completeness = 4; - * @return \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaCompleteness|null - */ - public function getCompleteness() - { - return $this->completeness; - } - - public function hasCompleteness() - { - return isset($this->completeness); - } - - public function clearCompleteness() - { - unset($this->completeness); - } - - /** - * Generated from protobuf field .grafeas.v1.SlsaProvenanceZeroTwo.SlsaCompleteness completeness = 4; - * @param \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaCompleteness $var - * @return $this - */ - public function setCompleteness($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\SlsaProvenanceZeroTwo\SlsaCompleteness::class); - $this->completeness = $var; - - return $this; - } - - /** - * Generated from protobuf field bool reproducible = 5; - * @return bool - */ - public function getReproducible() - { - return $this->reproducible; - } - - /** - * Generated from protobuf field bool reproducible = 5; - * @param bool $var - * @return $this - */ - public function setReproducible($var) - { - GPBUtil::checkBool($var); - $this->reproducible = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SlsaMetadata::class, \Grafeas\V1\SlsaProvenanceZeroTwo_SlsaMetadata::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaBuilder.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaBuilder.php deleted file mode 100644 index 47d4e33cdfd..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SlsaProvenanceZeroTwo_SlsaBuilder.php +++ /dev/null @@ -1,16 +0,0 @@ -grafeas.v1.Source - */ -class Source extends \Google\Protobuf\Internal\Message -{ - /** - * If provided, the input binary artifacts for the build came from this - * location. - * - * Generated from protobuf field string artifact_storage_source_uri = 1; - */ - protected $artifact_storage_source_uri = ''; - /** - * 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. - * - * Generated from protobuf field map file_hashes = 2; - */ - private $file_hashes; - /** - * If provided, the source code used for the build came from this location. - * - * Generated from protobuf field .grafeas.v1.SourceContext context = 3; - */ - protected $context = null; - /** - * 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. - * - * Generated from protobuf field repeated .grafeas.v1.SourceContext additional_contexts = 4; - */ - private $additional_contexts; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $artifact_storage_source_uri - * If provided, the input binary artifacts for the build came from this - * location. - * @type array|\Google\Protobuf\Internal\MapField $file_hashes - * 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. - * @type \Grafeas\V1\SourceContext $context - * If provided, the source code used for the build came from this location. - * @type array<\Grafeas\V1\SourceContext>|\Google\Protobuf\Internal\RepeatedField $additional_contexts - * 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * If provided, the input binary artifacts for the build came from this - * location. - * - * Generated from protobuf field string artifact_storage_source_uri = 1; - * @return string - */ - public function getArtifactStorageSourceUri() - { - return $this->artifact_storage_source_uri; - } - - /** - * If provided, the input binary artifacts for the build came from this - * location. - * - * Generated from protobuf field string artifact_storage_source_uri = 1; - * @param string $var - * @return $this - */ - public function setArtifactStorageSourceUri($var) - { - GPBUtil::checkString($var, True); - $this->artifact_storage_source_uri = $var; - - 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. - * - * Generated from protobuf field map file_hashes = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getFileHashes() - { - return $this->file_hashes; - } - - /** - * 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. - * - * Generated from protobuf field map file_hashes = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setFileHashes($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\FileHashes::class); - $this->file_hashes = $arr; - - return $this; - } - - /** - * If provided, the source code used for the build came from this location. - * - * Generated from protobuf field .grafeas.v1.SourceContext context = 3; - * @return \Grafeas\V1\SourceContext|null - */ - public function getContext() - { - return $this->context; - } - - public function hasContext() - { - return isset($this->context); - } - - public function clearContext() - { - unset($this->context); - } - - /** - * If provided, the source code used for the build came from this location. - * - * Generated from protobuf field .grafeas.v1.SourceContext context = 3; - * @param \Grafeas\V1\SourceContext $var - * @return $this - */ - public function setContext($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\SourceContext::class); - $this->context = $var; - - 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. - * - * Generated from protobuf field repeated .grafeas.v1.SourceContext additional_contexts = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAdditionalContexts() - { - return $this->additional_contexts; - } - - /** - * 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. - * - * Generated from protobuf field repeated .grafeas.v1.SourceContext additional_contexts = 4; - * @param array<\Grafeas\V1\SourceContext>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAdditionalContexts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\SourceContext::class); - $this->additional_contexts = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SourceContext.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SourceContext.php deleted file mode 100644 index fced17b0d00..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/SourceContext.php +++ /dev/null @@ -1,176 +0,0 @@ -grafeas.v1.SourceContext - */ -class SourceContext extends \Google\Protobuf\Internal\Message -{ - /** - * Labels with user defined metadata. - * - * Generated from protobuf field map labels = 4; - */ - private $labels; - protected $context; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\CloudRepoSourceContext $cloud_repo - * A SourceContext referring to a revision in a Google Cloud Source Repo. - * @type \Grafeas\V1\GerritSourceContext $gerrit - * A SourceContext referring to a Gerrit project. - * @type \Grafeas\V1\GitSourceContext $git - * A SourceContext referring to any third party Git repo (e.g., GitHub). - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels with user defined metadata. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Provenance::initOnce(); - parent::__construct($data); - } - - /** - * A SourceContext referring to a revision in a Google Cloud Source Repo. - * - * Generated from protobuf field .grafeas.v1.CloudRepoSourceContext cloud_repo = 1; - * @return \Grafeas\V1\CloudRepoSourceContext|null - */ - public function getCloudRepo() - { - return $this->readOneof(1); - } - - public function hasCloudRepo() - { - return $this->hasOneof(1); - } - - /** - * A SourceContext referring to a revision in a Google Cloud Source Repo. - * - * Generated from protobuf field .grafeas.v1.CloudRepoSourceContext cloud_repo = 1; - * @param \Grafeas\V1\CloudRepoSourceContext $var - * @return $this - */ - public function setCloudRepo($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\CloudRepoSourceContext::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * A SourceContext referring to a Gerrit project. - * - * Generated from protobuf field .grafeas.v1.GerritSourceContext gerrit = 2; - * @return \Grafeas\V1\GerritSourceContext|null - */ - public function getGerrit() - { - return $this->readOneof(2); - } - - public function hasGerrit() - { - return $this->hasOneof(2); - } - - /** - * A SourceContext referring to a Gerrit project. - * - * Generated from protobuf field .grafeas.v1.GerritSourceContext gerrit = 2; - * @param \Grafeas\V1\GerritSourceContext $var - * @return $this - */ - public function setGerrit($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\GerritSourceContext::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * A SourceContext referring to any third party Git repo (e.g., GitHub). - * - * Generated from protobuf field .grafeas.v1.GitSourceContext git = 3; - * @return \Grafeas\V1\GitSourceContext|null - */ - public function getGit() - { - return $this->readOneof(3); - } - - public function hasGit() - { - return $this->hasOneof(3); - } - - /** - * A SourceContext referring to any third party Git repo (e.g., GitHub). - * - * Generated from protobuf field .grafeas.v1.GitSourceContext git = 3; - * @param \Grafeas\V1\GitSourceContext $var - * @return $this - */ - public function setGit($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\GitSourceContext::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Labels with user defined metadata. - * - * Generated from protobuf field map labels = 4; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels with user defined metadata. - * - * Generated from protobuf field map labels = 4; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * @return string - */ - public function getContext() - { - return $this->whichOneof("context"); - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Subject.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Subject.php deleted file mode 100644 index 14d4fa6fe2e..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Subject.php +++ /dev/null @@ -1,104 +0,0 @@ -grafeas.v1.Subject - */ -class Subject extends \Google\Protobuf\Internal\Message -{ - /** - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * `"": ""` - * Algorithms can be e.g. sha256, sha512 - * See - * https://github.com/in-toto/attestation/blob/main/spec/field_types.md#DigestSet - * - * Generated from protobuf field map digest = 2; - */ - private $digest; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * @type array|\Google\Protobuf\Internal\MapField $digest - * `"": ""` - * Algorithms can be e.g. sha256, sha512 - * See - * https://github.com/in-toto/attestation/blob/main/spec/field_types.md#DigestSet - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\IntotoStatement::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * `"": ""` - * Algorithms can be e.g. sha256, sha512 - * See - * https://github.com/in-toto/attestation/blob/main/spec/field_types.md#DigestSet - * - * Generated from protobuf field map digest = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getDigest() - { - return $this->digest; - } - - /** - * `"": ""` - * Algorithms can be e.g. sha256, sha512 - * See - * https://github.com/in-toto/attestation/blob/main/spec/field_types.md#DigestSet - * - * Generated from protobuf field map digest = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setDigest($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->digest = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateNoteRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateNoteRequest.php deleted file mode 100644 index f9630fde979..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateNoteRequest.php +++ /dev/null @@ -1,159 +0,0 @@ -grafeas.v1.UpdateNoteRequest - */ -class UpdateNoteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * The updated note. - * - * Generated from protobuf field .grafeas.v1.Note note = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $note = null; - /** - * The fields to update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; - */ - protected $update_mask = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @type \Grafeas\V1\Note $note - * The updated note. - * @type \Google\Protobuf\FieldMask $update_mask - * The fields to update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The updated note. - * - * Generated from protobuf field .grafeas.v1.Note note = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Grafeas\V1\Note|null - */ - public function getNote() - { - return $this->note; - } - - public function hasNote() - { - return isset($this->note); - } - - public function clearNote() - { - unset($this->note); - } - - /** - * The updated note. - * - * Generated from protobuf field .grafeas.v1.Note note = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Grafeas\V1\Note $var - * @return $this - */ - public function setNote($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Note::class); - $this->note = $var; - - return $this; - } - - /** - * The fields to update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The fields to update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateOccurrenceRequest.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateOccurrenceRequest.php deleted file mode 100644 index 6e79019d4de..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpdateOccurrenceRequest.php +++ /dev/null @@ -1,159 +0,0 @@ -grafeas.v1.UpdateOccurrenceRequest - */ -class UpdateOccurrenceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * The updated occurrence. - * - * Generated from protobuf field .grafeas.v1.Occurrence occurrence = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $occurrence = null; - /** - * The fields to update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; - */ - protected $update_mask = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @type \Grafeas\V1\Occurrence $occurrence - * The updated occurrence. - * @type \Google\Protobuf\FieldMask $update_mask - * The fields to update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Grafeas::initOnce(); - parent::__construct($data); - } - - /** - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The updated occurrence. - * - * Generated from protobuf field .grafeas.v1.Occurrence occurrence = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Grafeas\V1\Occurrence|null - */ - public function getOccurrence() - { - return $this->occurrence; - } - - public function hasOccurrence() - { - return isset($this->occurrence); - } - - public function clearOccurrence() - { - unset($this->occurrence); - } - - /** - * The updated occurrence. - * - * Generated from protobuf field .grafeas.v1.Occurrence occurrence = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Grafeas\V1\Occurrence $var - * @return $this - */ - public function setOccurrence($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Occurrence::class); - $this->occurrence = $var; - - return $this; - } - - /** - * The fields to update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The fields to update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeDistribution.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeDistribution.php deleted file mode 100644 index b5b16a112b0..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeDistribution.php +++ /dev/null @@ -1,187 +0,0 @@ -grafeas.v1.UpgradeDistribution - */ -class UpgradeDistribution extends \Google\Protobuf\Internal\Message -{ - /** - * Required - The specific operating system this metadata applies to. See - * https://cpe.mitre.org/specification/. - * - * Generated from protobuf field string cpe_uri = 1; - */ - protected $cpe_uri = ''; - /** - * The operating system classification of this Upgrade, as specified by the - * upstream operating system upgrade feed. For Windows the classification is - * one of the category_ids listed at - * https://docs.microsoft.com/en-us/previous-versions/windows/desktop/ff357803(v=vs.85) - * - * Generated from protobuf field string classification = 2; - */ - protected $classification = ''; - /** - * The severity as specified by the upstream operating system. - * - * Generated from protobuf field string severity = 3; - */ - protected $severity = ''; - /** - * The cve tied to this Upgrade. - * - * Generated from protobuf field repeated string cve = 4; - */ - private $cve; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $cpe_uri - * Required - The specific operating system this metadata applies to. See - * https://cpe.mitre.org/specification/. - * @type string $classification - * The operating system classification of this Upgrade, as specified by the - * upstream operating system upgrade feed. For Windows the classification is - * one of the category_ids listed at - * https://docs.microsoft.com/en-us/previous-versions/windows/desktop/ff357803(v=vs.85) - * @type string $severity - * The severity as specified by the upstream operating system. - * @type array|\Google\Protobuf\Internal\RepeatedField $cve - * The cve tied to this Upgrade. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Upgrade::initOnce(); - parent::__construct($data); - } - - /** - * Required - The specific operating system this metadata applies to. See - * https://cpe.mitre.org/specification/. - * - * Generated from protobuf field string cpe_uri = 1; - * @return string - */ - public function getCpeUri() - { - return $this->cpe_uri; - } - - /** - * Required - The specific operating system this metadata applies to. See - * https://cpe.mitre.org/specification/. - * - * Generated from protobuf field string cpe_uri = 1; - * @param string $var - * @return $this - */ - public function setCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->cpe_uri = $var; - - return $this; - } - - /** - * The operating system classification of this Upgrade, as specified by the - * upstream operating system upgrade feed. For Windows the classification is - * one of the category_ids listed at - * https://docs.microsoft.com/en-us/previous-versions/windows/desktop/ff357803(v=vs.85) - * - * Generated from protobuf field string classification = 2; - * @return string - */ - public function getClassification() - { - return $this->classification; - } - - /** - * The operating system classification of this Upgrade, as specified by the - * upstream operating system upgrade feed. For Windows the classification is - * one of the category_ids listed at - * https://docs.microsoft.com/en-us/previous-versions/windows/desktop/ff357803(v=vs.85) - * - * Generated from protobuf field string classification = 2; - * @param string $var - * @return $this - */ - public function setClassification($var) - { - GPBUtil::checkString($var, True); - $this->classification = $var; - - return $this; - } - - /** - * The severity as specified by the upstream operating system. - * - * Generated from protobuf field string severity = 3; - * @return string - */ - public function getSeverity() - { - return $this->severity; - } - - /** - * The severity as specified by the upstream operating system. - * - * Generated from protobuf field string severity = 3; - * @param string $var - * @return $this - */ - public function setSeverity($var) - { - GPBUtil::checkString($var, True); - $this->severity = $var; - - return $this; - } - - /** - * The cve tied to this Upgrade. - * - * Generated from protobuf field repeated string cve = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCve() - { - return $this->cve; - } - - /** - * The cve tied to this Upgrade. - * - * Generated from protobuf field repeated string cve = 4; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCve($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->cve = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeNote.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeNote.php deleted file mode 100644 index b91b637b0c3..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeNote.php +++ /dev/null @@ -1,196 +0,0 @@ -grafeas.v1.UpgradeNote - */ -class UpgradeNote extends \Google\Protobuf\Internal\Message -{ - /** - * Required for non-Windows OS. The package this Upgrade is for. - * - * Generated from protobuf field string package = 1; - */ - protected $package = ''; - /** - * Required for non-Windows OS. The version of the package in machine + human - * readable form. - * - * Generated from protobuf field .grafeas.v1.Version version = 2; - */ - protected $version = null; - /** - * Metadata about the upgrade for each specific operating system. - * - * Generated from protobuf field repeated .grafeas.v1.UpgradeDistribution distributions = 3; - */ - private $distributions; - /** - * Required for Windows OS. Represents the metadata about the Windows update. - * - * Generated from protobuf field .grafeas.v1.WindowsUpdate windows_update = 4; - */ - protected $windows_update = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $package - * Required for non-Windows OS. The package this Upgrade is for. - * @type \Grafeas\V1\Version $version - * Required for non-Windows OS. The version of the package in machine + human - * readable form. - * @type array<\Grafeas\V1\UpgradeDistribution>|\Google\Protobuf\Internal\RepeatedField $distributions - * Metadata about the upgrade for each specific operating system. - * @type \Grafeas\V1\WindowsUpdate $windows_update - * Required for Windows OS. Represents the metadata about the Windows update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Upgrade::initOnce(); - parent::__construct($data); - } - - /** - * Required for non-Windows OS. The package this Upgrade is for. - * - * Generated from protobuf field string package = 1; - * @return string - */ - public function getPackage() - { - return $this->package; - } - - /** - * Required for non-Windows OS. The package this Upgrade is for. - * - * Generated from protobuf field string package = 1; - * @param string $var - * @return $this - */ - public function setPackage($var) - { - GPBUtil::checkString($var, True); - $this->package = $var; - - return $this; - } - - /** - * Required for non-Windows OS. The version of the package in machine + human - * readable form. - * - * Generated from protobuf field .grafeas.v1.Version version = 2; - * @return \Grafeas\V1\Version|null - */ - public function getVersion() - { - return $this->version; - } - - public function hasVersion() - { - return isset($this->version); - } - - public function clearVersion() - { - unset($this->version); - } - - /** - * Required for non-Windows OS. The version of the package in machine + human - * readable form. - * - * Generated from protobuf field .grafeas.v1.Version version = 2; - * @param \Grafeas\V1\Version $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); - $this->version = $var; - - return $this; - } - - /** - * Metadata about the upgrade for each specific operating system. - * - * Generated from protobuf field repeated .grafeas.v1.UpgradeDistribution distributions = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDistributions() - { - return $this->distributions; - } - - /** - * Metadata about the upgrade for each specific operating system. - * - * Generated from protobuf field repeated .grafeas.v1.UpgradeDistribution distributions = 3; - * @param array<\Grafeas\V1\UpgradeDistribution>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDistributions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\UpgradeDistribution::class); - $this->distributions = $arr; - - return $this; - } - - /** - * Required for Windows OS. Represents the metadata about the Windows update. - * - * Generated from protobuf field .grafeas.v1.WindowsUpdate windows_update = 4; - * @return \Grafeas\V1\WindowsUpdate|null - */ - public function getWindowsUpdate() - { - return $this->windows_update; - } - - public function hasWindowsUpdate() - { - return isset($this->windows_update); - } - - public function clearWindowsUpdate() - { - unset($this->windows_update); - } - - /** - * Required for Windows OS. Represents the metadata about the Windows update. - * - * Generated from protobuf field .grafeas.v1.WindowsUpdate windows_update = 4; - * @param \Grafeas\V1\WindowsUpdate $var - * @return $this - */ - public function setWindowsUpdate($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\WindowsUpdate::class); - $this->windows_update = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeOccurrence.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeOccurrence.php deleted file mode 100644 index 15c700918d0..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/UpgradeOccurrence.php +++ /dev/null @@ -1,215 +0,0 @@ -grafeas.v1.UpgradeOccurrence - */ -class UpgradeOccurrence extends \Google\Protobuf\Internal\Message -{ - /** - * Required for non-Windows OS. The package this Upgrade is for. - * - * Generated from protobuf field string package = 1; - */ - protected $package = ''; - /** - * Required for non-Windows OS. The version of the package in a machine + - * human readable form. - * - * Generated from protobuf field .grafeas.v1.Version parsed_version = 3; - */ - protected $parsed_version = null; - /** - * Metadata about the upgrade for available for the specific operating system - * for the resource_url. This allows efficient filtering, as well as - * making it easier to use the occurrence. - * - * Generated from protobuf field .grafeas.v1.UpgradeDistribution distribution = 4; - */ - protected $distribution = null; - /** - * Required for Windows OS. Represents the metadata about the Windows update. - * - * Generated from protobuf field .grafeas.v1.WindowsUpdate windows_update = 5; - */ - protected $windows_update = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $package - * Required for non-Windows OS. The package this Upgrade is for. - * @type \Grafeas\V1\Version $parsed_version - * Required for non-Windows OS. The version of the package in a machine + - * human readable form. - * @type \Grafeas\V1\UpgradeDistribution $distribution - * Metadata about the upgrade for available for the specific operating system - * for the resource_url. This allows efficient filtering, as well as - * making it easier to use the occurrence. - * @type \Grafeas\V1\WindowsUpdate $windows_update - * Required for Windows OS. Represents the metadata about the Windows update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Upgrade::initOnce(); - parent::__construct($data); - } - - /** - * Required for non-Windows OS. The package this Upgrade is for. - * - * Generated from protobuf field string package = 1; - * @return string - */ - public function getPackage() - { - return $this->package; - } - - /** - * Required for non-Windows OS. The package this Upgrade is for. - * - * Generated from protobuf field string package = 1; - * @param string $var - * @return $this - */ - public function setPackage($var) - { - GPBUtil::checkString($var, True); - $this->package = $var; - - return $this; - } - - /** - * Required for non-Windows OS. The version of the package in a machine + - * human readable form. - * - * Generated from protobuf field .grafeas.v1.Version parsed_version = 3; - * @return \Grafeas\V1\Version|null - */ - public function getParsedVersion() - { - return $this->parsed_version; - } - - public function hasParsedVersion() - { - return isset($this->parsed_version); - } - - public function clearParsedVersion() - { - unset($this->parsed_version); - } - - /** - * Required for non-Windows OS. The version of the package in a machine + - * human readable form. - * - * Generated from protobuf field .grafeas.v1.Version parsed_version = 3; - * @param \Grafeas\V1\Version $var - * @return $this - */ - public function setParsedVersion($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); - $this->parsed_version = $var; - - return $this; - } - - /** - * Metadata about the upgrade for available for the specific operating system - * for the resource_url. This allows efficient filtering, as well as - * making it easier to use the occurrence. - * - * Generated from protobuf field .grafeas.v1.UpgradeDistribution distribution = 4; - * @return \Grafeas\V1\UpgradeDistribution|null - */ - public function getDistribution() - { - return $this->distribution; - } - - public function hasDistribution() - { - return isset($this->distribution); - } - - public function clearDistribution() - { - unset($this->distribution); - } - - /** - * Metadata about the upgrade for available for the specific operating system - * for the resource_url. This allows efficient filtering, as well as - * making it easier to use the occurrence. - * - * Generated from protobuf field .grafeas.v1.UpgradeDistribution distribution = 4; - * @param \Grafeas\V1\UpgradeDistribution $var - * @return $this - */ - public function setDistribution($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\UpgradeDistribution::class); - $this->distribution = $var; - - return $this; - } - - /** - * Required for Windows OS. Represents the metadata about the Windows update. - * - * Generated from protobuf field .grafeas.v1.WindowsUpdate windows_update = 5; - * @return \Grafeas\V1\WindowsUpdate|null - */ - public function getWindowsUpdate() - { - return $this->windows_update; - } - - public function hasWindowsUpdate() - { - return isset($this->windows_update); - } - - public function clearWindowsUpdate() - { - unset($this->windows_update); - } - - /** - * Required for Windows OS. Represents the metadata about the Windows update. - * - * Generated from protobuf field .grafeas.v1.WindowsUpdate windows_update = 5; - * @param \Grafeas\V1\WindowsUpdate $var - * @return $this - */ - public function setWindowsUpdate($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\WindowsUpdate::class); - $this->windows_update = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version.php deleted file mode 100644 index ed635362b2f..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version.php +++ /dev/null @@ -1,269 +0,0 @@ -grafeas.v1.Version - */ -class Version extends \Google\Protobuf\Internal\Message -{ - /** - * Used to correct mistakes in the version numbering scheme. - * - * Generated from protobuf field int32 epoch = 1; - */ - protected $epoch = 0; - /** - * Required only when version kind is NORMAL. The main part of the version - * name. - * - * Generated from protobuf field string name = 2; - */ - protected $name = ''; - /** - * The iteration of the package build from the above version. - * - * Generated from protobuf field string revision = 3; - */ - protected $revision = ''; - /** - * Whether this version is specifying part of an inclusive range. Grafeas - * does not have the capability to specify version ranges; instead we have - * fields that specify start version and end versions. At times this is - * insufficient - we also need to specify whether the version is included in - * the range or is excluded from the range. This boolean is expected to be set - * to true when the version is included in a range. - * - * Generated from protobuf field bool inclusive = 6; - */ - protected $inclusive = false; - /** - * Required. Distinguishes between sentinel MIN/MAX versions and normal - * versions. - * - * Generated from protobuf field .grafeas.v1.Version.VersionKind kind = 4; - */ - protected $kind = 0; - /** - * Human readable version string. This string is of the form - * :- and is only set when kind is NORMAL. - * - * Generated from protobuf field string full_name = 5; - */ - protected $full_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $epoch - * Used to correct mistakes in the version numbering scheme. - * @type string $name - * Required only when version kind is NORMAL. The main part of the version - * name. - * @type string $revision - * The iteration of the package build from the above version. - * @type bool $inclusive - * Whether this version is specifying part of an inclusive range. Grafeas - * does not have the capability to specify version ranges; instead we have - * fields that specify start version and end versions. At times this is - * insufficient - we also need to specify whether the version is included in - * the range or is excluded from the range. This boolean is expected to be set - * to true when the version is included in a range. - * @type int $kind - * Required. Distinguishes between sentinel MIN/MAX versions and normal - * versions. - * @type string $full_name - * Human readable version string. This string is of the form - * :- and is only set when kind is NORMAL. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Package::initOnce(); - parent::__construct($data); - } - - /** - * Used to correct mistakes in the version numbering scheme. - * - * Generated from protobuf field int32 epoch = 1; - * @return int - */ - public function getEpoch() - { - return $this->epoch; - } - - /** - * Used to correct mistakes in the version numbering scheme. - * - * Generated from protobuf field int32 epoch = 1; - * @param int $var - * @return $this - */ - public function setEpoch($var) - { - GPBUtil::checkInt32($var); - $this->epoch = $var; - - return $this; - } - - /** - * Required only when version kind is NORMAL. The main part of the version - * name. - * - * Generated from protobuf field string name = 2; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required only when version kind is NORMAL. The main part of the version - * name. - * - * Generated from protobuf field string name = 2; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The iteration of the package build from the above version. - * - * Generated from protobuf field string revision = 3; - * @return string - */ - public function getRevision() - { - return $this->revision; - } - - /** - * The iteration of the package build from the above version. - * - * Generated from protobuf field string revision = 3; - * @param string $var - * @return $this - */ - public function setRevision($var) - { - GPBUtil::checkString($var, True); - $this->revision = $var; - - return $this; - } - - /** - * Whether this version is specifying part of an inclusive range. Grafeas - * does not have the capability to specify version ranges; instead we have - * fields that specify start version and end versions. At times this is - * insufficient - we also need to specify whether the version is included in - * the range or is excluded from the range. This boolean is expected to be set - * to true when the version is included in a range. - * - * Generated from protobuf field bool inclusive = 6; - * @return bool - */ - public function getInclusive() - { - return $this->inclusive; - } - - /** - * Whether this version is specifying part of an inclusive range. Grafeas - * does not have the capability to specify version ranges; instead we have - * fields that specify start version and end versions. At times this is - * insufficient - we also need to specify whether the version is included in - * the range or is excluded from the range. This boolean is expected to be set - * to true when the version is included in a range. - * - * Generated from protobuf field bool inclusive = 6; - * @param bool $var - * @return $this - */ - public function setInclusive($var) - { - GPBUtil::checkBool($var); - $this->inclusive = $var; - - return $this; - } - - /** - * Required. Distinguishes between sentinel MIN/MAX versions and normal - * versions. - * - * Generated from protobuf field .grafeas.v1.Version.VersionKind kind = 4; - * @return int - */ - public function getKind() - { - return $this->kind; - } - - /** - * Required. Distinguishes between sentinel MIN/MAX versions and normal - * versions. - * - * Generated from protobuf field .grafeas.v1.Version.VersionKind kind = 4; - * @param int $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\Version\VersionKind::class); - $this->kind = $var; - - return $this; - } - - /** - * Human readable version string. This string is of the form - * :- and is only set when kind is NORMAL. - * - * Generated from protobuf field string full_name = 5; - * @return string - */ - public function getFullName() - { - return $this->full_name; - } - - /** - * Human readable version string. This string is of the form - * :- and is only set when kind is NORMAL. - * - * Generated from protobuf field string full_name = 5; - * @param string $var - * @return $this - */ - public function setFullName($var) - { - GPBUtil::checkString($var, True); - $this->full_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version/VersionKind.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version/VersionKind.php deleted file mode 100644 index d978c7d44cf..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version/VersionKind.php +++ /dev/null @@ -1,71 +0,0 @@ -grafeas.v1.Version.VersionKind - */ -class VersionKind -{ - /** - * Unknown. - * - * Generated from protobuf enum VERSION_KIND_UNSPECIFIED = 0; - */ - const VERSION_KIND_UNSPECIFIED = 0; - /** - * A standard package version. - * - * Generated from protobuf enum NORMAL = 1; - */ - const NORMAL = 1; - /** - * A special version representing negative infinity. - * - * Generated from protobuf enum MINIMUM = 2; - */ - const MINIMUM = 2; - /** - * A special version representing positive infinity. - * - * Generated from protobuf enum MAXIMUM = 3; - */ - const MAXIMUM = 3; - - private static $valueToName = [ - self::VERSION_KIND_UNSPECIFIED => 'VERSION_KIND_UNSPECIFIED', - self::NORMAL => 'NORMAL', - self::MINIMUM => 'MINIMUM', - self::MAXIMUM => 'MAXIMUM', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(VersionKind::class, \Grafeas\V1\Version_VersionKind::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version_VersionKind.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version_VersionKind.php deleted file mode 100644 index 681173bb0c7..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/Version_VersionKind.php +++ /dev/null @@ -1,16 +0,0 @@ -grafeas.v1.VulnerabilityNote - */ -class VulnerabilityNote extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field float cvss_score = 1; - */ - protected $cvss_score = 0.0; - /** - * The note provider assigned severity of this vulnerability. - * - * Generated from protobuf field .grafeas.v1.Severity severity = 2; - */ - protected $severity = 0; - /** - * Details of all known distros and packages affected by this vulnerability. - * - * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.Detail details = 3; - */ - private $details; - /** - * The full description of the CVSSv3 for this vulnerability. - * - * Generated from protobuf field .grafeas.v1.CVSSv3 cvss_v3 = 4; - */ - protected $cvss_v3 = null; - /** - * Windows details get their own format because the information format and - * model don't match a normal detail. Specifically Windows updates are done as - * patches, thus Windows vulnerabilities really are a missing package, rather - * than a package being at an incorrect version. - * - * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.WindowsDetail windows_details = 5; - */ - private $windows_details; - /** - * The time this information was last changed at the source. This is an - * upstream timestamp from the underlying information source - e.g. Ubuntu - * security tracker. - * - * Generated from protobuf field .google.protobuf.Timestamp source_update_time = 6; - */ - protected $source_update_time = null; - /** - * CVSS version used to populate cvss_score and severity. - * - * Generated from protobuf field .grafeas.v1.CVSSVersion cvss_version = 7; - */ - protected $cvss_version = 0; - /** - * The full description of the v2 CVSS for this vulnerability. - * - * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 8; - */ - protected $cvss_v2 = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $cvss_score - * 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. - * @type int $severity - * The note provider assigned severity of this vulnerability. - * @type array<\Grafeas\V1\VulnerabilityNote\Detail>|\Google\Protobuf\Internal\RepeatedField $details - * Details of all known distros and packages affected by this vulnerability. - * @type \Grafeas\V1\CVSSv3 $cvss_v3 - * The full description of the CVSSv3 for this vulnerability. - * @type array<\Grafeas\V1\VulnerabilityNote\WindowsDetail>|\Google\Protobuf\Internal\RepeatedField $windows_details - * Windows details get their own format because the information format and - * model don't match a normal detail. Specifically Windows updates are done as - * patches, thus Windows vulnerabilities really are a missing package, rather - * than a package being at an incorrect version. - * @type \Google\Protobuf\Timestamp $source_update_time - * The time this information was last changed at the source. This is an - * upstream timestamp from the underlying information source - e.g. Ubuntu - * security tracker. - * @type int $cvss_version - * CVSS version used to populate cvss_score and severity. - * @type \Grafeas\V1\CVSS $cvss_v2 - * The full description of the v2 CVSS for this vulnerability. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field float cvss_score = 1; - * @return float - */ - public function getCvssScore() - { - return $this->cvss_score; - } - - /** - * 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. - * - * Generated from protobuf field float cvss_score = 1; - * @param float $var - * @return $this - */ - public function setCvssScore($var) - { - GPBUtil::checkFloat($var); - $this->cvss_score = $var; - - return $this; - } - - /** - * The note provider assigned severity of this vulnerability. - * - * Generated from protobuf field .grafeas.v1.Severity severity = 2; - * @return int - */ - public function getSeverity() - { - return $this->severity; - } - - /** - * The note provider assigned severity of this vulnerability. - * - * Generated from protobuf field .grafeas.v1.Severity severity = 2; - * @param int $var - * @return $this - */ - public function setSeverity($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\Severity::class); - $this->severity = $var; - - return $this; - } - - /** - * Details of all known distros and packages affected by this vulnerability. - * - * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.Detail details = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDetails() - { - return $this->details; - } - - /** - * Details of all known distros and packages affected by this vulnerability. - * - * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.Detail details = 3; - * @param array<\Grafeas\V1\VulnerabilityNote\Detail>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDetails($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\VulnerabilityNote\Detail::class); - $this->details = $arr; - - return $this; - } - - /** - * The full description of the CVSSv3 for this vulnerability. - * - * Generated from protobuf field .grafeas.v1.CVSSv3 cvss_v3 = 4; - * @return \Grafeas\V1\CVSSv3|null - */ - public function getCvssV3() - { - return $this->cvss_v3; - } - - public function hasCvssV3() - { - return isset($this->cvss_v3); - } - - public function clearCvssV3() - { - unset($this->cvss_v3); - } - - /** - * The full description of the CVSSv3 for this vulnerability. - * - * Generated from protobuf field .grafeas.v1.CVSSv3 cvss_v3 = 4; - * @param \Grafeas\V1\CVSSv3 $var - * @return $this - */ - public function setCvssV3($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\CVSSv3::class); - $this->cvss_v3 = $var; - - return $this; - } - - /** - * Windows details get their own format because the information format and - * model don't match a normal detail. Specifically Windows updates are done as - * patches, thus Windows vulnerabilities really are a missing package, rather - * than a package being at an incorrect version. - * - * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.WindowsDetail windows_details = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getWindowsDetails() - { - return $this->windows_details; - } - - /** - * Windows details get their own format because the information format and - * model don't match a normal detail. Specifically Windows updates are done as - * patches, thus Windows vulnerabilities really are a missing package, rather - * than a package being at an incorrect version. - * - * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.WindowsDetail windows_details = 5; - * @param array<\Grafeas\V1\VulnerabilityNote\WindowsDetail>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setWindowsDetails($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\VulnerabilityNote\WindowsDetail::class); - $this->windows_details = $arr; - - return $this; - } - - /** - * The time this information was last changed at the source. This is an - * upstream timestamp from the underlying information source - e.g. Ubuntu - * security tracker. - * - * Generated from protobuf field .google.protobuf.Timestamp source_update_time = 6; - * @return \Google\Protobuf\Timestamp|null - */ - public function getSourceUpdateTime() - { - return $this->source_update_time; - } - - public function hasSourceUpdateTime() - { - return isset($this->source_update_time); - } - - public function clearSourceUpdateTime() - { - unset($this->source_update_time); - } - - /** - * The time this information was last changed at the source. This is an - * upstream timestamp from the underlying information source - e.g. Ubuntu - * security tracker. - * - * Generated from protobuf field .google.protobuf.Timestamp source_update_time = 6; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setSourceUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->source_update_time = $var; - - return $this; - } - - /** - * CVSS version used to populate cvss_score and severity. - * - * Generated from protobuf field .grafeas.v1.CVSSVersion cvss_version = 7; - * @return int - */ - public function getCvssVersion() - { - return $this->cvss_version; - } - - /** - * CVSS version used to populate cvss_score and severity. - * - * Generated from protobuf field .grafeas.v1.CVSSVersion cvss_version = 7; - * @param int $var - * @return $this - */ - public function setCvssVersion($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSSVersion::class); - $this->cvss_version = $var; - - return $this; - } - - /** - * The full description of the v2 CVSS for this vulnerability. - * - * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 8; - * @return \Grafeas\V1\CVSS|null - */ - public function getCvssV2() - { - return $this->cvss_v2; - } - - public function hasCvssV2() - { - return isset($this->cvss_v2); - } - - public function clearCvssV2() - { - unset($this->cvss_v2); - } - - /** - * The full description of the v2 CVSS for this vulnerability. - * - * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 8; - * @param \Grafeas\V1\CVSS $var - * @return $this - */ - public function setCvssV2($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\CVSS::class); - $this->cvss_v2 = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/Detail.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/Detail.php deleted file mode 100644 index 8bd53ea558d..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/Detail.php +++ /dev/null @@ -1,645 +0,0 @@ -grafeas.v1.VulnerabilityNote.Detail - */ -class Detail extends \Google\Protobuf\Internal\Message -{ - /** - * The distro assigned severity of this vulnerability. - * - * Generated from protobuf field string severity_name = 1; - */ - protected $severity_name = ''; - /** - * A vendor-specific description of this vulnerability. - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - /** - * The type of package; whether native or non native (e.g., ruby gems, - * node.js packages, etc.). - * - * Generated from protobuf field string package_type = 3; - */ - protected $package_type = ''; - /** - * Required. The [CPE URI](https://cpe.mitre.org/specification/) this - * vulnerability affects. - * - * Generated from protobuf field string affected_cpe_uri = 4; - */ - protected $affected_cpe_uri = ''; - /** - * Required. The package this vulnerability affects. - * - * Generated from protobuf field string affected_package = 5; - */ - protected $affected_package = ''; - /** - * The version number at the start of an interval in which this - * vulnerability exists. A vulnerability can affect a package between - * version numbers that are disjoint sets of intervals (example: - * [1.0.0-1.1.0], [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be - * represented in its own Detail. If a specific affected version is provided - * by a vulnerability database, affected_version_start and - * affected_version_end will be the same in that Detail. - * - * Generated from protobuf field .grafeas.v1.Version affected_version_start = 6; - */ - protected $affected_version_start = null; - /** - * The version number at the end of an interval in which this vulnerability - * exists. A vulnerability can affect a package between version numbers - * that are disjoint sets of intervals (example: [1.0.0-1.1.0], - * [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be represented in its - * own Detail. If a specific affected version is provided by a vulnerability - * database, affected_version_start and affected_version_end will be the - * same in that Detail. - * - * Generated from protobuf field .grafeas.v1.Version affected_version_end = 7; - */ - protected $affected_version_end = null; - /** - * The distro recommended [CPE URI](https://cpe.mitre.org/specification/) - * to update to that contains a fix for this vulnerability. It is possible - * for this to be different from the affected_cpe_uri. - * - * Generated from protobuf field string fixed_cpe_uri = 8; - */ - protected $fixed_cpe_uri = ''; - /** - * The distro recommended package to update to that contains a fix for this - * vulnerability. It is possible for this to be different from the - * affected_package. - * - * Generated from protobuf field string fixed_package = 9; - */ - protected $fixed_package = ''; - /** - * The distro recommended version to update to that contains a - * fix for this vulnerability. Setting this to VersionKind.MAXIMUM means no - * such version is yet available. - * - * Generated from protobuf field .grafeas.v1.Version fixed_version = 10; - */ - protected $fixed_version = null; - /** - * Whether this detail is obsolete. Occurrences are expected not to point to - * obsolete details. - * - * Generated from protobuf field bool is_obsolete = 11; - */ - protected $is_obsolete = false; - /** - * The time this information was last changed at the source. This is an - * upstream timestamp from the underlying information source - e.g. Ubuntu - * security tracker. - * - * Generated from protobuf field .google.protobuf.Timestamp source_update_time = 12; - */ - protected $source_update_time = null; - /** - * The source from which the information in this Detail was obtained. - * - * Generated from protobuf field string source = 13; - */ - protected $source = ''; - /** - * The name of the vendor of the product. - * - * Generated from protobuf field string vendor = 14; - */ - protected $vendor = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $severity_name - * The distro assigned severity of this vulnerability. - * @type string $description - * A vendor-specific description of this vulnerability. - * @type string $package_type - * The type of package; whether native or non native (e.g., ruby gems, - * node.js packages, etc.). - * @type string $affected_cpe_uri - * Required. The [CPE URI](https://cpe.mitre.org/specification/) this - * vulnerability affects. - * @type string $affected_package - * Required. The package this vulnerability affects. - * @type \Grafeas\V1\Version $affected_version_start - * The version number at the start of an interval in which this - * vulnerability exists. A vulnerability can affect a package between - * version numbers that are disjoint sets of intervals (example: - * [1.0.0-1.1.0], [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be - * represented in its own Detail. If a specific affected version is provided - * by a vulnerability database, affected_version_start and - * affected_version_end will be the same in that Detail. - * @type \Grafeas\V1\Version $affected_version_end - * The version number at the end of an interval in which this vulnerability - * exists. A vulnerability can affect a package between version numbers - * that are disjoint sets of intervals (example: [1.0.0-1.1.0], - * [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be represented in its - * own Detail. If a specific affected version is provided by a vulnerability - * database, affected_version_start and affected_version_end will be the - * same in that Detail. - * @type string $fixed_cpe_uri - * The distro recommended [CPE URI](https://cpe.mitre.org/specification/) - * to update to that contains a fix for this vulnerability. It is possible - * for this to be different from the affected_cpe_uri. - * @type string $fixed_package - * The distro recommended package to update to that contains a fix for this - * vulnerability. It is possible for this to be different from the - * affected_package. - * @type \Grafeas\V1\Version $fixed_version - * The distro recommended version to update to that contains a - * fix for this vulnerability. Setting this to VersionKind.MAXIMUM means no - * such version is yet available. - * @type bool $is_obsolete - * Whether this detail is obsolete. Occurrences are expected not to point to - * obsolete details. - * @type \Google\Protobuf\Timestamp $source_update_time - * The time this information was last changed at the source. This is an - * upstream timestamp from the underlying information source - e.g. Ubuntu - * security tracker. - * @type string $source - * The source from which the information in this Detail was obtained. - * @type string $vendor - * The name of the vendor of the product. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * The distro assigned severity of this vulnerability. - * - * Generated from protobuf field string severity_name = 1; - * @return string - */ - public function getSeverityName() - { - return $this->severity_name; - } - - /** - * The distro assigned severity of this vulnerability. - * - * Generated from protobuf field string severity_name = 1; - * @param string $var - * @return $this - */ - public function setSeverityName($var) - { - GPBUtil::checkString($var, True); - $this->severity_name = $var; - - return $this; - } - - /** - * A vendor-specific description of this vulnerability. - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * A vendor-specific description of this vulnerability. - * - * Generated from protobuf field string description = 2; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The type of package; whether native or non native (e.g., ruby gems, - * node.js packages, etc.). - * - * Generated from protobuf field string package_type = 3; - * @return string - */ - public function getPackageType() - { - return $this->package_type; - } - - /** - * The type of package; whether native or non native (e.g., ruby gems, - * node.js packages, etc.). - * - * Generated from protobuf field string package_type = 3; - * @param string $var - * @return $this - */ - public function setPackageType($var) - { - GPBUtil::checkString($var, True); - $this->package_type = $var; - - return $this; - } - - /** - * Required. The [CPE URI](https://cpe.mitre.org/specification/) this - * vulnerability affects. - * - * Generated from protobuf field string affected_cpe_uri = 4; - * @return string - */ - public function getAffectedCpeUri() - { - return $this->affected_cpe_uri; - } - - /** - * Required. The [CPE URI](https://cpe.mitre.org/specification/) this - * vulnerability affects. - * - * Generated from protobuf field string affected_cpe_uri = 4; - * @param string $var - * @return $this - */ - public function setAffectedCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->affected_cpe_uri = $var; - - return $this; - } - - /** - * Required. The package this vulnerability affects. - * - * Generated from protobuf field string affected_package = 5; - * @return string - */ - public function getAffectedPackage() - { - return $this->affected_package; - } - - /** - * Required. The package this vulnerability affects. - * - * Generated from protobuf field string affected_package = 5; - * @param string $var - * @return $this - */ - public function setAffectedPackage($var) - { - GPBUtil::checkString($var, True); - $this->affected_package = $var; - - return $this; - } - - /** - * The version number at the start of an interval in which this - * vulnerability exists. A vulnerability can affect a package between - * version numbers that are disjoint sets of intervals (example: - * [1.0.0-1.1.0], [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be - * represented in its own Detail. If a specific affected version is provided - * by a vulnerability database, affected_version_start and - * affected_version_end will be the same in that Detail. - * - * Generated from protobuf field .grafeas.v1.Version affected_version_start = 6; - * @return \Grafeas\V1\Version|null - */ - public function getAffectedVersionStart() - { - return $this->affected_version_start; - } - - public function hasAffectedVersionStart() - { - return isset($this->affected_version_start); - } - - public function clearAffectedVersionStart() - { - unset($this->affected_version_start); - } - - /** - * The version number at the start of an interval in which this - * vulnerability exists. A vulnerability can affect a package between - * version numbers that are disjoint sets of intervals (example: - * [1.0.0-1.1.0], [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be - * represented in its own Detail. If a specific affected version is provided - * by a vulnerability database, affected_version_start and - * affected_version_end will be the same in that Detail. - * - * Generated from protobuf field .grafeas.v1.Version affected_version_start = 6; - * @param \Grafeas\V1\Version $var - * @return $this - */ - public function setAffectedVersionStart($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); - $this->affected_version_start = $var; - - return $this; - } - - /** - * The version number at the end of an interval in which this vulnerability - * exists. A vulnerability can affect a package between version numbers - * that are disjoint sets of intervals (example: [1.0.0-1.1.0], - * [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be represented in its - * own Detail. If a specific affected version is provided by a vulnerability - * database, affected_version_start and affected_version_end will be the - * same in that Detail. - * - * Generated from protobuf field .grafeas.v1.Version affected_version_end = 7; - * @return \Grafeas\V1\Version|null - */ - public function getAffectedVersionEnd() - { - return $this->affected_version_end; - } - - public function hasAffectedVersionEnd() - { - return isset($this->affected_version_end); - } - - public function clearAffectedVersionEnd() - { - unset($this->affected_version_end); - } - - /** - * The version number at the end of an interval in which this vulnerability - * exists. A vulnerability can affect a package between version numbers - * that are disjoint sets of intervals (example: [1.0.0-1.1.0], - * [2.4.6-2.4.8] and [4.5.6-4.6.8]) each of which will be represented in its - * own Detail. If a specific affected version is provided by a vulnerability - * database, affected_version_start and affected_version_end will be the - * same in that Detail. - * - * Generated from protobuf field .grafeas.v1.Version affected_version_end = 7; - * @param \Grafeas\V1\Version $var - * @return $this - */ - public function setAffectedVersionEnd($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); - $this->affected_version_end = $var; - - return $this; - } - - /** - * The distro recommended [CPE URI](https://cpe.mitre.org/specification/) - * to update to that contains a fix for this vulnerability. It is possible - * for this to be different from the affected_cpe_uri. - * - * Generated from protobuf field string fixed_cpe_uri = 8; - * @return string - */ - public function getFixedCpeUri() - { - return $this->fixed_cpe_uri; - } - - /** - * The distro recommended [CPE URI](https://cpe.mitre.org/specification/) - * to update to that contains a fix for this vulnerability. It is possible - * for this to be different from the affected_cpe_uri. - * - * Generated from protobuf field string fixed_cpe_uri = 8; - * @param string $var - * @return $this - */ - public function setFixedCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->fixed_cpe_uri = $var; - - return $this; - } - - /** - * The distro recommended package to update to that contains a fix for this - * vulnerability. It is possible for this to be different from the - * affected_package. - * - * Generated from protobuf field string fixed_package = 9; - * @return string - */ - public function getFixedPackage() - { - return $this->fixed_package; - } - - /** - * The distro recommended package to update to that contains a fix for this - * vulnerability. It is possible for this to be different from the - * affected_package. - * - * Generated from protobuf field string fixed_package = 9; - * @param string $var - * @return $this - */ - public function setFixedPackage($var) - { - GPBUtil::checkString($var, True); - $this->fixed_package = $var; - - return $this; - } - - /** - * The distro recommended version to update to that contains a - * fix for this vulnerability. Setting this to VersionKind.MAXIMUM means no - * such version is yet available. - * - * Generated from protobuf field .grafeas.v1.Version fixed_version = 10; - * @return \Grafeas\V1\Version|null - */ - public function getFixedVersion() - { - return $this->fixed_version; - } - - public function hasFixedVersion() - { - return isset($this->fixed_version); - } - - public function clearFixedVersion() - { - unset($this->fixed_version); - } - - /** - * The distro recommended version to update to that contains a - * fix for this vulnerability. Setting this to VersionKind.MAXIMUM means no - * such version is yet available. - * - * Generated from protobuf field .grafeas.v1.Version fixed_version = 10; - * @param \Grafeas\V1\Version $var - * @return $this - */ - public function setFixedVersion($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); - $this->fixed_version = $var; - - return $this; - } - - /** - * Whether this detail is obsolete. Occurrences are expected not to point to - * obsolete details. - * - * Generated from protobuf field bool is_obsolete = 11; - * @return bool - */ - public function getIsObsolete() - { - return $this->is_obsolete; - } - - /** - * Whether this detail is obsolete. Occurrences are expected not to point to - * obsolete details. - * - * Generated from protobuf field bool is_obsolete = 11; - * @param bool $var - * @return $this - */ - public function setIsObsolete($var) - { - GPBUtil::checkBool($var); - $this->is_obsolete = $var; - - return $this; - } - - /** - * The time this information was last changed at the source. This is an - * upstream timestamp from the underlying information source - e.g. Ubuntu - * security tracker. - * - * Generated from protobuf field .google.protobuf.Timestamp source_update_time = 12; - * @return \Google\Protobuf\Timestamp|null - */ - public function getSourceUpdateTime() - { - return $this->source_update_time; - } - - public function hasSourceUpdateTime() - { - return isset($this->source_update_time); - } - - public function clearSourceUpdateTime() - { - unset($this->source_update_time); - } - - /** - * The time this information was last changed at the source. This is an - * upstream timestamp from the underlying information source - e.g. Ubuntu - * security tracker. - * - * Generated from protobuf field .google.protobuf.Timestamp source_update_time = 12; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setSourceUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->source_update_time = $var; - - return $this; - } - - /** - * The source from which the information in this Detail was obtained. - * - * Generated from protobuf field string source = 13; - * @return string - */ - public function getSource() - { - return $this->source; - } - - /** - * The source from which the information in this Detail was obtained. - * - * Generated from protobuf field string source = 13; - * @param string $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkString($var, True); - $this->source = $var; - - return $this; - } - - /** - * The name of the vendor of the product. - * - * Generated from protobuf field string vendor = 14; - * @return string - */ - public function getVendor() - { - return $this->vendor; - } - - /** - * The name of the vendor of the product. - * - * Generated from protobuf field string vendor = 14; - * @param string $var - * @return $this - */ - public function setVendor($var) - { - GPBUtil::checkString($var, True); - $this->vendor = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Detail::class, \Grafeas\V1\VulnerabilityNote_Detail::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail.php deleted file mode 100644 index e20cc151c87..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail.php +++ /dev/null @@ -1,186 +0,0 @@ -grafeas.v1.VulnerabilityNote.WindowsDetail - */ -class WindowsDetail extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The [CPE URI](https://cpe.mitre.org/specification/) this - * vulnerability affects. - * - * Generated from protobuf field string cpe_uri = 1; - */ - protected $cpe_uri = ''; - /** - * Required. The name of this vulnerability. - * - * Generated from protobuf field string name = 2; - */ - protected $name = ''; - /** - * The description of this vulnerability. - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * Required. The names of the KBs which have hotfixes to mitigate this - * vulnerability. Note that there may be multiple hotfixes (and thus - * multiple KBs) that mitigate a given vulnerability. Currently any listed - * KBs presence is considered a fix. - * - * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.WindowsDetail.KnowledgeBase fixing_kbs = 4; - */ - private $fixing_kbs; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $cpe_uri - * Required. The [CPE URI](https://cpe.mitre.org/specification/) this - * vulnerability affects. - * @type string $name - * Required. The name of this vulnerability. - * @type string $description - * The description of this vulnerability. - * @type array<\Grafeas\V1\VulnerabilityNote\WindowsDetail\KnowledgeBase>|\Google\Protobuf\Internal\RepeatedField $fixing_kbs - * Required. The names of the KBs which have hotfixes to mitigate this - * vulnerability. Note that there may be multiple hotfixes (and thus - * multiple KBs) that mitigate a given vulnerability. Currently any listed - * KBs presence is considered a fix. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * Required. The [CPE URI](https://cpe.mitre.org/specification/) this - * vulnerability affects. - * - * Generated from protobuf field string cpe_uri = 1; - * @return string - */ - public function getCpeUri() - { - return $this->cpe_uri; - } - - /** - * Required. The [CPE URI](https://cpe.mitre.org/specification/) this - * vulnerability affects. - * - * Generated from protobuf field string cpe_uri = 1; - * @param string $var - * @return $this - */ - public function setCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->cpe_uri = $var; - - return $this; - } - - /** - * Required. The name of this vulnerability. - * - * Generated from protobuf field string name = 2; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of this vulnerability. - * - * Generated from protobuf field string name = 2; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The description of this vulnerability. - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The description of this vulnerability. - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Required. The names of the KBs which have hotfixes to mitigate this - * vulnerability. Note that there may be multiple hotfixes (and thus - * multiple KBs) that mitigate a given vulnerability. Currently any listed - * KBs presence is considered a fix. - * - * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.WindowsDetail.KnowledgeBase fixing_kbs = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFixingKbs() - { - return $this->fixing_kbs; - } - - /** - * Required. The names of the KBs which have hotfixes to mitigate this - * vulnerability. Note that there may be multiple hotfixes (and thus - * multiple KBs) that mitigate a given vulnerability. Currently any listed - * KBs presence is considered a fix. - * - * Generated from protobuf field repeated .grafeas.v1.VulnerabilityNote.WindowsDetail.KnowledgeBase fixing_kbs = 4; - * @param array<\Grafeas\V1\VulnerabilityNote\WindowsDetail\KnowledgeBase>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFixingKbs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\VulnerabilityNote\WindowsDetail\KnowledgeBase::class); - $this->fixing_kbs = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(WindowsDetail::class, \Grafeas\V1\VulnerabilityNote_WindowsDetail::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail/KnowledgeBase.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail/KnowledgeBase.php deleted file mode 100644 index 26ec0c58b2f..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote/WindowsDetail/KnowledgeBase.php +++ /dev/null @@ -1,106 +0,0 @@ -grafeas.v1.VulnerabilityNote.WindowsDetail.KnowledgeBase - */ -class KnowledgeBase extends \Google\Protobuf\Internal\Message -{ - /** - * The KB name (generally of the form KB[0-9]+ (e.g., KB123456)). - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * A link to the KB in the [Windows update catalog] - * (https://www.catalog.update.microsoft.com/). - * - * Generated from protobuf field string url = 2; - */ - protected $url = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The KB name (generally of the form KB[0-9]+ (e.g., KB123456)). - * @type string $url - * A link to the KB in the [Windows update catalog] - * (https://www.catalog.update.microsoft.com/). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * The KB name (generally of the form KB[0-9]+ (e.g., KB123456)). - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The KB name (generally of the form KB[0-9]+ (e.g., KB123456)). - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * A link to the KB in the [Windows update catalog] - * (https://www.catalog.update.microsoft.com/). - * - * Generated from protobuf field string url = 2; - * @return string - */ - public function getUrl() - { - return $this->url; - } - - /** - * A link to the KB in the [Windows update catalog] - * (https://www.catalog.update.microsoft.com/). - * - * Generated from protobuf field string url = 2; - * @param string $var - * @return $this - */ - public function setUrl($var) - { - GPBUtil::checkString($var, True); - $this->url = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(KnowledgeBase::class, \Grafeas\V1\VulnerabilityNote_WindowsDetail_KnowledgeBase::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote_Detail.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote_Detail.php deleted file mode 100644 index 3406384a9d4..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityNote_Detail.php +++ /dev/null @@ -1,16 +0,0 @@ -grafeas.v1.VulnerabilityOccurrence - */ -class VulnerabilityOccurrence extends \Google\Protobuf\Internal\Message -{ - /** - * The type of package; whether native or non native (e.g., ruby gems, node.js - * packages, etc.). - * - * Generated from protobuf field string type = 1; - */ - protected $type = ''; - /** - * Output only. The note provider assigned severity of this vulnerability. - * - * Generated from protobuf field .grafeas.v1.Severity severity = 2; - */ - protected $severity = 0; - /** - * 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. - * - * Generated from protobuf field float cvss_score = 3; - */ - protected $cvss_score = 0.0; - /** - * The cvss v3 score for the vulnerability. - * - * Generated from protobuf field .grafeas.v1.CVSS cvssv3 = 10; - */ - protected $cvssv3 = null; - /** - * Required. The set of affected locations and their fixes (if available) - * within the associated resource. - * - * Generated from protobuf field repeated .grafeas.v1.VulnerabilityOccurrence.PackageIssue package_issue = 4; - */ - private $package_issue; - /** - * Output only. A one sentence description of this vulnerability. - * - * Generated from protobuf field string short_description = 5; - */ - protected $short_description = ''; - /** - * Output only. A detailed description of this vulnerability. - * - * Generated from protobuf field string long_description = 6; - */ - protected $long_description = ''; - /** - * Output only. URLs related to this vulnerability. - * - * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_urls = 7; - */ - private $related_urls; - /** - * The distro assigned severity for this vulnerability when it is available, - * otherwise this is the note provider assigned severity. - * When there are multiple PackageIssues for this vulnerability, they can have - * different effective severities because some might be provided by the distro - * while others are provided by the language ecosystem for a language pack. - * For this reason, it is advised to use the effective severity on the - * PackageIssue level. In the case where multiple PackageIssues have differing - * effective severities, this field should be the highest severity for any of - * the PackageIssues. - * - * Generated from protobuf field .grafeas.v1.Severity effective_severity = 8; - */ - protected $effective_severity = 0; - /** - * Output only. Whether at least one of the affected packages has a fix - * available. - * - * Generated from protobuf field bool fix_available = 9; - */ - protected $fix_available = false; - /** - * Output only. CVSS version used to populate cvss_score and severity. - * - * Generated from protobuf field .grafeas.v1.CVSSVersion cvss_version = 11; - */ - protected $cvss_version = 0; - /** - * The cvss v2 score for the vulnerability. - * - * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 12; - */ - protected $cvss_v2 = null; - /** - * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence.VexAssessment vex_assessment = 13; - */ - protected $vex_assessment = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $type - * The type of package; whether native or non native (e.g., ruby gems, node.js - * packages, etc.). - * @type int $severity - * Output only. The note provider assigned severity of this vulnerability. - * @type float $cvss_score - * 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. - * @type \Grafeas\V1\CVSS $cvssv3 - * The cvss v3 score for the vulnerability. - * @type array<\Grafeas\V1\VulnerabilityOccurrence\PackageIssue>|\Google\Protobuf\Internal\RepeatedField $package_issue - * Required. The set of affected locations and their fixes (if available) - * within the associated resource. - * @type string $short_description - * Output only. A one sentence description of this vulnerability. - * @type string $long_description - * Output only. A detailed description of this vulnerability. - * @type array<\Grafeas\V1\RelatedUrl>|\Google\Protobuf\Internal\RepeatedField $related_urls - * Output only. URLs related to this vulnerability. - * @type int $effective_severity - * The distro assigned severity for this vulnerability when it is available, - * otherwise this is the note provider assigned severity. - * When there are multiple PackageIssues for this vulnerability, they can have - * different effective severities because some might be provided by the distro - * while others are provided by the language ecosystem for a language pack. - * For this reason, it is advised to use the effective severity on the - * PackageIssue level. In the case where multiple PackageIssues have differing - * effective severities, this field should be the highest severity for any of - * the PackageIssues. - * @type bool $fix_available - * Output only. Whether at least one of the affected packages has a fix - * available. - * @type int $cvss_version - * Output only. CVSS version used to populate cvss_score and severity. - * @type \Grafeas\V1\CVSS $cvss_v2 - * The cvss v2 score for the vulnerability. - * @type \Grafeas\V1\VulnerabilityOccurrence\VexAssessment $vex_assessment - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * The type of package; whether native or non native (e.g., ruby gems, node.js - * packages, etc.). - * - * Generated from protobuf field string type = 1; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * The type of package; whether native or non native (e.g., ruby gems, node.js - * packages, etc.). - * - * Generated from protobuf field string type = 1; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Output only. The note provider assigned severity of this vulnerability. - * - * Generated from protobuf field .grafeas.v1.Severity severity = 2; - * @return int - */ - public function getSeverity() - { - return $this->severity; - } - - /** - * Output only. The note provider assigned severity of this vulnerability. - * - * Generated from protobuf field .grafeas.v1.Severity severity = 2; - * @param int $var - * @return $this - */ - public function setSeverity($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\Severity::class); - $this->severity = $var; - - 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. - * - * Generated from protobuf field float cvss_score = 3; - * @return float - */ - public function getCvssScore() - { - return $this->cvss_score; - } - - /** - * 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. - * - * Generated from protobuf field float cvss_score = 3; - * @param float $var - * @return $this - */ - public function setCvssScore($var) - { - GPBUtil::checkFloat($var); - $this->cvss_score = $var; - - return $this; - } - - /** - * The cvss v3 score for the vulnerability. - * - * Generated from protobuf field .grafeas.v1.CVSS cvssv3 = 10; - * @return \Grafeas\V1\CVSS|null - */ - public function getCvssv3() - { - return $this->cvssv3; - } - - public function hasCvssv3() - { - return isset($this->cvssv3); - } - - public function clearCvssv3() - { - unset($this->cvssv3); - } - - /** - * The cvss v3 score for the vulnerability. - * - * Generated from protobuf field .grafeas.v1.CVSS cvssv3 = 10; - * @param \Grafeas\V1\CVSS $var - * @return $this - */ - public function setCvssv3($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\CVSS::class); - $this->cvssv3 = $var; - - return $this; - } - - /** - * Required. The set of affected locations and their fixes (if available) - * within the associated resource. - * - * Generated from protobuf field repeated .grafeas.v1.VulnerabilityOccurrence.PackageIssue package_issue = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPackageIssue() - { - return $this->package_issue; - } - - /** - * Required. The set of affected locations and their fixes (if available) - * within the associated resource. - * - * Generated from protobuf field repeated .grafeas.v1.VulnerabilityOccurrence.PackageIssue package_issue = 4; - * @param array<\Grafeas\V1\VulnerabilityOccurrence\PackageIssue>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPackageIssue($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\VulnerabilityOccurrence\PackageIssue::class); - $this->package_issue = $arr; - - return $this; - } - - /** - * Output only. A one sentence description of this vulnerability. - * - * Generated from protobuf field string short_description = 5; - * @return string - */ - public function getShortDescription() - { - return $this->short_description; - } - - /** - * Output only. A one sentence description of this vulnerability. - * - * Generated from protobuf field string short_description = 5; - * @param string $var - * @return $this - */ - public function setShortDescription($var) - { - GPBUtil::checkString($var, True); - $this->short_description = $var; - - return $this; - } - - /** - * Output only. A detailed description of this vulnerability. - * - * Generated from protobuf field string long_description = 6; - * @return string - */ - public function getLongDescription() - { - return $this->long_description; - } - - /** - * Output only. A detailed description of this vulnerability. - * - * Generated from protobuf field string long_description = 6; - * @param string $var - * @return $this - */ - public function setLongDescription($var) - { - GPBUtil::checkString($var, True); - $this->long_description = $var; - - return $this; - } - - /** - * Output only. URLs related to this vulnerability. - * - * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_urls = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRelatedUrls() - { - return $this->related_urls; - } - - /** - * Output only. URLs related to this vulnerability. - * - * Generated from protobuf field repeated .grafeas.v1.RelatedUrl related_urls = 7; - * @param array<\Grafeas\V1\RelatedUrl>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRelatedUrls($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\RelatedUrl::class); - $this->related_urls = $arr; - - return $this; - } - - /** - * The distro assigned severity for this vulnerability when it is available, - * otherwise this is the note provider assigned severity. - * When there are multiple PackageIssues for this vulnerability, they can have - * different effective severities because some might be provided by the distro - * while others are provided by the language ecosystem for a language pack. - * For this reason, it is advised to use the effective severity on the - * PackageIssue level. In the case where multiple PackageIssues have differing - * effective severities, this field should be the highest severity for any of - * the PackageIssues. - * - * Generated from protobuf field .grafeas.v1.Severity effective_severity = 8; - * @return int - */ - public function getEffectiveSeverity() - { - return $this->effective_severity; - } - - /** - * The distro assigned severity for this vulnerability when it is available, - * otherwise this is the note provider assigned severity. - * When there are multiple PackageIssues for this vulnerability, they can have - * different effective severities because some might be provided by the distro - * while others are provided by the language ecosystem for a language pack. - * For this reason, it is advised to use the effective severity on the - * PackageIssue level. In the case where multiple PackageIssues have differing - * effective severities, this field should be the highest severity for any of - * the PackageIssues. - * - * Generated from protobuf field .grafeas.v1.Severity effective_severity = 8; - * @param int $var - * @return $this - */ - public function setEffectiveSeverity($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\Severity::class); - $this->effective_severity = $var; - - return $this; - } - - /** - * Output only. Whether at least one of the affected packages has a fix - * available. - * - * Generated from protobuf field bool fix_available = 9; - * @return bool - */ - public function getFixAvailable() - { - return $this->fix_available; - } - - /** - * Output only. Whether at least one of the affected packages has a fix - * available. - * - * Generated from protobuf field bool fix_available = 9; - * @param bool $var - * @return $this - */ - public function setFixAvailable($var) - { - GPBUtil::checkBool($var); - $this->fix_available = $var; - - return $this; - } - - /** - * Output only. CVSS version used to populate cvss_score and severity. - * - * Generated from protobuf field .grafeas.v1.CVSSVersion cvss_version = 11; - * @return int - */ - public function getCvssVersion() - { - return $this->cvss_version; - } - - /** - * Output only. CVSS version used to populate cvss_score and severity. - * - * Generated from protobuf field .grafeas.v1.CVSSVersion cvss_version = 11; - * @param int $var - * @return $this - */ - public function setCvssVersion($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\CVSSVersion::class); - $this->cvss_version = $var; - - return $this; - } - - /** - * The cvss v2 score for the vulnerability. - * - * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 12; - * @return \Grafeas\V1\CVSS|null - */ - public function getCvssV2() - { - return $this->cvss_v2; - } - - public function hasCvssV2() - { - return isset($this->cvss_v2); - } - - public function clearCvssV2() - { - unset($this->cvss_v2); - } - - /** - * The cvss v2 score for the vulnerability. - * - * Generated from protobuf field .grafeas.v1.CVSS cvss_v2 = 12; - * @param \Grafeas\V1\CVSS $var - * @return $this - */ - public function setCvssV2($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\CVSS::class); - $this->cvss_v2 = $var; - - return $this; - } - - /** - * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence.VexAssessment vex_assessment = 13; - * @return \Grafeas\V1\VulnerabilityOccurrence\VexAssessment|null - */ - public function getVexAssessment() - { - return $this->vex_assessment; - } - - public function hasVexAssessment() - { - return isset($this->vex_assessment); - } - - public function clearVexAssessment() - { - unset($this->vex_assessment); - } - - /** - * Generated from protobuf field .grafeas.v1.VulnerabilityOccurrence.VexAssessment vex_assessment = 13; - * @param \Grafeas\V1\VulnerabilityOccurrence\VexAssessment $var - * @return $this - */ - public function setVexAssessment($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\VulnerabilityOccurrence\VexAssessment::class); - $this->vex_assessment = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/PackageIssue.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/PackageIssue.php deleted file mode 100644 index 50eb18f7d2f..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence/PackageIssue.php +++ /dev/null @@ -1,429 +0,0 @@ -grafeas.v1.VulnerabilityOccurrence.PackageIssue - */ -class PackageIssue extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The [CPE URI](https://cpe.mitre.org/specification/) this - * vulnerability was found in. - * - * Generated from protobuf field string affected_cpe_uri = 1; - */ - protected $affected_cpe_uri = ''; - /** - * Required. The package this vulnerability was found in. - * - * Generated from protobuf field string affected_package = 2; - */ - protected $affected_package = ''; - /** - * Required. The version of the package that is installed on the resource - * affected by this vulnerability. - * - * Generated from protobuf field .grafeas.v1.Version affected_version = 3; - */ - protected $affected_version = null; - /** - * The [CPE URI](https://cpe.mitre.org/specification/) this vulnerability - * was fixed in. It is possible for this to be different from the - * affected_cpe_uri. - * - * Generated from protobuf field string fixed_cpe_uri = 4; - */ - protected $fixed_cpe_uri = ''; - /** - * The package this vulnerability was fixed in. It is possible for this to - * be different from the affected_package. - * - * Generated from protobuf field string fixed_package = 5; - */ - protected $fixed_package = ''; - /** - * Required. The version of the package this vulnerability was fixed in. - * Setting this to VersionKind.MAXIMUM means no fix is yet available. - * - * Generated from protobuf field .grafeas.v1.Version fixed_version = 6; - */ - protected $fixed_version = null; - /** - * Output only. Whether a fix is available for this package. - * - * Generated from protobuf field bool fix_available = 7; - */ - protected $fix_available = false; - /** - * The type of package (e.g. OS, MAVEN, GO). - * - * Generated from protobuf field string package_type = 8; - */ - protected $package_type = ''; - /** - * The distro or language system assigned severity for this vulnerability - * when that is available and note provider assigned severity when it is not - * available. - * - * Generated from protobuf field .grafeas.v1.Severity effective_severity = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $effective_severity = 0; - /** - * The location at which this package was found. - * - * Generated from protobuf field repeated .grafeas.v1.FileLocation file_location = 10; - */ - private $file_location; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $affected_cpe_uri - * Required. The [CPE URI](https://cpe.mitre.org/specification/) this - * vulnerability was found in. - * @type string $affected_package - * Required. The package this vulnerability was found in. - * @type \Grafeas\V1\Version $affected_version - * Required. The version of the package that is installed on the resource - * affected by this vulnerability. - * @type string $fixed_cpe_uri - * The [CPE URI](https://cpe.mitre.org/specification/) this vulnerability - * was fixed in. It is possible for this to be different from the - * affected_cpe_uri. - * @type string $fixed_package - * The package this vulnerability was fixed in. It is possible for this to - * be different from the affected_package. - * @type \Grafeas\V1\Version $fixed_version - * Required. The version of the package this vulnerability was fixed in. - * Setting this to VersionKind.MAXIMUM means no fix is yet available. - * @type bool $fix_available - * Output only. Whether a fix is available for this package. - * @type string $package_type - * The type of package (e.g. OS, MAVEN, GO). - * @type int $effective_severity - * The distro or language system assigned severity for this vulnerability - * when that is available and note provider assigned severity when it is not - * available. - * @type array<\Grafeas\V1\FileLocation>|\Google\Protobuf\Internal\RepeatedField $file_location - * The location at which this package was found. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * Required. The [CPE URI](https://cpe.mitre.org/specification/) this - * vulnerability was found in. - * - * Generated from protobuf field string affected_cpe_uri = 1; - * @return string - */ - public function getAffectedCpeUri() - { - return $this->affected_cpe_uri; - } - - /** - * Required. The [CPE URI](https://cpe.mitre.org/specification/) this - * vulnerability was found in. - * - * Generated from protobuf field string affected_cpe_uri = 1; - * @param string $var - * @return $this - */ - public function setAffectedCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->affected_cpe_uri = $var; - - return $this; - } - - /** - * Required. The package this vulnerability was found in. - * - * Generated from protobuf field string affected_package = 2; - * @return string - */ - public function getAffectedPackage() - { - return $this->affected_package; - } - - /** - * Required. The package this vulnerability was found in. - * - * Generated from protobuf field string affected_package = 2; - * @param string $var - * @return $this - */ - public function setAffectedPackage($var) - { - GPBUtil::checkString($var, True); - $this->affected_package = $var; - - return $this; - } - - /** - * Required. The version of the package that is installed on the resource - * affected by this vulnerability. - * - * Generated from protobuf field .grafeas.v1.Version affected_version = 3; - * @return \Grafeas\V1\Version|null - */ - public function getAffectedVersion() - { - return $this->affected_version; - } - - public function hasAffectedVersion() - { - return isset($this->affected_version); - } - - public function clearAffectedVersion() - { - unset($this->affected_version); - } - - /** - * Required. The version of the package that is installed on the resource - * affected by this vulnerability. - * - * Generated from protobuf field .grafeas.v1.Version affected_version = 3; - * @param \Grafeas\V1\Version $var - * @return $this - */ - public function setAffectedVersion($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); - $this->affected_version = $var; - - return $this; - } - - /** - * The [CPE URI](https://cpe.mitre.org/specification/) this vulnerability - * was fixed in. It is possible for this to be different from the - * affected_cpe_uri. - * - * Generated from protobuf field string fixed_cpe_uri = 4; - * @return string - */ - public function getFixedCpeUri() - { - return $this->fixed_cpe_uri; - } - - /** - * The [CPE URI](https://cpe.mitre.org/specification/) this vulnerability - * was fixed in. It is possible for this to be different from the - * affected_cpe_uri. - * - * Generated from protobuf field string fixed_cpe_uri = 4; - * @param string $var - * @return $this - */ - public function setFixedCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->fixed_cpe_uri = $var; - - return $this; - } - - /** - * The package this vulnerability was fixed in. It is possible for this to - * be different from the affected_package. - * - * Generated from protobuf field string fixed_package = 5; - * @return string - */ - public function getFixedPackage() - { - return $this->fixed_package; - } - - /** - * The package this vulnerability was fixed in. It is possible for this to - * be different from the affected_package. - * - * Generated from protobuf field string fixed_package = 5; - * @param string $var - * @return $this - */ - public function setFixedPackage($var) - { - GPBUtil::checkString($var, True); - $this->fixed_package = $var; - - return $this; - } - - /** - * Required. The version of the package this vulnerability was fixed in. - * Setting this to VersionKind.MAXIMUM means no fix is yet available. - * - * Generated from protobuf field .grafeas.v1.Version fixed_version = 6; - * @return \Grafeas\V1\Version|null - */ - public function getFixedVersion() - { - return $this->fixed_version; - } - - public function hasFixedVersion() - { - return isset($this->fixed_version); - } - - public function clearFixedVersion() - { - unset($this->fixed_version); - } - - /** - * Required. The version of the package this vulnerability was fixed in. - * Setting this to VersionKind.MAXIMUM means no fix is yet available. - * - * Generated from protobuf field .grafeas.v1.Version fixed_version = 6; - * @param \Grafeas\V1\Version $var - * @return $this - */ - public function setFixedVersion($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\Version::class); - $this->fixed_version = $var; - - return $this; - } - - /** - * Output only. Whether a fix is available for this package. - * - * Generated from protobuf field bool fix_available = 7; - * @return bool - */ - public function getFixAvailable() - { - return $this->fix_available; - } - - /** - * Output only. Whether a fix is available for this package. - * - * Generated from protobuf field bool fix_available = 7; - * @param bool $var - * @return $this - */ - public function setFixAvailable($var) - { - GPBUtil::checkBool($var); - $this->fix_available = $var; - - return $this; - } - - /** - * The type of package (e.g. OS, MAVEN, GO). - * - * Generated from protobuf field string package_type = 8; - * @return string - */ - public function getPackageType() - { - return $this->package_type; - } - - /** - * The type of package (e.g. OS, MAVEN, GO). - * - * Generated from protobuf field string package_type = 8; - * @param string $var - * @return $this - */ - public function setPackageType($var) - { - GPBUtil::checkString($var, True); - $this->package_type = $var; - - return $this; - } - - /** - * The distro or language system assigned severity for this vulnerability - * when that is available and note provider assigned severity when it is not - * available. - * - * Generated from protobuf field .grafeas.v1.Severity effective_severity = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getEffectiveSeverity() - { - return $this->effective_severity; - } - - /** - * The distro or language system assigned severity for this vulnerability - * when that is available and note provider assigned severity when it is not - * available. - * - * Generated from protobuf field .grafeas.v1.Severity effective_severity = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setEffectiveSeverity($var) - { - GPBUtil::checkEnum($var, \Grafeas\V1\Severity::class); - $this->effective_severity = $var; - - return $this; - } - - /** - * The location at which this package was found. - * - * Generated from protobuf field repeated .grafeas.v1.FileLocation file_location = 10; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFileLocation() - { - return $this->file_location; - } - - /** - * The location at which this package was found. - * - * Generated from protobuf field repeated .grafeas.v1.FileLocation file_location = 10; - * @param array<\Grafeas\V1\FileLocation>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFileLocation($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\FileLocation::class); - $this->file_location = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PackageIssue::class, \Grafeas\V1\VulnerabilityOccurrence_PackageIssue::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence_PackageIssue.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence_PackageIssue.php deleted file mode 100644 index cc29d1796f1..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/VulnerabilityOccurrence_PackageIssue.php +++ /dev/null @@ -1,16 +0,0 @@ -grafeas.v1.WindowsUpdate - */ -class WindowsUpdate extends \Google\Protobuf\Internal\Message -{ - /** - * Required - The unique identifier for the update. - * - * Generated from protobuf field .grafeas.v1.WindowsUpdate.Identity identity = 1; - */ - protected $identity = null; - /** - * The localized title of the update. - * - * Generated from protobuf field string title = 2; - */ - protected $title = ''; - /** - * The localized description of the update. - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * The list of categories to which the update belongs. - * - * Generated from protobuf field repeated .grafeas.v1.WindowsUpdate.Category categories = 4; - */ - private $categories; - /** - * The Microsoft Knowledge Base article IDs that are associated with the - * update. - * - * Generated from protobuf field repeated string kb_article_ids = 5; - */ - private $kb_article_ids; - /** - * The hyperlink to the support information for the update. - * - * Generated from protobuf field string support_url = 6; - */ - protected $support_url = ''; - /** - * The last published timestamp of the update. - * - * Generated from protobuf field .google.protobuf.Timestamp last_published_timestamp = 7; - */ - protected $last_published_timestamp = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Grafeas\V1\WindowsUpdate\Identity $identity - * Required - The unique identifier for the update. - * @type string $title - * The localized title of the update. - * @type string $description - * The localized description of the update. - * @type array<\Grafeas\V1\WindowsUpdate\Category>|\Google\Protobuf\Internal\RepeatedField $categories - * The list of categories to which the update belongs. - * @type array|\Google\Protobuf\Internal\RepeatedField $kb_article_ids - * The Microsoft Knowledge Base article IDs that are associated with the - * update. - * @type string $support_url - * The hyperlink to the support information for the update. - * @type \Google\Protobuf\Timestamp $last_published_timestamp - * The last published timestamp of the update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Upgrade::initOnce(); - parent::__construct($data); - } - - /** - * Required - The unique identifier for the update. - * - * Generated from protobuf field .grafeas.v1.WindowsUpdate.Identity identity = 1; - * @return \Grafeas\V1\WindowsUpdate\Identity|null - */ - public function getIdentity() - { - return $this->identity; - } - - public function hasIdentity() - { - return isset($this->identity); - } - - public function clearIdentity() - { - unset($this->identity); - } - - /** - * Required - The unique identifier for the update. - * - * Generated from protobuf field .grafeas.v1.WindowsUpdate.Identity identity = 1; - * @param \Grafeas\V1\WindowsUpdate\Identity $var - * @return $this - */ - public function setIdentity($var) - { - GPBUtil::checkMessage($var, \Grafeas\V1\WindowsUpdate\Identity::class); - $this->identity = $var; - - return $this; - } - - /** - * The localized title of the update. - * - * Generated from protobuf field string title = 2; - * @return string - */ - public function getTitle() - { - return $this->title; - } - - /** - * The localized title of the update. - * - * Generated from protobuf field string title = 2; - * @param string $var - * @return $this - */ - public function setTitle($var) - { - GPBUtil::checkString($var, True); - $this->title = $var; - - return $this; - } - - /** - * The localized description of the update. - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The localized description of the update. - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The list of categories to which the update belongs. - * - * Generated from protobuf field repeated .grafeas.v1.WindowsUpdate.Category categories = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCategories() - { - return $this->categories; - } - - /** - * The list of categories to which the update belongs. - * - * Generated from protobuf field repeated .grafeas.v1.WindowsUpdate.Category categories = 4; - * @param array<\Grafeas\V1\WindowsUpdate\Category>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCategories($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Grafeas\V1\WindowsUpdate\Category::class); - $this->categories = $arr; - - return $this; - } - - /** - * The Microsoft Knowledge Base article IDs that are associated with the - * update. - * - * Generated from protobuf field repeated string kb_article_ids = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getKbArticleIds() - { - return $this->kb_article_ids; - } - - /** - * The Microsoft Knowledge Base article IDs that are associated with the - * update. - * - * Generated from protobuf field repeated string kb_article_ids = 5; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setKbArticleIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->kb_article_ids = $arr; - - return $this; - } - - /** - * The hyperlink to the support information for the update. - * - * Generated from protobuf field string support_url = 6; - * @return string - */ - public function getSupportUrl() - { - return $this->support_url; - } - - /** - * The hyperlink to the support information for the update. - * - * Generated from protobuf field string support_url = 6; - * @param string $var - * @return $this - */ - public function setSupportUrl($var) - { - GPBUtil::checkString($var, True); - $this->support_url = $var; - - return $this; - } - - /** - * The last published timestamp of the update. - * - * Generated from protobuf field .google.protobuf.Timestamp last_published_timestamp = 7; - * @return \Google\Protobuf\Timestamp|null - */ - public function getLastPublishedTimestamp() - { - return $this->last_published_timestamp; - } - - public function hasLastPublishedTimestamp() - { - return isset($this->last_published_timestamp); - } - - public function clearLastPublishedTimestamp() - { - unset($this->last_published_timestamp); - } - - /** - * The last published timestamp of the update. - * - * Generated from protobuf field .google.protobuf.Timestamp last_published_timestamp = 7; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setLastPublishedTimestamp($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->last_published_timestamp = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Category.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Category.php deleted file mode 100644 index f3fc03d57a4..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Category.php +++ /dev/null @@ -1,104 +0,0 @@ -grafeas.v1.WindowsUpdate.Category - */ -class Category extends \Google\Protobuf\Internal\Message -{ - /** - * The identifier of the category. - * - * Generated from protobuf field string category_id = 1; - */ - protected $category_id = ''; - /** - * The localized name of the category. - * - * Generated from protobuf field string name = 2; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $category_id - * The identifier of the category. - * @type string $name - * The localized name of the category. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Upgrade::initOnce(); - parent::__construct($data); - } - - /** - * The identifier of the category. - * - * Generated from protobuf field string category_id = 1; - * @return string - */ - public function getCategoryId() - { - return $this->category_id; - } - - /** - * The identifier of the category. - * - * Generated from protobuf field string category_id = 1; - * @param string $var - * @return $this - */ - public function setCategoryId($var) - { - GPBUtil::checkString($var, True); - $this->category_id = $var; - - return $this; - } - - /** - * The localized name of the category. - * - * Generated from protobuf field string name = 2; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The localized name of the category. - * - * Generated from protobuf field string name = 2; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Category::class, \Grafeas\V1\WindowsUpdate_Category::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Identity.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Identity.php deleted file mode 100644 index 8d4340a93fc..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate/Identity.php +++ /dev/null @@ -1,104 +0,0 @@ -grafeas.v1.WindowsUpdate.Identity - */ -class Identity extends \Google\Protobuf\Internal\Message -{ - /** - * The revision independent identifier of the update. - * - * Generated from protobuf field string update_id = 1; - */ - protected $update_id = ''; - /** - * The revision number of the update. - * - * Generated from protobuf field int32 revision = 2; - */ - protected $revision = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $update_id - * The revision independent identifier of the update. - * @type int $revision - * The revision number of the update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Grafeas\V1\Upgrade::initOnce(); - parent::__construct($data); - } - - /** - * The revision independent identifier of the update. - * - * Generated from protobuf field string update_id = 1; - * @return string - */ - public function getUpdateId() - { - return $this->update_id; - } - - /** - * The revision independent identifier of the update. - * - * Generated from protobuf field string update_id = 1; - * @param string $var - * @return $this - */ - public function setUpdateId($var) - { - GPBUtil::checkString($var, True); - $this->update_id = $var; - - return $this; - } - - /** - * The revision number of the update. - * - * Generated from protobuf field int32 revision = 2; - * @return int - */ - public function getRevision() - { - return $this->revision; - } - - /** - * The revision number of the update. - * - * Generated from protobuf field int32 revision = 2; - * @param int $var - * @return $this - */ - public function setRevision($var) - { - GPBUtil::checkInt32($var); - $this->revision = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Identity::class, \Grafeas\V1\WindowsUpdate_Identity::class); - diff --git a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate_Category.php b/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate_Category.php deleted file mode 100644 index 4acf25cc639..00000000000 --- a/owl-bot-staging/Grafeas/v1/proto/src/Grafeas/V1/WindowsUpdate_Category.php +++ /dev/null @@ -1,16 +0,0 @@ -batchCreateNotes($formattedParent, $notes); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = GrafeasClient::projectName('[PROJECT]'); - - batch_create_notes_sample($formattedParent); -} -// [END containeranalysis_v1_generated_Grafeas_BatchCreateNotes_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/batch_create_occurrences.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/batch_create_occurrences.php deleted file mode 100644 index fe167aa897c..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/batch_create_occurrences.php +++ /dev/null @@ -1,71 +0,0 @@ -batchCreateOccurrences($formattedParent, $occurrences); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = GrafeasClient::projectName('[PROJECT]'); - - batch_create_occurrences_sample($formattedParent); -} -// [END containeranalysis_v1_generated_Grafeas_BatchCreateOccurrences_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_note.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_note.php deleted file mode 100644 index 23288a642b1..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_note.php +++ /dev/null @@ -1,72 +0,0 @@ -createNote($formattedParent, $noteId, $note); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = GrafeasClient::projectName('[PROJECT]'); - $noteId = '[NOTE_ID]'; - - create_note_sample($formattedParent, $noteId); -} -// [END containeranalysis_v1_generated_Grafeas_CreateNote_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_occurrence.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_occurrence.php deleted file mode 100644 index 3ef0cf3be2f..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/create_occurrence.php +++ /dev/null @@ -1,70 +0,0 @@ -createOccurrence($formattedParent, $occurrence); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = GrafeasClient::projectName('[PROJECT]'); - - create_occurrence_sample($formattedParent); -} -// [END containeranalysis_v1_generated_Grafeas_CreateOccurrence_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_note.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_note.php deleted file mode 100644 index 0f28ce4570e..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_note.php +++ /dev/null @@ -1,65 +0,0 @@ -deleteNote($formattedName); - printf('Call completed successfully.' . PHP_EOL); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = GrafeasClient::noteName('[PROJECT]', '[NOTE]'); - - delete_note_sample($formattedName); -} -// [END containeranalysis_v1_generated_Grafeas_DeleteNote_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_occurrence.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_occurrence.php deleted file mode 100644 index b5c45a1db5d..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/delete_occurrence.php +++ /dev/null @@ -1,67 +0,0 @@ -deleteOccurrence($formattedName); - printf('Call completed successfully.' . PHP_EOL); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = GrafeasClient::occurrenceName('[PROJECT]', '[OCCURRENCE]'); - - delete_occurrence_sample($formattedName); -} -// [END containeranalysis_v1_generated_Grafeas_DeleteOccurrence_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_note.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_note.php deleted file mode 100644 index 8e7f6b8a878..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_note.php +++ /dev/null @@ -1,67 +0,0 @@ -getNote($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = GrafeasClient::noteName('[PROJECT]', '[NOTE]'); - - get_note_sample($formattedName); -} -// [END containeranalysis_v1_generated_Grafeas_GetNote_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence.php deleted file mode 100644 index e1c746d2eed..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence.php +++ /dev/null @@ -1,67 +0,0 @@ -getOccurrence($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = GrafeasClient::occurrenceName('[PROJECT]', '[OCCURRENCE]'); - - get_occurrence_sample($formattedName); -} -// [END containeranalysis_v1_generated_Grafeas_GetOccurrence_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence_note.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence_note.php deleted file mode 100644 index f811ea3f799..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/get_occurrence_note.php +++ /dev/null @@ -1,68 +0,0 @@ -getOccurrenceNote($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = GrafeasClient::occurrenceName('[PROJECT]', '[OCCURRENCE]'); - - get_occurrence_note_sample($formattedName); -} -// [END containeranalysis_v1_generated_Grafeas_GetOccurrenceNote_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_note_occurrences.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_note_occurrences.php deleted file mode 100644 index 585f2c67bdd..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_note_occurrences.php +++ /dev/null @@ -1,74 +0,0 @@ -listNoteOccurrences($formattedName); - - /** @var Occurrence $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = GrafeasClient::noteName('[PROJECT]', '[NOTE]'); - - list_note_occurrences_sample($formattedName); -} -// [END containeranalysis_v1_generated_Grafeas_ListNoteOccurrences_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_notes.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_notes.php deleted file mode 100644 index e2efbce6d25..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_notes.php +++ /dev/null @@ -1,72 +0,0 @@ -listNotes($formattedParent); - - /** @var Note $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = GrafeasClient::projectName('[PROJECT]'); - - list_notes_sample($formattedParent); -} -// [END containeranalysis_v1_generated_Grafeas_ListNotes_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_occurrences.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_occurrences.php deleted file mode 100644 index f5fd4a42b07..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/list_occurrences.php +++ /dev/null @@ -1,72 +0,0 @@ -listOccurrences($formattedParent); - - /** @var Occurrence $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = GrafeasClient::projectName('[PROJECT]'); - - list_occurrences_sample($formattedParent); -} -// [END containeranalysis_v1_generated_Grafeas_ListOccurrences_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_note.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_note.php deleted file mode 100644 index a21bfab7faf..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_note.php +++ /dev/null @@ -1,70 +0,0 @@ -updateNote($formattedName, $note); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = GrafeasClient::noteName('[PROJECT]', '[NOTE]'); - - update_note_sample($formattedName); -} -// [END containeranalysis_v1_generated_Grafeas_UpdateNote_sync] diff --git a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_occurrence.php b/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_occurrence.php deleted file mode 100644 index d6016829c69..00000000000 --- a/owl-bot-staging/Grafeas/v1/samples/V1/GrafeasClient/update_occurrence.php +++ /dev/null @@ -1,70 +0,0 @@ -updateOccurrence($formattedName, $occurrence); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = GrafeasClient::occurrenceName('[PROJECT]', '[OCCURRENCE]'); - - update_occurrence_sample($formattedName); -} -// [END containeranalysis_v1_generated_Grafeas_UpdateOccurrence_sync] diff --git a/owl-bot-staging/Grafeas/v1/src/V1/Gapic/GrafeasGapicClient.php b/owl-bot-staging/Grafeas/v1/src/V1/Gapic/GrafeasGapicClient.php deleted file mode 100644 index 23d79eb57ed..00000000000 --- a/owl-bot-staging/Grafeas/v1/src/V1/Gapic/GrafeasGapicClient.php +++ /dev/null @@ -1,1031 +0,0 @@ -projectName('[PROJECT]'); - * $notes = []; - * $response = $grafeasClient->batchCreateNotes($formattedParent, $notes); - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * 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 parseName method to extract the individual identifiers - * contained within formatted names that are returned by the API. - */ -class GrafeasGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'grafeas.v1.Grafeas'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'containeranalysis.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = []; - - private static $noteNameTemplate; - - private static $occurrenceNameTemplate; - - private static $projectNameTemplate; - - private static $pathTemplateMap; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/grafeas_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/grafeas_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/grafeas_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/grafeas_rest_client_config.php', - ], - ], - ]; - } - - private static function getNoteNameTemplate() - { - if (self::$noteNameTemplate == null) { - self::$noteNameTemplate = new PathTemplate('projects/{project}/notes/{note}'); - } - - return self::$noteNameTemplate; - } - - private static function getOccurrenceNameTemplate() - { - if (self::$occurrenceNameTemplate == null) { - self::$occurrenceNameTemplate = new PathTemplate('projects/{project}/occurrences/{occurrence}'); - } - - return self::$occurrenceNameTemplate; - } - - private static function getProjectNameTemplate() - { - if (self::$projectNameTemplate == null) { - self::$projectNameTemplate = new PathTemplate('projects/{project}'); - } - - return self::$projectNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'note' => self::getNoteNameTemplate(), - 'occurrence' => self::getOccurrenceNameTemplate(), - 'project' => self::getProjectNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a note - * resource. - * - * @param string $project - * @param string $note - * - * @return string The formatted note resource. - */ - public static function noteName($project, $note) - { - return self::getNoteNameTemplate()->render([ - 'project' => $project, - 'note' => $note, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a occurrence - * resource. - * - * @param string $project - * @param string $occurrence - * - * @return string The formatted occurrence resource. - */ - public static function occurrenceName($project, $occurrence) - { - return self::getOccurrenceNameTemplate()->render([ - 'project' => $project, - 'occurrence' => $occurrence, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a project - * resource. - * - * @param string $project - * - * @return string The formatted project resource. - */ - public static function projectName($project) - { - return self::getProjectNameTemplate()->render([ - 'project' => $project, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - note: projects/{project}/notes/{note} - * - occurrence: projects/{project}/occurrences/{occurrence} - * - project: projects/{project} - * - * The optional $template argument can be supplied to specify a particular pattern, - * and must match one of the templates listed above. If no $template argument is - * provided, or if the $template argument does not match one of the templates - * listed, then parseName will check each of the supported templates, and return - * the first match. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'containeranalysis.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * Client method configuration, including retry settings. This option can be either - * a path to a JSON file, or a PHP array containing the decoded JSON data. By - * default this settings points to the default client config file, which is - * provided in the resources folder. - * @type string|TransportInterface $transport - * The transport used for executing network requests. May be either the string - * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. - * *Advanced usage*: Additionally, it is possible to pass in an already - * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * Configuration options that will be used to construct the transport. Options for - * each supported transport type should be passed in a key for that transport. For - * example: - * $transportConfig = [ - * 'grpc' => [...], - * 'rest' => [...], - * ]; - * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * A callable which returns the client cert as a string. This can be used to - * provide a certificate and private key to the transport layer for mTLS. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - } - - /** - * Creates new notes in batch. - * - * Sample code: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedParent = $grafeasClient->projectName('[PROJECT]'); - * $notes = []; - * $response = $grafeasClient->batchCreateNotes($formattedParent, $notes); - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $parent The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the notes are to be created. - * @param array $notes The notes to create. Max allowed length is 1000. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Grafeas\V1\BatchCreateNotesResponse - * - * @throws ApiException if the remote call fails - */ - public function batchCreateNotes($parent, $notes, array $optionalArgs = []) - { - $request = new BatchCreateNotesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setNotes($notes); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('BatchCreateNotes', BatchCreateNotesResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates new occurrences in batch. - * - * Sample code: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedParent = $grafeasClient->projectName('[PROJECT]'); - * $occurrences = []; - * $response = $grafeasClient->batchCreateOccurrences($formattedParent, $occurrences); - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $parent The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the occurrences are to be created. - * @param Occurrence[] $occurrences The occurrences to create. Max allowed length is 1000. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Grafeas\V1\BatchCreateOccurrencesResponse - * - * @throws ApiException if the remote call fails - */ - public function batchCreateOccurrences($parent, $occurrences, array $optionalArgs = []) - { - $request = new BatchCreateOccurrencesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setOccurrences($occurrences); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('BatchCreateOccurrences', BatchCreateOccurrencesResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a new note. - * - * Sample code: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedParent = $grafeasClient->projectName('[PROJECT]'); - * $noteId = 'note_id'; - * $note = new Note(); - * $response = $grafeasClient->createNote($formattedParent, $noteId, $note); - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $parent The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the note is to be created. - * @param string $noteId The ID to use for this note. - * @param Note $note The note to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Grafeas\V1\Note - * - * @throws ApiException if the remote call fails - */ - public function createNote($parent, $noteId, $note, array $optionalArgs = []) - { - $request = new CreateNoteRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setNoteId($noteId); - $request->setNote($note); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateNote', Note::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a new occurrence. - * - * Sample code: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedParent = $grafeasClient->projectName('[PROJECT]'); - * $occurrence = new Occurrence(); - * $response = $grafeasClient->createOccurrence($formattedParent, $occurrence); - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $parent The name of the project in the form of `projects/[PROJECT_ID]`, under which - * the occurrence is to be created. - * @param Occurrence $occurrence The occurrence to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Grafeas\V1\Occurrence - * - * @throws ApiException if the remote call fails - */ - public function createOccurrence($parent, $occurrence, array $optionalArgs = []) - { - $request = new CreateOccurrenceRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setOccurrence($occurrence); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateOccurrence', Occurrence::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes the specified note. - * - * Sample code: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedName = $grafeasClient->noteName('[PROJECT]', '[NOTE]'); - * $grafeasClient->deleteNote($formattedName); - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $name The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteNote($name, array $optionalArgs = []) - { - $request = new DeleteNoteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteNote', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * 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: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedName = $grafeasClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); - * $grafeasClient->deleteOccurrence($formattedName); - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $name The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteOccurrence($name, array $optionalArgs = []) - { - $request = new DeleteOccurrenceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteOccurrence', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the specified note. - * - * Sample code: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedName = $grafeasClient->noteName('[PROJECT]', '[NOTE]'); - * $response = $grafeasClient->getNote($formattedName); - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $name The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Grafeas\V1\Note - * - * @throws ApiException if the remote call fails - */ - public function getNote($name, array $optionalArgs = []) - { - $request = new GetNoteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetNote', Note::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the specified occurrence. - * - * Sample code: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedName = $grafeasClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); - * $response = $grafeasClient->getOccurrence($formattedName); - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $name The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Grafeas\V1\Occurrence - * - * @throws ApiException if the remote call fails - */ - public function getOccurrence($name, array $optionalArgs = []) - { - $request = new GetOccurrenceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetOccurrence', Occurrence::class, $optionalArgs, $request)->wait(); - } - - /** - * 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: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedName = $grafeasClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); - * $response = $grafeasClient->getOccurrenceNote($formattedName); - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $name The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Grafeas\V1\Note - * - * @throws ApiException if the remote call fails - */ - public function getOccurrenceNote($name, array $optionalArgs = []) - { - $request = new GetOccurrenceNoteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetOccurrenceNote', Note::class, $optionalArgs, $request)->wait(); - } - - /** - * 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: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedName = $grafeasClient->noteName('[PROJECT]', '[NOTE]'); - * // Iterate over pages of elements - * $pagedResponse = $grafeasClient->listNoteOccurrences($formattedName); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $grafeasClient->listNoteOccurrences($formattedName); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $name The name of the note to list occurrences for in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * The filter expression. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listNoteOccurrences($name, array $optionalArgs = []) - { - $request = new ListNoteOccurrencesRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListNoteOccurrences', $optionalArgs, ListNoteOccurrencesResponse::class, $request); - } - - /** - * Lists notes for the specified project. - * - * Sample code: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedParent = $grafeasClient->projectName('[PROJECT]'); - * // Iterate over pages of elements - * $pagedResponse = $grafeasClient->listNotes($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $grafeasClient->listNotes($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $parent The name of the project to list notes for in the form of - * `projects/[PROJECT_ID]`. - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * The filter expression. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listNotes($parent, array $optionalArgs = []) - { - $request = new ListNotesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListNotes', $optionalArgs, ListNotesResponse::class, $request); - } - - /** - * Lists occurrences for the specified project. - * - * Sample code: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedParent = $grafeasClient->projectName('[PROJECT]'); - * // Iterate over pages of elements - * $pagedResponse = $grafeasClient->listOccurrences($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $grafeasClient->listOccurrences($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $parent The name of the project to list occurrences for in the form of - * `projects/[PROJECT_ID]`. - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * The filter expression. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listOccurrences($parent, array $optionalArgs = []) - { - $request = new ListOccurrencesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListOccurrences', $optionalArgs, ListOccurrencesResponse::class, $request); - } - - /** - * Updates the specified note. - * - * Sample code: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedName = $grafeasClient->noteName('[PROJECT]', '[NOTE]'); - * $note = new Note(); - * $response = $grafeasClient->updateNote($formattedName, $note); - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $name The name of the note in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @param Note $note The updated note. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The fields to update. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Grafeas\V1\Note - * - * @throws ApiException if the remote call fails - */ - public function updateNote($name, $note, array $optionalArgs = []) - { - $request = new UpdateNoteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $request->setNote($note); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateNote', Note::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates the specified occurrence. - * - * Sample code: - * ``` - * $grafeasClient = new GrafeasClient(); - * try { - * $formattedName = $grafeasClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); - * $occurrence = new Occurrence(); - * $response = $grafeasClient->updateOccurrence($formattedName, $occurrence); - * } finally { - * $grafeasClient->close(); - * } - * ``` - * - * @param string $name The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @param Occurrence $occurrence The updated occurrence. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The fields to update. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Grafeas\V1\Occurrence - * - * @throws ApiException if the remote call fails - */ - public function updateOccurrence($name, $occurrence, array $optionalArgs = []) - { - $request = new UpdateOccurrenceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $request->setOccurrence($occurrence); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateOccurrence', Occurrence::class, $optionalArgs, $request)->wait(); - } -} diff --git a/owl-bot-staging/Grafeas/v1/src/V1/GrafeasClient.php b/owl-bot-staging/Grafeas/v1/src/V1/GrafeasClient.php deleted file mode 100644 index ec675d7f8cb..00000000000 --- a/owl-bot-staging/Grafeas/v1/src/V1/GrafeasClient.php +++ /dev/null @@ -1,34 +0,0 @@ - [ - 'grafeas.v1.Grafeas' => [ - 'ListNoteOccurrences' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getOccurrences', - ], - ], - 'ListNotes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getNotes', - ], - ], - 'ListOccurrences' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getOccurrences', - ], - ], - ], - ], -]; diff --git a/owl-bot-staging/Grafeas/v1/src/V1/resources/grafeas_rest_client_config.php b/owl-bot-staging/Grafeas/v1/src/V1/resources/grafeas_rest_client_config.php deleted file mode 100644 index 30b86b499f1..00000000000 --- a/owl-bot-staging/Grafeas/v1/src/V1/resources/grafeas_rest_client_config.php +++ /dev/null @@ -1,172 +0,0 @@ - [ - 'grafeas.v1.Grafeas' => [ - 'BatchCreateNotes' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*}/notes:batchCreate', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'BatchCreateOccurrences' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*}/occurrences:batchCreate', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateNote' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*}/notes', - 'body' => 'note', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'note_id', - ], - ], - 'CreateOccurrence' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*}/occurrences', - 'body' => 'occurrence', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteNote' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/notes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOccurrence' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/occurrences/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetNote' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/notes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOccurrence' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/occurrences/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOccurrenceNote' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/occurrences/*}/notes', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListNoteOccurrences' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/notes/*}/occurrences', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListNotes' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*}/notes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListOccurrences' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*}/occurrences', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'UpdateNote' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{name=projects/*/notes/*}', - 'body' => 'note', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateOccurrence' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{name=projects/*/occurrences/*}', - 'body' => 'occurrence', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/Grafeas/v1/tests/Unit/V1/GrafeasClientTest.php b/owl-bot-staging/Grafeas/v1/tests/Unit/V1/GrafeasClientTest.php deleted file mode 100644 index 8b715d081bc..00000000000 --- a/owl-bot-staging/Grafeas/v1/tests/Unit/V1/GrafeasClientTest.php +++ /dev/null @@ -1,990 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return GrafeasClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new GrafeasClient($options); - } - - /** @test */ - public function batchCreateNotesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new BatchCreateNotesResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $notesValue = new Note(); - $notes = [ - 'notesKey' => $notesValue, - ]; - $response = $gapicClient->batchCreateNotes($formattedParent, $notes); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/BatchCreateNotes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getNotes(); - $this->assertProtobufEquals($notes, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchCreateNotesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $notesValue = new Note(); - $notes = [ - 'notesKey' => $notesValue, - ]; - try { - $gapicClient->batchCreateNotes($formattedParent, $notes); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchCreateOccurrencesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new BatchCreateOccurrencesResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $occurrences = []; - $response = $gapicClient->batchCreateOccurrences($formattedParent, $occurrences); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/BatchCreateOccurrences', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getOccurrences(); - $this->assertProtobufEquals($occurrences, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchCreateOccurrencesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $occurrences = []; - try { - $gapicClient->batchCreateOccurrences($formattedParent, $occurrences); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createNoteTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $shortDescription = 'shortDescription-235369287'; - $longDescription = 'longDescription-1747792199'; - $expectedResponse = new Note(); - $expectedResponse->setName($name); - $expectedResponse->setShortDescription($shortDescription); - $expectedResponse->setLongDescription($longDescription); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $noteId = 'noteId2129224840'; - $note = new Note(); - $response = $gapicClient->createNote($formattedParent, $noteId, $note); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/CreateNote', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getNoteId(); - $this->assertProtobufEquals($noteId, $actualValue); - $actualValue = $actualRequestObject->getNote(); - $this->assertProtobufEquals($note, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createNoteExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $noteId = 'noteId2129224840'; - $note = new Note(); - try { - $gapicClient->createNote($formattedParent, $noteId, $note); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createOccurrenceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $resourceUri = 'resourceUri-384040517'; - $noteName = 'noteName1780787896'; - $remediation = 'remediation779381797'; - $expectedResponse = new Occurrence(); - $expectedResponse->setName($name); - $expectedResponse->setResourceUri($resourceUri); - $expectedResponse->setNoteName($noteName); - $expectedResponse->setRemediation($remediation); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $occurrence = new Occurrence(); - $response = $gapicClient->createOccurrence($formattedParent, $occurrence); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/CreateOccurrence', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getOccurrence(); - $this->assertProtobufEquals($occurrence, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createOccurrenceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $occurrence = new Occurrence(); - try { - $gapicClient->createOccurrence($formattedParent, $occurrence); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteNoteTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); - $gapicClient->deleteNote($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/DeleteNote', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteNoteExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); - try { - $gapicClient->deleteNote($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteOccurrenceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); - $gapicClient->deleteOccurrence($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/DeleteOccurrence', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteOccurrenceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); - try { - $gapicClient->deleteOccurrence($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNoteTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $shortDescription = 'shortDescription-235369287'; - $longDescription = 'longDescription-1747792199'; - $expectedResponse = new Note(); - $expectedResponse->setName($name2); - $expectedResponse->setShortDescription($shortDescription); - $expectedResponse->setLongDescription($longDescription); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); - $response = $gapicClient->getNote($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/GetNote', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNoteExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); - try { - $gapicClient->getNote($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getOccurrenceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $resourceUri = 'resourceUri-384040517'; - $noteName = 'noteName1780787896'; - $remediation = 'remediation779381797'; - $expectedResponse = new Occurrence(); - $expectedResponse->setName($name2); - $expectedResponse->setResourceUri($resourceUri); - $expectedResponse->setNoteName($noteName); - $expectedResponse->setRemediation($remediation); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); - $response = $gapicClient->getOccurrence($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/GetOccurrence', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getOccurrenceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); - try { - $gapicClient->getOccurrence($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getOccurrenceNoteTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $shortDescription = 'shortDescription-235369287'; - $longDescription = 'longDescription-1747792199'; - $expectedResponse = new Note(); - $expectedResponse->setName($name2); - $expectedResponse->setShortDescription($shortDescription); - $expectedResponse->setLongDescription($longDescription); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); - $response = $gapicClient->getOccurrenceNote($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/GetOccurrenceNote', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getOccurrenceNoteExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); - try { - $gapicClient->getOccurrenceNote($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNoteOccurrencesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $occurrencesElement = new Occurrence(); - $occurrences = [ - $occurrencesElement, - ]; - $expectedResponse = new ListNoteOccurrencesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setOccurrences($occurrences); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); - $response = $gapicClient->listNoteOccurrences($formattedName); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getOccurrences()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/ListNoteOccurrences', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNoteOccurrencesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); - try { - $gapicClient->listNoteOccurrences($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNotesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $notesElement = new Note(); - $notes = [ - $notesElement, - ]; - $expectedResponse = new ListNotesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setNotes($notes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->listNotes($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getNotes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/ListNotes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNotesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - try { - $gapicClient->listNotes($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listOccurrencesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $occurrencesElement = new Occurrence(); - $occurrences = [ - $occurrencesElement, - ]; - $expectedResponse = new ListOccurrencesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setOccurrences($occurrences); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->listOccurrences($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getOccurrences()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/ListOccurrences', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listOccurrencesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - try { - $gapicClient->listOccurrences($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateNoteTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $shortDescription = 'shortDescription-235369287'; - $longDescription = 'longDescription-1747792199'; - $expectedResponse = new Note(); - $expectedResponse->setName($name2); - $expectedResponse->setShortDescription($shortDescription); - $expectedResponse->setLongDescription($longDescription); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); - $note = new Note(); - $response = $gapicClient->updateNote($formattedName, $note); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/UpdateNote', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getNote(); - $this->assertProtobufEquals($note, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateNoteExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->noteName('[PROJECT]', '[NOTE]'); - $note = new Note(); - try { - $gapicClient->updateNote($formattedName, $note); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateOccurrenceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $resourceUri = 'resourceUri-384040517'; - $noteName = 'noteName1780787896'; - $remediation = 'remediation779381797'; - $expectedResponse = new Occurrence(); - $expectedResponse->setName($name2); - $expectedResponse->setResourceUri($resourceUri); - $expectedResponse->setNoteName($noteName); - $expectedResponse->setRemediation($remediation); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); - $occurrence = new Occurrence(); - $response = $gapicClient->updateOccurrence($formattedName, $occurrence); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/grafeas.v1.Grafeas/UpdateOccurrence', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getOccurrence(); - $this->assertProtobufEquals($occurrence, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateOccurrenceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->occurrenceName('[PROJECT]', '[OCCURRENCE]'); - $occurrence = new Occurrence(); - try { - $gapicClient->updateOccurrence($formattedName, $occurrence); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -}