From 20cfb8464d054dce0e36aa1357940c01ba1075db Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Thu, 23 May 2024 19:01:29 +0000 Subject: [PATCH 1/2] feat: add secrets discovery support docs: Updated method documentation PiperOrigin-RevId: 636593602 Source-Link: https://github.com/googleapis/googleapis/commit/1834a9697a18c717a216c5919aa4aef737a146d7 Source-Link: https://github.com/googleapis/googleapis-gen/commit/ca0da7b3d25218dc66c4ba36752592959c63ad03 Copy-Tag: eyJwIjoiRGxwLy5Pd2xCb3QueWFtbCIsImgiOiJjYTBkYTdiM2QyNTIxOGRjNjZjNGJhMzY3NTI1OTI5NTljNjNhZDAzIn0= --- .../GPBMetadata/Google/Privacy/Dlp/V2/Dlp.php | Bin 0 -> 72515 bytes .../Google/Privacy/Dlp/V2/Storage.php | Bin 0 -> 6272 bytes .../proto/src/Google/Cloud/Dlp/V2/Action.php | 281 + .../Google/Cloud/Dlp/V2/Action/Deidentify.php | 277 + .../Dlp/V2/Action/JobNotificationEmails.php | 38 + .../PublishFindingsToCloudDataCatalog.php | 51 + .../Dlp/V2/Action/PublishSummaryToCscc.php | 43 + .../Cloud/Dlp/V2/Action/PublishToPubSub.php | 86 + .../Dlp/V2/Action/PublishToStackdriver.php | 39 + .../Cloud/Dlp/V2/Action/SaveFindings.php | 83 + .../src/Google/Cloud/Dlp/V2/ActionDetails.php | 75 + .../Dlp/V2/ActivateJobTriggerRequest.php | 71 + .../Dlp/V2/AllOtherDatabaseResources.php | 33 + .../Dlp/V2/AnalyzeDataSourceRiskDetails.php | 372 ++ .../CategoricalStatsResult.php | 70 + .../CategoricalStatsHistogramBucket.php | 210 + .../DeltaPresenceEstimationResult.php | 99 + ...DeltaPresenceEstimationHistogramBucket.php | 218 + .../DeltaPresenceEstimationQuasiIdValues.php | 132 + .../KAnonymityResult.php | 70 + .../KAnonymityEquivalenceClass.php | 116 + .../KAnonymityHistogramBucket.php | 210 + .../KMapEstimationResult.php | 99 + .../KMapEstimationHistogramBucket.php | 217 + .../KMapEstimationQuasiIdValues.php | 104 + .../LDiversityResult.php | 70 + .../LDiversityEquivalenceClass.php | 176 + .../LDiversityHistogramBucket.php | 218 + .../NumericalStatsResult.php | 162 + .../RequestedRiskAnalysisOptions.php | 80 + .../Cloud/Dlp/V2/BigQueryDiscoveryTarget.php | 210 + .../src/Google/Cloud/Dlp/V2/BigQueryField.php | 121 + .../src/Google/Cloud/Dlp/V2/BigQueryKey.php | 127 + .../Google/Cloud/Dlp/V2/BigQueryOptions.php | 369 ++ .../Dlp/V2/BigQueryOptions/SampleMethod.php | 68 + .../src/Google/Cloud/Dlp/V2/BigQueryRegex.php | 143 + .../Google/Cloud/Dlp/V2/BigQueryRegexes.php | 72 + .../Dlp/V2/BigQuerySchemaModification.php | 63 + .../src/Google/Cloud/Dlp/V2/BigQueryTable.php | 143 + .../Cloud/Dlp/V2/BigQueryTableCollection.php | 75 + .../Dlp/V2/BigQueryTableModification.php | 56 + .../Google/Cloud/Dlp/V2/BigQueryTableType.php | 62 + .../Dlp/V2/BigQueryTableTypeCollection.php | 68 + .../Cloud/Dlp/V2/BigQueryTableTypes.php | 67 + .../src/Google/Cloud/Dlp/V2/BoundingBox.php | 169 + .../Google/Cloud/Dlp/V2/BucketingConfig.php | 77 + .../Cloud/Dlp/V2/BucketingConfig/Bucket.php | 172 + .../Google/Cloud/Dlp/V2/ByteContentItem.php | 101 + .../Dlp/V2/ByteContentItem/BytesType.php | 143 + .../Cloud/Dlp/V2/CancelDlpJobRequest.php | 67 + .../Cloud/Dlp/V2/CharacterMaskConfig.php | 266 + .../src/Google/Cloud/Dlp/V2/CharsToIgnore.php | 112 + .../V2/CharsToIgnore/CommonCharsToIgnore.php | 85 + .../Cloud/Dlp/V2/CloudSqlDiscoveryTarget.php | 210 + .../Cloud/Dlp/V2/CloudSqlIamCredential.php | 36 + .../Cloud/Dlp/V2/CloudSqlProperties.php | 250 + .../V2/CloudSqlProperties/DatabaseEngine.php | 65 + .../Cloud/Dlp/V2/CloudStorageFileSet.php | 71 + .../Cloud/Dlp/V2/CloudStorageOptions.php | 332 ++ .../Dlp/V2/CloudStorageOptions/FileSet.php | 146 + .../V2/CloudStorageOptions/SampleMethod.php | 67 + .../Google/Cloud/Dlp/V2/CloudStoragePath.php | 71 + .../Cloud/Dlp/V2/CloudStorageRegexFileSet.php | 208 + .../proto/src/Google/Cloud/Dlp/V2/Color.php | 135 + .../Google/Cloud/Dlp/V2/ColumnDataProfile.php | 795 +++ .../V2/ColumnDataProfile/ColumnDataType.php | 177 + .../ColumnDataProfile/ColumnPolicyState.php | 57 + .../Cloud/Dlp/V2/ColumnDataProfile/State.php | 67 + .../src/Google/Cloud/Dlp/V2/Connection.php | 186 + .../Google/Cloud/Dlp/V2/ConnectionState.php | 75 + .../src/Google/Cloud/Dlp/V2/Container.php | 354 ++ .../src/Google/Cloud/Dlp/V2/ContentItem.php | 147 + .../Google/Cloud/Dlp/V2/ContentLocation.php | 331 ++ .../src/Google/Cloud/Dlp/V2/ContentOption.php | 61 + .../Cloud/Dlp/V2/CreateConnectionRequest.php | 132 + .../V2/CreateDeidentifyTemplateRequest.php | 286 + .../Dlp/V2/CreateDiscoveryConfigRequest.php | 206 + .../Cloud/Dlp/V2/CreateDlpJobRequest.php | 334 ++ .../Dlp/V2/CreateInspectTemplateRequest.php | 286 + .../Cloud/Dlp/V2/CreateJobTriggerRequest.php | 266 + .../Dlp/V2/CreateStoredInfoTypeRequest.php | 286 + .../Dlp/V2/CryptoDeterministicConfig.php | 327 ++ .../Google/Cloud/Dlp/V2/CryptoHashConfig.php | 84 + .../src/Google/Cloud/Dlp/V2/CryptoKey.php | 146 + .../Dlp/V2/CryptoReplaceFfxFpeConfig.php | 448 ++ .../FfxCommonNativeAlphabet.php | 80 + .../Google/Cloud/Dlp/V2/CustomInfoType.php | 427 ++ .../Dlp/V2/CustomInfoType/DetectionRule.php | 81 + .../DetectionRule/HotwordRule.php | 213 + .../DetectionRule/LikelihoodAdjustment.php | 133 + .../DetectionRule/Proximity.php | 121 + .../Dlp/V2/CustomInfoType/Dictionary.php | 134 + .../V2/CustomInfoType/Dictionary/WordList.php | 78 + .../Dlp/V2/CustomInfoType/ExclusionType.php | 58 + .../Cloud/Dlp/V2/CustomInfoType/Regex.php | 116 + .../Dlp/V2/CustomInfoType/SurrogateType.php | 43 + .../Google/Cloud/Dlp/V2/DataProfileAction.php | 108 + .../Dlp/V2/DataProfileAction/EventType.php | 80 + .../Cloud/Dlp/V2/DataProfileAction/Export.php | 113 + .../DataProfileAction/PubSubNotification.php | 204 + .../PubSubNotification/DetailLevel.php | 64 + .../Dlp/V2/DataProfileBigQueryRowSchema.php | 109 + .../Dlp/V2/DataProfileConfigSnapshot.php | 270 + .../Cloud/Dlp/V2/DataProfileJobConfig.php | 240 + .../Cloud/Dlp/V2/DataProfileLocation.php | 108 + .../Dlp/V2/DataProfilePubSubCondition.php | 77 + .../ProfileScoreBucket.php | 64 + .../PubSubCondition.php | 111 + .../PubSubExpressions.php | 104 + .../PubSubLogicalOperator.php | 68 + .../Cloud/Dlp/V2/DataProfilePubSubMessage.php | 121 + .../Dlp/V2/DataProfileUpdateFrequency.php | 69 + .../src/Google/Cloud/Dlp/V2/DataRiskLevel.php | 68 + .../V2/DataRiskLevel/DataRiskLevelScore.php | 77 + .../Google/Cloud/Dlp/V2/DataSourceType.php | 71 + .../Dlp/V2/DatabaseResourceCollection.php | 76 + .../Dlp/V2/DatabaseResourceReference.php | 181 + .../Cloud/Dlp/V2/DatabaseResourceRegex.php | 188 + .../Cloud/Dlp/V2/DatabaseResourceRegexes.php | 80 + .../src/Google/Cloud/Dlp/V2/DatastoreKey.php | 77 + .../Google/Cloud/Dlp/V2/DatastoreOptions.php | 125 + .../Google/Cloud/Dlp/V2/DateShiftConfig.php | 220 + .../src/Google/Cloud/Dlp/V2/DateTime.php | 204 + .../Google/Cloud/Dlp/V2/DateTime/TimeZone.php | 74 + .../Google/Cloud/Dlp/V2/DeidentifyConfig.php | 198 + .../Cloud/Dlp/V2/DeidentifyContentRequest.php | 417 ++ .../Dlp/V2/DeidentifyContentResponse.php | 121 + .../Dlp/V2/DeidentifyDataSourceDetails.php | 122 + .../RequestedDeidentifyOptions.php | 184 + .../Dlp/V2/DeidentifyDataSourceStats.php | 135 + .../Cloud/Dlp/V2/DeidentifyTemplate.php | 282 + .../Cloud/Dlp/V2/DeleteConnectionRequest.php | 86 + .../V2/DeleteDeidentifyTemplateRequest.php | 96 + .../Dlp/V2/DeleteDiscoveryConfigRequest.php | 86 + .../Cloud/Dlp/V2/DeleteDlpJobRequest.php | 81 + .../Dlp/V2/DeleteInspectTemplateRequest.php | 91 + .../Cloud/Dlp/V2/DeleteJobTriggerRequest.php | 86 + .../Dlp/V2/DeleteStoredInfoTypeRequest.php | 91 + .../Dlp/V2/DeleteTableDataProfileRequest.php | 81 + .../src/Google/Cloud/Dlp/V2/Disabled.php | 33 + .../Dlp/V2/DiscoveryBigQueryConditions.php | 204 + .../OrConditions.php | 123 + .../Cloud/Dlp/V2/DiscoveryBigQueryFilter.php | 167 + .../AllOtherBigQueryTables.php | 38 + .../Dlp/V2/DiscoveryCloudSqlConditions.php | 114 + .../DatabaseEngine.php | 71 + .../DatabaseResourceType.php | 64 + .../Cloud/Dlp/V2/DiscoveryCloudSqlFilter.php | 155 + .../V2/DiscoveryCloudSqlGenerationCadence.php | 125 + .../SchemaModifiedCadence.php | 112 + .../CloudSqlSchemaModification.php | 64 + .../Google/Cloud/Dlp/V2/DiscoveryConfig.php | 520 ++ .../Dlp/V2/DiscoveryConfig/OrgConfig.php | 122 + .../Cloud/Dlp/V2/DiscoveryConfig/Status.php | 65 + .../Dlp/V2/DiscoveryGenerationCadence.php | 124 + .../Dlp/V2/DiscoverySchemaModifiedCadence.php | 113 + .../Dlp/V2/DiscoveryStartingLocation.php | 109 + .../Dlp/V2/DiscoveryTableModifiedCadence.php | 113 + .../Google/Cloud/Dlp/V2/DiscoveryTarget.php | 153 + .../proto/src/Google/Cloud/Dlp/V2/DlpJob.php | 492 ++ .../Google/Cloud/Dlp/V2/DlpJob/JobState.php | 96 + .../src/Google/Cloud/Dlp/V2/DlpJobType.php | 61 + .../Google/Cloud/Dlp/V2/DocumentLocation.php | 71 + .../Google/Cloud/Dlp/V2/EncryptionStatus.php | 61 + .../src/Google/Cloud/Dlp/V2/EntityId.php | 81 + .../proto/src/Google/Cloud/Dlp/V2/Error.php | 116 + .../Google/Cloud/Dlp/V2/ExcludeByHotword.php | 136 + .../Google/Cloud/Dlp/V2/ExcludeInfoTypes.php | 95 + .../src/Google/Cloud/Dlp/V2/ExclusionRule.php | 212 + .../proto/src/Google/Cloud/Dlp/V2/FieldId.php | 67 + .../Cloud/Dlp/V2/FieldTransformation.php | 225 + .../src/Google/Cloud/Dlp/V2/FileType.php | 150 + .../proto/src/Google/Cloud/Dlp/V2/Finding.php | 593 ++ .../Cloud/Dlp/V2/FinishDlpJobRequest.php | 67 + .../Cloud/Dlp/V2/FixedSizeBucketingConfig.php | 196 + .../Dlp/V2/GetColumnDataProfileRequest.php | 86 + .../Cloud/Dlp/V2/GetConnectionRequest.php | 86 + .../Dlp/V2/GetDeidentifyTemplateRequest.php | 91 + .../Dlp/V2/GetDiscoveryConfigRequest.php | 86 + .../Google/Cloud/Dlp/V2/GetDlpJobRequest.php | 81 + .../Dlp/V2/GetInspectTemplateRequest.php | 91 + .../Cloud/Dlp/V2/GetJobTriggerRequest.php | 86 + .../Dlp/V2/GetProjectDataProfileRequest.php | 86 + .../Cloud/Dlp/V2/GetStoredInfoTypeRequest.php | 91 + .../Dlp/V2/GetTableDataProfileRequest.php | 86 + .../Google/Cloud/Dlp/V2/HybridContentItem.php | 122 + .../Cloud/Dlp/V2/HybridFindingDetails.php | 303 + .../Dlp/V2/HybridInspectDlpJobRequest.php | 130 + .../Dlp/V2/HybridInspectJobTriggerRequest.php | 130 + .../Cloud/Dlp/V2/HybridInspectResponse.php | 33 + .../Cloud/Dlp/V2/HybridInspectStatistics.php | 155 + .../src/Google/Cloud/Dlp/V2/HybridOptions.php | 240 + .../src/Google/Cloud/Dlp/V2/ImageLocation.php | 67 + .../Cloud/Dlp/V2/ImageTransformations.php | 67 + .../ImageTransformation.php | 201 + .../ImageTransformation/AllInfoTypes.php | 36 + .../ImageTransformation/AllText.php | 36 + .../ImageTransformation/SelectedInfoTypes.php | 74 + .../src/Google/Cloud/Dlp/V2/InfoType.php | 173 + .../Google/Cloud/Dlp/V2/InfoTypeCategory.php | 145 + .../V2/InfoTypeCategory/IndustryCategory.php | 72 + .../V2/InfoTypeCategory/LocationCategory.php | 392 ++ .../Dlp/V2/InfoTypeCategory/TypeCategory.php | 104 + .../Cloud/Dlp/V2/InfoTypeDescription.php | 285 + .../src/Google/Cloud/Dlp/V2/InfoTypeStats.php | 111 + .../Google/Cloud/Dlp/V2/InfoTypeSummary.php | 116 + .../Cloud/Dlp/V2/InfoTypeSupportedBy.php | 61 + .../Cloud/Dlp/V2/InfoTypeTransformations.php | 74 + .../InfoTypeTransformation.php | 123 + .../src/Google/Cloud/Dlp/V2/InspectConfig.php | 495 ++ .../Dlp/V2/InspectConfig/FindingLimits.php | 204 + .../FindingLimits/InfoTypeLimit.php | 127 + .../V2/InspectConfig/InfoTypeLikelihood.php | 130 + .../Cloud/Dlp/V2/InspectContentRequest.php | 287 + .../Cloud/Dlp/V2/InspectContentResponse.php | 77 + .../Cloud/Dlp/V2/InspectDataSourceDetails.php | 121 + .../RequestedOptions.php | 128 + .../V2/InspectDataSourceDetails/Result.php | 224 + .../Google/Cloud/Dlp/V2/InspectJobConfig.php | 197 + .../src/Google/Cloud/Dlp/V2/InspectResult.php | 121 + .../Google/Cloud/Dlp/V2/InspectTemplate.php | 283 + .../Google/Cloud/Dlp/V2/InspectionRule.php | 109 + .../Google/Cloud/Dlp/V2/InspectionRuleSet.php | 102 + .../src/Google/Cloud/Dlp/V2/JobTrigger.php | 442 ++ .../Google/Cloud/Dlp/V2/JobTrigger/Status.php | 74 + .../Cloud/Dlp/V2/JobTrigger/Trigger.php | 111 + .../v2/proto/src/Google/Cloud/Dlp/V2/Key.php | 150 + .../Google/Cloud/Dlp/V2/Key/PathElement.php | 174 + .../Google/Cloud/Dlp/V2/KindExpression.php | 67 + .../Cloud/Dlp/V2/KmsWrappedCryptoKey.php | 109 + .../Dlp/V2/LargeCustomDictionaryConfig.php | 169 + .../Dlp/V2/LargeCustomDictionaryStats.php | 67 + .../src/Google/Cloud/Dlp/V2/Likelihood.php | 93 + .../Dlp/V2/ListColumnDataProfilesRequest.php | 387 ++ .../Dlp/V2/ListColumnDataProfilesResponse.php | 101 + .../Cloud/Dlp/V2/ListConnectionsRequest.php | 192 + .../Cloud/Dlp/V2/ListConnectionsResponse.php | 105 + .../Dlp/V2/ListDeidentifyTemplatesRequest.php | 340 ++ .../V2/ListDeidentifyTemplatesResponse.php | 109 + .../Dlp/V2/ListDiscoveryConfigsRequest.php | 256 + .../Dlp/V2/ListDiscoveryConfigsResponse.php | 105 + .../Cloud/Dlp/V2/ListDlpJobsRequest.php | 468 ++ .../Cloud/Dlp/V2/ListDlpJobsResponse.php | 101 + .../Cloud/Dlp/V2/ListInfoTypesRequest.php | 206 + .../Cloud/Dlp/V2/ListInfoTypesResponse.php | 67 + .../Dlp/V2/ListInspectTemplatesRequest.php | 340 ++ .../Dlp/V2/ListInspectTemplatesResponse.php | 105 + .../Cloud/Dlp/V2/ListJobTriggersRequest.php | 468 ++ .../Cloud/Dlp/V2/ListJobTriggersResponse.php | 105 + .../Dlp/V2/ListProjectDataProfilesRequest.php | 329 ++ .../V2/ListProjectDataProfilesResponse.php | 101 + .../Dlp/V2/ListStoredInfoTypesRequest.php | 324 ++ .../Dlp/V2/ListStoredInfoTypesResponse.php | 105 + .../Dlp/V2/ListTableDataProfilesRequest.php | 383 ++ .../Dlp/V2/ListTableDataProfilesResponse.php | 101 + .../src/Google/Cloud/Dlp/V2/Location.php | 227 + .../proto/src/Google/Cloud/Dlp/V2/Manual.php | 34 + .../src/Google/Cloud/Dlp/V2/MatchingType.php | 79 + .../Google/Cloud/Dlp/V2/MetadataLocation.php | 109 + .../src/Google/Cloud/Dlp/V2/MetadataType.php | 54 + .../Cloud/Dlp/V2/NullPercentageLevel.php | 76 + .../Cloud/Dlp/V2/OtherInfoTypeSummary.php | 153 + .../Cloud/Dlp/V2/OutputStorageConfig.php | 174 + .../V2/OutputStorageConfig/OutputSchema.php | 87 + .../src/Google/Cloud/Dlp/V2/PartitionId.php | 105 + .../Cloud/Dlp/V2/PrimitiveTransformation.php | 438 ++ .../src/Google/Cloud/Dlp/V2/PrivacyMetric.php | 240 + .../PrivacyMetric/CategoricalStatsConfig.php | 93 + .../DeltaPresenceEstimationConfig.php | 161 + .../Dlp/V2/PrivacyMetric/KAnonymityConfig.php | 162 + .../V2/PrivacyMetric/KMapEstimationConfig.php | 163 + .../KMapEstimationConfig/AuxiliaryTable.php | 168 + .../AuxiliaryTable/QuasiIdField.php | 115 + .../KMapEstimationConfig/TaggedField.php | 209 + .../Dlp/V2/PrivacyMetric/LDiversityConfig.php | 122 + .../V2/PrivacyMetric/NumericalStatsConfig.php | 85 + .../src/Google/Cloud/Dlp/V2/ProfileStatus.php | 125 + .../Cloud/Dlp/V2/ProjectDataProfile.php | 278 + .../proto/src/Google/Cloud/Dlp/V2/QuasiId.php | 206 + .../src/Google/Cloud/Dlp/V2/QuoteInfo.php | 75 + .../proto/src/Google/Cloud/Dlp/V2/Range.php | 101 + .../Google/Cloud/Dlp/V2/RecordCondition.php | 78 + .../Dlp/V2/RecordCondition/Condition.php | 174 + .../Dlp/V2/RecordCondition/Conditions.php | 70 + .../Dlp/V2/RecordCondition/Expressions.php | 116 + .../Expressions/LogicalOperator.php | 61 + .../src/Google/Cloud/Dlp/V2/RecordKey.php | 146 + .../Google/Cloud/Dlp/V2/RecordLocation.php | 165 + .../Google/Cloud/Dlp/V2/RecordSuppression.php | 82 + .../Cloud/Dlp/V2/RecordTransformation.php | 155 + .../Cloud/Dlp/V2/RecordTransformations.php | 106 + .../src/Google/Cloud/Dlp/V2/RedactConfig.php | 35 + .../Cloud/Dlp/V2/RedactImageRequest.php | 306 + .../ImageRedactionConfig.php | 171 + .../Cloud/Dlp/V2/RedactImageResponse.php | 153 + .../Cloud/Dlp/V2/ReidentifyContentRequest.php | 417 ++ .../Dlp/V2/ReidentifyContentResponse.php | 121 + .../Cloud/Dlp/V2/RelationalOperator.php | 96 + .../Cloud/Dlp/V2/ReplaceDictionaryConfig.php | 81 + .../Cloud/Dlp/V2/ReplaceValueConfig.php | 77 + .../Dlp/V2/ReplaceWithInfoTypeConfig.php | 33 + .../Cloud/Dlp/V2/ResourceVisibility.php | 71 + .../Cloud/Dlp/V2/RiskAnalysisJobConfig.php | 161 + .../src/Google/Cloud/Dlp/V2/Schedule.php | 90 + .../Cloud/Dlp/V2/SearchConnectionsRequest.php | 192 + .../Dlp/V2/SearchConnectionsResponse.php | 113 + .../Cloud/Dlp/V2/SecretManagerCredential.php | 108 + .../Cloud/Dlp/V2/SecretsDiscoveryTarget.php | 41 + .../Google/Cloud/Dlp/V2/SensitivityScore.php | 68 + .../SensitivityScoreLevel.php | 78 + .../Google/Cloud/Dlp/V2/StatisticalTable.php | 165 + .../StatisticalTable/QuasiIdentifierField.php | 123 + .../src/Google/Cloud/Dlp/V2/StorageConfig.php | 218 + .../Dlp/V2/StorageConfig/TimespanConfig.php | 367 ++ .../Cloud/Dlp/V2/StorageMetadataLabel.php | 67 + .../Google/Cloud/Dlp/V2/StoredInfoType.php | 150 + .../Cloud/Dlp/V2/StoredInfoTypeConfig.php | 211 + .../Cloud/Dlp/V2/StoredInfoTypeState.php | 78 + .../Cloud/Dlp/V2/StoredInfoTypeStats.php | 75 + .../Cloud/Dlp/V2/StoredInfoTypeVersion.php | 282 + .../src/Google/Cloud/Dlp/V2/StoredType.php | 123 + .../proto/src/Google/Cloud/Dlp/V2/Table.php | 103 + .../src/Google/Cloud/Dlp/V2/Table/Row.php | 70 + .../Google/Cloud/Dlp/V2/TableDataProfile.php | 1027 ++++ .../Cloud/Dlp/V2/TableDataProfile/State.php | 67 + .../src/Google/Cloud/Dlp/V2/TableLocation.php | 87 + .../src/Google/Cloud/Dlp/V2/TableOptions.php | 79 + .../Google/Cloud/Dlp/V2/TableReference.php | 102 + .../Google/Cloud/Dlp/V2/TimePartConfig.php | 68 + .../Cloud/Dlp/V2/TimePartConfig/TimePart.php | 92 + .../Cloud/Dlp/V2/TransformationConfig.php | 193 + .../Dlp/V2/TransformationContainerType.php | 68 + .../Dlp/V2/TransformationDescription.php | 224 + .../Cloud/Dlp/V2/TransformationDetails.php | 296 + .../V2/TransformationDetailsStorageConfig.php | 90 + .../Dlp/V2/TransformationErrorHandling.php | 115 + .../LeaveUntransformed.php | 39 + .../ThrowError.php | 36 + .../Cloud/Dlp/V2/TransformationLocation.php | 158 + .../Cloud/Dlp/V2/TransformationOverview.php | 101 + .../Dlp/V2/TransformationResultStatus.php | 115 + .../Dlp/V2/TransformationResultStatusType.php | 82 + .../Cloud/Dlp/V2/TransformationSummary.php | 321 ++ .../TransformationSummary/SummaryResult.php | 143 + .../TransformationResultCode.php | 64 + .../Cloud/Dlp/V2/TransformationType.php | 147 + .../Cloud/Dlp/V2/TransientCryptoKey.php | 88 + .../Cloud/Dlp/V2/UniquenessScoreLevel.php | 72 + .../Cloud/Dlp/V2/UnwrappedCryptoKey.php | 68 + .../Cloud/Dlp/V2/UpdateConnectionRequest.php | 174 + .../V2/UpdateDeidentifyTemplateRequest.php | 188 + .../Dlp/V2/UpdateDiscoveryConfigRequest.php | 178 + .../Dlp/V2/UpdateInspectTemplateRequest.php | 183 + .../Cloud/Dlp/V2/UpdateJobTriggerRequest.php | 178 + .../Dlp/V2/UpdateStoredInfoTypeRequest.php | 193 + .../proto/src/Google/Cloud/Dlp/V2/Value.php | 311 + .../Google/Cloud/Dlp/V2/ValueFrequency.php | 111 + .../Cloud/Dlp/V2/VersionDescription.php | 101 + .../DlpServiceClient/activate_job_trigger.php | 73 + .../V2/DlpServiceClient/cancel_dlp_job.php | 76 + .../V2/DlpServiceClient/create_connection.php | 78 + .../create_deidentify_template.php | 96 + .../create_discovery_config.php | 86 + .../V2/DlpServiceClient/create_dlp_job.php | 95 + .../create_inspect_template.php | 96 + .../DlpServiceClient/create_job_trigger.php | 96 + .../create_stored_info_type.php | 96 + .../DlpServiceClient/deidentify_content.php | 65 + .../V2/DlpServiceClient/delete_connection.php | 70 + .../delete_deidentify_template.php | 78 + .../delete_discovery_config.php | 74 + .../V2/DlpServiceClient/delete_dlp_job.php | 76 + .../delete_inspect_template.php | 74 + .../DlpServiceClient/delete_job_trigger.php | 73 + .../delete_stored_info_type.php | 74 + .../delete_table_data_profile.php | 74 + .../V2/DlpServiceClient/finish_dlp_job.php | 70 + .../get_column_data_profile.php | 76 + .../V2/DlpServiceClient/get_connection.php | 72 + .../get_deidentify_template.php | 79 + .../DlpServiceClient/get_discovery_config.php | 76 + .../V2/DlpServiceClient/get_dlp_job.php | 76 + .../DlpServiceClient/get_inspect_template.php | 76 + .../V2/DlpServiceClient/get_job_trigger.php | 75 + .../get_project_data_profile.php | 76 + .../DlpServiceClient/get_stored_info_type.php | 76 + .../get_table_data_profile.php | 76 + .../hybrid_inspect_dlp_job.php | 74 + .../hybrid_inspect_job_trigger.php | 74 + .../V2/DlpServiceClient/inspect_content.php | 67 + .../list_column_data_profiles.php | 78 + .../V2/DlpServiceClient/list_connections.php | 77 + .../list_deidentify_templates.php | 98 + .../list_discovery_configs.php | 85 + .../V2/DlpServiceClient/list_dlp_jobs.php | 96 + .../V2/DlpServiceClient/list_info_types.php | 60 + .../list_inspect_templates.php | 98 + .../V2/DlpServiceClient/list_job_triggers.php | 94 + .../list_project_data_profiles.php | 76 + .../list_stored_info_types.php | 94 + .../list_table_data_profiles.php | 78 + .../V2/DlpServiceClient/redact_image.php | 65 + .../DlpServiceClient/reidentify_content.php | 89 + .../DlpServiceClient/search_connections.php | 77 + .../V2/DlpServiceClient/update_connection.php | 78 + .../update_deidentify_template.php | 80 + .../update_discovery_config.php | 82 + .../update_inspect_template.php | 76 + .../DlpServiceClient/update_job_trigger.php | 75 + .../update_stored_info_type.php | 77 + .../Dlp/v2/src/V2/Client/DlpServiceClient.php | 2469 ++++++++ .../Dlp/v2/src/V2/DlpServiceClient.php | 34 + .../v2/src/V2/Gapic/DlpServiceGapicClient.php | 4978 +++++++++++++++++ .../Dlp/v2/src/V2/gapic_metadata.json | 278 + .../resources/dlp_service_client_config.json | 305 + .../dlp_service_descriptor_config.php | 778 +++ .../dlp_service_rest_client_config.php | 1062 ++++ .../Unit/V2/Client/DlpServiceClientTest.php | 3672 ++++++++++++ .../v2/tests/Unit/V2/DlpServiceClientTest.php | 3373 +++++++++++ 419 files changed, 74527 insertions(+) create mode 100644 owl-bot-staging/Dlp/v2/proto/src/GPBMetadata/Google/Privacy/Dlp/V2/Dlp.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/GPBMetadata/Google/Privacy/Dlp/V2/Storage.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/Deidentify.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/JobNotificationEmails.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishFindingsToCloudDataCatalog.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishSummaryToCscc.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToPubSub.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToStackdriver.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/SaveFindings.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActionDetails.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActivateJobTriggerRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AllOtherDatabaseResources.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult/CategoricalStatsHistogramBucket.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationHistogramBucket.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationQuasiIdValues.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityEquivalenceClass.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityHistogramBucket.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationHistogramBucket.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationQuasiIdValues.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityEquivalenceClass.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityHistogramBucket.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/NumericalStatsResult.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/RequestedRiskAnalysisOptions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryDiscoveryTarget.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryField.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryKey.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions/SampleMethod.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegex.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegexes.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQuerySchemaModification.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTable.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableCollection.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableModification.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypeCollection.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypes.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BoundingBox.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig/Bucket.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem/BytesType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CancelDlpJobRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharacterMaskConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore/CommonCharsToIgnore.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlDiscoveryTarget.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlIamCredential.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties/DatabaseEngine.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageFileSet.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/FileSet.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/SampleMethod.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStoragePath.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageRegexFileSet.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Color.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnDataType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnPolicyState.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/State.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Connection.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ConnectionState.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Container.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentItem.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentLocation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentOption.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateConnectionRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDeidentifyTemplateRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDiscoveryConfigRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDlpJobRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateInspectTemplateRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateJobTriggerRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateStoredInfoTypeRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoDeterministicConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoHashConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoKey.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig/FfxCommonNativeAlphabet.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/HotwordRule.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/LikelihoodAdjustment.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/Proximity.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary/WordList.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/ExclusionType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Regex.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/SurrogateType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/EventType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/Export.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification/DetailLevel.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileBigQueryRowSchema.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileConfigSnapshot.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileJobConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileLocation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/ProfileScoreBucket.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubCondition.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions/PubSubLogicalOperator.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubMessage.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileUpdateFrequency.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel/DataRiskLevelScore.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataSourceType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceCollection.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceReference.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegex.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegexes.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreKey.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreOptions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateShiftConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime/TimeZone.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails/RequestedDeidentifyOptions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceStats.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyTemplate.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteConnectionRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDeidentifyTemplateRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDiscoveryConfigRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDlpJobRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteInspectTemplateRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteJobTriggerRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteStoredInfoTypeRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteTableDataProfileRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Disabled.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions/OrConditions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter/AllOtherBigQueryTables.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseEngine.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseResourceType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlFilter.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence/CloudSqlSchemaModification.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/OrgConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/Status.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryGenerationCadence.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoverySchemaModifiedCadence.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryStartingLocation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTableModifiedCadence.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTarget.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob/JobState.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJobType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DocumentLocation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EncryptionStatus.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EntityId.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Error.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeByHotword.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeInfoTypes.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExclusionRule.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldId.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldTransformation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FileType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Finding.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FinishDlpJobRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FixedSizeBucketingConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetColumnDataProfileRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetConnectionRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDeidentifyTemplateRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDiscoveryConfigRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDlpJobRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetInspectTemplateRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetJobTriggerRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetProjectDataProfileRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetStoredInfoTypeRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetTableDataProfileRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridContentItem.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridFindingDetails.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectDlpJobRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectJobTriggerRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectStatistics.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridOptions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageLocation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllInfoTypes.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllText.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/SelectedInfoTypes.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/IndustryCategory.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/LocationCategory.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/TypeCategory.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeDescription.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeStats.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSummary.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSupportedBy.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations/InfoTypeTransformation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits/InfoTypeLimit.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/InfoTypeLikelihood.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/RequestedOptions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/Result.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectJobConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectResult.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectTemplate.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRule.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRuleSet.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Status.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Trigger.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key/PathElement.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KindExpression.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KmsWrappedCryptoKey.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryStats.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Likelihood.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Location.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Manual.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MatchingType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataLocation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/NullPercentageLevel.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OtherInfoTypeSummary.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig/OutputSchema.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PartitionId.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrimitiveTransformation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/CategoricalStatsConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/DeltaPresenceEstimationConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KAnonymityConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable/QuasiIdField.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/TaggedField.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/LDiversityConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/NumericalStatsConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProfileStatus.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProjectDataProfile.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuasiId.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuoteInfo.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Range.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Condition.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Conditions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions/LogicalOperator.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordKey.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordLocation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordSuppression.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformations.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest/ImageRedactionConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RelationalOperator.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceDictionaryConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceValueConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceWithInfoTypeConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ResourceVisibility.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RiskAnalysisJobConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Schedule.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsResponse.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretManagerCredential.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretsDiscoveryTarget.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore/SensitivityScoreLevel.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable/QuasiIdentifierField.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig/TimespanConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageMetadataLabel.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeState.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeStats.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeVersion.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table/Row.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile/State.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableLocation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableOptions.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableReference.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig/TimePart.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationContainerType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDescription.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetails.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetailsStorageConfig.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/LeaveUntransformed.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/ThrowError.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationLocation.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationOverview.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatus.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatusType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/SummaryResult.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/TransformationResultCode.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationType.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransientCryptoKey.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UniquenessScoreLevel.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UnwrappedCryptoKey.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateConnectionRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDeidentifyTemplateRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDiscoveryConfigRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateInspectTemplateRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateJobTriggerRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateStoredInfoTypeRequest.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Value.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ValueFrequency.php create mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/VersionDescription.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/activate_job_trigger.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/cancel_dlp_job.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_connection.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_deidentify_template.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_discovery_config.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_dlp_job.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_inspect_template.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_job_trigger.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_stored_info_type.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/deidentify_content.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_connection.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_deidentify_template.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_discovery_config.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_dlp_job.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_inspect_template.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_job_trigger.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_stored_info_type.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_table_data_profile.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/finish_dlp_job.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_column_data_profile.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_connection.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_deidentify_template.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_discovery_config.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_dlp_job.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_inspect_template.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_job_trigger.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_project_data_profile.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_stored_info_type.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_table_data_profile.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_dlp_job.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_job_trigger.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/inspect_content.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_column_data_profiles.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_connections.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_deidentify_templates.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_discovery_configs.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_dlp_jobs.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_info_types.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_inspect_templates.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_job_triggers.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_project_data_profiles.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_stored_info_types.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_table_data_profiles.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/redact_image.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/reidentify_content.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/search_connections.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_connection.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_deidentify_template.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_discovery_config.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_inspect_template.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_job_trigger.php create mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_stored_info_type.php create mode 100644 owl-bot-staging/Dlp/v2/src/V2/Client/DlpServiceClient.php create mode 100644 owl-bot-staging/Dlp/v2/src/V2/DlpServiceClient.php create mode 100644 owl-bot-staging/Dlp/v2/src/V2/Gapic/DlpServiceGapicClient.php create mode 100644 owl-bot-staging/Dlp/v2/src/V2/gapic_metadata.json create mode 100644 owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_client_config.json create mode 100644 owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_descriptor_config.php create mode 100644 owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_rest_client_config.php create mode 100644 owl-bot-staging/Dlp/v2/tests/Unit/V2/Client/DlpServiceClientTest.php create mode 100644 owl-bot-staging/Dlp/v2/tests/Unit/V2/DlpServiceClientTest.php diff --git a/owl-bot-staging/Dlp/v2/proto/src/GPBMetadata/Google/Privacy/Dlp/V2/Dlp.php b/owl-bot-staging/Dlp/v2/proto/src/GPBMetadata/Google/Privacy/Dlp/V2/Dlp.php new file mode 100644 index 0000000000000000000000000000000000000000..ede415345d0961fc7dfba3e707f918f7c41c385c GIT binary patch literal 72515 zcmdsgdvv2oR^Q5QyIbXMxBBasTir9``R29b>9Kb`J1@`l%*eKEYuc7PlH5Jr(~DM? z?Iq1~2_yl|lI4*l5I7+`vmr|o;N(DfC2+!q1Ww2an`MC|kU)lT2pkR^ z9tru~x>eu1B-z~?2>Zuu`%~4es#~}2yKcSs^3LXtcxZgFwq0wLJGJWg`rdeFvo^ld zYId5HW@CJPcVna08m~0BcIu5`hf0J5#r&>Hj7rEFrebTebF1xl$WnT%BF1b;{Lpr+i~kcDu34-EPb`c5Ymm zenE&zqug$f<4^I0VjTb5*xr6_ExZW<+x9gpHxl#WxW_@XVquglM&@bF} zV|TmKsW-RBsY7nNQhV>?;|!D9KD^V!Dld(@6T!l<=o^{sPOY_FZrqr!wJWXqPN&&g zMbnv?o3)OEF8cD`$JMX|uD&t;UY_I3OlXpq#yhRuns@Z^@m8&~+uD9X&YJ+-asG89 z0!^u%`i<1~c9XEs+-}dzxNCAjm^#ii>b338{`xG`YmMq`ZL@r<-fZo!YrdvPqwh)j ziQq;7C@ay3|c&Ap|$I@g!T2^zTS~j3l9=<1Es;i@xs#cwo zwE%AOUgs>($#_hB{1b=713mbRb($N1>qtg4NgU|bbn>j~SKg^lRpdcnzLeAe>4y!X z_R_i{ch%sWr)NviwEF3x=*hI1a8;xGokmQZQ&mNs>i6@(-)lsF>PMHYs?I#cEl`K6H?#R&PV-7L&@#sAMHhv zNZ+nBcB{3__C}K^plv-RL>+&W2wHnAHa_^?k?98}d1!R=ZqlUgWq(i1fi%0f)a<;| zY*npUacq48Wc+0Gr#zK5S`_lX>c5t%^7hb-TV*@9d2Y$o`l5>px%X z)TA8A?>1_aU^NWH{;dIVOfI?&hC{zu3qn-uvT3=srzZKnJ_m97ExpHjQ4H}qd7k@O zCwixaRpY&Yq;&8`Dt9WI_3fLI7RC+% z#OU-xhMBCWwnRj;!{QK;kNpENF`C(K@3{Yyj<}fu;92bN(W6!awCgt#hD5VSNDffO)hr5jsSV7$)K$&Hlt; zaZG)hYi@7UZys#$=f&t&eY@1Czg270H=E6>M91j#gN9iwI}NQ5iVOa(rJY*KCCaf8 zxtwPWfP8azID`lMtQc<4d2Wv}aZmRJXraDc1t~7ep4Mq`tiCN7SLyBDW~U~J^N5v< zJVQkLN32)GiHhVf?n>HY!(DgAPkq)UalF!m=-cj;nmbaT8#{vjqthl5!~Rk0oNSB( zb%e;F)UI{LgdF$1-B+&o6X-Ab4p~)^47G5VG$_&ZN_RBzDVg+5%tLpe zwB$89QY_#k0a*t@+$nL?J5^qQ{nG>D`0QS%ruI66#e)?|_9u}rI&BgqfnJmJcbnL! zbyOT8TT6~`)c%c_h`YZf#hKY_#dM)mytbMytz`?V>AB28COw~cj};d~nU&OHIx%dG z3L*bldUZ9un21@&M4bPgU0F>GxPPu@7ZZc-pM@)ni9_^fG5vb6v{qbrE-_@C5XY|O z^7Ezn+}zqqI$KN}whoKI)%k_Q5$mitxthD0&adV&*`nJbZdqb9{rX&b+5IN0BjQl% zNJgB81drpxEQ)sZtT`1lZb=AKPiSf<#n)il0zfY7YsyE zq&8^&f{3pJp`|)eBTK(W4P62o0a-92;v;D0xF(jc{Q{wPutz50Ov|e<-0iv`l zGF59*9BMV+(E?!H&{_hY%s1ajJ|zb6f7V4YEZ44wF|G9qA;|uqBQIdV?KV2r`@|7_ zAVGp8dd%~bOqKYi?oootyImpIf+W8q_OA_z!|H4iVUky1Y!q7%2bl~p^Ci75?mts3 zdwVjYr-krHD3S+#NvQXWBaJ2|2@a{q!8FpcYKFZVskCZXSBaEhFn%JUq`M=mu1}Hy zB<(s#Zy{GF#l_fR+1|8+uaOKQ4r4tnj%k~tBvEyQa5H=VpQg@>b7b1EA`RoEJqaJp z6dWe6HrK7^#L-Txe)A^etn3w+z3e|tJs|Fj=!GstZVst3+$gWt8f_(0Cfp_YRCTq5 zlgqMkdb`uwgJN;~&E|T^iFRkbI+6-oB}|Q`7m&QyXkK)PiblrwOyT#NC+syLU@LA5q$bo?RPc zM#t5}s1$#6=K7R~6Nqvh&OoRlMA0S+rLMA_{Y``7co5JTG3o%~o#i9_ia6e?Rbb1N z^b{piFzd2;*;-GKwetEFoI)-DR{BgTQ-&IQ`p=6K)n;XPiqiv;Ko*ppIijyv$9J{>_W^#@f_B`|Dvw2Zy!Z@6#rX z_Lo|oR3PTXG3C=JN#>w5ZIeZ+9Cyyh#3CRC4~rq$+kQx#ifUqcPpy69F_8#j-a08p zHsBa4H8(a$?Io%jw0{Uzp`TEQ*(yTQY`{#)-1Ty8j|ClhfWTJx$e9Hlnn57HC`P3c z;Sxc2a+IQ36M$`tW4;g2jN*{*kPubn-59h#0d37WY$Pzr5S9xkok%F=q-Pu_5F5LV zMro(q*<@XZp*B1GiL{+K**mRT0|M_>jX%>7h?7v;-62m`0M6WdHe~u=2HPxzdr7%d=epHDq|F+ycK~ zq|cHNwW5S5M6cq5M5da#(9TGiO|(*H-$e|5OSP2oj1a_3ZW6CYeA3r#= zk9#Qt${tj1HT52p!RopF=>ah|U#nL^qV?ZjL?uL42AtN1lep)pOH{S$^Uc=Ph zoiqB}JmAEKq@l&OnTZXkwMrWqo&$ZlV4>}Rx7AqlV9o~5foDzr7Non!gJ)I>Q~PUU z;+$`3j9azOdY0^m?q`-Siz7`i%v<%^JL>d5X*jk;XnyUDW(z)3oY9=>WdAZYJMU~x zV6&eNu&PHsmm27UTVcOj4#>Yg`|VlNzVA#he|SKg%7$Y2kSm@ zF1J=(T`QIfb4%%!RKO<(=hqs`y5Vc1~DS(&4ql_E^(&N9zNR;tVtyRYgP7^w-J@o)Wh`q zjDhi*W(SBQnv>rQn<@l6BhIzA%R6m^qM*IY02Ks0iyA|@`-hOf4oWDM#P3QuQ2o+*T8jLVyXO@=w#4th+`?K)9VwpDlCuMQ{{7}&|!*`x%v(*$9F>Q((%~#_Gd)yJTyS`dXUqVbdA#TP98Pmx z+<44^*oL3Jf>bo@RTOYu(>{Q|Chm7&OB)C|8`5%f=F67&!n8K^4=V^aIL^mM^e0Tzxe zgv?ueB?m0+&OX3q6aWv{6)=0a#9WX>SEJJ(=y#^%;B>*+KQbf|!O2@=;?#0(E>+Cr zvH^8Wh~dTM+-z!@W1^}2A_AJ3Y>H!|skK5epIXkO5EDfNHFZ6mpG{?6O=T1BgPY;- zYr2J1nJ_3S20_`uiG7G?Q z0yLM;VREU&1pP6e&aR~LmlJ{@E#y<#xiliA_+cTFT~1}^5hcYRi|PDIDtj$)jH0tk zx$I);GX9eol|kR^Jb)diUozSGTsB?6p9$)f$)_cV69hX`$fwfF2}^bqr)a^KQ`b|MmkLGvJw-oVhC-T3oTknz>DM!Jxx^WqtK-F`bSaz0fAa*qkT^>^ zX*PYebUmGt!#z$tvbp@#)V0JIEq^tYPc5$DuX7XxUQOrM5=m;anv?C%%Qm@uacvPh zbAf)zuN7z&7im$2Om;D~in%22vl8NH0s8h*DYcN#%%u|d(>x2SsZ2KU0QDxeuK_~ee0n9fm`|-PW#;%i%;gEUAlzjf z0pMXVcLnR9lz>uZ9wz}yb8-ZR5mY`im%~b5FRrDQOPTCK4irpBGI5xK9-5`tGs22s zwjNJ4%ZUI#mtw+R$3cgdso7auiDU8=D<`nyKW`vdw@Z;I3f4)LDo)LyDHq{7(>~&FGXZZ_L5K@d1C)0d`>hnR*7w@=wqq5LGfrh%mJqgT)hkK` zG->oI5gP#R~KsW5W)`SoA!?lh=gOQlpBnL=d`DRH69bveTd`L6h-`PLI#2eI(Oqm zcM86Ed~noBg+=KVuGd;Jg@mELEG#GZv(X}hd%L2OVf#Tc(w|O6L8p|OeQX$ouRK`i z1NgDy;+UWM-VkSCPu4()uvn#njT0xsC#=vvZ$O9-%4Al9AUw6%SjHBY#F*k6Vem{n zFZ2ao@md1nAD|$tw@T&h=JpKcLI= zy0-)L#tm`ytLo4;}9w=Z{=)bfU5A zPK?^b-_o*OrkeaRc&vgOevq+W5GS?8Q7e@@kPYj*NR{Pt(qrPuFC7-AqDTYT!6781 z`=Wp-Xp_YPXOMp{B*t(!qyLX^4{RCw~G7 zh@RQ}e<;n8|9(J>`d5X-vLRLi_ASe{!uz~-uaK>UooC^;?bO<#X%j8!Lbl!Ee zpxAN7TlcFJY9toX^9LEpl}p|+yc&iYgXQyq#&G42GsasH`i2^a;{pfTB)?Q}2E(;l zv-+V%r6k#r>DLZ|Lc^(chJP!{AuZ&1s|OiR*`>9r*WOc(Vq!A^-G}Fa^sYEv#NlLE z)}Bq-F)|fgcEEKEH+$BcC(j*_h4c1q8HxvT^klC#EGLQ`bsZ=9HG^R_OU)S`hX*C3 zl4GirHesSSZ??)?rS;v)TQvlzI0fp>gP=0{oJ|HlFX=I7<&eqG#KZ$V+E@>X^TDY% zn(rVdTPC|nvvx455xmY$BT`rf$@$DnEwypqU0SGvuMOMiqaAr8BG4*A+NTocH-~E#6vI^VRbg7{w{Cm8~5T14zd?PPBiI$2;#pZlJ1Xb zcUp5)Hvn=p0Xk&ESrZ~(UFb@P*8Sp4c!?6_avvx}bIu($Fef++?C9P|4-Ia+xow}j ze=BA=GxGn@^JS+%YW`-Fz%2o^b7k;DIomG zpCw7(Oc{D&Y`cZmT6K%adi zFt~@qhUv9y^S=a=br;5D=Gp4dW_BalZ#WdROBLDvZ4gMvAL39em^X>FjRT!FpNB+E z->HY?c@=luELyN6IiMX{;{{axuO^Tm3xY)sMDlx*+9qF!`H@jJBF0kne;%H0zW>O1XWI6?IiB zCk?*_b}4yBJZxy`$HqZf9@2?iB0{dqdU+k56;)m#mi+qz;!(r+ftgYk4AGMp22oT@ z{s4;d{y;Pp3+hEoQ(qH{CaPQi&$hsi*luL@A#tIbE|0tgZ#Ed~>=zB|@Y(`S?1wVk zThjEkm&Is62YfC2me4kK!$WvyOU7wX!x*$a+?}{m$hm)rZa9F83_~@1hXYP4!^o)rsIx z&Vam~ncJ8zBZ6b$zLBWH)vKDb33@`KS~iF0gRTNUh5UGAmozs@R1rtDr#l{_(|+&( zoZGmHHV6<6^UWRmH4%4jcOqIPhoosLKdQ-_OJf(&44{x#hF~OR^~npR_OIc-q5j!= zK;HG%DR1HVTTdX5#htwz)i`hKVa%H5#@;^v>S#6+d2~0LT9rQB+}78rO?h&9o)Y!f z(LQM-bdJvSZ@M7CH@iyU1Mn?##^R9u2MDXV2~iwVunOWF!gE|$2Dgm8>GIrfWZINj zsN=gue=qDUvX9lpu^>cZI3v@>vnMYqhT$#aT7tZ<7zD?jA=3@I4D|^^yC&}Q!zpoY z+-7;Z+Q5NQ`((=O^8-v%THTWBIh(*uHXk=Iu! z@{ik&`k4IVK_qvDS8eT3(4m2wxFC0DyUDB2%~ulvD00-vfxq74$*5TkUv$TJu- zo8`M);$*7P@Q(9_IO5!5V&=4X4@M~Bh7lHVu%bj68QYR6`a`BVq#NzfzmCV z1gG*YI*H^_{7qBzT)g^<0dd|>AwJ5qiejX*N!KDJt*c}JQ_-d_fF_Fsg<-!3g+fk3 z(%||dydIkFRgHp?X;T2I8}wy@w&n%4^q%BVA>2`ur-T)5MUr6)DJ1r%4vVu0S|d)3 z*sOmf*n_xHhMY!(O)K8uw<+5&&yA&gc0#c57pWXf1%p|d=>~9K=4(2=FN@Qa&9c0_ z))h4CCbJoy$Zew>gq$ZWlLq)KPZ>_y0`)AQBYXMK&w)ED66`PY0OMn8 zybLKlgo6@_E%++B>T~8y55XQOgP|F8G&H`DZt@n8)Llhu z2LvjHsZH4|w>LEq_KF)LM!XeE=-|MaBmD@9RC}|&;mn0IQ%$HMwV*)F9Uxc5c{LfN zo7Y;<2gqeo(X%=#`M(KKJSl{x+>Q=ls114#s!p{v4VDT}nAHY_|9PjI1{xtfKZ{H0 zehgcSxR61+1FBcoKqWI9HL5B8{!(S44YR)l3ZMQBcVbT$Gb`y5QX)}d$5+1x*>~5{ zsXX%Vkkhz=+&N0^L&D>H>RKtcP~tCxGBuCCTurAhBNY!#=wH-E_8+1qOS!c?eL?5M zu)QP_!JVf|_iD>}U%KbcxO8tLPJYg~Uk8H;&-lsqF4UWwM23za@1bGqBZa8P;R@ZN z#qDC|ZKe>c3=C(gHV%#=4G+Vm;K_FF9c3Q$VPM&Bi?ap_gIXG=5{M|jhDuiq%ao1d zFETdi66@quK%mS+k2QiKGHS>$Q?Vhvy)wZ5A(ZPPcHS;FGdH)9K5ktA$I$$}O?2IU ztIl`t$(}3W2sgL3D2>S1s4hDz%fpmW?i*-wPQvkhTY8U;8c!!9ez6`EHf63NS$l3N zl}Bl-Tq(1N^xQGp71zc?buWKAuvF5$l2D)Na-bE!far^WfYOjW7)t2{BQ zYuPy@qRRZ!LzJX@bqR^RNE}AC_0TNjzPo1oJ7}I71+E;#(LF(eR0{C@(%$O zR5b9%FnR>_I57eJg3jT-`i+GHUNH&L{$DW^Nb^fp6i7SFvRP+Inr>AGI!^N6$#21} zIsT{hxEO@2QD>}su!x$LZ!50Sz3Gb-|CNf4tUTlTJ^De0{U?K(MXJN8uLXCXz?G+}PPfT^BB%F*-;)3fH&%SfU6IA;y>Krrvog@xB~Emks;EKd5BbV+iE z*>q6Q`WOkx%Jl20dDPKcL1y~^xa642Qy4@^^PNG;duP6*KOLfMcD-`@(^UUOs=HL7 z<|TMq$XcO7-ik&|CV;dcsGZXr=tBS9?RQ#b1ekS+8&m%^-Ok%TB}U%bYL_&G?yCRg zt@c$O$^(K7KThkR3O`nOmOuy>g(EQ+=QIDPu)@=Un&K4sI?C-<#L0+3aRFjP&A6mB z6YhYmIbLBq1V4E0i!r#L0;>sVrno$t@G!IzTxrTl#U~0sd-x>(Oh;>ofA$=>zElhF zUGL#$tH@ZBOOpu%Jg|&R|IKFA{>}k$R;xCCtFleUS(1}eXF~H&lL2f1P?aZL>dnNE~N??pC5SRqeJOu~&KGK0x@Q643!(#rLzU+W@jm%F03sV zp@h#z*zSe3xw&+KD&WAqmComL`NV+zNw|~z19+}TTF-jwCz@HHzdzk~4c`7I9LZXX z4qxNt`Hul}%AQup&kO_)l}@Uc*1k%Dmj!aAPE5`LjLY>`JxZ&!6mdW(OUcA*{pnmDH>*`jWn~Rnjs?IVK?vheLTj|oBynU#&+c;U$ zNk2k-MDQA2Ii>p-@&+f!N}`9RJ34K;v1kS-Pvk=`XW^M!dbjY<%_I|_T@kh)j5=BO zq7;}Tn%Be;Dm+xhV+_{IA_Y>NBQLsu_G zY^2+;SMN8v&LWZ^`Un16#MJH%qz%JtNTylfZi}P+v1p3m(I^oi)AXQkZ0%?}z6(>a ze{@&~q&F7Tg9Z8x2`SU}!vkLuBbo!e*<4o&j**fw%s!mFO2~T@e?l4~J+h!LAen4x zce>D&We?oH9+vqm`pqDdJuMOGuwO6J=3Id;m~wh~nKpaId-i$;`bW8q_Xl>jxfVF5 z0rc#53Eo|)_o1E@33rnng`$BP>`UZjq6s_7EZMVV(-~Yl~{}tQ7)AIo$kQA?F%w4wTDTMSUkclp~+NLCGe( zPP2?Z2WP%M_HGJwJ)??*yX&?tMx4Ai9l8c9!5`2|CAr+OQW32qgv)hNM__PbCl zxY`QRijK7@2g)h<&8O640dud(0=g`qlo#TblrQ&+IE=?xOYPltg>;kFuDY+%ORnwB zViW%;?5+dCnm8+;cSX`kn;i`l!mP9_6=mU@G-y9WWsDY^bLa`MZ;MAYSiL|Ax6#~% zPDYg(EBFswNb=U($n?vuUgj&U;vYq?9K#SG#0Sc_2S{KrBue{6j2*DIWCTaEWGrAf>%Sh3#Don z#gk{mDb>Qa-^qu>gX+6^hmuHI7cRnKv7PSt4Nx_4=B+0C&u>z&W`UZMj|5;T(;4WN z@7U@bBX%X4(l`9DBh3{&pHY!CtN}M=L1MX;95BOD3<8so0+0Mkde-EaVCxJYHEXAj?rPTL;~W7%dNt4a;-+dX{TWVoyB5e@ zZ5hg36(;epvLNF*lmKI|iF1oJ)LD}l4DQQ;S7Lv6Oq{0_rvTu##?jsEI3)fK)qCqS z-%{^ENDrX==G@92LR9*Q%*=rwo_CJ+*t?xFmjMUkLi9vcF*rQuR1eUX4xRK#V03G0 z8%b<<;Ke^{`*qY$M&dg?F?NsfkEeLf@{t3>P@0^^{eE62aC<|`9(mJMgp`V5dUe$8 z$HxnMrZlJ?r)yQ5BYAua34<;SJ@co0CriDm&_lhme;BCX^LlRpQVP~V5V8NWd0Cvo z*}ONimc_c6BIfI;Q45uWo+yEGppm@MaRreTPWw zUx4i3-3#>4)9#-~1pwTuNgt5q24-{D%d!8iVz~jp2V%Ja81jLu0P}*wD&CXjYVI0< zhdH_2wHhFtUfeYRs}JrP=yCU`{v*mGl?n~sn!@?i5aCPk=`jyVJ?6aC<$=h6^Men~ zew-gjC}^SlQwc0d8EK|Sa^$sCXs9TbO8iVKIFVvf+pNEe$PS51mnk{)bwIIlU}^5w zc$I=2?3JHnBTuCHu~FVI8Mp|j17vE%Z4^TatxwVFv*IY>Ny#xyroAPgnL-hFWBKo* zQ2nbCqBDh zX*#C*qhWxse&J5>n*T7-(_)whf*y4YE+n=I<-5mhoSP8pt45oAcR*NS_yN-#_Wuxa z)74uqqthm*LU`(F>Lm}yWsv|f2p1q4U;dma^z4DgGXxE&M5%Rp$c)0*bXObi@U|gK zq)t9MZMtgdfyUcB8D2IDFA&gWthIsr+#{YpDc5&Cjk4g&rRDS$yjJbMkb_*`Vrq67 zmv!>F1uE+vqx4@SIpA*19BQDaR&eLQ-W72dA*gx{K&XfvQDz&N##ANU1%_Jcxbcu( zM1gVraR7Yvcwvq%KV-5fxQ%NKa8c5*GGl^nNKpI4A&=1x!}*j45#BTHzLVVDx8v!) ztm4>Gnsa=Om_Bn)gp}(cGlyQSjpKZss^ZY;=Tk~$=~2-Ba+6ohGq5_nZ{Wow^@vj* zMG9^s9XO$!sh9^YAmW>HJm41^5>Jb|zYyP%_c3JMOZU5EC3Xgv5xl@_RE*^a9^b^( zGh`)lm6%>j?Fcw<3*`hc_@4dk zK$u~{@bm+%VDls*y4_yZ%ag(d@0C$e4aAo)zYmI|&CVv>HDox9FVh_m!#t?GMUJ5O z#^C_raS0fr7OyFIkZHV`PSeQi#?WHN#F=R5L{m^{vG4Xxm!twKgkFjl?JAAkYK^76 zgDMk$*GrIsxki^A5GPhb-Tr&@_?X^q-O@ud?-$2#THr{mmdYELnc9}HH=M3;BNVr_ zgFu85@{D;?8i5{6u1~55*t`|o;emnx)}nW`N7`WsijNkqAcjYettlN^S6VT}M!O&a z;@ZUu#R|QD>)LTt*Ta49ZV0#T4&(Y|i4=9lg*jP{E}*Dw#cRr>BiWxq7NRqw&`G4| zDy0-`l}jkNfdDIZNS|&#I;K=a2PUN&Y?W73Z*{^cy2=C|0?TVKy+!4Kl^Ys>YJV41 z3)gfO)dIOe;j<&AnEomcr>897Cah|dt9um!n)~55{F7z@R~x$&K_uZp%ZXWSp@E< z4vPJ^ypl){#2DZ!GY%KxBW2oZvPafoX~88c-+=WoAt;_wAW=FPi8K>sYoQPXMp6d_ zM97w-F~Idz5`9ntnE(d?dW4Zjy+t17q+Bn$E3Ynb+JztHoM*)78g9ni$hCGknkiOu=)&= zN?~t{QU7o#DR`cqlg6{t=~6noh^OoVZY^8fPcKLpaLYZHr`PQQ&D9m1m1~99=srBX z-yE z12)W)XrmWz{hf0NDdfqx8~591hs7|*lyICp^%9(L6tUsH!ck9)A#g>!<3tR4blPMR z@nDni1!EnZ8m=uKmGM7zuxm5Hn4U;a5*nV4fvkR&L?tIvX?Wxw9+@_UQ!?C|7*)ah zggjs&F3#o`=PmOEfo{eZ^3Q<)s>=m?Oyz8LYkyH3!PDE^x@R^uT!WlQtxbcm<8oo$ z27nj(O*i1j7yKxjI*y9AI%#|a2h&_ThO_SxLt~%0bBXV$>}7ICv%j398Ev~MjyRi* z8e^~KW=ryc(!dEpPV{OT@5M^T8vf8;wgGzklirR+umKF8)1xWQ0RP?a0sV~0Y~cdX|lT4|>>+Ub8rboD-M zJ|_}Lfnl20p-}{S-8-1GD#qSr!uEfTq242c)(pl8Si8}BsqAP--JL3F6{;1>Cp@8`y$r8S=jz_;ocAzh!K2#mSz7FcuwR= z3c+`{#ody`f%9AfX)44+;x?*KJYbx#Vgrka+dAuUQoA)O-GCgC6ROH@qr)2f;^B&=9(Q!#^RZP^CD`` z$y@3<3?jMX6Q}d|49M$i7UlK_G(x{<0K5cjZ1GVkn z9~7hh2?Q*xG?gc8(Y2A1u7SWSH+kFq&@|>3kc9#}0-F?4JX_XWgve!-AG3$S?5eWsgg}>>;ZUq$4`34j2>3ehwJxVYn(4 z+zLv{VHH0hrP+P@Z?GKJ$D)^mDmWfXMlGfv3Uax{{ui@<-K!wRpnKihCD?eiDM=cP zAFQKp-NjDdTTSaWUt|hRQz==mh!br|s_yyJ8kQ-l?gwSou24XqwJU!IeHIQ%JX9j) z{-wS3RvjvW^!32K5V#_AknCgYk{H>PU`zE*ZA+;Nrlc>P0OVH({5ym8_E&=-eABu+ zJMV6%gI6|BgeHk1KZoSvSQoGj{#ehl5ZXPiE-(1JA{5 zT$W{!ipmjO*+GHInhcW@=UL_KHS%5JpM(g9`|Qiu3&ROGf#jV0z9K?v)D=b7!NhhR zip5DgFFXe3s#wsHIK871@v2yh&ePRw$Ykh+L7G_+O2^7ul5%6C5C(zd6UW`H32?$&k`qFxLj>Y_x{ zqt?R_hzdcucbNK8x_&}n>dB9lMJ3ZAPUso{tzlGc>&9>Fq_ZhGlk2DHc=A3|3UyfYVB)gDQf6@}alidB6mg0;K>iRADI$RkS#Z)b3X>&S*F`0l zpb9v#gpuiPRvQX0>6c>htYe8$#dfrjb_?oVTXbM7ToT8t#3f|Vs6kgJlx=46Qur_l z<9k%kzYTkEx2*y-rrtmjkqz07yX~1@K|vN22aNKfq9IlMqR~_z6qen;!Gg&Jz`&kS zAAN*;$I7eEZi72hk%mkEFzuhkQ@@@iuzgF zBX51i1MMF;DiR^q>px*HE0n1G6-quFdsv<$lk!a{;Yg*-ZMc9tU+Rcf=~UnkB3I=I zgQJbU(lr#_3I^X8sTh=sqkq#xGj^Z+1;<|hg4XBcHw1K8@Zd{QenCmmja@u%ha>_S zI8}CJ_~oR-?^ z2rF*aEnQ9R2%k3R=szPY$?yG#pm*5%DRCT^8|$3O&L^j51u$HGJJqg~x3?*;mPI(H z_EPYA(1IUh1J~w)Khm|JK_Y7=RDQK>kKX>IH@@hmTHH+%ruVr9iC~aLPOlwMeIz9h zM)A|=w2@%aP6w6=5c;SiuMY67db_S3EvE3ixiT=6UwLY-I32o3)&xLxm#jr9AFbw~ zjFl6TTuiq-(3)l8oqZs{;Ws%aldTQ8U^*R#tJ=o>I6!c=ozD=I4pFb9su* zVoTefZh2bkNq#sN6uh<5TM@$*2b6*3hcq28VciUhb*xOafcNyO{G z^j3oi?u%#ZPfCZVL)-DuVj^kLdmRfE7T`8U6~W<4ib zLpX^AL~97Aqc+xDaWvk)@vkzYJR zaa0n;rFND_{fg#U+-s3{oIv)t#L-55O0p;SC6`ykIhT^RNsB^(=L#H&bX|qm?5Hu) zltt@Rr!kwIIgxb1?QYlUt`{z;D+7zvy;0-*)|}?jykdYT_=L1jRH&k=Pi&@Fc_ zJfhGiRaF+1CNnoo=7DdWI8naAh?y>_A1PaXN9> z`IDL?j*y`*d(f})Q``Zvn9eQcQ>#nY;1AGq(JzCI&^w&6V?GUM!hGT=UGC?(;DJN+ zl;JUFv{wtcY+}?I4J%IPui#0t<4!lcwy>BcRHYLMcuY<*aOb0(+X*OVr#wHn%e3sg zX3n17MAhF1)E=znmNRqLBJ&0T)8D9=TBJGzv6)XpKlo2E(Vu7P`u-J!O2|nz^@aQ` zV5qP5t0MFZ(dKL-oP&U`K*v`0k+l*Af@I?);$=m0G zzzys`D{Ea?^v>`WvRkB^idiTPIyyanfI*dwOuj*WT@qO&b#YFQ5q7GP26oSenmw$7 z6Ul!(AWraFJs7as#^;l+9bm1p_>2d;2Nwuo%F@F)`~fzqmAj>WJiGmEJ>l=d6dtxGJfl9J#Y=bC*L8K_cf_dTL|D z&sWm(nYEP?-gc7T2I#%ou@I52a9tYfIovQ-ULYoOqjD8I;rF2K4n;v#;YJ{Jn{S5e z^Sz%6TW)U{#`J)ef~7LsOjWDgZhXCpOAxwW^;G%~5W9WtZ&1a<+)s!$K-p?{tOG9X zjJF0In@#dg7F|Ab>($8&4Zf^(QeRVd?~uhLITUK;R%P?A+RWbMYGl4?si+^SP*$8> z)v>pCI`uPUr?TaHGP&(CX>qrBDH$XUUJ_#;P>Xb=Iv3JL3*TCrN_SAQ1voQ z!DP;eeY*jM4O6UBr&TwQp6<3$4XTXWMa0?F#nZ>dg`IM{EuVGg`YJjP z(DS61#37{==!Is=TP|q(2M2|ve{oTO3!CIWRvXIDc;MmBrH1J4=w)$2PYD^!JPF02 zO_!4mtAj?9M!gHpW=5@Kd#HzVuWk3iEl?Z-d~;_ zeqg-PMdx?7EjuH6&Awe}0s5oY@cU-6Feo$gCFk8fXi~TiJeyg3Z7rR@R$58DUdrdL zmI|5cxIFy&Tsl1uBX59$;wz|=N617-JfDVboxVb)@nCS{7MXt9@6f~-i}U^&&gnEF zIX&D>c7_HZxlg#6nMDb{Y&wq}Bja4ZDOj4#&C}Bzc;CbQrl)~PkumMG<;%c>6Q4ur zL;noqz%X*1ws;#nmyPl@U?8^C<=tppVlJQ|CII_CpI%)~q2?dZw}zsBG$;LOK7%W9 zxoj$b4VF4?%jMJaxFiR}U@a)um&YIJJTP0h3}*xoIhVh-TFl|CM21MOmM^TP;h2Dp zy^whwS5+nUSz#p?hICK3e;$@83aa}J@8eKe*|8O(rPMSOvK3pp~hQE z6_((nfIo%&2c^PNW}yg=1a?FtWe;#%@}(jQZ{kejcrAl3@SpNHdmE7PD7%xN5&k)+spp4b;t}cBamosb!xLW< z6GvCb#a-XNDH+v$;@nEAIJbm@AH|}u1^%BG)^J|rC#(R6+5anXfehBi4FoDB4x6LRj?hNl}yP> z;gDV{WD0)6^V4w;XwE#RwQ6D_{d0=8Y>Y|XWia|@lQE`}b zq<__SFB|XUg6bgq28dSF?Q1D$mHftG{tij@q42gOdsUzIN~VyR%`9h%LG}V(=TzwM zG+JGoh5r{a0t`IrcNC<}W#^XH3UmSdIOz>ht?&)n0c75M;uLs7A{5DgP}~QWM?#Rq zFlj5Hm%DHXJWUpJxkVJ=UBM1YmorhZ=jXXKV0cA}SZ**dftT%1Mul)55f5hRyxCglfREZ1^p`glI zHbe4(7!Ic+M$HzW!|miup&N&OQ8OB#^Aq|}PHAvr19gcVy~go+h3$rO{_# z-C!oPqNnZmMK|@YDA3J%7s{4<3s?ya%Txg*)KV|am?P!f6;_~O>TqIyOD?csPejk! z-LF zrEc3Yh24Fv^de1XHqcltaQ-tXbtgb>>(kaT+9gUGAmQA;j_19++onA|?I|2GrFGGuJ{=EHx=;l2~vi=Xy&elx;Ge)#Ww%#w= zzjEL+sRzkH7ee~Q-5uzfNFv6gWoiSac>}2Vr2zUtKz{6lsN@Dr^9Drr@lc?t|C7_a z0kXe~epB=3r+EW{&3lhz{XD!Ki1h}sZ(^$9ru#+xuY%&G!&zeY7hs}G+KI$e1a_~# zU>zK_*C(vL@p}Ck>p)1g{wuD~F{kpAhGnWp9o1N4)x>R;fCX7Y4)@VNC2Ed!0=KAi&WO{3- zvu6j1bz;B7I&n9|Ihy7>vr0OEc26J8K5Cq_9jM_uv_`l9`8 zbdP?@xZ4u7D{9aer+H(7J^C8Y`c3c~$i9eOG4Y$o)(6;CKSr@>5^Z5Tw=Gkxc0+rOY7-MPc2h$1e+Go8gZXHg z7|9SE%t!a>$r2pQhs0y_a2oTW<~>KUerW)yN-{(l#=VjAm^x_Oo5X66rY84^i=^tTR(1dCX={)J_Vx(6F-OqvpIT#)t;f?zG)`HOG5th4rILRUx2W`vbh7PpTXfQF8P;({PzC9q?9IS-ohL1ZqSP3;V zvIYk$s!JEV_=d9n3@?nbbaC-wWD3EC8ZRdC6QqfW{%B%i|1{yX%DSvQaMmrnuWC_o zX8-HtmdPm-ZmKcRy(X`HOA3b_`(orle$!#cZjp{EBpjT;fwg!OP9|zrQXKPi1q69RIEHSaypCi-h%ah)>%Qd3E z_05hWG%#x;N|f2B*THkyFG{`xC}BsaGbx3TkYwEJ!^!9XQJ7JZ@}+*=q0#-V-^Y0% zd&<97<9P@--7i|c#3wb{eRu*RX6|^=dWwXI&elhi8!@oxc2_rIu(4jZ=~zi4$d6U0 zFc02c@w*W<8hWt*;9?v!^dkd;ovq)ZH)_}}@z2wEE+SiNM3_WEV8gw9+v8pEvbW$& zLF(6E=-1sB(b@VnB=RUWCsRu-Q_R-eNUy60qyKVjrM3-}50=Whd?t0AH|3(d{)8`* z4PLPyh&BP7BKjl)jJ`3yHh^3I5aGllNvMxVisMhl__e2vUY`jUzNSjO`T79eegtVv zJ=SA3v?CXDeOh^8`XXty+J6=kapFw8xyH*rP7}TK9$WiCuTH+IRvOgF)g};)nw&X4 z+U6;vx%C5}N_C=m;-;POHqui!oi_iRCwOKu@ zxPeC{`gBZbhtZ@SDkJRG4x_vHPgL7ie^;tf7rW%sL^SU+pC;VX`dy%zwJ1L>jA)K( zyiYX$3DA6&Nc|!sIizNNIyUW5$Ad;gU=>Qgx-{)k$AewG)E3?SBC6;_5^8kw=cYM< zDR^Le4rKjX+)D+23t-!n@e^vfPgH*fsCFaGKNqw1h1csd)`5|F{c)>rj9!1*ItV(g zUmoB`S^UUsTc-CHNm2&dYJ7GJOozHCA^X{Ykaf@-edt4c!a;9z`>ssFMX&1Ys%YVH zGno$|IGk8-mzZrE~qOyDxvBk*PpZcOcV_k?T-Bg6=uGSwR^B#)|9uK2ji)gEt zZ?v(3z@@9hUA;aHJy##1Xj;2I4c*or)sf8OQ&>%ix{V?yss-*uC1;sx&7HR<Sp2^*Z+#!n^EUyv`HuHhqs}8w%fj9Sm*nn|nq>+uKOb+q6HI zq@le}+Zj(E;N?GZGW`%DM{Ewm2d!%ym?C7shI($Mz@iJ%Ml4i&)W%`TsgdN|`wXGG zy`*>S+mJLbPqc<*Oq%z#+Q*b%^6q^akwpbuwqrD-ErKmPx4Ii1C(5sHL8`DfSl8LFrgwrJ_%*z`?>yTNaDCeraFo zNU*#0%}y-U-H;x!RJWmCzv;C4X{wJ9sb_D9roIQ0W4DSsrg3t?hI(>+9M_bW_WQ}) z@Xr&RCAsjalm%|66jS}^)_+V*Zgx65?U|{mciwp?@Z(f@x3f7Vt7SY%#mP6Ct*zPL zLG5>R^upK8COv^Wg~4&h1^?Pve?k8D`vy)fHk&sa zHGXP)5UZU;ka=F-*4QwGX3tr8E!r^BY&8g!4ESt_#xGbtfYdUu|M)g z-F-@N^A^&rx<5}x{Oo#$JcU-=KJTV(+z>Y&!-pXHa;=-??fQqyRQGwgsV;Ac zo;8aaYke4#>NKBvOpL4lT^#SUc59EnAe=8$@TOjwnR&S0E^lRJ2csXqdXK4|GlJPliKciUa-BP&Hx}M6uEokD6VvTB&#Mps1x! z%mFEhBV8Y9WXmwsGkGxGQZ!@hthi;_x+#xHf$0Mn%csOLq_3$1(XwS5|GTGJk~&sxRo2vBqV?P2P}VGh zvTyGlPR0XU)yEfC%sQM`-pVG?Y5rcp!h!@oX+y9-2L zSm&EC7g&lEFhvSy#oPy;EVpjUcCF)ClRt%ceLU2=Q-cU8Sf)9&5fLMs31JOZ&xmPZ zP&by?LK&`FWNcwVoT>IyvIe?IHlp}bve>&{n0tPq;|p}?{`}t~kiEDlG$6*c(UUX9 z?FE&+rM*GUh?f5~tY18V{UF?dTb=4rr{1j}*SjyJ&Tg|^l|Db}w5q%Hy?V8hy&_zL zwcwUU^F>1uu#6U#B3mJHb*v_2N{7go-hfYz!I;RGH1$N+ zm5mkV=Q|-n4R52c2cW2|vSoAXSo{4Du~{n%6;G~qMR*P|lZ?o@lP@1GrlL(nQ2G!u z*2FaR5%U|p^)gGl$BU`yxUw`JsO~8wDRdHrdoadyg*n5IBuX}5O(8a64w1}>My!oh zF^UDSpd}SoxQ(*H0c6PeK%3ASk}71c}$W zsYse?*-oN;yqL>VE88k|EnCmqExbm7q~TffnwsUCG^q zxT{r2LyX#Jp?%TKL^%#C9JzB_5M%j6feg=~jmAN?bx4m)ePUpDQ^+~Sa0x|Yxiv`7 zWJ>PO%aERp*b7LV=r;2SjlScPPZ#t_F!+TU*FzHlZ}b!r*g($JQ$$t)?R$-;>93_e z8B&m?uoy$INjb~%5O2e(F_!yn1g`r9yQ6%GSaC|mwy+J^p?Z!<9;kbcuVJa~tHD^^ zf@>zxkO-WSpa$9sVzn#f6oBlVmHT=Ll7R~eWk`E|Vr5ScP8Q##?1dI2kl1jSILH&$ z7%n2ujH7+Oj$qyQh2)#>WMJ*vgwgkz@A~ozEK_X8Mv$H@(%X=$ezDv5yi;!;N!^#N zi|r=|H!l3nzE-N)h^O>Bu)3!bO{puh4Lkn?k}cV^u|Ml${80cv|9y#IC8-K?V1lNQ z#}er(h0#R*He?Pk->T<^Nh}IR7Zm>ndv*o6Bm>Q+LG@b*qA9~YjjG}i&WHFgXxL*| zeuc+5G5v0c#H>a6pTkBF2v}uPzSJQ$Htl48GI&L7DL`Mah}1EHt3o8+d1#R*Xl*gf z^_HV_IseZnTnp-VZ&`u(5KoaT;sRhX#NIj51=qm$;d*~+6AKFo3tTdYDN(J={ZZi_ zyg%<(x@~}kyg{2nOn3~yETM^IZN$*(Ola4q=dz}71ZfMIC|=-{*e71&fAS7@=rDO4 zCs15?53W%o0vBNxu2Ktg5=~4Vkt9SXrslxyK4e$~*qxatDTpMCTMJkbjB~yQsTpf- z!OhOjVXIM<4y)Z-vvPsUtwOZhY-J-t7EU4M7-Rx36KO60NX6Hr724hNF z53LKIkznJjZ#pIx9kO`$SuA$CN z3p1g30&7lLDX!5pMK3oR1)VbW1UaL+|YlFk9o zfvZq1brB%3g&x5AV219vs`$|KFeIMAtaF@=%68#uUmZzb(PZ;%;xzbsA&M?U43&HW znUiVXR25GHXNY0RS!0`hBar{H0n(7i(t!DjjS}JfcgC-LszF)q=G-?C$gn}jTM`NY zI6Ip*pN@D>`7hIv@Daqx7}VFIZsok^@w)Zl>RU3kwVUrkgxl?<^v((2dbKGCFC zWXcgBA^ZeZ*qViA)8Y!7#AePbG^iS@I=0Oz;!B#tlbeb>gYJf85CbJA{JBSv45~tm zN7Eehk%gbh+Jq0ZiPF;3Nd6a)bQAD^Op%WMPr%5*O&U*5`wsPu=0AayS9SCVOdblI z_%`7hHZxk!492)W|ECB3`L9t((VMTV(~I^`G*K3+5{g}6ncl}koF<#6~=}4*s#C`{f5Up zgR~DWRGK4H7@G^k6@{B!$aqMC&`&r@7s zchCPAv4U1$+wH5A;0ENluAm%ywaQz*39L~fk%}?Z@6?wcL5%fc$E}y(MgC)mW4&P} zA`kaOIhtK2`Wd9yJ)NoxVFYy8y|lSLv;qA21i8SCM*X1LsMnfraiyz}KCZT3B7nsAi++`4wm1GLF|tCh9E29{xT8agTxCg!R2TGPF6v4hoj* zM>}{b-GL{jADL>A2Wm!I90@AK&+0fj{EU*@4&Z(3fwvlRr|wfj0pE0l58^$p8QV literal 0 HcmV?d00001 diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action.php new file mode 100644 index 000000000000..5d72ac3d6475 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action.php @@ -0,0 +1,281 @@ +google.privacy.dlp.v2.Action + */ +class Action extends \Google\Protobuf\Internal\Message +{ + protected $action; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\Action\SaveFindings $save_findings + * Save resulting findings in a provided location. + * @type \Google\Cloud\Dlp\V2\Action\PublishToPubSub $pub_sub + * Publish a notification to a Pub/Sub topic. + * @type \Google\Cloud\Dlp\V2\Action\PublishSummaryToCscc $publish_summary_to_cscc + * Publish summary to Cloud Security Command Center (Alpha). + * @type \Google\Cloud\Dlp\V2\Action\PublishFindingsToCloudDataCatalog $publish_findings_to_cloud_data_catalog + * Publish findings to Cloud Datahub. + * @type \Google\Cloud\Dlp\V2\Action\Deidentify $deidentify + * Create a de-identified copy of the input data. + * @type \Google\Cloud\Dlp\V2\Action\JobNotificationEmails $job_notification_emails + * Sends an email when the job completes. The email goes to IAM project + * owners and technical [Essential + * Contacts](https://cloud.google.com/resource-manager/docs/managing-notification-contacts). + * @type \Google\Cloud\Dlp\V2\Action\PublishToStackdriver $publish_to_stackdriver + * Enable Stackdriver metric dlp.googleapis.com/finding_count. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Save resulting findings in a provided location. + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.SaveFindings save_findings = 1; + * @return \Google\Cloud\Dlp\V2\Action\SaveFindings|null + */ + public function getSaveFindings() + { + return $this->readOneof(1); + } + + public function hasSaveFindings() + { + return $this->hasOneof(1); + } + + /** + * Save resulting findings in a provided location. + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.SaveFindings save_findings = 1; + * @param \Google\Cloud\Dlp\V2\Action\SaveFindings $var + * @return $this + */ + public function setSaveFindings($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\SaveFindings::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Publish a notification to a Pub/Sub topic. + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishToPubSub pub_sub = 2; + * @return \Google\Cloud\Dlp\V2\Action\PublishToPubSub|null + */ + public function getPubSub() + { + return $this->readOneof(2); + } + + public function hasPubSub() + { + return $this->hasOneof(2); + } + + /** + * Publish a notification to a Pub/Sub topic. + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishToPubSub pub_sub = 2; + * @param \Google\Cloud\Dlp\V2\Action\PublishToPubSub $var + * @return $this + */ + public function setPubSub($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\PublishToPubSub::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Publish summary to Cloud Security Command Center (Alpha). + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishSummaryToCscc publish_summary_to_cscc = 3; + * @return \Google\Cloud\Dlp\V2\Action\PublishSummaryToCscc|null + */ + public function getPublishSummaryToCscc() + { + return $this->readOneof(3); + } + + public function hasPublishSummaryToCscc() + { + return $this->hasOneof(3); + } + + /** + * Publish summary to Cloud Security Command Center (Alpha). + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishSummaryToCscc publish_summary_to_cscc = 3; + * @param \Google\Cloud\Dlp\V2\Action\PublishSummaryToCscc $var + * @return $this + */ + public function setPublishSummaryToCscc($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\PublishSummaryToCscc::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Publish findings to Cloud Datahub. + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishFindingsToCloudDataCatalog publish_findings_to_cloud_data_catalog = 5; + * @return \Google\Cloud\Dlp\V2\Action\PublishFindingsToCloudDataCatalog|null + */ + public function getPublishFindingsToCloudDataCatalog() + { + return $this->readOneof(5); + } + + public function hasPublishFindingsToCloudDataCatalog() + { + return $this->hasOneof(5); + } + + /** + * Publish findings to Cloud Datahub. + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishFindingsToCloudDataCatalog publish_findings_to_cloud_data_catalog = 5; + * @param \Google\Cloud\Dlp\V2\Action\PublishFindingsToCloudDataCatalog $var + * @return $this + */ + public function setPublishFindingsToCloudDataCatalog($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\PublishFindingsToCloudDataCatalog::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * Create a de-identified copy of the input data. + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.Deidentify deidentify = 7; + * @return \Google\Cloud\Dlp\V2\Action\Deidentify|null + */ + public function getDeidentify() + { + return $this->readOneof(7); + } + + public function hasDeidentify() + { + return $this->hasOneof(7); + } + + /** + * Create a de-identified copy of the input data. + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.Deidentify deidentify = 7; + * @param \Google\Cloud\Dlp\V2\Action\Deidentify $var + * @return $this + */ + public function setDeidentify($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\Deidentify::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * Sends an email when the job completes. The email goes to IAM project + * owners and technical [Essential + * Contacts](https://cloud.google.com/resource-manager/docs/managing-notification-contacts). + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.JobNotificationEmails job_notification_emails = 8; + * @return \Google\Cloud\Dlp\V2\Action\JobNotificationEmails|null + */ + public function getJobNotificationEmails() + { + return $this->readOneof(8); + } + + public function hasJobNotificationEmails() + { + return $this->hasOneof(8); + } + + /** + * Sends an email when the job completes. The email goes to IAM project + * owners and technical [Essential + * Contacts](https://cloud.google.com/resource-manager/docs/managing-notification-contacts). + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.JobNotificationEmails job_notification_emails = 8; + * @param \Google\Cloud\Dlp\V2\Action\JobNotificationEmails $var + * @return $this + */ + public function setJobNotificationEmails($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\JobNotificationEmails::class); + $this->writeOneof(8, $var); + + return $this; + } + + /** + * Enable Stackdriver metric dlp.googleapis.com/finding_count. + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishToStackdriver publish_to_stackdriver = 9; + * @return \Google\Cloud\Dlp\V2\Action\PublishToStackdriver|null + */ + public function getPublishToStackdriver() + { + return $this->readOneof(9); + } + + public function hasPublishToStackdriver() + { + return $this->hasOneof(9); + } + + /** + * Enable Stackdriver metric dlp.googleapis.com/finding_count. + * + * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishToStackdriver publish_to_stackdriver = 9; + * @param \Google\Cloud\Dlp\V2\Action\PublishToStackdriver $var + * @return $this + */ + public function setPublishToStackdriver($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\PublishToStackdriver::class); + $this->writeOneof(9, $var); + + return $this; + } + + /** + * @return string + */ + public function getAction() + { + return $this->whichOneof("action"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/Deidentify.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/Deidentify.php new file mode 100644 index 000000000000..81e49cd4f2d5 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/Deidentify.php @@ -0,0 +1,277 @@ +google.privacy.dlp.v2.Action.Deidentify + */ +class Deidentify extends \Google\Protobuf\Internal\Message +{ + /** + * User specified deidentify templates and configs for structured, + * unstructured, and image files. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationConfig transformation_config = 7; + */ + protected $transformation_config = null; + /** + * Config for storing transformation details. This is separate from the + * de-identified content, and contains metadata about the successful + * transformations and/or failures that occurred while de-identifying. This + * needs to be set in order for users to access information about the status + * of each transformation (see + * [TransformationDetails][google.privacy.dlp.v2.TransformationDetails] + * message for more information about what is noted). + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationDetailsStorageConfig transformation_details_storage_config = 3; + */ + protected $transformation_details_storage_config = null; + /** + * List of user-specified file type groups to transform. If specified, only + * the files with these filetypes will be transformed. If empty, all + * supported files will be transformed. Supported types may be automatically + * added over time. If a file type is set in this field that isn't supported + * by the Deidentify action then the job will fail and will not be + * successfully created/started. Currently the only filetypes supported are: + * IMAGES, TEXT_FILES, CSV, TSV. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FileType file_types_to_transform = 8; + */ + private $file_types_to_transform; + protected $output; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\TransformationConfig $transformation_config + * User specified deidentify templates and configs for structured, + * unstructured, and image files. + * @type \Google\Cloud\Dlp\V2\TransformationDetailsStorageConfig $transformation_details_storage_config + * Config for storing transformation details. This is separate from the + * de-identified content, and contains metadata about the successful + * transformations and/or failures that occurred while de-identifying. This + * needs to be set in order for users to access information about the status + * of each transformation (see + * [TransformationDetails][google.privacy.dlp.v2.TransformationDetails] + * message for more information about what is noted). + * @type string $cloud_storage_output + * Required. User settable Cloud Storage bucket and folders to store + * de-identified files. This field must be set for cloud storage + * deidentification. The output Cloud Storage bucket must be different + * from the input bucket. De-identified files will overwrite files in the + * output path. + * Form of: gs://bucket/folder/ or gs://bucket + * @type array|\Google\Protobuf\Internal\RepeatedField $file_types_to_transform + * List of user-specified file type groups to transform. If specified, only + * the files with these filetypes will be transformed. If empty, all + * supported files will be transformed. Supported types may be automatically + * added over time. If a file type is set in this field that isn't supported + * by the Deidentify action then the job will fail and will not be + * successfully created/started. Currently the only filetypes supported are: + * IMAGES, TEXT_FILES, CSV, TSV. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * User specified deidentify templates and configs for structured, + * unstructured, and image files. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationConfig transformation_config = 7; + * @return \Google\Cloud\Dlp\V2\TransformationConfig|null + */ + public function getTransformationConfig() + { + return $this->transformation_config; + } + + public function hasTransformationConfig() + { + return isset($this->transformation_config); + } + + public function clearTransformationConfig() + { + unset($this->transformation_config); + } + + /** + * User specified deidentify templates and configs for structured, + * unstructured, and image files. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationConfig transformation_config = 7; + * @param \Google\Cloud\Dlp\V2\TransformationConfig $var + * @return $this + */ + public function setTransformationConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationConfig::class); + $this->transformation_config = $var; + + return $this; + } + + /** + * Config for storing transformation details. This is separate from the + * de-identified content, and contains metadata about the successful + * transformations and/or failures that occurred while de-identifying. This + * needs to be set in order for users to access information about the status + * of each transformation (see + * [TransformationDetails][google.privacy.dlp.v2.TransformationDetails] + * message for more information about what is noted). + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationDetailsStorageConfig transformation_details_storage_config = 3; + * @return \Google\Cloud\Dlp\V2\TransformationDetailsStorageConfig|null + */ + public function getTransformationDetailsStorageConfig() + { + return $this->transformation_details_storage_config; + } + + public function hasTransformationDetailsStorageConfig() + { + return isset($this->transformation_details_storage_config); + } + + public function clearTransformationDetailsStorageConfig() + { + unset($this->transformation_details_storage_config); + } + + /** + * Config for storing transformation details. This is separate from the + * de-identified content, and contains metadata about the successful + * transformations and/or failures that occurred while de-identifying. This + * needs to be set in order for users to access information about the status + * of each transformation (see + * [TransformationDetails][google.privacy.dlp.v2.TransformationDetails] + * message for more information about what is noted). + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationDetailsStorageConfig transformation_details_storage_config = 3; + * @param \Google\Cloud\Dlp\V2\TransformationDetailsStorageConfig $var + * @return $this + */ + public function setTransformationDetailsStorageConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationDetailsStorageConfig::class); + $this->transformation_details_storage_config = $var; + + return $this; + } + + /** + * Required. User settable Cloud Storage bucket and folders to store + * de-identified files. This field must be set for cloud storage + * deidentification. The output Cloud Storage bucket must be different + * from the input bucket. De-identified files will overwrite files in the + * output path. + * Form of: gs://bucket/folder/ or gs://bucket + * + * Generated from protobuf field string cloud_storage_output = 9 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getCloudStorageOutput() + { + return $this->readOneof(9); + } + + public function hasCloudStorageOutput() + { + return $this->hasOneof(9); + } + + /** + * Required. User settable Cloud Storage bucket and folders to store + * de-identified files. This field must be set for cloud storage + * deidentification. The output Cloud Storage bucket must be different + * from the input bucket. De-identified files will overwrite files in the + * output path. + * Form of: gs://bucket/folder/ or gs://bucket + * + * Generated from protobuf field string cloud_storage_output = 9 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setCloudStorageOutput($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(9, $var); + + return $this; + } + + /** + * List of user-specified file type groups to transform. If specified, only + * the files with these filetypes will be transformed. If empty, all + * supported files will be transformed. Supported types may be automatically + * added over time. If a file type is set in this field that isn't supported + * by the Deidentify action then the job will fail and will not be + * successfully created/started. Currently the only filetypes supported are: + * IMAGES, TEXT_FILES, CSV, TSV. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FileType file_types_to_transform = 8; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFileTypesToTransform() + { + return $this->file_types_to_transform; + } + + /** + * List of user-specified file type groups to transform. If specified, only + * the files with these filetypes will be transformed. If empty, all + * supported files will be transformed. Supported types may be automatically + * added over time. If a file type is set in this field that isn't supported + * by the Deidentify action then the job will fail and will not be + * successfully created/started. Currently the only filetypes supported are: + * IMAGES, TEXT_FILES, CSV, TSV. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FileType file_types_to_transform = 8; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFileTypesToTransform($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\FileType::class); + $this->file_types_to_transform = $arr; + + return $this; + } + + /** + * @return string + */ + public function getOutput() + { + return $this->whichOneof("output"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Deidentify::class, \Google\Cloud\Dlp\V2\Action_Deidentify::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/JobNotificationEmails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/JobNotificationEmails.php new file mode 100644 index 000000000000..24eddd43c8b5 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/JobNotificationEmails.php @@ -0,0 +1,38 @@ +google.privacy.dlp.v2.Action.JobNotificationEmails + */ +class JobNotificationEmails extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(JobNotificationEmails::class, \Google\Cloud\Dlp\V2\Action_JobNotificationEmails::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishFindingsToCloudDataCatalog.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishFindingsToCloudDataCatalog.php new file mode 100644 index 000000000000..0afab97bd631 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishFindingsToCloudDataCatalog.php @@ -0,0 +1,51 @@ +google.privacy.dlp.v2.Action.PublishFindingsToCloudDataCatalog + */ +class PublishFindingsToCloudDataCatalog extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PublishFindingsToCloudDataCatalog::class, \Google\Cloud\Dlp\V2\Action_PublishFindingsToCloudDataCatalog::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishSummaryToCscc.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishSummaryToCscc.php new file mode 100644 index 000000000000..56a2fa0844d2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishSummaryToCscc.php @@ -0,0 +1,43 @@ +google.privacy.dlp.v2.Action.PublishSummaryToCscc + */ +class PublishSummaryToCscc extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PublishSummaryToCscc::class, \Google\Cloud\Dlp\V2\Action_PublishSummaryToCscc::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToPubSub.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToPubSub.php new file mode 100644 index 000000000000..afad5e77ebae --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToPubSub.php @@ -0,0 +1,86 @@ +google.privacy.dlp.v2.Action.PublishToPubSub + */ +class PublishToPubSub extends \Google\Protobuf\Internal\Message +{ + /** + * Cloud Pub/Sub topic to send notifications to. The topic must have given + * publishing access rights to the DLP API service account executing + * the long running DlpJob sending the notifications. + * Format is projects/{project}/topics/{topic}. + * + * Generated from protobuf field string topic = 1; + */ + protected $topic = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $topic + * Cloud Pub/Sub topic to send notifications to. The topic must have given + * publishing access rights to the DLP API service account executing + * the long running DlpJob sending the notifications. + * Format is projects/{project}/topics/{topic}. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Cloud Pub/Sub topic to send notifications to. The topic must have given + * publishing access rights to the DLP API service account executing + * the long running DlpJob sending the notifications. + * Format is projects/{project}/topics/{topic}. + * + * Generated from protobuf field string topic = 1; + * @return string + */ + public function getTopic() + { + return $this->topic; + } + + /** + * Cloud Pub/Sub topic to send notifications to. The topic must have given + * publishing access rights to the DLP API service account executing + * the long running DlpJob sending the notifications. + * Format is projects/{project}/topics/{topic}. + * + * Generated from protobuf field string topic = 1; + * @param string $var + * @return $this + */ + public function setTopic($var) + { + GPBUtil::checkString($var, True); + $this->topic = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PublishToPubSub::class, \Google\Cloud\Dlp\V2\Action_PublishToPubSub::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToStackdriver.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToStackdriver.php new file mode 100644 index 000000000000..186382acf182 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToStackdriver.php @@ -0,0 +1,39 @@ +google.privacy.dlp.v2.Action.PublishToStackdriver + */ +class PublishToStackdriver extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PublishToStackdriver::class, \Google\Cloud\Dlp\V2\Action_PublishToStackdriver::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/SaveFindings.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/SaveFindings.php new file mode 100644 index 000000000000..1b0051e218d2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/SaveFindings.php @@ -0,0 +1,83 @@ +google.privacy.dlp.v2.Action.SaveFindings + */ +class SaveFindings extends \Google\Protobuf\Internal\Message +{ + /** + * Location to store findings outside of DLP. + * + * Generated from protobuf field .google.privacy.dlp.v2.OutputStorageConfig output_config = 1; + */ + protected $output_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\OutputStorageConfig $output_config + * Location to store findings outside of DLP. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Location to store findings outside of DLP. + * + * Generated from protobuf field .google.privacy.dlp.v2.OutputStorageConfig output_config = 1; + * @return \Google\Cloud\Dlp\V2\OutputStorageConfig|null + */ + public function getOutputConfig() + { + return $this->output_config; + } + + public function hasOutputConfig() + { + return isset($this->output_config); + } + + public function clearOutputConfig() + { + unset($this->output_config); + } + + /** + * Location to store findings outside of DLP. + * + * Generated from protobuf field .google.privacy.dlp.v2.OutputStorageConfig output_config = 1; + * @param \Google\Cloud\Dlp\V2\OutputStorageConfig $var + * @return $this + */ + public function setOutputConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\OutputStorageConfig::class); + $this->output_config = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SaveFindings::class, \Google\Cloud\Dlp\V2\Action_SaveFindings::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActionDetails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActionDetails.php new file mode 100644 index 000000000000..9830d068c860 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActionDetails.php @@ -0,0 +1,75 @@ +google.privacy.dlp.v2.ActionDetails + */ +class ActionDetails extends \Google\Protobuf\Internal\Message +{ + protected $details; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails $deidentify_details + * Outcome of a de-identification action. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Outcome of a de-identification action. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceDetails deidentify_details = 1; + * @return \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails|null + */ + public function getDeidentifyDetails() + { + return $this->readOneof(1); + } + + public function hasDeidentifyDetails() + { + return $this->hasOneof(1); + } + + /** + * Outcome of a de-identification action. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceDetails deidentify_details = 1; + * @param \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails $var + * @return $this + */ + public function setDeidentifyDetails($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getDetails() + { + return $this->whichOneof("details"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActivateJobTriggerRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActivateJobTriggerRequest.php new file mode 100644 index 000000000000..bd9291228bd1 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActivateJobTriggerRequest.php @@ -0,0 +1,71 @@ +google.privacy.dlp.v2.ActivateJobTriggerRequest + */ +class ActivateJobTriggerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the trigger to activate, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * 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 + * Required. Resource name of the trigger to activate, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the trigger to activate, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the trigger to activate, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AllOtherDatabaseResources.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AllOtherDatabaseResources.php new file mode 100644 index 000000000000..77c9979299d6 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AllOtherDatabaseResources.php @@ -0,0 +1,33 @@ +google.privacy.dlp.v2.AllOtherDatabaseResources + */ +class AllOtherDatabaseResources extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails.php new file mode 100644 index 000000000000..f61ea6917a50 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails.php @@ -0,0 +1,372 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails + */ +class AnalyzeDataSourceRiskDetails extends \Google\Protobuf\Internal\Message +{ + /** + * Privacy metric to compute. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric requested_privacy_metric = 1; + */ + protected $requested_privacy_metric = null; + /** + * Input dataset to compute metrics over. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable requested_source_table = 2; + */ + protected $requested_source_table = null; + /** + * The configuration used for this job. + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.RequestedRiskAnalysisOptions requested_options = 10; + */ + protected $requested_options = null; + protected $result; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\PrivacyMetric $requested_privacy_metric + * Privacy metric to compute. + * @type \Google\Cloud\Dlp\V2\BigQueryTable $requested_source_table + * Input dataset to compute metrics over. + * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\NumericalStatsResult $numerical_stats_result + * Numerical stats result + * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult $categorical_stats_result + * Categorical stats result + * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult $k_anonymity_result + * K-anonymity result + * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult $l_diversity_result + * L-divesity result + * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult $k_map_estimation_result + * K-map result + * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult $delta_presence_estimation_result + * Delta-presence result + * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\RequestedRiskAnalysisOptions $requested_options + * The configuration used for this job. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Privacy metric to compute. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric requested_privacy_metric = 1; + * @return \Google\Cloud\Dlp\V2\PrivacyMetric|null + */ + public function getRequestedPrivacyMetric() + { + return $this->requested_privacy_metric; + } + + public function hasRequestedPrivacyMetric() + { + return isset($this->requested_privacy_metric); + } + + public function clearRequestedPrivacyMetric() + { + unset($this->requested_privacy_metric); + } + + /** + * Privacy metric to compute. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric requested_privacy_metric = 1; + * @param \Google\Cloud\Dlp\V2\PrivacyMetric $var + * @return $this + */ + public function setRequestedPrivacyMetric($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric::class); + $this->requested_privacy_metric = $var; + + return $this; + } + + /** + * Input dataset to compute metrics over. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable requested_source_table = 2; + * @return \Google\Cloud\Dlp\V2\BigQueryTable|null + */ + public function getRequestedSourceTable() + { + return $this->requested_source_table; + } + + public function hasRequestedSourceTable() + { + return isset($this->requested_source_table); + } + + public function clearRequestedSourceTable() + { + unset($this->requested_source_table); + } + + /** + * Input dataset to compute metrics over. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable requested_source_table = 2; + * @param \Google\Cloud\Dlp\V2\BigQueryTable $var + * @return $this + */ + public function setRequestedSourceTable($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); + $this->requested_source_table = $var; + + return $this; + } + + /** + * Numerical stats result + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.NumericalStatsResult numerical_stats_result = 3; + * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\NumericalStatsResult|null + */ + public function getNumericalStatsResult() + { + return $this->readOneof(3); + } + + public function hasNumericalStatsResult() + { + return $this->hasOneof(3); + } + + /** + * Numerical stats result + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.NumericalStatsResult numerical_stats_result = 3; + * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\NumericalStatsResult $var + * @return $this + */ + public function setNumericalStatsResult($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\NumericalStatsResult::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Categorical stats result + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult categorical_stats_result = 4; + * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult|null + */ + public function getCategoricalStatsResult() + { + return $this->readOneof(4); + } + + public function hasCategoricalStatsResult() + { + return $this->hasOneof(4); + } + + /** + * Categorical stats result + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult categorical_stats_result = 4; + * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult $var + * @return $this + */ + public function setCategoricalStatsResult($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * K-anonymity result + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult k_anonymity_result = 5; + * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult|null + */ + public function getKAnonymityResult() + { + return $this->readOneof(5); + } + + public function hasKAnonymityResult() + { + return $this->hasOneof(5); + } + + /** + * K-anonymity result + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult k_anonymity_result = 5; + * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult $var + * @return $this + */ + public function setKAnonymityResult($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * L-divesity result + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult l_diversity_result = 6; + * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult|null + */ + public function getLDiversityResult() + { + return $this->readOneof(6); + } + + public function hasLDiversityResult() + { + return $this->hasOneof(6); + } + + /** + * L-divesity result + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult l_diversity_result = 6; + * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult $var + * @return $this + */ + public function setLDiversityResult($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * K-map result + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult k_map_estimation_result = 7; + * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult|null + */ + public function getKMapEstimationResult() + { + return $this->readOneof(7); + } + + public function hasKMapEstimationResult() + { + return $this->hasOneof(7); + } + + /** + * K-map result + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult k_map_estimation_result = 7; + * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult $var + * @return $this + */ + public function setKMapEstimationResult($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * Delta-presence result + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult delta_presence_estimation_result = 9; + * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult|null + */ + public function getDeltaPresenceEstimationResult() + { + return $this->readOneof(9); + } + + public function hasDeltaPresenceEstimationResult() + { + return $this->hasOneof(9); + } + + /** + * Delta-presence result + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult delta_presence_estimation_result = 9; + * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult $var + * @return $this + */ + public function setDeltaPresenceEstimationResult($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult::class); + $this->writeOneof(9, $var); + + return $this; + } + + /** + * The configuration used for this job. + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.RequestedRiskAnalysisOptions requested_options = 10; + * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\RequestedRiskAnalysisOptions|null + */ + public function getRequestedOptions() + { + return $this->requested_options; + } + + public function hasRequestedOptions() + { + return isset($this->requested_options); + } + + public function clearRequestedOptions() + { + unset($this->requested_options); + } + + /** + * The configuration used for this job. + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.RequestedRiskAnalysisOptions requested_options = 10; + * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\RequestedRiskAnalysisOptions $var + * @return $this + */ + public function setRequestedOptions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\RequestedRiskAnalysisOptions::class); + $this->requested_options = $var; + + return $this; + } + + /** + * @return string + */ + public function getResult() + { + return $this->whichOneof("result"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult.php new file mode 100644 index 000000000000..d052e08ae603 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult.php @@ -0,0 +1,70 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult + */ +class CategoricalStatsResult extends \Google\Protobuf\Internal\Message +{ + /** + * Histogram of value frequencies in the column. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; + */ + private $value_frequency_histogram_buckets; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult\CategoricalStatsHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $value_frequency_histogram_buckets + * Histogram of value frequencies in the column. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Histogram of value frequencies in the column. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getValueFrequencyHistogramBuckets() + { + return $this->value_frequency_histogram_buckets; + } + + /** + * Histogram of value frequencies in the column. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; + * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult\CategoricalStatsHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setValueFrequencyHistogramBuckets($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult\CategoricalStatsHistogramBucket::class); + $this->value_frequency_histogram_buckets = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(CategoricalStatsResult::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_CategoricalStatsResult::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult/CategoricalStatsHistogramBucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult/CategoricalStatsHistogramBucket.php new file mode 100644 index 000000000000..a815c81eb646 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult/CategoricalStatsHistogramBucket.php @@ -0,0 +1,210 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult.CategoricalStatsHistogramBucket + */ +class CategoricalStatsHistogramBucket extends \Google\Protobuf\Internal\Message +{ + /** + * Lower bound on the value frequency of the values in this bucket. + * + * Generated from protobuf field int64 value_frequency_lower_bound = 1; + */ + protected $value_frequency_lower_bound = 0; + /** + * Upper bound on the value frequency of the values in this bucket. + * + * Generated from protobuf field int64 value_frequency_upper_bound = 2; + */ + protected $value_frequency_upper_bound = 0; + /** + * Total number of values in this bucket. + * + * Generated from protobuf field int64 bucket_size = 3; + */ + protected $bucket_size = 0; + /** + * Sample of value frequencies in this bucket. The total number of + * values returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ValueFrequency bucket_values = 4; + */ + private $bucket_values; + /** + * Total number of distinct values in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 5; + */ + protected $bucket_value_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $value_frequency_lower_bound + * Lower bound on the value frequency of the values in this bucket. + * @type int|string $value_frequency_upper_bound + * Upper bound on the value frequency of the values in this bucket. + * @type int|string $bucket_size + * Total number of values in this bucket. + * @type array<\Google\Cloud\Dlp\V2\ValueFrequency>|\Google\Protobuf\Internal\RepeatedField $bucket_values + * Sample of value frequencies in this bucket. The total number of + * values returned per bucket is capped at 20. + * @type int|string $bucket_value_count + * Total number of distinct values in this bucket. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Lower bound on the value frequency of the values in this bucket. + * + * Generated from protobuf field int64 value_frequency_lower_bound = 1; + * @return int|string + */ + public function getValueFrequencyLowerBound() + { + return $this->value_frequency_lower_bound; + } + + /** + * Lower bound on the value frequency of the values in this bucket. + * + * Generated from protobuf field int64 value_frequency_lower_bound = 1; + * @param int|string $var + * @return $this + */ + public function setValueFrequencyLowerBound($var) + { + GPBUtil::checkInt64($var); + $this->value_frequency_lower_bound = $var; + + return $this; + } + + /** + * Upper bound on the value frequency of the values in this bucket. + * + * Generated from protobuf field int64 value_frequency_upper_bound = 2; + * @return int|string + */ + public function getValueFrequencyUpperBound() + { + return $this->value_frequency_upper_bound; + } + + /** + * Upper bound on the value frequency of the values in this bucket. + * + * Generated from protobuf field int64 value_frequency_upper_bound = 2; + * @param int|string $var + * @return $this + */ + public function setValueFrequencyUpperBound($var) + { + GPBUtil::checkInt64($var); + $this->value_frequency_upper_bound = $var; + + return $this; + } + + /** + * Total number of values in this bucket. + * + * Generated from protobuf field int64 bucket_size = 3; + * @return int|string + */ + public function getBucketSize() + { + return $this->bucket_size; + } + + /** + * Total number of values in this bucket. + * + * Generated from protobuf field int64 bucket_size = 3; + * @param int|string $var + * @return $this + */ + public function setBucketSize($var) + { + GPBUtil::checkInt64($var); + $this->bucket_size = $var; + + return $this; + } + + /** + * Sample of value frequencies in this bucket. The total number of + * values returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ValueFrequency bucket_values = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBucketValues() + { + return $this->bucket_values; + } + + /** + * Sample of value frequencies in this bucket. The total number of + * values returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ValueFrequency bucket_values = 4; + * @param array<\Google\Cloud\Dlp\V2\ValueFrequency>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBucketValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ValueFrequency::class); + $this->bucket_values = $arr; + + return $this; + } + + /** + * Total number of distinct values in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 5; + * @return int|string + */ + public function getBucketValueCount() + { + return $this->bucket_value_count; + } + + /** + * Total number of distinct values in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 5; + * @param int|string $var + * @return $this + */ + public function setBucketValueCount($var) + { + GPBUtil::checkInt64($var); + $this->bucket_value_count = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(CategoricalStatsHistogramBucket::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_CategoricalStatsResult_CategoricalStatsHistogramBucket::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult.php new file mode 100644 index 000000000000..4ac13f1966a8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult.php @@ -0,0 +1,99 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult + */ +class DeltaPresenceEstimationResult extends \Google\Protobuf\Internal\Message +{ + /** + * The intervals [min_probability, max_probability) do not overlap. If a + * value doesn't correspond to any such interval, the associated frequency + * is zero. For example, the following records: + * {min_probability: 0, max_probability: 0.1, frequency: 17} + * {min_probability: 0.2, max_probability: 0.3, frequency: 42} + * {min_probability: 0.3, max_probability: 0.4, frequency: 99} + * mean that there are no record with an estimated probability in [0.1, 0.2) + * nor larger or equal to 0.4. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationHistogramBucket delta_presence_estimation_histogram = 1; + */ + private $delta_presence_estimation_histogram; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult\DeltaPresenceEstimationHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $delta_presence_estimation_histogram + * The intervals [min_probability, max_probability) do not overlap. If a + * value doesn't correspond to any such interval, the associated frequency + * is zero. For example, the following records: + * {min_probability: 0, max_probability: 0.1, frequency: 17} + * {min_probability: 0.2, max_probability: 0.3, frequency: 42} + * {min_probability: 0.3, max_probability: 0.4, frequency: 99} + * mean that there are no record with an estimated probability in [0.1, 0.2) + * nor larger or equal to 0.4. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The intervals [min_probability, max_probability) do not overlap. If a + * value doesn't correspond to any such interval, the associated frequency + * is zero. For example, the following records: + * {min_probability: 0, max_probability: 0.1, frequency: 17} + * {min_probability: 0.2, max_probability: 0.3, frequency: 42} + * {min_probability: 0.3, max_probability: 0.4, frequency: 99} + * mean that there are no record with an estimated probability in [0.1, 0.2) + * nor larger or equal to 0.4. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationHistogramBucket delta_presence_estimation_histogram = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDeltaPresenceEstimationHistogram() + { + return $this->delta_presence_estimation_histogram; + } + + /** + * The intervals [min_probability, max_probability) do not overlap. If a + * value doesn't correspond to any such interval, the associated frequency + * is zero. For example, the following records: + * {min_probability: 0, max_probability: 0.1, frequency: 17} + * {min_probability: 0.2, max_probability: 0.3, frequency: 42} + * {min_probability: 0.3, max_probability: 0.4, frequency: 99} + * mean that there are no record with an estimated probability in [0.1, 0.2) + * nor larger or equal to 0.4. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationHistogramBucket delta_presence_estimation_histogram = 1; + * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult\DeltaPresenceEstimationHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDeltaPresenceEstimationHistogram($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult\DeltaPresenceEstimationHistogramBucket::class); + $this->delta_presence_estimation_histogram = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(DeltaPresenceEstimationResult::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_DeltaPresenceEstimationResult::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationHistogramBucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationHistogramBucket.php new file mode 100644 index 000000000000..2d50a7c114c1 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationHistogramBucket.php @@ -0,0 +1,218 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationHistogramBucket + */ +class DeltaPresenceEstimationHistogramBucket extends \Google\Protobuf\Internal\Message +{ + /** + * Between 0 and 1. + * + * Generated from protobuf field double min_probability = 1; + */ + protected $min_probability = 0.0; + /** + * Always greater than or equal to min_probability. + * + * Generated from protobuf field double max_probability = 2; + */ + protected $max_probability = 0.0; + /** + * Number of records within these probability bounds. + * + * Generated from protobuf field int64 bucket_size = 5; + */ + protected $bucket_size = 0; + /** + * Sample of quasi-identifier tuple values in this bucket. The total + * number of classes returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationQuasiIdValues bucket_values = 6; + */ + private $bucket_values; + /** + * Total number of distinct quasi-identifier tuple values in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 7; + */ + protected $bucket_value_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $min_probability + * Between 0 and 1. + * @type float $max_probability + * Always greater than or equal to min_probability. + * @type int|string $bucket_size + * Number of records within these probability bounds. + * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult\DeltaPresenceEstimationQuasiIdValues>|\Google\Protobuf\Internal\RepeatedField $bucket_values + * Sample of quasi-identifier tuple values in this bucket. The total + * number of classes returned per bucket is capped at 20. + * @type int|string $bucket_value_count + * Total number of distinct quasi-identifier tuple values in this bucket. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Between 0 and 1. + * + * Generated from protobuf field double min_probability = 1; + * @return float + */ + public function getMinProbability() + { + return $this->min_probability; + } + + /** + * Between 0 and 1. + * + * Generated from protobuf field double min_probability = 1; + * @param float $var + * @return $this + */ + public function setMinProbability($var) + { + GPBUtil::checkDouble($var); + $this->min_probability = $var; + + return $this; + } + + /** + * Always greater than or equal to min_probability. + * + * Generated from protobuf field double max_probability = 2; + * @return float + */ + public function getMaxProbability() + { + return $this->max_probability; + } + + /** + * Always greater than or equal to min_probability. + * + * Generated from protobuf field double max_probability = 2; + * @param float $var + * @return $this + */ + public function setMaxProbability($var) + { + GPBUtil::checkDouble($var); + $this->max_probability = $var; + + return $this; + } + + /** + * Number of records within these probability bounds. + * + * Generated from protobuf field int64 bucket_size = 5; + * @return int|string + */ + public function getBucketSize() + { + return $this->bucket_size; + } + + /** + * Number of records within these probability bounds. + * + * Generated from protobuf field int64 bucket_size = 5; + * @param int|string $var + * @return $this + */ + public function setBucketSize($var) + { + GPBUtil::checkInt64($var); + $this->bucket_size = $var; + + return $this; + } + + /** + * Sample of quasi-identifier tuple values in this bucket. The total + * number of classes returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationQuasiIdValues bucket_values = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBucketValues() + { + return $this->bucket_values; + } + + /** + * Sample of quasi-identifier tuple values in this bucket. The total + * number of classes returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationQuasiIdValues bucket_values = 6; + * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult\DeltaPresenceEstimationQuasiIdValues>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBucketValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult\DeltaPresenceEstimationQuasiIdValues::class); + $this->bucket_values = $arr; + + return $this; + } + + /** + * Total number of distinct quasi-identifier tuple values in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 7; + * @return int|string + */ + public function getBucketValueCount() + { + return $this->bucket_value_count; + } + + /** + * Total number of distinct quasi-identifier tuple values in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 7; + * @param int|string $var + * @return $this + */ + public function setBucketValueCount($var) + { + GPBUtil::checkInt64($var); + $this->bucket_value_count = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(DeltaPresenceEstimationHistogramBucket::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_DeltaPresenceEstimationResult_DeltaPresenceEstimationHistogramBucket::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationQuasiIdValues.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationQuasiIdValues.php new file mode 100644 index 000000000000..3af689322032 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationQuasiIdValues.php @@ -0,0 +1,132 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationQuasiIdValues + */ +class DeltaPresenceEstimationQuasiIdValues extends \Google\Protobuf\Internal\Message +{ + /** + * The quasi-identifier values. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; + */ + private $quasi_ids_values; + /** + * The estimated probability that a given individual sharing these + * quasi-identifier values is in the dataset. This value, typically + * called δ, is the ratio between the number of records in the dataset + * with these quasi-identifier values, and the total number of individuals + * (inside *and* outside the dataset) with these quasi-identifier values. + * For example, if there are 15 individuals in the dataset who share the + * same quasi-identifier values, and an estimated 100 people in the entire + * population with these values, then δ is 0.15. + * + * Generated from protobuf field double estimated_probability = 2; + */ + protected $estimated_probability = 0.0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $quasi_ids_values + * The quasi-identifier values. + * @type float $estimated_probability + * The estimated probability that a given individual sharing these + * quasi-identifier values is in the dataset. This value, typically + * called δ, is the ratio between the number of records in the dataset + * with these quasi-identifier values, and the total number of individuals + * (inside *and* outside the dataset) with these quasi-identifier values. + * For example, if there are 15 individuals in the dataset who share the + * same quasi-identifier values, and an estimated 100 people in the entire + * population with these values, then δ is 0.15. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The quasi-identifier values. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getQuasiIdsValues() + { + return $this->quasi_ids_values; + } + + /** + * The quasi-identifier values. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; + * @param array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setQuasiIdsValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Value::class); + $this->quasi_ids_values = $arr; + + return $this; + } + + /** + * The estimated probability that a given individual sharing these + * quasi-identifier values is in the dataset. This value, typically + * called δ, is the ratio between the number of records in the dataset + * with these quasi-identifier values, and the total number of individuals + * (inside *and* outside the dataset) with these quasi-identifier values. + * For example, if there are 15 individuals in the dataset who share the + * same quasi-identifier values, and an estimated 100 people in the entire + * population with these values, then δ is 0.15. + * + * Generated from protobuf field double estimated_probability = 2; + * @return float + */ + public function getEstimatedProbability() + { + return $this->estimated_probability; + } + + /** + * The estimated probability that a given individual sharing these + * quasi-identifier values is in the dataset. This value, typically + * called δ, is the ratio between the number of records in the dataset + * with these quasi-identifier values, and the total number of individuals + * (inside *and* outside the dataset) with these quasi-identifier values. + * For example, if there are 15 individuals in the dataset who share the + * same quasi-identifier values, and an estimated 100 people in the entire + * population with these values, then δ is 0.15. + * + * Generated from protobuf field double estimated_probability = 2; + * @param float $var + * @return $this + */ + public function setEstimatedProbability($var) + { + GPBUtil::checkDouble($var); + $this->estimated_probability = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(DeltaPresenceEstimationQuasiIdValues::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_DeltaPresenceEstimationResult_DeltaPresenceEstimationQuasiIdValues::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult.php new file mode 100644 index 000000000000..3bdc61e513dc --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult.php @@ -0,0 +1,70 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult + */ +class KAnonymityResult extends \Google\Protobuf\Internal\Message +{ + /** + * Histogram of k-anonymity equivalence classes. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; + */ + private $equivalence_class_histogram_buckets; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult\KAnonymityHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $equivalence_class_histogram_buckets + * Histogram of k-anonymity equivalence classes. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Histogram of k-anonymity equivalence classes. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getEquivalenceClassHistogramBuckets() + { + return $this->equivalence_class_histogram_buckets; + } + + /** + * Histogram of k-anonymity equivalence classes. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; + * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult\KAnonymityHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setEquivalenceClassHistogramBuckets($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult\KAnonymityHistogramBucket::class); + $this->equivalence_class_histogram_buckets = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(KAnonymityResult::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KAnonymityResult::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityEquivalenceClass.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityEquivalenceClass.php new file mode 100644 index 000000000000..fd97e7fb3704 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityEquivalenceClass.php @@ -0,0 +1,116 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityEquivalenceClass + */ +class KAnonymityEquivalenceClass extends \Google\Protobuf\Internal\Message +{ + /** + * Set of values defining the equivalence class. One value per + * quasi-identifier column in the original KAnonymity metric message. + * The order is always the same as the original request. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; + */ + private $quasi_ids_values; + /** + * Size of the equivalence class, for example number of rows with the + * above set of values. + * + * Generated from protobuf field int64 equivalence_class_size = 2; + */ + protected $equivalence_class_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $quasi_ids_values + * Set of values defining the equivalence class. One value per + * quasi-identifier column in the original KAnonymity metric message. + * The order is always the same as the original request. + * @type int|string $equivalence_class_size + * Size of the equivalence class, for example number of rows with the + * above set of values. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Set of values defining the equivalence class. One value per + * quasi-identifier column in the original KAnonymity metric message. + * The order is always the same as the original request. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getQuasiIdsValues() + { + return $this->quasi_ids_values; + } + + /** + * Set of values defining the equivalence class. One value per + * quasi-identifier column in the original KAnonymity metric message. + * The order is always the same as the original request. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; + * @param array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setQuasiIdsValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Value::class); + $this->quasi_ids_values = $arr; + + return $this; + } + + /** + * Size of the equivalence class, for example number of rows with the + * above set of values. + * + * Generated from protobuf field int64 equivalence_class_size = 2; + * @return int|string + */ + public function getEquivalenceClassSize() + { + return $this->equivalence_class_size; + } + + /** + * Size of the equivalence class, for example number of rows with the + * above set of values. + * + * Generated from protobuf field int64 equivalence_class_size = 2; + * @param int|string $var + * @return $this + */ + public function setEquivalenceClassSize($var) + { + GPBUtil::checkInt64($var); + $this->equivalence_class_size = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(KAnonymityEquivalenceClass::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KAnonymityResult_KAnonymityEquivalenceClass::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityHistogramBucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityHistogramBucket.php new file mode 100644 index 000000000000..3dce3345ac27 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityHistogramBucket.php @@ -0,0 +1,210 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityHistogramBucket + */ +class KAnonymityHistogramBucket extends \Google\Protobuf\Internal\Message +{ + /** + * Lower bound on the size of the equivalence classes in this bucket. + * + * Generated from protobuf field int64 equivalence_class_size_lower_bound = 1; + */ + protected $equivalence_class_size_lower_bound = 0; + /** + * Upper bound on the size of the equivalence classes in this bucket. + * + * Generated from protobuf field int64 equivalence_class_size_upper_bound = 2; + */ + protected $equivalence_class_size_upper_bound = 0; + /** + * Total number of equivalence classes in this bucket. + * + * Generated from protobuf field int64 bucket_size = 3; + */ + protected $bucket_size = 0; + /** + * Sample of equivalence classes in this bucket. The total number of + * classes returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; + */ + private $bucket_values; + /** + * Total number of distinct equivalence classes in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 5; + */ + protected $bucket_value_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $equivalence_class_size_lower_bound + * Lower bound on the size of the equivalence classes in this bucket. + * @type int|string $equivalence_class_size_upper_bound + * Upper bound on the size of the equivalence classes in this bucket. + * @type int|string $bucket_size + * Total number of equivalence classes in this bucket. + * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult\KAnonymityEquivalenceClass>|\Google\Protobuf\Internal\RepeatedField $bucket_values + * Sample of equivalence classes in this bucket. The total number of + * classes returned per bucket is capped at 20. + * @type int|string $bucket_value_count + * Total number of distinct equivalence classes in this bucket. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Lower bound on the size of the equivalence classes in this bucket. + * + * Generated from protobuf field int64 equivalence_class_size_lower_bound = 1; + * @return int|string + */ + public function getEquivalenceClassSizeLowerBound() + { + return $this->equivalence_class_size_lower_bound; + } + + /** + * Lower bound on the size of the equivalence classes in this bucket. + * + * Generated from protobuf field int64 equivalence_class_size_lower_bound = 1; + * @param int|string $var + * @return $this + */ + public function setEquivalenceClassSizeLowerBound($var) + { + GPBUtil::checkInt64($var); + $this->equivalence_class_size_lower_bound = $var; + + return $this; + } + + /** + * Upper bound on the size of the equivalence classes in this bucket. + * + * Generated from protobuf field int64 equivalence_class_size_upper_bound = 2; + * @return int|string + */ + public function getEquivalenceClassSizeUpperBound() + { + return $this->equivalence_class_size_upper_bound; + } + + /** + * Upper bound on the size of the equivalence classes in this bucket. + * + * Generated from protobuf field int64 equivalence_class_size_upper_bound = 2; + * @param int|string $var + * @return $this + */ + public function setEquivalenceClassSizeUpperBound($var) + { + GPBUtil::checkInt64($var); + $this->equivalence_class_size_upper_bound = $var; + + return $this; + } + + /** + * Total number of equivalence classes in this bucket. + * + * Generated from protobuf field int64 bucket_size = 3; + * @return int|string + */ + public function getBucketSize() + { + return $this->bucket_size; + } + + /** + * Total number of equivalence classes in this bucket. + * + * Generated from protobuf field int64 bucket_size = 3; + * @param int|string $var + * @return $this + */ + public function setBucketSize($var) + { + GPBUtil::checkInt64($var); + $this->bucket_size = $var; + + return $this; + } + + /** + * Sample of equivalence classes in this bucket. The total number of + * classes returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBucketValues() + { + return $this->bucket_values; + } + + /** + * Sample of equivalence classes in this bucket. The total number of + * classes returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; + * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult\KAnonymityEquivalenceClass>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBucketValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult\KAnonymityEquivalenceClass::class); + $this->bucket_values = $arr; + + return $this; + } + + /** + * Total number of distinct equivalence classes in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 5; + * @return int|string + */ + public function getBucketValueCount() + { + return $this->bucket_value_count; + } + + /** + * Total number of distinct equivalence classes in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 5; + * @param int|string $var + * @return $this + */ + public function setBucketValueCount($var) + { + GPBUtil::checkInt64($var); + $this->bucket_value_count = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(KAnonymityHistogramBucket::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KAnonymityResult_KAnonymityHistogramBucket::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult.php new file mode 100644 index 000000000000..a100b0ca2d17 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult.php @@ -0,0 +1,99 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult + */ +class KMapEstimationResult extends \Google\Protobuf\Internal\Message +{ + /** + * The intervals [min_anonymity, max_anonymity] do not overlap. If a value + * doesn't correspond to any such interval, the associated frequency is + * zero. For example, the following records: + * {min_anonymity: 1, max_anonymity: 1, frequency: 17} + * {min_anonymity: 2, max_anonymity: 3, frequency: 42} + * {min_anonymity: 5, max_anonymity: 10, frequency: 99} + * mean that there are no record with an estimated anonymity of 4, 5, or + * larger than 10. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationHistogramBucket k_map_estimation_histogram = 1; + */ + private $k_map_estimation_histogram; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult\KMapEstimationHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $k_map_estimation_histogram + * The intervals [min_anonymity, max_anonymity] do not overlap. If a value + * doesn't correspond to any such interval, the associated frequency is + * zero. For example, the following records: + * {min_anonymity: 1, max_anonymity: 1, frequency: 17} + * {min_anonymity: 2, max_anonymity: 3, frequency: 42} + * {min_anonymity: 5, max_anonymity: 10, frequency: 99} + * mean that there are no record with an estimated anonymity of 4, 5, or + * larger than 10. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The intervals [min_anonymity, max_anonymity] do not overlap. If a value + * doesn't correspond to any such interval, the associated frequency is + * zero. For example, the following records: + * {min_anonymity: 1, max_anonymity: 1, frequency: 17} + * {min_anonymity: 2, max_anonymity: 3, frequency: 42} + * {min_anonymity: 5, max_anonymity: 10, frequency: 99} + * mean that there are no record with an estimated anonymity of 4, 5, or + * larger than 10. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationHistogramBucket k_map_estimation_histogram = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getKMapEstimationHistogram() + { + return $this->k_map_estimation_histogram; + } + + /** + * The intervals [min_anonymity, max_anonymity] do not overlap. If a value + * doesn't correspond to any such interval, the associated frequency is + * zero. For example, the following records: + * {min_anonymity: 1, max_anonymity: 1, frequency: 17} + * {min_anonymity: 2, max_anonymity: 3, frequency: 42} + * {min_anonymity: 5, max_anonymity: 10, frequency: 99} + * mean that there are no record with an estimated anonymity of 4, 5, or + * larger than 10. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationHistogramBucket k_map_estimation_histogram = 1; + * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult\KMapEstimationHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setKMapEstimationHistogram($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult\KMapEstimationHistogramBucket::class); + $this->k_map_estimation_histogram = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(KMapEstimationResult::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KMapEstimationResult::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationHistogramBucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationHistogramBucket.php new file mode 100644 index 000000000000..1be3e59cf31b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationHistogramBucket.php @@ -0,0 +1,217 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationHistogramBucket + */ +class KMapEstimationHistogramBucket extends \Google\Protobuf\Internal\Message +{ + /** + * Always positive. + * + * Generated from protobuf field int64 min_anonymity = 1; + */ + protected $min_anonymity = 0; + /** + * Always greater than or equal to min_anonymity. + * + * Generated from protobuf field int64 max_anonymity = 2; + */ + protected $max_anonymity = 0; + /** + * Number of records within these anonymity bounds. + * + * Generated from protobuf field int64 bucket_size = 5; + */ + protected $bucket_size = 0; + /** + * Sample of quasi-identifier tuple values in this bucket. The total + * number of classes returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationQuasiIdValues bucket_values = 6; + */ + private $bucket_values; + /** + * Total number of distinct quasi-identifier tuple values in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 7; + */ + protected $bucket_value_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $min_anonymity + * Always positive. + * @type int|string $max_anonymity + * Always greater than or equal to min_anonymity. + * @type int|string $bucket_size + * Number of records within these anonymity bounds. + * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult\KMapEstimationQuasiIdValues>|\Google\Protobuf\Internal\RepeatedField $bucket_values + * Sample of quasi-identifier tuple values in this bucket. The total + * number of classes returned per bucket is capped at 20. + * @type int|string $bucket_value_count + * Total number of distinct quasi-identifier tuple values in this bucket. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Always positive. + * + * Generated from protobuf field int64 min_anonymity = 1; + * @return int|string + */ + public function getMinAnonymity() + { + return $this->min_anonymity; + } + + /** + * Always positive. + * + * Generated from protobuf field int64 min_anonymity = 1; + * @param int|string $var + * @return $this + */ + public function setMinAnonymity($var) + { + GPBUtil::checkInt64($var); + $this->min_anonymity = $var; + + return $this; + } + + /** + * Always greater than or equal to min_anonymity. + * + * Generated from protobuf field int64 max_anonymity = 2; + * @return int|string + */ + public function getMaxAnonymity() + { + return $this->max_anonymity; + } + + /** + * Always greater than or equal to min_anonymity. + * + * Generated from protobuf field int64 max_anonymity = 2; + * @param int|string $var + * @return $this + */ + public function setMaxAnonymity($var) + { + GPBUtil::checkInt64($var); + $this->max_anonymity = $var; + + return $this; + } + + /** + * Number of records within these anonymity bounds. + * + * Generated from protobuf field int64 bucket_size = 5; + * @return int|string + */ + public function getBucketSize() + { + return $this->bucket_size; + } + + /** + * Number of records within these anonymity bounds. + * + * Generated from protobuf field int64 bucket_size = 5; + * @param int|string $var + * @return $this + */ + public function setBucketSize($var) + { + GPBUtil::checkInt64($var); + $this->bucket_size = $var; + + return $this; + } + + /** + * Sample of quasi-identifier tuple values in this bucket. The total + * number of classes returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationQuasiIdValues bucket_values = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBucketValues() + { + return $this->bucket_values; + } + + /** + * Sample of quasi-identifier tuple values in this bucket. The total + * number of classes returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationQuasiIdValues bucket_values = 6; + * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult\KMapEstimationQuasiIdValues>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBucketValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult\KMapEstimationQuasiIdValues::class); + $this->bucket_values = $arr; + + return $this; + } + + /** + * Total number of distinct quasi-identifier tuple values in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 7; + * @return int|string + */ + public function getBucketValueCount() + { + return $this->bucket_value_count; + } + + /** + * Total number of distinct quasi-identifier tuple values in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 7; + * @param int|string $var + * @return $this + */ + public function setBucketValueCount($var) + { + GPBUtil::checkInt64($var); + $this->bucket_value_count = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(KMapEstimationHistogramBucket::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KMapEstimationResult_KMapEstimationHistogramBucket::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationQuasiIdValues.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationQuasiIdValues.php new file mode 100644 index 000000000000..abdb15fe761d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationQuasiIdValues.php @@ -0,0 +1,104 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationQuasiIdValues + */ +class KMapEstimationQuasiIdValues extends \Google\Protobuf\Internal\Message +{ + /** + * The quasi-identifier values. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; + */ + private $quasi_ids_values; + /** + * The estimated anonymity for these quasi-identifier values. + * + * Generated from protobuf field int64 estimated_anonymity = 2; + */ + protected $estimated_anonymity = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $quasi_ids_values + * The quasi-identifier values. + * @type int|string $estimated_anonymity + * The estimated anonymity for these quasi-identifier values. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The quasi-identifier values. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getQuasiIdsValues() + { + return $this->quasi_ids_values; + } + + /** + * The quasi-identifier values. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; + * @param array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setQuasiIdsValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Value::class); + $this->quasi_ids_values = $arr; + + return $this; + } + + /** + * The estimated anonymity for these quasi-identifier values. + * + * Generated from protobuf field int64 estimated_anonymity = 2; + * @return int|string + */ + public function getEstimatedAnonymity() + { + return $this->estimated_anonymity; + } + + /** + * The estimated anonymity for these quasi-identifier values. + * + * Generated from protobuf field int64 estimated_anonymity = 2; + * @param int|string $var + * @return $this + */ + public function setEstimatedAnonymity($var) + { + GPBUtil::checkInt64($var); + $this->estimated_anonymity = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(KMapEstimationQuasiIdValues::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KMapEstimationResult_KMapEstimationQuasiIdValues::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult.php new file mode 100644 index 000000000000..eb7cd5fd1392 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult.php @@ -0,0 +1,70 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult + */ +class LDiversityResult extends \Google\Protobuf\Internal\Message +{ + /** + * Histogram of l-diversity equivalence class sensitive value frequencies. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; + */ + private $sensitive_value_frequency_histogram_buckets; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult\LDiversityHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $sensitive_value_frequency_histogram_buckets + * Histogram of l-diversity equivalence class sensitive value frequencies. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Histogram of l-diversity equivalence class sensitive value frequencies. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSensitiveValueFrequencyHistogramBuckets() + { + return $this->sensitive_value_frequency_histogram_buckets; + } + + /** + * Histogram of l-diversity equivalence class sensitive value frequencies. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; + * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult\LDiversityHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSensitiveValueFrequencyHistogramBuckets($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult\LDiversityHistogramBucket::class); + $this->sensitive_value_frequency_histogram_buckets = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(LDiversityResult::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_LDiversityResult::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityEquivalenceClass.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityEquivalenceClass.php new file mode 100644 index 000000000000..7b8f0fcf1822 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityEquivalenceClass.php @@ -0,0 +1,176 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityEquivalenceClass + */ +class LDiversityEquivalenceClass extends \Google\Protobuf\Internal\Message +{ + /** + * Quasi-identifier values defining the k-anonymity equivalence + * class. The order is always the same as the original request. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; + */ + private $quasi_ids_values; + /** + * Size of the k-anonymity equivalence class. + * + * Generated from protobuf field int64 equivalence_class_size = 2; + */ + protected $equivalence_class_size = 0; + /** + * Number of distinct sensitive values in this equivalence class. + * + * Generated from protobuf field int64 num_distinct_sensitive_values = 3; + */ + protected $num_distinct_sensitive_values = 0; + /** + * Estimated frequencies of top sensitive values. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ValueFrequency top_sensitive_values = 4; + */ + private $top_sensitive_values; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $quasi_ids_values + * Quasi-identifier values defining the k-anonymity equivalence + * class. The order is always the same as the original request. + * @type int|string $equivalence_class_size + * Size of the k-anonymity equivalence class. + * @type int|string $num_distinct_sensitive_values + * Number of distinct sensitive values in this equivalence class. + * @type array<\Google\Cloud\Dlp\V2\ValueFrequency>|\Google\Protobuf\Internal\RepeatedField $top_sensitive_values + * Estimated frequencies of top sensitive values. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Quasi-identifier values defining the k-anonymity equivalence + * class. The order is always the same as the original request. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getQuasiIdsValues() + { + return $this->quasi_ids_values; + } + + /** + * Quasi-identifier values defining the k-anonymity equivalence + * class. The order is always the same as the original request. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; + * @param array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setQuasiIdsValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Value::class); + $this->quasi_ids_values = $arr; + + return $this; + } + + /** + * Size of the k-anonymity equivalence class. + * + * Generated from protobuf field int64 equivalence_class_size = 2; + * @return int|string + */ + public function getEquivalenceClassSize() + { + return $this->equivalence_class_size; + } + + /** + * Size of the k-anonymity equivalence class. + * + * Generated from protobuf field int64 equivalence_class_size = 2; + * @param int|string $var + * @return $this + */ + public function setEquivalenceClassSize($var) + { + GPBUtil::checkInt64($var); + $this->equivalence_class_size = $var; + + return $this; + } + + /** + * Number of distinct sensitive values in this equivalence class. + * + * Generated from protobuf field int64 num_distinct_sensitive_values = 3; + * @return int|string + */ + public function getNumDistinctSensitiveValues() + { + return $this->num_distinct_sensitive_values; + } + + /** + * Number of distinct sensitive values in this equivalence class. + * + * Generated from protobuf field int64 num_distinct_sensitive_values = 3; + * @param int|string $var + * @return $this + */ + public function setNumDistinctSensitiveValues($var) + { + GPBUtil::checkInt64($var); + $this->num_distinct_sensitive_values = $var; + + return $this; + } + + /** + * Estimated frequencies of top sensitive values. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ValueFrequency top_sensitive_values = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTopSensitiveValues() + { + return $this->top_sensitive_values; + } + + /** + * Estimated frequencies of top sensitive values. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ValueFrequency top_sensitive_values = 4; + * @param array<\Google\Cloud\Dlp\V2\ValueFrequency>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTopSensitiveValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ValueFrequency::class); + $this->top_sensitive_values = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(LDiversityEquivalenceClass::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_LDiversityResult_LDiversityEquivalenceClass::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityHistogramBucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityHistogramBucket.php new file mode 100644 index 000000000000..6c7082628ea1 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityHistogramBucket.php @@ -0,0 +1,218 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityHistogramBucket + */ +class LDiversityHistogramBucket extends \Google\Protobuf\Internal\Message +{ + /** + * Lower bound on the sensitive value frequencies of the equivalence + * classes in this bucket. + * + * Generated from protobuf field int64 sensitive_value_frequency_lower_bound = 1; + */ + protected $sensitive_value_frequency_lower_bound = 0; + /** + * Upper bound on the sensitive value frequencies of the equivalence + * classes in this bucket. + * + * Generated from protobuf field int64 sensitive_value_frequency_upper_bound = 2; + */ + protected $sensitive_value_frequency_upper_bound = 0; + /** + * Total number of equivalence classes in this bucket. + * + * Generated from protobuf field int64 bucket_size = 3; + */ + protected $bucket_size = 0; + /** + * Sample of equivalence classes in this bucket. The total number of + * classes returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; + */ + private $bucket_values; + /** + * Total number of distinct equivalence classes in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 5; + */ + protected $bucket_value_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $sensitive_value_frequency_lower_bound + * Lower bound on the sensitive value frequencies of the equivalence + * classes in this bucket. + * @type int|string $sensitive_value_frequency_upper_bound + * Upper bound on the sensitive value frequencies of the equivalence + * classes in this bucket. + * @type int|string $bucket_size + * Total number of equivalence classes in this bucket. + * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult\LDiversityEquivalenceClass>|\Google\Protobuf\Internal\RepeatedField $bucket_values + * Sample of equivalence classes in this bucket. The total number of + * classes returned per bucket is capped at 20. + * @type int|string $bucket_value_count + * Total number of distinct equivalence classes in this bucket. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Lower bound on the sensitive value frequencies of the equivalence + * classes in this bucket. + * + * Generated from protobuf field int64 sensitive_value_frequency_lower_bound = 1; + * @return int|string + */ + public function getSensitiveValueFrequencyLowerBound() + { + return $this->sensitive_value_frequency_lower_bound; + } + + /** + * Lower bound on the sensitive value frequencies of the equivalence + * classes in this bucket. + * + * Generated from protobuf field int64 sensitive_value_frequency_lower_bound = 1; + * @param int|string $var + * @return $this + */ + public function setSensitiveValueFrequencyLowerBound($var) + { + GPBUtil::checkInt64($var); + $this->sensitive_value_frequency_lower_bound = $var; + + return $this; + } + + /** + * Upper bound on the sensitive value frequencies of the equivalence + * classes in this bucket. + * + * Generated from protobuf field int64 sensitive_value_frequency_upper_bound = 2; + * @return int|string + */ + public function getSensitiveValueFrequencyUpperBound() + { + return $this->sensitive_value_frequency_upper_bound; + } + + /** + * Upper bound on the sensitive value frequencies of the equivalence + * classes in this bucket. + * + * Generated from protobuf field int64 sensitive_value_frequency_upper_bound = 2; + * @param int|string $var + * @return $this + */ + public function setSensitiveValueFrequencyUpperBound($var) + { + GPBUtil::checkInt64($var); + $this->sensitive_value_frequency_upper_bound = $var; + + return $this; + } + + /** + * Total number of equivalence classes in this bucket. + * + * Generated from protobuf field int64 bucket_size = 3; + * @return int|string + */ + public function getBucketSize() + { + return $this->bucket_size; + } + + /** + * Total number of equivalence classes in this bucket. + * + * Generated from protobuf field int64 bucket_size = 3; + * @param int|string $var + * @return $this + */ + public function setBucketSize($var) + { + GPBUtil::checkInt64($var); + $this->bucket_size = $var; + + return $this; + } + + /** + * Sample of equivalence classes in this bucket. The total number of + * classes returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBucketValues() + { + return $this->bucket_values; + } + + /** + * Sample of equivalence classes in this bucket. The total number of + * classes returned per bucket is capped at 20. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; + * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult\LDiversityEquivalenceClass>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBucketValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult\LDiversityEquivalenceClass::class); + $this->bucket_values = $arr; + + return $this; + } + + /** + * Total number of distinct equivalence classes in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 5; + * @return int|string + */ + public function getBucketValueCount() + { + return $this->bucket_value_count; + } + + /** + * Total number of distinct equivalence classes in this bucket. + * + * Generated from protobuf field int64 bucket_value_count = 5; + * @param int|string $var + * @return $this + */ + public function setBucketValueCount($var) + { + GPBUtil::checkInt64($var); + $this->bucket_value_count = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(LDiversityHistogramBucket::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_LDiversityResult_LDiversityHistogramBucket::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/NumericalStatsResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/NumericalStatsResult.php new file mode 100644 index 000000000000..46207acfa508 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/NumericalStatsResult.php @@ -0,0 +1,162 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.NumericalStatsResult + */ +class NumericalStatsResult extends \Google\Protobuf\Internal\Message +{ + /** + * Minimum value appearing in the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value min_value = 1; + */ + protected $min_value = null; + /** + * Maximum value appearing in the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value max_value = 2; + */ + protected $max_value = null; + /** + * List of 99 values that partition the set of field values into 100 equal + * sized buckets. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quantile_values = 4; + */ + private $quantile_values; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\Value $min_value + * Minimum value appearing in the column. + * @type \Google\Cloud\Dlp\V2\Value $max_value + * Maximum value appearing in the column. + * @type array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $quantile_values + * List of 99 values that partition the set of field values into 100 equal + * sized buckets. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Minimum value appearing in the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value min_value = 1; + * @return \Google\Cloud\Dlp\V2\Value|null + */ + public function getMinValue() + { + return $this->min_value; + } + + public function hasMinValue() + { + return isset($this->min_value); + } + + public function clearMinValue() + { + unset($this->min_value); + } + + /** + * Minimum value appearing in the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value min_value = 1; + * @param \Google\Cloud\Dlp\V2\Value $var + * @return $this + */ + public function setMinValue($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); + $this->min_value = $var; + + return $this; + } + + /** + * Maximum value appearing in the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value max_value = 2; + * @return \Google\Cloud\Dlp\V2\Value|null + */ + public function getMaxValue() + { + return $this->max_value; + } + + public function hasMaxValue() + { + return isset($this->max_value); + } + + public function clearMaxValue() + { + unset($this->max_value); + } + + /** + * Maximum value appearing in the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value max_value = 2; + * @param \Google\Cloud\Dlp\V2\Value $var + * @return $this + */ + public function setMaxValue($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); + $this->max_value = $var; + + return $this; + } + + /** + * List of 99 values that partition the set of field values into 100 equal + * sized buckets. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quantile_values = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getQuantileValues() + { + return $this->quantile_values; + } + + /** + * List of 99 values that partition the set of field values into 100 equal + * sized buckets. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quantile_values = 4; + * @param array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setQuantileValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Value::class); + $this->quantile_values = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(NumericalStatsResult::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_NumericalStatsResult::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/RequestedRiskAnalysisOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/RequestedRiskAnalysisOptions.php new file mode 100644 index 000000000000..3bcb2274cf7f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/RequestedRiskAnalysisOptions.php @@ -0,0 +1,80 @@ +google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.RequestedRiskAnalysisOptions + */ +class RequestedRiskAnalysisOptions extends \Google\Protobuf\Internal\Message +{ + /** + * The job config for the risk job. + * + * Generated from protobuf field .google.privacy.dlp.v2.RiskAnalysisJobConfig job_config = 1; + */ + protected $job_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig $job_config + * The job config for the risk job. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The job config for the risk job. + * + * Generated from protobuf field .google.privacy.dlp.v2.RiskAnalysisJobConfig job_config = 1; + * @return \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig|null + */ + public function getJobConfig() + { + return $this->job_config; + } + + public function hasJobConfig() + { + return isset($this->job_config); + } + + public function clearJobConfig() + { + unset($this->job_config); + } + + /** + * The job config for the risk job. + * + * Generated from protobuf field .google.privacy.dlp.v2.RiskAnalysisJobConfig job_config = 1; + * @param \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig $var + * @return $this + */ + public function setJobConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig::class); + $this->job_config = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(RequestedRiskAnalysisOptions::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_RequestedRiskAnalysisOptions::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryDiscoveryTarget.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryDiscoveryTarget.php new file mode 100644 index 000000000000..6c568fa2188f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryDiscoveryTarget.php @@ -0,0 +1,210 @@ +google.privacy.dlp.v2.BigQueryDiscoveryTarget + */ +class BigQueryDiscoveryTarget extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The tables the discovery cadence applies to. The first target + * with a matching filter will be the one to apply to a table. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryFilter filter = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $filter = null; + /** + * In addition to matching the filter, these conditions must be true + * before a profile is generated. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryConditions conditions = 2; + */ + protected $conditions = null; + protected $frequency; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter $filter + * Required. The tables the discovery cadence applies to. The first target + * with a matching filter will be the one to apply to a table. + * @type \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions $conditions + * In addition to matching the filter, these conditions must be true + * before a profile is generated. + * @type \Google\Cloud\Dlp\V2\DiscoveryGenerationCadence $cadence + * How often and when to update profiles. New tables that match both the + * filter and conditions are scanned as quickly as possible depending on + * system capacity. + * @type \Google\Cloud\Dlp\V2\Disabled $disabled + * Tables that match this filter will not have profiles created. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. The tables the discovery cadence applies to. The first target + * with a matching filter will be the one to apply to a table. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryFilter filter = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter|null + */ + public function getFilter() + { + return $this->filter; + } + + public function hasFilter() + { + return isset($this->filter); + } + + public function clearFilter() + { + unset($this->filter); + } + + /** + * Required. The tables the discovery cadence applies to. The first target + * with a matching filter will be the one to apply to a table. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryFilter filter = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter::class); + $this->filter = $var; + + return $this; + } + + /** + * In addition to matching the filter, these conditions must be true + * before a profile is generated. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryConditions conditions = 2; + * @return \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions|null + */ + public function getConditions() + { + return $this->conditions; + } + + public function hasConditions() + { + return isset($this->conditions); + } + + public function clearConditions() + { + unset($this->conditions); + } + + /** + * In addition to matching the filter, these conditions must be true + * before a profile is generated. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryConditions conditions = 2; + * @param \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions $var + * @return $this + */ + public function setConditions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions::class); + $this->conditions = $var; + + return $this; + } + + /** + * How often and when to update profiles. New tables that match both the + * filter and conditions are scanned as quickly as possible depending on + * system capacity. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryGenerationCadence cadence = 3; + * @return \Google\Cloud\Dlp\V2\DiscoveryGenerationCadence|null + */ + public function getCadence() + { + return $this->readOneof(3); + } + + public function hasCadence() + { + return $this->hasOneof(3); + } + + /** + * How often and when to update profiles. New tables that match both the + * filter and conditions are scanned as quickly as possible depending on + * system capacity. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryGenerationCadence cadence = 3; + * @param \Google\Cloud\Dlp\V2\DiscoveryGenerationCadence $var + * @return $this + */ + public function setCadence($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryGenerationCadence::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Tables that match this filter will not have profiles created. + * + * Generated from protobuf field .google.privacy.dlp.v2.Disabled disabled = 4; + * @return \Google\Cloud\Dlp\V2\Disabled|null + */ + public function getDisabled() + { + return $this->readOneof(4); + } + + public function hasDisabled() + { + return $this->hasOneof(4); + } + + /** + * Tables that match this filter will not have profiles created. + * + * Generated from protobuf field .google.privacy.dlp.v2.Disabled disabled = 4; + * @param \Google\Cloud\Dlp\V2\Disabled $var + * @return $this + */ + public function setDisabled($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Disabled::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getFrequency() + { + return $this->whichOneof("frequency"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryField.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryField.php new file mode 100644 index 000000000000..ff205ef48b1f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryField.php @@ -0,0 +1,121 @@ +google.privacy.dlp.v2.BigQueryField + */ +class BigQueryField extends \Google\Protobuf\Internal\Message +{ + /** + * Source table of the field. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; + */ + protected $table = null; + /** + * Designated field in the BigQuery table. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 2; + */ + protected $field = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\BigQueryTable $table + * Source table of the field. + * @type \Google\Cloud\Dlp\V2\FieldId $field + * Designated field in the BigQuery table. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Source table of the field. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; + * @return \Google\Cloud\Dlp\V2\BigQueryTable|null + */ + public function getTable() + { + return $this->table; + } + + public function hasTable() + { + return isset($this->table); + } + + public function clearTable() + { + unset($this->table); + } + + /** + * Source table of the field. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; + * @param \Google\Cloud\Dlp\V2\BigQueryTable $var + * @return $this + */ + public function setTable($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); + $this->table = $var; + + return $this; + } + + /** + * Designated field in the BigQuery table. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 2; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getField() + { + return $this->field; + } + + public function hasField() + { + return isset($this->field); + } + + public function clearField() + { + unset($this->field); + } + + /** + * Designated field in the BigQuery table. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 2; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setField($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->field = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryKey.php new file mode 100644 index 000000000000..142e075dda01 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryKey.php @@ -0,0 +1,127 @@ +google.privacy.dlp.v2.BigQueryKey + */ +class BigQueryKey extends \Google\Protobuf\Internal\Message +{ + /** + * Complete BigQuery table reference. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table_reference = 1; + */ + protected $table_reference = null; + /** + * Row number inferred at the time the table was scanned. This value is + * nondeterministic, cannot be queried, and may be null for inspection + * jobs. To locate findings within a table, specify + * `inspect_job.storage_config.big_query_options.identifying_fields` in + * `CreateDlpJobRequest`. + * + * Generated from protobuf field int64 row_number = 2; + */ + protected $row_number = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\BigQueryTable $table_reference + * Complete BigQuery table reference. + * @type int|string $row_number + * Row number inferred at the time the table was scanned. This value is + * nondeterministic, cannot be queried, and may be null for inspection + * jobs. To locate findings within a table, specify + * `inspect_job.storage_config.big_query_options.identifying_fields` in + * `CreateDlpJobRequest`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Complete BigQuery table reference. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table_reference = 1; + * @return \Google\Cloud\Dlp\V2\BigQueryTable|null + */ + public function getTableReference() + { + return $this->table_reference; + } + + public function hasTableReference() + { + return isset($this->table_reference); + } + + public function clearTableReference() + { + unset($this->table_reference); + } + + /** + * Complete BigQuery table reference. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table_reference = 1; + * @param \Google\Cloud\Dlp\V2\BigQueryTable $var + * @return $this + */ + public function setTableReference($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); + $this->table_reference = $var; + + return $this; + } + + /** + * Row number inferred at the time the table was scanned. This value is + * nondeterministic, cannot be queried, and may be null for inspection + * jobs. To locate findings within a table, specify + * `inspect_job.storage_config.big_query_options.identifying_fields` in + * `CreateDlpJobRequest`. + * + * Generated from protobuf field int64 row_number = 2; + * @return int|string + */ + public function getRowNumber() + { + return $this->row_number; + } + + /** + * Row number inferred at the time the table was scanned. This value is + * nondeterministic, cannot be queried, and may be null for inspection + * jobs. To locate findings within a table, specify + * `inspect_job.storage_config.big_query_options.identifying_fields` in + * `CreateDlpJobRequest`. + * + * Generated from protobuf field int64 row_number = 2; + * @param int|string $var + * @return $this + */ + public function setRowNumber($var) + { + GPBUtil::checkInt64($var); + $this->row_number = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions.php new file mode 100644 index 000000000000..0886b43eaab5 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions.php @@ -0,0 +1,369 @@ +google.privacy.dlp.v2.BigQueryOptions + */ +class BigQueryOptions extends \Google\Protobuf\Internal\Message +{ + /** + * Complete BigQuery table reference. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table_reference = 1; + */ + protected $table_reference = null; + /** + * Table fields that may uniquely identify a row within the table. When + * `actions.saveFindings.outputConfig.table` is specified, the values of + * columns specified here are available in the output table under + * `location.content_locations.record_location.record_key.id_values`. Nested + * fields such as `person.birthdate.year` are allowed. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId identifying_fields = 2; + */ + private $identifying_fields; + /** + * Max number of rows to scan. If the table has more rows than this value, the + * rest of the rows are omitted. If not set, or if set to 0, all rows will be + * scanned. Only one of rows_limit and rows_limit_percent can be specified. + * Cannot be used in conjunction with TimespanConfig. + * + * Generated from protobuf field int64 rows_limit = 3; + */ + protected $rows_limit = 0; + /** + * Max percentage of rows to scan. The rest are omitted. The number of rows + * scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and + * 100 means no limit. Defaults to 0. Only one of rows_limit and + * rows_limit_percent can be specified. Cannot be used in conjunction with + * TimespanConfig. + * Caution: A [known + * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-sampling) + * is causing the `rowsLimitPercent` field to behave unexpectedly. We + * recommend using `rowsLimit` instead. + * + * Generated from protobuf field int32 rows_limit_percent = 6; + */ + protected $rows_limit_percent = 0; + /** + * How to sample the data. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryOptions.SampleMethod sample_method = 4; + */ + protected $sample_method = 0; + /** + * References to fields excluded from scanning. This allows you to skip + * inspection of entire columns which you know have no findings. + * When inspecting a table, we recommend that you inspect all columns. + * Otherwise, findings might be affected because hints from excluded columns + * will not be used. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId excluded_fields = 5; + */ + private $excluded_fields; + /** + * Limit scanning only to these fields. + * When inspecting a table, we recommend that you inspect all columns. + * Otherwise, findings might be affected because hints from excluded columns + * will not be used. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId included_fields = 7; + */ + private $included_fields; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\BigQueryTable $table_reference + * Complete BigQuery table reference. + * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $identifying_fields + * Table fields that may uniquely identify a row within the table. When + * `actions.saveFindings.outputConfig.table` is specified, the values of + * columns specified here are available in the output table under + * `location.content_locations.record_location.record_key.id_values`. Nested + * fields such as `person.birthdate.year` are allowed. + * @type int|string $rows_limit + * Max number of rows to scan. If the table has more rows than this value, the + * rest of the rows are omitted. If not set, or if set to 0, all rows will be + * scanned. Only one of rows_limit and rows_limit_percent can be specified. + * Cannot be used in conjunction with TimespanConfig. + * @type int $rows_limit_percent + * Max percentage of rows to scan. The rest are omitted. The number of rows + * scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and + * 100 means no limit. Defaults to 0. Only one of rows_limit and + * rows_limit_percent can be specified. Cannot be used in conjunction with + * TimespanConfig. + * Caution: A [known + * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-sampling) + * is causing the `rowsLimitPercent` field to behave unexpectedly. We + * recommend using `rowsLimit` instead. + * @type int $sample_method + * How to sample the data. + * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $excluded_fields + * References to fields excluded from scanning. This allows you to skip + * inspection of entire columns which you know have no findings. + * When inspecting a table, we recommend that you inspect all columns. + * Otherwise, findings might be affected because hints from excluded columns + * will not be used. + * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $included_fields + * Limit scanning only to these fields. + * When inspecting a table, we recommend that you inspect all columns. + * Otherwise, findings might be affected because hints from excluded columns + * will not be used. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Complete BigQuery table reference. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table_reference = 1; + * @return \Google\Cloud\Dlp\V2\BigQueryTable|null + */ + public function getTableReference() + { + return $this->table_reference; + } + + public function hasTableReference() + { + return isset($this->table_reference); + } + + public function clearTableReference() + { + unset($this->table_reference); + } + + /** + * Complete BigQuery table reference. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table_reference = 1; + * @param \Google\Cloud\Dlp\V2\BigQueryTable $var + * @return $this + */ + public function setTableReference($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); + $this->table_reference = $var; + + return $this; + } + + /** + * Table fields that may uniquely identify a row within the table. When + * `actions.saveFindings.outputConfig.table` is specified, the values of + * columns specified here are available in the output table under + * `location.content_locations.record_location.record_key.id_values`. Nested + * fields such as `person.birthdate.year` are allowed. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId identifying_fields = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getIdentifyingFields() + { + return $this->identifying_fields; + } + + /** + * Table fields that may uniquely identify a row within the table. When + * `actions.saveFindings.outputConfig.table` is specified, the values of + * columns specified here are available in the output table under + * `location.content_locations.record_location.record_key.id_values`. Nested + * fields such as `person.birthdate.year` are allowed. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId identifying_fields = 2; + * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setIdentifyingFields($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); + $this->identifying_fields = $arr; + + return $this; + } + + /** + * Max number of rows to scan. If the table has more rows than this value, the + * rest of the rows are omitted. If not set, or if set to 0, all rows will be + * scanned. Only one of rows_limit and rows_limit_percent can be specified. + * Cannot be used in conjunction with TimespanConfig. + * + * Generated from protobuf field int64 rows_limit = 3; + * @return int|string + */ + public function getRowsLimit() + { + return $this->rows_limit; + } + + /** + * Max number of rows to scan. If the table has more rows than this value, the + * rest of the rows are omitted. If not set, or if set to 0, all rows will be + * scanned. Only one of rows_limit and rows_limit_percent can be specified. + * Cannot be used in conjunction with TimespanConfig. + * + * Generated from protobuf field int64 rows_limit = 3; + * @param int|string $var + * @return $this + */ + public function setRowsLimit($var) + { + GPBUtil::checkInt64($var); + $this->rows_limit = $var; + + return $this; + } + + /** + * Max percentage of rows to scan. The rest are omitted. The number of rows + * scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and + * 100 means no limit. Defaults to 0. Only one of rows_limit and + * rows_limit_percent can be specified. Cannot be used in conjunction with + * TimespanConfig. + * Caution: A [known + * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-sampling) + * is causing the `rowsLimitPercent` field to behave unexpectedly. We + * recommend using `rowsLimit` instead. + * + * Generated from protobuf field int32 rows_limit_percent = 6; + * @return int + */ + public function getRowsLimitPercent() + { + return $this->rows_limit_percent; + } + + /** + * Max percentage of rows to scan. The rest are omitted. The number of rows + * scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and + * 100 means no limit. Defaults to 0. Only one of rows_limit and + * rows_limit_percent can be specified. Cannot be used in conjunction with + * TimespanConfig. + * Caution: A [known + * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-sampling) + * is causing the `rowsLimitPercent` field to behave unexpectedly. We + * recommend using `rowsLimit` instead. + * + * Generated from protobuf field int32 rows_limit_percent = 6; + * @param int $var + * @return $this + */ + public function setRowsLimitPercent($var) + { + GPBUtil::checkInt32($var); + $this->rows_limit_percent = $var; + + return $this; + } + + /** + * How to sample the data. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryOptions.SampleMethod sample_method = 4; + * @return int + */ + public function getSampleMethod() + { + return $this->sample_method; + } + + /** + * How to sample the data. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryOptions.SampleMethod sample_method = 4; + * @param int $var + * @return $this + */ + public function setSampleMethod($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\BigQueryOptions\SampleMethod::class); + $this->sample_method = $var; + + return $this; + } + + /** + * References to fields excluded from scanning. This allows you to skip + * inspection of entire columns which you know have no findings. + * When inspecting a table, we recommend that you inspect all columns. + * Otherwise, findings might be affected because hints from excluded columns + * will not be used. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId excluded_fields = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getExcludedFields() + { + return $this->excluded_fields; + } + + /** + * References to fields excluded from scanning. This allows you to skip + * inspection of entire columns which you know have no findings. + * When inspecting a table, we recommend that you inspect all columns. + * Otherwise, findings might be affected because hints from excluded columns + * will not be used. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId excluded_fields = 5; + * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setExcludedFields($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); + $this->excluded_fields = $arr; + + return $this; + } + + /** + * Limit scanning only to these fields. + * When inspecting a table, we recommend that you inspect all columns. + * Otherwise, findings might be affected because hints from excluded columns + * will not be used. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId included_fields = 7; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getIncludedFields() + { + return $this->included_fields; + } + + /** + * Limit scanning only to these fields. + * When inspecting a table, we recommend that you inspect all columns. + * Otherwise, findings might be affected because hints from excluded columns + * will not be used. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId included_fields = 7; + * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setIncludedFields($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); + $this->included_fields = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions/SampleMethod.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions/SampleMethod.php new file mode 100644 index 000000000000..a62e95948378 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions/SampleMethod.php @@ -0,0 +1,68 @@ +google.privacy.dlp.v2.BigQueryOptions.SampleMethod + */ +class SampleMethod +{ + /** + * No sampling. + * + * Generated from protobuf enum SAMPLE_METHOD_UNSPECIFIED = 0; + */ + const SAMPLE_METHOD_UNSPECIFIED = 0; + /** + * Scan groups of rows in the order BigQuery provides (default). Multiple + * groups of rows may be scanned in parallel, so results may not appear in + * the same order the rows are read. + * + * Generated from protobuf enum TOP = 1; + */ + const TOP = 1; + /** + * Randomly pick groups of rows to scan. + * + * Generated from protobuf enum RANDOM_START = 2; + */ + const RANDOM_START = 2; + + private static $valueToName = [ + self::SAMPLE_METHOD_UNSPECIFIED => 'SAMPLE_METHOD_UNSPECIFIED', + self::TOP => 'TOP', + self::RANDOM_START => 'RANDOM_START', + ]; + + 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(SampleMethod::class, \Google\Cloud\Dlp\V2\BigQueryOptions_SampleMethod::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegex.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegex.php new file mode 100644 index 000000000000..e0379d8b0e9a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegex.php @@ -0,0 +1,143 @@ +google.privacy.dlp.v2.BigQueryRegex + */ +class BigQueryRegex extends \Google\Protobuf\Internal\Message +{ + /** + * For organizations, if unset, will match all projects. Has no effect + * for data profile configurations created within a project. + * + * Generated from protobuf field string project_id_regex = 1; + */ + protected $project_id_regex = ''; + /** + * If unset, this property matches all datasets. + * + * Generated from protobuf field string dataset_id_regex = 2; + */ + protected $dataset_id_regex = ''; + /** + * If unset, this property matches all tables. + * + * Generated from protobuf field string table_id_regex = 3; + */ + protected $table_id_regex = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $project_id_regex + * For organizations, if unset, will match all projects. Has no effect + * for data profile configurations created within a project. + * @type string $dataset_id_regex + * If unset, this property matches all datasets. + * @type string $table_id_regex + * If unset, this property matches all tables. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * For organizations, if unset, will match all projects. Has no effect + * for data profile configurations created within a project. + * + * Generated from protobuf field string project_id_regex = 1; + * @return string + */ + public function getProjectIdRegex() + { + return $this->project_id_regex; + } + + /** + * For organizations, if unset, will match all projects. Has no effect + * for data profile configurations created within a project. + * + * Generated from protobuf field string project_id_regex = 1; + * @param string $var + * @return $this + */ + public function setProjectIdRegex($var) + { + GPBUtil::checkString($var, True); + $this->project_id_regex = $var; + + return $this; + } + + /** + * If unset, this property matches all datasets. + * + * Generated from protobuf field string dataset_id_regex = 2; + * @return string + */ + public function getDatasetIdRegex() + { + return $this->dataset_id_regex; + } + + /** + * If unset, this property matches all datasets. + * + * Generated from protobuf field string dataset_id_regex = 2; + * @param string $var + * @return $this + */ + public function setDatasetIdRegex($var) + { + GPBUtil::checkString($var, True); + $this->dataset_id_regex = $var; + + return $this; + } + + /** + * If unset, this property matches all tables. + * + * Generated from protobuf field string table_id_regex = 3; + * @return string + */ + public function getTableIdRegex() + { + return $this->table_id_regex; + } + + /** + * If unset, this property matches all tables. + * + * Generated from protobuf field string table_id_regex = 3; + * @param string $var + * @return $this + */ + public function setTableIdRegex($var) + { + GPBUtil::checkString($var, True); + $this->table_id_regex = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegexes.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegexes.php new file mode 100644 index 000000000000..ead1a639827f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegexes.php @@ -0,0 +1,72 @@ +google.privacy.dlp.v2.BigQueryRegexes + */ +class BigQueryRegexes extends \Google\Protobuf\Internal\Message +{ + /** + * A single BigQuery regular expression pattern to match against one or more + * tables, datasets, or projects that contain BigQuery tables. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryRegex patterns = 1; + */ + private $patterns; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\BigQueryRegex>|\Google\Protobuf\Internal\RepeatedField $patterns + * A single BigQuery regular expression pattern to match against one or more + * tables, datasets, or projects that contain BigQuery tables. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A single BigQuery regular expression pattern to match against one or more + * tables, datasets, or projects that contain BigQuery tables. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryRegex patterns = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPatterns() + { + return $this->patterns; + } + + /** + * A single BigQuery regular expression pattern to match against one or more + * tables, datasets, or projects that contain BigQuery tables. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryRegex patterns = 1; + * @param array<\Google\Cloud\Dlp\V2\BigQueryRegex>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPatterns($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\BigQueryRegex::class); + $this->patterns = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQuerySchemaModification.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQuerySchemaModification.php new file mode 100644 index 000000000000..331f232a4b09 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQuerySchemaModification.php @@ -0,0 +1,63 @@ +google.privacy.dlp.v2.BigQuerySchemaModification + */ +class BigQuerySchemaModification +{ + /** + * Unused + * + * Generated from protobuf enum SCHEMA_MODIFICATION_UNSPECIFIED = 0; + */ + const SCHEMA_MODIFICATION_UNSPECIFIED = 0; + /** + * Profiles should be regenerated when new columns are added to the table. + * Default. + * + * Generated from protobuf enum SCHEMA_NEW_COLUMNS = 1; + */ + const SCHEMA_NEW_COLUMNS = 1; + /** + * Profiles should be regenerated when columns are removed from the table. + * + * Generated from protobuf enum SCHEMA_REMOVED_COLUMNS = 2; + */ + const SCHEMA_REMOVED_COLUMNS = 2; + + private static $valueToName = [ + self::SCHEMA_MODIFICATION_UNSPECIFIED => 'SCHEMA_MODIFICATION_UNSPECIFIED', + self::SCHEMA_NEW_COLUMNS => 'SCHEMA_NEW_COLUMNS', + self::SCHEMA_REMOVED_COLUMNS => 'SCHEMA_REMOVED_COLUMNS', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTable.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTable.php new file mode 100644 index 000000000000..c3352043e7f5 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTable.php @@ -0,0 +1,143 @@ +:.` or + * `..`. + * + * Generated from protobuf message google.privacy.dlp.v2.BigQueryTable + */ +class BigQueryTable extends \Google\Protobuf\Internal\Message +{ + /** + * The Google Cloud Platform project ID of the project containing the table. + * If omitted, project ID is inferred from the API call. + * + * Generated from protobuf field string project_id = 1; + */ + protected $project_id = ''; + /** + * Dataset ID of the table. + * + * Generated from protobuf field string dataset_id = 2; + */ + protected $dataset_id = ''; + /** + * Name of the table. + * + * Generated from protobuf field string table_id = 3; + */ + protected $table_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $project_id + * The Google Cloud Platform project ID of the project containing the table. + * If omitted, project ID is inferred from the API call. + * @type string $dataset_id + * Dataset ID of the table. + * @type string $table_id + * Name of the table. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * The Google Cloud Platform project ID of the project containing the table. + * If omitted, project ID is inferred from the API call. + * + * Generated from protobuf field string project_id = 1; + * @return string + */ + public function getProjectId() + { + return $this->project_id; + } + + /** + * The Google Cloud Platform project ID of the project containing the table. + * If omitted, project ID is inferred from the API call. + * + * 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; + } + + /** + * Dataset ID of the table. + * + * Generated from protobuf field string dataset_id = 2; + * @return string + */ + public function getDatasetId() + { + return $this->dataset_id; + } + + /** + * Dataset ID of the table. + * + * Generated from protobuf field string dataset_id = 2; + * @param string $var + * @return $this + */ + public function setDatasetId($var) + { + GPBUtil::checkString($var, True); + $this->dataset_id = $var; + + return $this; + } + + /** + * Name of the table. + * + * Generated from protobuf field string table_id = 3; + * @return string + */ + public function getTableId() + { + return $this->table_id; + } + + /** + * Name of the table. + * + * Generated from protobuf field string table_id = 3; + * @param string $var + * @return $this + */ + public function setTableId($var) + { + GPBUtil::checkString($var, True); + $this->table_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableCollection.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableCollection.php new file mode 100644 index 000000000000..6c26ad1fcc08 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableCollection.php @@ -0,0 +1,75 @@ +google.privacy.dlp.v2.BigQueryTableCollection + */ +class BigQueryTableCollection extends \Google\Protobuf\Internal\Message +{ + protected $pattern; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\BigQueryRegexes $include_regexes + * A collection of regular expressions to match a BigQuery table against. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A collection of regular expressions to match a BigQuery table against. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryRegexes include_regexes = 1; + * @return \Google\Cloud\Dlp\V2\BigQueryRegexes|null + */ + public function getIncludeRegexes() + { + return $this->readOneof(1); + } + + public function hasIncludeRegexes() + { + return $this->hasOneof(1); + } + + /** + * A collection of regular expressions to match a BigQuery table against. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryRegexes include_regexes = 1; + * @param \Google\Cloud\Dlp\V2\BigQueryRegexes $var + * @return $this + */ + public function setIncludeRegexes($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryRegexes::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getPattern() + { + return $this->whichOneof("pattern"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableModification.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableModification.php new file mode 100644 index 000000000000..c2f8c68bd6b5 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableModification.php @@ -0,0 +1,56 @@ +google.privacy.dlp.v2.BigQueryTableModification + */ +class BigQueryTableModification +{ + /** + * Unused. + * + * Generated from protobuf enum TABLE_MODIFICATION_UNSPECIFIED = 0; + */ + const TABLE_MODIFICATION_UNSPECIFIED = 0; + /** + * A table will be considered modified when the last_modified_time from + * BigQuery has been updated. + * + * Generated from protobuf enum TABLE_MODIFIED_TIMESTAMP = 1; + */ + const TABLE_MODIFIED_TIMESTAMP = 1; + + private static $valueToName = [ + self::TABLE_MODIFICATION_UNSPECIFIED => 'TABLE_MODIFICATION_UNSPECIFIED', + self::TABLE_MODIFIED_TIMESTAMP => 'TABLE_MODIFIED_TIMESTAMP', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableType.php new file mode 100644 index 000000000000..476495f15848 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableType.php @@ -0,0 +1,62 @@ +google.privacy.dlp.v2.BigQueryTableType + */ +class BigQueryTableType +{ + /** + * Unused. + * + * Generated from protobuf enum BIG_QUERY_TABLE_TYPE_UNSPECIFIED = 0; + */ + const BIG_QUERY_TABLE_TYPE_UNSPECIFIED = 0; + /** + * A normal BigQuery table. + * + * Generated from protobuf enum BIG_QUERY_TABLE_TYPE_TABLE = 1; + */ + const BIG_QUERY_TABLE_TYPE_TABLE = 1; + /** + * A table that references data stored in Cloud Storage. + * + * Generated from protobuf enum BIG_QUERY_TABLE_TYPE_EXTERNAL_BIG_LAKE = 2; + */ + const BIG_QUERY_TABLE_TYPE_EXTERNAL_BIG_LAKE = 2; + + private static $valueToName = [ + self::BIG_QUERY_TABLE_TYPE_UNSPECIFIED => 'BIG_QUERY_TABLE_TYPE_UNSPECIFIED', + self::BIG_QUERY_TABLE_TYPE_TABLE => 'BIG_QUERY_TABLE_TYPE_TABLE', + self::BIG_QUERY_TABLE_TYPE_EXTERNAL_BIG_LAKE => 'BIG_QUERY_TABLE_TYPE_EXTERNAL_BIG_LAKE', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypeCollection.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypeCollection.php new file mode 100644 index 000000000000..b6e5441108ea --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypeCollection.php @@ -0,0 +1,68 @@ +google.privacy.dlp.v2.BigQueryTableTypeCollection + */ +class BigQueryTableTypeCollection +{ + /** + * Unused. + * + * Generated from protobuf enum BIG_QUERY_COLLECTION_UNSPECIFIED = 0; + */ + const BIG_QUERY_COLLECTION_UNSPECIFIED = 0; + /** + * Automatically generate profiles for all tables, even if the table type is + * not yet fully supported for analysis. Profiles for unsupported tables will + * be generated with errors to indicate their partial support. When full + * support is added, the tables will automatically be profiled during the next + * scheduled run. + * + * Generated from protobuf enum BIG_QUERY_COLLECTION_ALL_TYPES = 1; + */ + const BIG_QUERY_COLLECTION_ALL_TYPES = 1; + /** + * Only those types fully supported will be profiled. Will expand + * automatically as Cloud DLP adds support for new table types. Unsupported + * table types will not have partial profiles generated. + * + * Generated from protobuf enum BIG_QUERY_COLLECTION_ONLY_SUPPORTED_TYPES = 2; + */ + const BIG_QUERY_COLLECTION_ONLY_SUPPORTED_TYPES = 2; + + private static $valueToName = [ + self::BIG_QUERY_COLLECTION_UNSPECIFIED => 'BIG_QUERY_COLLECTION_UNSPECIFIED', + self::BIG_QUERY_COLLECTION_ALL_TYPES => 'BIG_QUERY_COLLECTION_ALL_TYPES', + self::BIG_QUERY_COLLECTION_ONLY_SUPPORTED_TYPES => 'BIG_QUERY_COLLECTION_ONLY_SUPPORTED_TYPES', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypes.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypes.php new file mode 100644 index 000000000000..3235dd3795d3 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypes.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.BigQueryTableTypes + */ +class BigQueryTableTypes extends \Google\Protobuf\Internal\Message +{ + /** + * A set of BigQuery table types. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryTableType types = 1; + */ + private $types; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $types + * A set of BigQuery table types. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A set of BigQuery table types. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryTableType types = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTypes() + { + return $this->types; + } + + /** + * A set of BigQuery table types. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryTableType types = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\BigQueryTableType::class); + $this->types = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BoundingBox.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BoundingBox.php new file mode 100644 index 000000000000..f0032c6eab48 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BoundingBox.php @@ -0,0 +1,169 @@ +google.privacy.dlp.v2.BoundingBox + */ +class BoundingBox extends \Google\Protobuf\Internal\Message +{ + /** + * Top coordinate of the bounding box. (0,0) is upper left. + * + * Generated from protobuf field int32 top = 1; + */ + protected $top = 0; + /** + * Left coordinate of the bounding box. (0,0) is upper left. + * + * Generated from protobuf field int32 left = 2; + */ + protected $left = 0; + /** + * Width of the bounding box in pixels. + * + * Generated from protobuf field int32 width = 3; + */ + protected $width = 0; + /** + * Height of the bounding box in pixels. + * + * Generated from protobuf field int32 height = 4; + */ + protected $height = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $top + * Top coordinate of the bounding box. (0,0) is upper left. + * @type int $left + * Left coordinate of the bounding box. (0,0) is upper left. + * @type int $width + * Width of the bounding box in pixels. + * @type int $height + * Height of the bounding box in pixels. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Top coordinate of the bounding box. (0,0) is upper left. + * + * Generated from protobuf field int32 top = 1; + * @return int + */ + public function getTop() + { + return $this->top; + } + + /** + * Top coordinate of the bounding box. (0,0) is upper left. + * + * Generated from protobuf field int32 top = 1; + * @param int $var + * @return $this + */ + public function setTop($var) + { + GPBUtil::checkInt32($var); + $this->top = $var; + + return $this; + } + + /** + * Left coordinate of the bounding box. (0,0) is upper left. + * + * Generated from protobuf field int32 left = 2; + * @return int + */ + public function getLeft() + { + return $this->left; + } + + /** + * Left coordinate of the bounding box. (0,0) is upper left. + * + * Generated from protobuf field int32 left = 2; + * @param int $var + * @return $this + */ + public function setLeft($var) + { + GPBUtil::checkInt32($var); + $this->left = $var; + + return $this; + } + + /** + * Width of the bounding box in pixels. + * + * Generated from protobuf field int32 width = 3; + * @return int + */ + public function getWidth() + { + return $this->width; + } + + /** + * Width of the bounding box in pixels. + * + * Generated from protobuf field int32 width = 3; + * @param int $var + * @return $this + */ + public function setWidth($var) + { + GPBUtil::checkInt32($var); + $this->width = $var; + + return $this; + } + + /** + * Height of the bounding box in pixels. + * + * Generated from protobuf field int32 height = 4; + * @return int + */ + public function getHeight() + { + return $this->height; + } + + /** + * Height of the bounding box in pixels. + * + * Generated from protobuf field int32 height = 4; + * @param int $var + * @return $this + */ + public function setHeight($var) + { + GPBUtil::checkInt32($var); + $this->height = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig.php new file mode 100644 index 000000000000..0fef73a3b6ba --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig.php @@ -0,0 +1,77 @@ + LOW 31-65 -> MEDIUM 66-100 -> HIGH + * This can be used on + * data of type: number, long, string, timestamp. + * If the bound `Value` type differs from the type of data being transformed, we + * will first attempt converting the type of the data to be transformed to match + * the type of the bound before comparing. + * See + * https://cloud.google.com/sensitive-data-protection/docs/concepts-bucketing to + * learn more. + * + * Generated from protobuf message google.privacy.dlp.v2.BucketingConfig + */ +class BucketingConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Set of buckets. Ranges must be non-overlapping. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BucketingConfig.Bucket buckets = 1; + */ + private $buckets; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\BucketingConfig\Bucket>|\Google\Protobuf\Internal\RepeatedField $buckets + * Set of buckets. Ranges must be non-overlapping. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Set of buckets. Ranges must be non-overlapping. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BucketingConfig.Bucket buckets = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBuckets() + { + return $this->buckets; + } + + /** + * Set of buckets. Ranges must be non-overlapping. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BucketingConfig.Bucket buckets = 1; + * @param array<\Google\Cloud\Dlp\V2\BucketingConfig\Bucket>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBuckets($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\BucketingConfig\Bucket::class); + $this->buckets = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig/Bucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig/Bucket.php new file mode 100644 index 000000000000..d70110e8ae4d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig/Bucket.php @@ -0,0 +1,172 @@ +google.privacy.dlp.v2.BucketingConfig.Bucket + */ +class Bucket extends \Google\Protobuf\Internal\Message +{ + /** + * Lower bound of the range, inclusive. Type should be the same as max if + * used. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value min = 1; + */ + protected $min = null; + /** + * Upper bound of the range, exclusive; type must match min. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value max = 2; + */ + protected $max = null; + /** + * Required. Replacement value for this bucket. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value replacement_value = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $replacement_value = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\Value $min + * Lower bound of the range, inclusive. Type should be the same as max if + * used. + * @type \Google\Cloud\Dlp\V2\Value $max + * Upper bound of the range, exclusive; type must match min. + * @type \Google\Cloud\Dlp\V2\Value $replacement_value + * Required. Replacement value for this bucket. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Lower bound of the range, inclusive. Type should be the same as max if + * used. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value min = 1; + * @return \Google\Cloud\Dlp\V2\Value|null + */ + public function getMin() + { + return $this->min; + } + + public function hasMin() + { + return isset($this->min); + } + + public function clearMin() + { + unset($this->min); + } + + /** + * Lower bound of the range, inclusive. Type should be the same as max if + * used. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value min = 1; + * @param \Google\Cloud\Dlp\V2\Value $var + * @return $this + */ + public function setMin($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); + $this->min = $var; + + return $this; + } + + /** + * Upper bound of the range, exclusive; type must match min. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value max = 2; + * @return \Google\Cloud\Dlp\V2\Value|null + */ + public function getMax() + { + return $this->max; + } + + public function hasMax() + { + return isset($this->max); + } + + public function clearMax() + { + unset($this->max); + } + + /** + * Upper bound of the range, exclusive; type must match min. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value max = 2; + * @param \Google\Cloud\Dlp\V2\Value $var + * @return $this + */ + public function setMax($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); + $this->max = $var; + + return $this; + } + + /** + * Required. Replacement value for this bucket. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value replacement_value = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\Value|null + */ + public function getReplacementValue() + { + return $this->replacement_value; + } + + public function hasReplacementValue() + { + return isset($this->replacement_value); + } + + public function clearReplacementValue() + { + unset($this->replacement_value); + } + + /** + * Required. Replacement value for this bucket. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value replacement_value = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\Value $var + * @return $this + */ + public function setReplacementValue($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); + $this->replacement_value = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Bucket::class, \Google\Cloud\Dlp\V2\BucketingConfig_Bucket::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem.php new file mode 100644 index 000000000000..afd0d936d3f5 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem.php @@ -0,0 +1,101 @@ +google.privacy.dlp.v2.ByteContentItem + */ +class ByteContentItem extends \Google\Protobuf\Internal\Message +{ + /** + * The type of data stored in the bytes string. Default will be TEXT_UTF8. + * + * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem.BytesType type = 1; + */ + protected $type = 0; + /** + * Content data to inspect or redact. + * + * Generated from protobuf field bytes data = 2; + */ + protected $data = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $type + * The type of data stored in the bytes string. Default will be TEXT_UTF8. + * @type string $data + * Content data to inspect or redact. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The type of data stored in the bytes string. Default will be TEXT_UTF8. + * + * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem.BytesType type = 1; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * The type of data stored in the bytes string. Default will be TEXT_UTF8. + * + * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem.BytesType type = 1; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\ByteContentItem\BytesType::class); + $this->type = $var; + + return $this; + } + + /** + * Content data to inspect or redact. + * + * Generated from protobuf field bytes data = 2; + * @return string + */ + public function getData() + { + return $this->data; + } + + /** + * Content data to inspect or redact. + * + * Generated from protobuf field bytes data = 2; + * @param string $var + * @return $this + */ + public function setData($var) + { + GPBUtil::checkString($var, False); + $this->data = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem/BytesType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem/BytesType.php new file mode 100644 index 000000000000..996665d6bd00 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem/BytesType.php @@ -0,0 +1,143 @@ +google.privacy.dlp.v2.ByteContentItem.BytesType + */ +class BytesType +{ + /** + * Unused + * + * Generated from protobuf enum BYTES_TYPE_UNSPECIFIED = 0; + */ + const BYTES_TYPE_UNSPECIFIED = 0; + /** + * Any image type. + * + * Generated from protobuf enum IMAGE = 6; + */ + const IMAGE = 6; + /** + * jpeg + * + * Generated from protobuf enum IMAGE_JPEG = 1; + */ + const IMAGE_JPEG = 1; + /** + * bmp + * + * Generated from protobuf enum IMAGE_BMP = 2; + */ + const IMAGE_BMP = 2; + /** + * png + * + * Generated from protobuf enum IMAGE_PNG = 3; + */ + const IMAGE_PNG = 3; + /** + * svg + * + * Generated from protobuf enum IMAGE_SVG = 4; + */ + const IMAGE_SVG = 4; + /** + * plain text + * + * Generated from protobuf enum TEXT_UTF8 = 5; + */ + const TEXT_UTF8 = 5; + /** + * docx, docm, dotx, dotm + * + * Generated from protobuf enum WORD_DOCUMENT = 7; + */ + const WORD_DOCUMENT = 7; + /** + * pdf + * + * Generated from protobuf enum PDF = 8; + */ + const PDF = 8; + /** + * pptx, pptm, potx, potm, pot + * + * Generated from protobuf enum POWERPOINT_DOCUMENT = 9; + */ + const POWERPOINT_DOCUMENT = 9; + /** + * xlsx, xlsm, xltx, xltm + * + * Generated from protobuf enum EXCEL_DOCUMENT = 10; + */ + const EXCEL_DOCUMENT = 10; + /** + * avro + * + * Generated from protobuf enum AVRO = 11; + */ + const AVRO = 11; + /** + * csv + * + * Generated from protobuf enum CSV = 12; + */ + const CSV = 12; + /** + * tsv + * + * Generated from protobuf enum TSV = 13; + */ + const TSV = 13; + + private static $valueToName = [ + self::BYTES_TYPE_UNSPECIFIED => 'BYTES_TYPE_UNSPECIFIED', + self::IMAGE => 'IMAGE', + self::IMAGE_JPEG => 'IMAGE_JPEG', + self::IMAGE_BMP => 'IMAGE_BMP', + self::IMAGE_PNG => 'IMAGE_PNG', + self::IMAGE_SVG => 'IMAGE_SVG', + self::TEXT_UTF8 => 'TEXT_UTF8', + self::WORD_DOCUMENT => 'WORD_DOCUMENT', + self::PDF => 'PDF', + self::POWERPOINT_DOCUMENT => 'POWERPOINT_DOCUMENT', + self::EXCEL_DOCUMENT => 'EXCEL_DOCUMENT', + self::AVRO => 'AVRO', + self::CSV => 'CSV', + self::TSV => 'TSV', + ]; + + 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(BytesType::class, \Google\Cloud\Dlp\V2\ByteContentItem_BytesType::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CancelDlpJobRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CancelDlpJobRequest.php new file mode 100644 index 000000000000..d9285b185051 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CancelDlpJobRequest.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.CancelDlpJobRequest + */ +class CancelDlpJobRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the DlpJob resource to be cancelled. + * + * 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 + * Required. The name of the DlpJob resource to be cancelled. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the DlpJob resource to be cancelled. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The name of the DlpJob resource to be cancelled. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharacterMaskConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharacterMaskConfig.php new file mode 100644 index 000000000000..82eaa69cab08 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharacterMaskConfig.php @@ -0,0 +1,266 @@ +google.privacy.dlp.v2.CharacterMaskConfig + */ +class CharacterMaskConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Character to use to mask the sensitive values—for example, `*` for an + * alphabetic string such as a name, or `0` for a numeric string such as ZIP + * code or credit card number. This string must have a length of 1. If not + * supplied, this value defaults to `*` for strings, and `0` for digits. + * + * Generated from protobuf field string masking_character = 1; + */ + protected $masking_character = ''; + /** + * Number of characters to mask. If not set, all matching chars will be + * masked. Skipped characters do not count towards this tally. + * If `number_to_mask` is negative, this denotes inverse masking. Cloud DLP + * masks all but a number of characters. + * For example, suppose you have the following values: + * - `masking_character` is `*` + * - `number_to_mask` is `-4` + * - `reverse_order` is `false` + * - `CharsToIgnore` includes `-` + * - Input string is `1234-5678-9012-3456` + * The resulting de-identified string is + * `****-****-****-3456`. Cloud DLP masks all but the last four characters. + * If `reverse_order` is `true`, all but the first four characters are masked + * as `1234-****-****-****`. + * + * Generated from protobuf field int32 number_to_mask = 2; + */ + protected $number_to_mask = 0; + /** + * Mask characters in reverse order. For example, if `masking_character` is + * `0`, `number_to_mask` is `14`, and `reverse_order` is `false`, then the + * input string `1234-5678-9012-3456` is masked as `00000000000000-3456`. + * If `masking_character` is `*`, `number_to_mask` is `3`, and `reverse_order` + * is `true`, then the string `12345` is masked as `12***`. + * + * Generated from protobuf field bool reverse_order = 3; + */ + protected $reverse_order = false; + /** + * When masking a string, items in this list will be skipped when replacing + * characters. For example, if the input string is `555-555-5555` and you + * instruct Cloud DLP to skip `-` and mask 5 characters with `*`, Cloud DLP + * returns `***-**5-5555`. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.CharsToIgnore characters_to_ignore = 4; + */ + private $characters_to_ignore; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $masking_character + * Character to use to mask the sensitive values—for example, `*` for an + * alphabetic string such as a name, or `0` for a numeric string such as ZIP + * code or credit card number. This string must have a length of 1. If not + * supplied, this value defaults to `*` for strings, and `0` for digits. + * @type int $number_to_mask + * Number of characters to mask. If not set, all matching chars will be + * masked. Skipped characters do not count towards this tally. + * If `number_to_mask` is negative, this denotes inverse masking. Cloud DLP + * masks all but a number of characters. + * For example, suppose you have the following values: + * - `masking_character` is `*` + * - `number_to_mask` is `-4` + * - `reverse_order` is `false` + * - `CharsToIgnore` includes `-` + * - Input string is `1234-5678-9012-3456` + * The resulting de-identified string is + * `****-****-****-3456`. Cloud DLP masks all but the last four characters. + * If `reverse_order` is `true`, all but the first four characters are masked + * as `1234-****-****-****`. + * @type bool $reverse_order + * Mask characters in reverse order. For example, if `masking_character` is + * `0`, `number_to_mask` is `14`, and `reverse_order` is `false`, then the + * input string `1234-5678-9012-3456` is masked as `00000000000000-3456`. + * If `masking_character` is `*`, `number_to_mask` is `3`, and `reverse_order` + * is `true`, then the string `12345` is masked as `12***`. + * @type array<\Google\Cloud\Dlp\V2\CharsToIgnore>|\Google\Protobuf\Internal\RepeatedField $characters_to_ignore + * When masking a string, items in this list will be skipped when replacing + * characters. For example, if the input string is `555-555-5555` and you + * instruct Cloud DLP to skip `-` and mask 5 characters with `*`, Cloud DLP + * returns `***-**5-5555`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Character to use to mask the sensitive values—for example, `*` for an + * alphabetic string such as a name, or `0` for a numeric string such as ZIP + * code or credit card number. This string must have a length of 1. If not + * supplied, this value defaults to `*` for strings, and `0` for digits. + * + * Generated from protobuf field string masking_character = 1; + * @return string + */ + public function getMaskingCharacter() + { + return $this->masking_character; + } + + /** + * Character to use to mask the sensitive values—for example, `*` for an + * alphabetic string such as a name, or `0` for a numeric string such as ZIP + * code or credit card number. This string must have a length of 1. If not + * supplied, this value defaults to `*` for strings, and `0` for digits. + * + * Generated from protobuf field string masking_character = 1; + * @param string $var + * @return $this + */ + public function setMaskingCharacter($var) + { + GPBUtil::checkString($var, True); + $this->masking_character = $var; + + return $this; + } + + /** + * Number of characters to mask. If not set, all matching chars will be + * masked. Skipped characters do not count towards this tally. + * If `number_to_mask` is negative, this denotes inverse masking. Cloud DLP + * masks all but a number of characters. + * For example, suppose you have the following values: + * - `masking_character` is `*` + * - `number_to_mask` is `-4` + * - `reverse_order` is `false` + * - `CharsToIgnore` includes `-` + * - Input string is `1234-5678-9012-3456` + * The resulting de-identified string is + * `****-****-****-3456`. Cloud DLP masks all but the last four characters. + * If `reverse_order` is `true`, all but the first four characters are masked + * as `1234-****-****-****`. + * + * Generated from protobuf field int32 number_to_mask = 2; + * @return int + */ + public function getNumberToMask() + { + return $this->number_to_mask; + } + + /** + * Number of characters to mask. If not set, all matching chars will be + * masked. Skipped characters do not count towards this tally. + * If `number_to_mask` is negative, this denotes inverse masking. Cloud DLP + * masks all but a number of characters. + * For example, suppose you have the following values: + * - `masking_character` is `*` + * - `number_to_mask` is `-4` + * - `reverse_order` is `false` + * - `CharsToIgnore` includes `-` + * - Input string is `1234-5678-9012-3456` + * The resulting de-identified string is + * `****-****-****-3456`. Cloud DLP masks all but the last four characters. + * If `reverse_order` is `true`, all but the first four characters are masked + * as `1234-****-****-****`. + * + * Generated from protobuf field int32 number_to_mask = 2; + * @param int $var + * @return $this + */ + public function setNumberToMask($var) + { + GPBUtil::checkInt32($var); + $this->number_to_mask = $var; + + return $this; + } + + /** + * Mask characters in reverse order. For example, if `masking_character` is + * `0`, `number_to_mask` is `14`, and `reverse_order` is `false`, then the + * input string `1234-5678-9012-3456` is masked as `00000000000000-3456`. + * If `masking_character` is `*`, `number_to_mask` is `3`, and `reverse_order` + * is `true`, then the string `12345` is masked as `12***`. + * + * Generated from protobuf field bool reverse_order = 3; + * @return bool + */ + public function getReverseOrder() + { + return $this->reverse_order; + } + + /** + * Mask characters in reverse order. For example, if `masking_character` is + * `0`, `number_to_mask` is `14`, and `reverse_order` is `false`, then the + * input string `1234-5678-9012-3456` is masked as `00000000000000-3456`. + * If `masking_character` is `*`, `number_to_mask` is `3`, and `reverse_order` + * is `true`, then the string `12345` is masked as `12***`. + * + * Generated from protobuf field bool reverse_order = 3; + * @param bool $var + * @return $this + */ + public function setReverseOrder($var) + { + GPBUtil::checkBool($var); + $this->reverse_order = $var; + + return $this; + } + + /** + * When masking a string, items in this list will be skipped when replacing + * characters. For example, if the input string is `555-555-5555` and you + * instruct Cloud DLP to skip `-` and mask 5 characters with `*`, Cloud DLP + * returns `***-**5-5555`. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.CharsToIgnore characters_to_ignore = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getCharactersToIgnore() + { + return $this->characters_to_ignore; + } + + /** + * When masking a string, items in this list will be skipped when replacing + * characters. For example, if the input string is `555-555-5555` and you + * instruct Cloud DLP to skip `-` and mask 5 characters with `*`, Cloud DLP + * returns `***-**5-5555`. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.CharsToIgnore characters_to_ignore = 4; + * @param array<\Google\Cloud\Dlp\V2\CharsToIgnore>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setCharactersToIgnore($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\CharsToIgnore::class); + $this->characters_to_ignore = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore.php new file mode 100644 index 000000000000..810e5f7da92f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore.php @@ -0,0 +1,112 @@ +google.privacy.dlp.v2.CharsToIgnore + */ +class CharsToIgnore extends \Google\Protobuf\Internal\Message +{ + protected $characters; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $characters_to_skip + * Characters to not transform when masking. + * @type int $common_characters_to_ignore + * Common characters to not transform when masking. Useful to avoid removing + * punctuation. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Characters to not transform when masking. + * + * Generated from protobuf field string characters_to_skip = 1; + * @return string + */ + public function getCharactersToSkip() + { + return $this->readOneof(1); + } + + public function hasCharactersToSkip() + { + return $this->hasOneof(1); + } + + /** + * Characters to not transform when masking. + * + * Generated from protobuf field string characters_to_skip = 1; + * @param string $var + * @return $this + */ + public function setCharactersToSkip($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Common characters to not transform when masking. Useful to avoid removing + * punctuation. + * + * Generated from protobuf field .google.privacy.dlp.v2.CharsToIgnore.CommonCharsToIgnore common_characters_to_ignore = 2; + * @return int + */ + public function getCommonCharactersToIgnore() + { + return $this->readOneof(2); + } + + public function hasCommonCharactersToIgnore() + { + return $this->hasOneof(2); + } + + /** + * Common characters to not transform when masking. Useful to avoid removing + * punctuation. + * + * Generated from protobuf field .google.privacy.dlp.v2.CharsToIgnore.CommonCharsToIgnore common_characters_to_ignore = 2; + * @param int $var + * @return $this + */ + public function setCommonCharactersToIgnore($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\CharsToIgnore\CommonCharsToIgnore::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getCharacters() + { + return $this->whichOneof("characters"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore/CommonCharsToIgnore.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore/CommonCharsToIgnore.php new file mode 100644 index 000000000000..bdda9d51629b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore/CommonCharsToIgnore.php @@ -0,0 +1,85 @@ +google.privacy.dlp.v2.CharsToIgnore.CommonCharsToIgnore + */ +class CommonCharsToIgnore +{ + /** + * Unused. + * + * Generated from protobuf enum COMMON_CHARS_TO_IGNORE_UNSPECIFIED = 0; + */ + const COMMON_CHARS_TO_IGNORE_UNSPECIFIED = 0; + /** + * 0-9 + * + * Generated from protobuf enum NUMERIC = 1; + */ + const NUMERIC = 1; + /** + * A-Z + * + * Generated from protobuf enum ALPHA_UPPER_CASE = 2; + */ + const ALPHA_UPPER_CASE = 2; + /** + * a-z + * + * Generated from protobuf enum ALPHA_LOWER_CASE = 3; + */ + const ALPHA_LOWER_CASE = 3; + /** + * US Punctuation, one of !"#$%&'()*+,-./:;<=>?@[\]^_`{|}~ + * + * Generated from protobuf enum PUNCTUATION = 4; + */ + const PUNCTUATION = 4; + /** + * Whitespace character, one of [ \t\n\x0B\f\r] + * + * Generated from protobuf enum WHITESPACE = 5; + */ + const WHITESPACE = 5; + + private static $valueToName = [ + self::COMMON_CHARS_TO_IGNORE_UNSPECIFIED => 'COMMON_CHARS_TO_IGNORE_UNSPECIFIED', + self::NUMERIC => 'NUMERIC', + self::ALPHA_UPPER_CASE => 'ALPHA_UPPER_CASE', + self::ALPHA_LOWER_CASE => 'ALPHA_LOWER_CASE', + self::PUNCTUATION => 'PUNCTUATION', + self::WHITESPACE => 'WHITESPACE', + ]; + + 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(CommonCharsToIgnore::class, \Google\Cloud\Dlp\V2\CharsToIgnore_CommonCharsToIgnore::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlDiscoveryTarget.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlDiscoveryTarget.php new file mode 100644 index 000000000000..64cf2263cd10 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlDiscoveryTarget.php @@ -0,0 +1,210 @@ +google.privacy.dlp.v2.CloudSqlDiscoveryTarget + */ +class CloudSqlDiscoveryTarget extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The tables the discovery cadence applies to. The first target + * with a matching filter will be the one to apply to a table. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlFilter filter = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $filter = null; + /** + * In addition to matching the filter, these conditions must be true + * before a profile is generated. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlConditions conditions = 2; + */ + protected $conditions = null; + protected $cadence; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DiscoveryCloudSqlFilter $filter + * Required. The tables the discovery cadence applies to. The first target + * with a matching filter will be the one to apply to a table. + * @type \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions $conditions + * In addition to matching the filter, these conditions must be true + * before a profile is generated. + * @type \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence $generation_cadence + * How often and when to update profiles. New tables that match both the + * filter and conditions are scanned as quickly as possible depending on + * system capacity. + * @type \Google\Cloud\Dlp\V2\Disabled $disabled + * Disable profiling for database resources that match this filter. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. The tables the discovery cadence applies to. The first target + * with a matching filter will be the one to apply to a table. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlFilter filter = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\DiscoveryCloudSqlFilter|null + */ + public function getFilter() + { + return $this->filter; + } + + public function hasFilter() + { + return isset($this->filter); + } + + public function clearFilter() + { + unset($this->filter); + } + + /** + * Required. The tables the discovery cadence applies to. The first target + * with a matching filter will be the one to apply to a table. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlFilter filter = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\DiscoveryCloudSqlFilter $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlFilter::class); + $this->filter = $var; + + return $this; + } + + /** + * In addition to matching the filter, these conditions must be true + * before a profile is generated. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlConditions conditions = 2; + * @return \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions|null + */ + public function getConditions() + { + return $this->conditions; + } + + public function hasConditions() + { + return isset($this->conditions); + } + + public function clearConditions() + { + unset($this->conditions); + } + + /** + * In addition to matching the filter, these conditions must be true + * before a profile is generated. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlConditions conditions = 2; + * @param \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions $var + * @return $this + */ + public function setConditions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions::class); + $this->conditions = $var; + + return $this; + } + + /** + * How often and when to update profiles. New tables that match both the + * filter and conditions are scanned as quickly as possible depending on + * system capacity. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence generation_cadence = 3; + * @return \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence|null + */ + public function getGenerationCadence() + { + return $this->readOneof(3); + } + + public function hasGenerationCadence() + { + return $this->hasOneof(3); + } + + /** + * How often and when to update profiles. New tables that match both the + * filter and conditions are scanned as quickly as possible depending on + * system capacity. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence generation_cadence = 3; + * @param \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence $var + * @return $this + */ + public function setGenerationCadence($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Disable profiling for database resources that match this filter. + * + * Generated from protobuf field .google.privacy.dlp.v2.Disabled disabled = 4; + * @return \Google\Cloud\Dlp\V2\Disabled|null + */ + public function getDisabled() + { + return $this->readOneof(4); + } + + public function hasDisabled() + { + return $this->hasOneof(4); + } + + /** + * Disable profiling for database resources that match this filter. + * + * Generated from protobuf field .google.privacy.dlp.v2.Disabled disabled = 4; + * @param \Google\Cloud\Dlp\V2\Disabled $var + * @return $this + */ + public function setDisabled($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Disabled::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getCadence() + { + return $this->whichOneof("cadence"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlIamCredential.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlIamCredential.php new file mode 100644 index 000000000000..bd753580e0b9 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlIamCredential.php @@ -0,0 +1,36 @@ +google.privacy.dlp.v2.CloudSqlIamCredential + */ +class CloudSqlIamCredential extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties.php new file mode 100644 index 000000000000..f14189ddced5 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties.php @@ -0,0 +1,250 @@ +google.privacy.dlp.v2.CloudSqlProperties + */ +class CloudSqlProperties extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Immutable. The Cloud SQL instance for which the connection is + * defined. Only one connection per instance is allowed. This can only be set + * at creation time, and cannot be updated. + * It is an error to use a connection_name from different project or region + * than the one that holds the connection. + * For example, a Connection resource for Cloud SQL connection_name + * `project-id:us-central1:sql-instance` + * must be created under the parent + * `projects/project-id/locations/us-central1` + * + * Generated from protobuf field string connection_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + */ + protected $connection_name = ''; + /** + * Required. DLP will limit its connections to max_connections. + * Must be 2 or greater. + * + * Generated from protobuf field int32 max_connections = 4 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $max_connections = 0; + /** + * Required. The database engine used by the Cloud SQL instance that this + * connection configures. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlProperties.DatabaseEngine database_engine = 7 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $database_engine = 0; + protected $credential; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $connection_name + * Optional. Immutable. The Cloud SQL instance for which the connection is + * defined. Only one connection per instance is allowed. This can only be set + * at creation time, and cannot be updated. + * It is an error to use a connection_name from different project or region + * than the one that holds the connection. + * For example, a Connection resource for Cloud SQL connection_name + * `project-id:us-central1:sql-instance` + * must be created under the parent + * `projects/project-id/locations/us-central1` + * @type \Google\Cloud\Dlp\V2\SecretManagerCredential $username_password + * A username and password stored in Secret Manager. + * @type \Google\Cloud\Dlp\V2\CloudSqlIamCredential $cloud_sql_iam + * Built-in IAM authentication (must be configured in Cloud SQL). + * @type int $max_connections + * Required. DLP will limit its connections to max_connections. + * Must be 2 or greater. + * @type int $database_engine + * Required. The database engine used by the Cloud SQL instance that this + * connection configures. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Optional. Immutable. The Cloud SQL instance for which the connection is + * defined. Only one connection per instance is allowed. This can only be set + * at creation time, and cannot be updated. + * It is an error to use a connection_name from different project or region + * than the one that holds the connection. + * For example, a Connection resource for Cloud SQL connection_name + * `project-id:us-central1:sql-instance` + * must be created under the parent + * `projects/project-id/locations/us-central1` + * + * Generated from protobuf field string connection_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getConnectionName() + { + return $this->connection_name; + } + + /** + * Optional. Immutable. The Cloud SQL instance for which the connection is + * defined. Only one connection per instance is allowed. This can only be set + * at creation time, and cannot be updated. + * It is an error to use a connection_name from different project or region + * than the one that holds the connection. + * For example, a Connection resource for Cloud SQL connection_name + * `project-id:us-central1:sql-instance` + * must be created under the parent + * `projects/project-id/locations/us-central1` + * + * Generated from protobuf field string connection_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setConnectionName($var) + { + GPBUtil::checkString($var, True); + $this->connection_name = $var; + + return $this; + } + + /** + * A username and password stored in Secret Manager. + * + * Generated from protobuf field .google.privacy.dlp.v2.SecretManagerCredential username_password = 2; + * @return \Google\Cloud\Dlp\V2\SecretManagerCredential|null + */ + public function getUsernamePassword() + { + return $this->readOneof(2); + } + + public function hasUsernamePassword() + { + return $this->hasOneof(2); + } + + /** + * A username and password stored in Secret Manager. + * + * Generated from protobuf field .google.privacy.dlp.v2.SecretManagerCredential username_password = 2; + * @param \Google\Cloud\Dlp\V2\SecretManagerCredential $var + * @return $this + */ + public function setUsernamePassword($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SecretManagerCredential::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Built-in IAM authentication (must be configured in Cloud SQL). + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlIamCredential cloud_sql_iam = 3; + * @return \Google\Cloud\Dlp\V2\CloudSqlIamCredential|null + */ + public function getCloudSqlIam() + { + return $this->readOneof(3); + } + + public function hasCloudSqlIam() + { + return $this->hasOneof(3); + } + + /** + * Built-in IAM authentication (must be configured in Cloud SQL). + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlIamCredential cloud_sql_iam = 3; + * @param \Google\Cloud\Dlp\V2\CloudSqlIamCredential $var + * @return $this + */ + public function setCloudSqlIam($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudSqlIamCredential::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Required. DLP will limit its connections to max_connections. + * Must be 2 or greater. + * + * Generated from protobuf field int32 max_connections = 4 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getMaxConnections() + { + return $this->max_connections; + } + + /** + * Required. DLP will limit its connections to max_connections. + * Must be 2 or greater. + * + * Generated from protobuf field int32 max_connections = 4 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setMaxConnections($var) + { + GPBUtil::checkInt32($var); + $this->max_connections = $var; + + return $this; + } + + /** + * Required. The database engine used by the Cloud SQL instance that this + * connection configures. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlProperties.DatabaseEngine database_engine = 7 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getDatabaseEngine() + { + return $this->database_engine; + } + + /** + * Required. The database engine used by the Cloud SQL instance that this + * connection configures. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlProperties.DatabaseEngine database_engine = 7 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setDatabaseEngine($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\CloudSqlProperties\DatabaseEngine::class); + $this->database_engine = $var; + + return $this; + } + + /** + * @return string + */ + public function getCredential() + { + return $this->whichOneof("credential"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties/DatabaseEngine.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties/DatabaseEngine.php new file mode 100644 index 000000000000..c21e1f3d23c8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties/DatabaseEngine.php @@ -0,0 +1,65 @@ +google.privacy.dlp.v2.CloudSqlProperties.DatabaseEngine + */ +class DatabaseEngine +{ + /** + * An engine that is not currently supported by Sensitive Data Protection. + * + * Generated from protobuf enum DATABASE_ENGINE_UNKNOWN = 0; + */ + const DATABASE_ENGINE_UNKNOWN = 0; + /** + * Cloud SQL for MySQL instance. + * + * Generated from protobuf enum DATABASE_ENGINE_MYSQL = 1; + */ + const DATABASE_ENGINE_MYSQL = 1; + /** + * Cloud SQL for PostgreSQL instance. + * + * Generated from protobuf enum DATABASE_ENGINE_POSTGRES = 2; + */ + const DATABASE_ENGINE_POSTGRES = 2; + + private static $valueToName = [ + self::DATABASE_ENGINE_UNKNOWN => 'DATABASE_ENGINE_UNKNOWN', + self::DATABASE_ENGINE_MYSQL => 'DATABASE_ENGINE_MYSQL', + self::DATABASE_ENGINE_POSTGRES => 'DATABASE_ENGINE_POSTGRES', + ]; + + 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(DatabaseEngine::class, \Google\Cloud\Dlp\V2\CloudSqlProperties_DatabaseEngine::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageFileSet.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageFileSet.php new file mode 100644 index 000000000000..39377fbb5684 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageFileSet.php @@ -0,0 +1,71 @@ +google.privacy.dlp.v2.CloudStorageFileSet + */ +class CloudStorageFileSet extends \Google\Protobuf\Internal\Message +{ + /** + * The url, in the format `gs:///`. Trailing wildcard in the + * path is allowed. + * + * Generated from protobuf field string url = 1; + */ + protected $url = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $url + * The url, in the format `gs:///`. Trailing wildcard in the + * path is allowed. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * The url, in the format `gs:///`. Trailing wildcard in the + * path is allowed. + * + * Generated from protobuf field string url = 1; + * @return string + */ + public function getUrl() + { + return $this->url; + } + + /** + * The url, in the format `gs:///`. Trailing wildcard in the + * path is allowed. + * + * 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; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions.php new file mode 100644 index 000000000000..b68860969e30 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions.php @@ -0,0 +1,332 @@ +google.privacy.dlp.v2.CloudStorageOptions + */ +class CloudStorageOptions extends \Google\Protobuf\Internal\Message +{ + /** + * The set of one or more files to scan. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions.FileSet file_set = 1; + */ + protected $file_set = null; + /** + * Max number of bytes to scan from a file. If a scanned file's size is bigger + * than this value then the rest of the bytes are omitted. Only one of + * `bytes_limit_per_file` and `bytes_limit_per_file_percent` can be specified. + * This field can't be set if de-identification is requested. For certain file + * types, setting this field has no effect. For more information, see [Limits + * on bytes scanned per + * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). + * + * Generated from protobuf field int64 bytes_limit_per_file = 4; + */ + protected $bytes_limit_per_file = 0; + /** + * Max percentage of bytes to scan from a file. The rest are omitted. The + * number of bytes scanned is rounded down. Must be between 0 and 100, + * inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of + * bytes_limit_per_file and bytes_limit_per_file_percent can be specified. + * This field can't be set if de-identification is requested. For certain file + * types, setting this field has no effect. For more information, see [Limits + * on bytes scanned per + * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). + * + * Generated from protobuf field int32 bytes_limit_per_file_percent = 8; + */ + protected $bytes_limit_per_file_percent = 0; + /** + * List of file type groups to include in the scan. + * If empty, all files are scanned and available data format processors + * are applied. In addition, the binary content of the selected files + * is always scanned as well. + * Images are scanned only as binary if the specified region + * does not support image inspection and no file_types were specified. + * Image inspection is restricted to 'global', 'us', 'asia', and 'europe'. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FileType file_types = 5; + */ + private $file_types; + /** + * How to sample the data. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions.SampleMethod sample_method = 6; + */ + protected $sample_method = 0; + /** + * Limits the number of files to scan to this percentage of the input FileSet. + * Number of files scanned is rounded down. Must be between 0 and 100, + * inclusively. Both 0 and 100 means no limit. Defaults to 0. + * + * Generated from protobuf field int32 files_limit_percent = 7; + */ + protected $files_limit_percent = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\CloudStorageOptions\FileSet $file_set + * The set of one or more files to scan. + * @type int|string $bytes_limit_per_file + * Max number of bytes to scan from a file. If a scanned file's size is bigger + * than this value then the rest of the bytes are omitted. Only one of + * `bytes_limit_per_file` and `bytes_limit_per_file_percent` can be specified. + * This field can't be set if de-identification is requested. For certain file + * types, setting this field has no effect. For more information, see [Limits + * on bytes scanned per + * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). + * @type int $bytes_limit_per_file_percent + * Max percentage of bytes to scan from a file. The rest are omitted. The + * number of bytes scanned is rounded down. Must be between 0 and 100, + * inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of + * bytes_limit_per_file and bytes_limit_per_file_percent can be specified. + * This field can't be set if de-identification is requested. For certain file + * types, setting this field has no effect. For more information, see [Limits + * on bytes scanned per + * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). + * @type array|\Google\Protobuf\Internal\RepeatedField $file_types + * List of file type groups to include in the scan. + * If empty, all files are scanned and available data format processors + * are applied. In addition, the binary content of the selected files + * is always scanned as well. + * Images are scanned only as binary if the specified region + * does not support image inspection and no file_types were specified. + * Image inspection is restricted to 'global', 'us', 'asia', and 'europe'. + * @type int $sample_method + * How to sample the data. + * @type int $files_limit_percent + * Limits the number of files to scan to this percentage of the input FileSet. + * Number of files scanned is rounded down. Must be between 0 and 100, + * inclusively. Both 0 and 100 means no limit. Defaults to 0. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * The set of one or more files to scan. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions.FileSet file_set = 1; + * @return \Google\Cloud\Dlp\V2\CloudStorageOptions\FileSet|null + */ + public function getFileSet() + { + return $this->file_set; + } + + public function hasFileSet() + { + return isset($this->file_set); + } + + public function clearFileSet() + { + unset($this->file_set); + } + + /** + * The set of one or more files to scan. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions.FileSet file_set = 1; + * @param \Google\Cloud\Dlp\V2\CloudStorageOptions\FileSet $var + * @return $this + */ + public function setFileSet($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudStorageOptions\FileSet::class); + $this->file_set = $var; + + return $this; + } + + /** + * Max number of bytes to scan from a file. If a scanned file's size is bigger + * than this value then the rest of the bytes are omitted. Only one of + * `bytes_limit_per_file` and `bytes_limit_per_file_percent` can be specified. + * This field can't be set if de-identification is requested. For certain file + * types, setting this field has no effect. For more information, see [Limits + * on bytes scanned per + * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). + * + * Generated from protobuf field int64 bytes_limit_per_file = 4; + * @return int|string + */ + public function getBytesLimitPerFile() + { + return $this->bytes_limit_per_file; + } + + /** + * Max number of bytes to scan from a file. If a scanned file's size is bigger + * than this value then the rest of the bytes are omitted. Only one of + * `bytes_limit_per_file` and `bytes_limit_per_file_percent` can be specified. + * This field can't be set if de-identification is requested. For certain file + * types, setting this field has no effect. For more information, see [Limits + * on bytes scanned per + * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). + * + * Generated from protobuf field int64 bytes_limit_per_file = 4; + * @param int|string $var + * @return $this + */ + public function setBytesLimitPerFile($var) + { + GPBUtil::checkInt64($var); + $this->bytes_limit_per_file = $var; + + return $this; + } + + /** + * Max percentage of bytes to scan from a file. The rest are omitted. The + * number of bytes scanned is rounded down. Must be between 0 and 100, + * inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of + * bytes_limit_per_file and bytes_limit_per_file_percent can be specified. + * This field can't be set if de-identification is requested. For certain file + * types, setting this field has no effect. For more information, see [Limits + * on bytes scanned per + * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). + * + * Generated from protobuf field int32 bytes_limit_per_file_percent = 8; + * @return int + */ + public function getBytesLimitPerFilePercent() + { + return $this->bytes_limit_per_file_percent; + } + + /** + * Max percentage of bytes to scan from a file. The rest are omitted. The + * number of bytes scanned is rounded down. Must be between 0 and 100, + * inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of + * bytes_limit_per_file and bytes_limit_per_file_percent can be specified. + * This field can't be set if de-identification is requested. For certain file + * types, setting this field has no effect. For more information, see [Limits + * on bytes scanned per + * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). + * + * Generated from protobuf field int32 bytes_limit_per_file_percent = 8; + * @param int $var + * @return $this + */ + public function setBytesLimitPerFilePercent($var) + { + GPBUtil::checkInt32($var); + $this->bytes_limit_per_file_percent = $var; + + return $this; + } + + /** + * List of file type groups to include in the scan. + * If empty, all files are scanned and available data format processors + * are applied. In addition, the binary content of the selected files + * is always scanned as well. + * Images are scanned only as binary if the specified region + * does not support image inspection and no file_types were specified. + * Image inspection is restricted to 'global', 'us', 'asia', and 'europe'. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FileType file_types = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFileTypes() + { + return $this->file_types; + } + + /** + * List of file type groups to include in the scan. + * If empty, all files are scanned and available data format processors + * are applied. In addition, the binary content of the selected files + * is always scanned as well. + * Images are scanned only as binary if the specified region + * does not support image inspection and no file_types were specified. + * Image inspection is restricted to 'global', 'us', 'asia', and 'europe'. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FileType file_types = 5; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFileTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\FileType::class); + $this->file_types = $arr; + + return $this; + } + + /** + * How to sample the data. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions.SampleMethod sample_method = 6; + * @return int + */ + public function getSampleMethod() + { + return $this->sample_method; + } + + /** + * How to sample the data. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions.SampleMethod sample_method = 6; + * @param int $var + * @return $this + */ + public function setSampleMethod($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\CloudStorageOptions\SampleMethod::class); + $this->sample_method = $var; + + return $this; + } + + /** + * Limits the number of files to scan to this percentage of the input FileSet. + * Number of files scanned is rounded down. Must be between 0 and 100, + * inclusively. Both 0 and 100 means no limit. Defaults to 0. + * + * Generated from protobuf field int32 files_limit_percent = 7; + * @return int + */ + public function getFilesLimitPercent() + { + return $this->files_limit_percent; + } + + /** + * Limits the number of files to scan to this percentage of the input FileSet. + * Number of files scanned is rounded down. Must be between 0 and 100, + * inclusively. Both 0 and 100 means no limit. Defaults to 0. + * + * Generated from protobuf field int32 files_limit_percent = 7; + * @param int $var + * @return $this + */ + public function setFilesLimitPercent($var) + { + GPBUtil::checkInt32($var); + $this->files_limit_percent = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/FileSet.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/FileSet.php new file mode 100644 index 000000000000..ac18796373e3 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/FileSet.php @@ -0,0 +1,146 @@ +google.privacy.dlp.v2.CloudStorageOptions.FileSet + */ +class FileSet extends \Google\Protobuf\Internal\Message +{ + /** + * The Cloud Storage url of the file(s) to scan, in the format + * `gs:///`. Trailing wildcard in the path is allowed. + * If the url ends in a trailing slash, the bucket or directory represented + * by the url will be scanned non-recursively (content in sub-directories + * will not be scanned). This means that `gs://mybucket/` is equivalent to + * `gs://mybucket/*`, and `gs://mybucket/directory/` is equivalent to + * `gs://mybucket/directory/*`. + * Exactly one of `url` or `regex_file_set` must be set. + * + * Generated from protobuf field string url = 1; + */ + protected $url = ''; + /** + * The regex-filtered set of files to scan. Exactly one of `url` or + * `regex_file_set` must be set. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageRegexFileSet regex_file_set = 2; + */ + protected $regex_file_set = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $url + * The Cloud Storage url of the file(s) to scan, in the format + * `gs:///`. Trailing wildcard in the path is allowed. + * If the url ends in a trailing slash, the bucket or directory represented + * by the url will be scanned non-recursively (content in sub-directories + * will not be scanned). This means that `gs://mybucket/` is equivalent to + * `gs://mybucket/*`, and `gs://mybucket/directory/` is equivalent to + * `gs://mybucket/directory/*`. + * Exactly one of `url` or `regex_file_set` must be set. + * @type \Google\Cloud\Dlp\V2\CloudStorageRegexFileSet $regex_file_set + * The regex-filtered set of files to scan. Exactly one of `url` or + * `regex_file_set` must be set. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * The Cloud Storage url of the file(s) to scan, in the format + * `gs:///`. Trailing wildcard in the path is allowed. + * If the url ends in a trailing slash, the bucket or directory represented + * by the url will be scanned non-recursively (content in sub-directories + * will not be scanned). This means that `gs://mybucket/` is equivalent to + * `gs://mybucket/*`, and `gs://mybucket/directory/` is equivalent to + * `gs://mybucket/directory/*`. + * Exactly one of `url` or `regex_file_set` must be set. + * + * Generated from protobuf field string url = 1; + * @return string + */ + public function getUrl() + { + return $this->url; + } + + /** + * The Cloud Storage url of the file(s) to scan, in the format + * `gs:///`. Trailing wildcard in the path is allowed. + * If the url ends in a trailing slash, the bucket or directory represented + * by the url will be scanned non-recursively (content in sub-directories + * will not be scanned). This means that `gs://mybucket/` is equivalent to + * `gs://mybucket/*`, and `gs://mybucket/directory/` is equivalent to + * `gs://mybucket/directory/*`. + * Exactly one of `url` or `regex_file_set` must be set. + * + * 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; + } + + /** + * The regex-filtered set of files to scan. Exactly one of `url` or + * `regex_file_set` must be set. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageRegexFileSet regex_file_set = 2; + * @return \Google\Cloud\Dlp\V2\CloudStorageRegexFileSet|null + */ + public function getRegexFileSet() + { + return $this->regex_file_set; + } + + public function hasRegexFileSet() + { + return isset($this->regex_file_set); + } + + public function clearRegexFileSet() + { + unset($this->regex_file_set); + } + + /** + * The regex-filtered set of files to scan. Exactly one of `url` or + * `regex_file_set` must be set. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageRegexFileSet regex_file_set = 2; + * @param \Google\Cloud\Dlp\V2\CloudStorageRegexFileSet $var + * @return $this + */ + public function setRegexFileSet($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudStorageRegexFileSet::class); + $this->regex_file_set = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(FileSet::class, \Google\Cloud\Dlp\V2\CloudStorageOptions_FileSet::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/SampleMethod.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/SampleMethod.php new file mode 100644 index 000000000000..ea69dd317b55 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/SampleMethod.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.CloudStorageOptions.SampleMethod + */ +class SampleMethod +{ + /** + * No sampling. + * + * Generated from protobuf enum SAMPLE_METHOD_UNSPECIFIED = 0; + */ + const SAMPLE_METHOD_UNSPECIFIED = 0; + /** + * Scan from the top (default). + * + * Generated from protobuf enum TOP = 1; + */ + const TOP = 1; + /** + * For each file larger than bytes_limit_per_file, randomly pick the offset + * to start scanning. The scanned bytes are contiguous. + * + * Generated from protobuf enum RANDOM_START = 2; + */ + const RANDOM_START = 2; + + private static $valueToName = [ + self::SAMPLE_METHOD_UNSPECIFIED => 'SAMPLE_METHOD_UNSPECIFIED', + self::TOP => 'TOP', + self::RANDOM_START => 'RANDOM_START', + ]; + + 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(SampleMethod::class, \Google\Cloud\Dlp\V2\CloudStorageOptions_SampleMethod::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStoragePath.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStoragePath.php new file mode 100644 index 000000000000..af52b7c78587 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStoragePath.php @@ -0,0 +1,71 @@ +google.privacy.dlp.v2.CloudStoragePath + */ +class CloudStoragePath extends \Google\Protobuf\Internal\Message +{ + /** + * A URL representing a file or path (no wildcards) in Cloud Storage. + * Example: `gs://[BUCKET_NAME]/dictionary.txt` + * + * Generated from protobuf field string path = 1; + */ + protected $path = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $path + * A URL representing a file or path (no wildcards) in Cloud Storage. + * Example: `gs://[BUCKET_NAME]/dictionary.txt` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * A URL representing a file or path (no wildcards) in Cloud Storage. + * Example: `gs://[BUCKET_NAME]/dictionary.txt` + * + * Generated from protobuf field string path = 1; + * @return string + */ + public function getPath() + { + return $this->path; + } + + /** + * A URL representing a file or path (no wildcards) in Cloud Storage. + * Example: `gs://[BUCKET_NAME]/dictionary.txt` + * + * 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; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageRegexFileSet.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageRegexFileSet.php new file mode 100644 index 000000000000..73325c4e9ca7 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageRegexFileSet.php @@ -0,0 +1,208 @@ +google.privacy.dlp.v2.CloudStorageRegexFileSet + */ +class CloudStorageRegexFileSet extends \Google\Protobuf\Internal\Message +{ + /** + * The name of a Cloud Storage bucket. Required. + * + * Generated from protobuf field string bucket_name = 1; + */ + protected $bucket_name = ''; + /** + * A list of regular expressions matching file paths to include. All files in + * the bucket that match at least one of these regular expressions will be + * included in the set of files, except for those that also match an item in + * `exclude_regex`. Leaving this field empty will match all files by default + * (this is equivalent to including `.*` in the list). + * Regular expressions use RE2 + * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found + * under the google/re2 repository on GitHub. + * + * Generated from protobuf field repeated string include_regex = 2; + */ + private $include_regex; + /** + * A list of regular expressions matching file paths to exclude. All files in + * the bucket that match at least one of these regular expressions will be + * excluded from the scan. + * Regular expressions use RE2 + * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found + * under the google/re2 repository on GitHub. + * + * Generated from protobuf field repeated string exclude_regex = 3; + */ + private $exclude_regex; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $bucket_name + * The name of a Cloud Storage bucket. Required. + * @type array|\Google\Protobuf\Internal\RepeatedField $include_regex + * A list of regular expressions matching file paths to include. All files in + * the bucket that match at least one of these regular expressions will be + * included in the set of files, except for those that also match an item in + * `exclude_regex`. Leaving this field empty will match all files by default + * (this is equivalent to including `.*` in the list). + * Regular expressions use RE2 + * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found + * under the google/re2 repository on GitHub. + * @type array|\Google\Protobuf\Internal\RepeatedField $exclude_regex + * A list of regular expressions matching file paths to exclude. All files in + * the bucket that match at least one of these regular expressions will be + * excluded from the scan. + * Regular expressions use RE2 + * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found + * under the google/re2 repository on GitHub. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * The name of a Cloud Storage bucket. Required. + * + * Generated from protobuf field string bucket_name = 1; + * @return string + */ + public function getBucketName() + { + return $this->bucket_name; + } + + /** + * The name of a Cloud Storage bucket. Required. + * + * Generated from protobuf field string bucket_name = 1; + * @param string $var + * @return $this + */ + public function setBucketName($var) + { + GPBUtil::checkString($var, True); + $this->bucket_name = $var; + + return $this; + } + + /** + * A list of regular expressions matching file paths to include. All files in + * the bucket that match at least one of these regular expressions will be + * included in the set of files, except for those that also match an item in + * `exclude_regex`. Leaving this field empty will match all files by default + * (this is equivalent to including `.*` in the list). + * Regular expressions use RE2 + * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found + * under the google/re2 repository on GitHub. + * + * Generated from protobuf field repeated string include_regex = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getIncludeRegex() + { + return $this->include_regex; + } + + /** + * A list of regular expressions matching file paths to include. All files in + * the bucket that match at least one of these regular expressions will be + * included in the set of files, except for those that also match an item in + * `exclude_regex`. Leaving this field empty will match all files by default + * (this is equivalent to including `.*` in the list). + * Regular expressions use RE2 + * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found + * under the google/re2 repository on GitHub. + * + * Generated from protobuf field repeated string include_regex = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setIncludeRegex($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->include_regex = $arr; + + return $this; + } + + /** + * A list of regular expressions matching file paths to exclude. All files in + * the bucket that match at least one of these regular expressions will be + * excluded from the scan. + * Regular expressions use RE2 + * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found + * under the google/re2 repository on GitHub. + * + * Generated from protobuf field repeated string exclude_regex = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getExcludeRegex() + { + return $this->exclude_regex; + } + + /** + * A list of regular expressions matching file paths to exclude. All files in + * the bucket that match at least one of these regular expressions will be + * excluded from the scan. + * Regular expressions use RE2 + * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found + * under the google/re2 repository on GitHub. + * + * Generated from protobuf field repeated string exclude_regex = 3; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setExcludeRegex($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->exclude_regex = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Color.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Color.php new file mode 100644 index 000000000000..4685448260e1 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Color.php @@ -0,0 +1,135 @@ +google.privacy.dlp.v2.Color + */ +class Color extends \Google\Protobuf\Internal\Message +{ + /** + * The amount of red in the color as a value in the interval [0, 1]. + * + * Generated from protobuf field float red = 1; + */ + protected $red = 0.0; + /** + * The amount of green in the color as a value in the interval [0, 1]. + * + * Generated from protobuf field float green = 2; + */ + protected $green = 0.0; + /** + * The amount of blue in the color as a value in the interval [0, 1]. + * + * Generated from protobuf field float blue = 3; + */ + protected $blue = 0.0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $red + * The amount of red in the color as a value in the interval [0, 1]. + * @type float $green + * The amount of green in the color as a value in the interval [0, 1]. + * @type float $blue + * The amount of blue in the color as a value in the interval [0, 1]. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The amount of red in the color as a value in the interval [0, 1]. + * + * Generated from protobuf field float red = 1; + * @return float + */ + public function getRed() + { + return $this->red; + } + + /** + * The amount of red in the color as a value in the interval [0, 1]. + * + * Generated from protobuf field float red = 1; + * @param float $var + * @return $this + */ + public function setRed($var) + { + GPBUtil::checkFloat($var); + $this->red = $var; + + return $this; + } + + /** + * The amount of green in the color as a value in the interval [0, 1]. + * + * Generated from protobuf field float green = 2; + * @return float + */ + public function getGreen() + { + return $this->green; + } + + /** + * The amount of green in the color as a value in the interval [0, 1]. + * + * Generated from protobuf field float green = 2; + * @param float $var + * @return $this + */ + public function setGreen($var) + { + GPBUtil::checkFloat($var); + $this->green = $var; + + return $this; + } + + /** + * The amount of blue in the color as a value in the interval [0, 1]. + * + * Generated from protobuf field float blue = 3; + * @return float + */ + public function getBlue() + { + return $this->blue; + } + + /** + * The amount of blue in the color as a value in the interval [0, 1]. + * + * Generated from protobuf field float blue = 3; + * @param float $var + * @return $this + */ + public function setBlue($var) + { + GPBUtil::checkFloat($var); + $this->blue = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile.php new file mode 100644 index 000000000000..6afebd01c479 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile.php @@ -0,0 +1,795 @@ +google.privacy.dlp.v2.ColumnDataProfile + */ +class ColumnDataProfile extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the profile. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Success or error status from the most recent profile generation attempt. + * May be empty if the profile is still being generated. + * + * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 17; + */ + protected $profile_status = null; + /** + * State of a profile. + * + * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.State state = 18; + */ + protected $state = 0; + /** + * The last time the profile was generated. + * + * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 3; + */ + protected $profile_last_generated = null; + /** + * The resource name of the table data profile. + * + * Generated from protobuf field string table_data_profile = 4; + */ + protected $table_data_profile = ''; + /** + * The resource name of the resource this column is within. + * + * Generated from protobuf field string table_full_resource = 5; + */ + protected $table_full_resource = ''; + /** + * The Google Cloud project ID that owns the profiled resource. + * + * Generated from protobuf field string dataset_project_id = 19; + */ + protected $dataset_project_id = ''; + /** + * The BigQuery location where the dataset's data is stored. + * See https://cloud.google.com/bigquery/docs/locations for supported + * locations. + * + * Generated from protobuf field string dataset_location = 20; + */ + protected $dataset_location = ''; + /** + * The BigQuery dataset ID. + * + * Generated from protobuf field string dataset_id = 21; + */ + protected $dataset_id = ''; + /** + * The BigQuery table ID. + * + * Generated from protobuf field string table_id = 22; + */ + protected $table_id = ''; + /** + * The name of the column. + * + * Generated from protobuf field string column = 6; + */ + protected $column = ''; + /** + * The sensitivity of this column. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 7; + */ + protected $sensitivity_score = null; + /** + * The data risk level for this column. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 8; + */ + protected $data_risk_level = null; + /** + * If it's been determined this column can be identified as a single type, + * this will be set. Otherwise the column either has unidentifiable content + * or mixed types. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeSummary column_info_type = 9; + */ + protected $column_info_type = null; + /** + * Other types found within this column. List will be unordered. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.OtherInfoTypeSummary other_matches = 10; + */ + private $other_matches; + /** + * Approximate percentage of entries being null in the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.NullPercentageLevel estimated_null_percentage = 23; + */ + protected $estimated_null_percentage = 0; + /** + * Approximate uniqueness of the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.UniquenessScoreLevel estimated_uniqueness_score = 24; + */ + protected $estimated_uniqueness_score = 0; + /** + * The likelihood that this column contains free-form text. + * A value close to 1 may indicate the column is likely to contain + * free-form or natural language text. + * Range in 0-1. + * + * Generated from protobuf field double free_text_score = 13; + */ + protected $free_text_score = 0.0; + /** + * The data type of a given column. + * + * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.ColumnDataType column_type = 14; + */ + protected $column_type = 0; + /** + * Indicates if a policy tag has been applied to the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.ColumnPolicyState policy_state = 15; + */ + protected $policy_state = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the profile. + * @type \Google\Cloud\Dlp\V2\ProfileStatus $profile_status + * Success or error status from the most recent profile generation attempt. + * May be empty if the profile is still being generated. + * @type int $state + * State of a profile. + * @type \Google\Protobuf\Timestamp $profile_last_generated + * The last time the profile was generated. + * @type string $table_data_profile + * The resource name of the table data profile. + * @type string $table_full_resource + * The resource name of the resource this column is within. + * @type string $dataset_project_id + * The Google Cloud project ID that owns the profiled resource. + * @type string $dataset_location + * The BigQuery location where the dataset's data is stored. + * See https://cloud.google.com/bigquery/docs/locations for supported + * locations. + * @type string $dataset_id + * The BigQuery dataset ID. + * @type string $table_id + * The BigQuery table ID. + * @type string $column + * The name of the column. + * @type \Google\Cloud\Dlp\V2\SensitivityScore $sensitivity_score + * The sensitivity of this column. + * @type \Google\Cloud\Dlp\V2\DataRiskLevel $data_risk_level + * The data risk level for this column. + * @type \Google\Cloud\Dlp\V2\InfoTypeSummary $column_info_type + * If it's been determined this column can be identified as a single type, + * this will be set. Otherwise the column either has unidentifiable content + * or mixed types. + * @type array<\Google\Cloud\Dlp\V2\OtherInfoTypeSummary>|\Google\Protobuf\Internal\RepeatedField $other_matches + * Other types found within this column. List will be unordered. + * @type int $estimated_null_percentage + * Approximate percentage of entries being null in the column. + * @type int $estimated_uniqueness_score + * Approximate uniqueness of the column. + * @type float $free_text_score + * The likelihood that this column contains free-form text. + * A value close to 1 may indicate the column is likely to contain + * free-form or natural language text. + * Range in 0-1. + * @type int $column_type + * The data type of a given column. + * @type int $policy_state + * Indicates if a policy tag has been applied to the column. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The name of the profile. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the profile. + * + * 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; + } + + /** + * Success or error status from the most recent profile generation attempt. + * May be empty if the profile is still being generated. + * + * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 17; + * @return \Google\Cloud\Dlp\V2\ProfileStatus|null + */ + public function getProfileStatus() + { + return $this->profile_status; + } + + public function hasProfileStatus() + { + return isset($this->profile_status); + } + + public function clearProfileStatus() + { + unset($this->profile_status); + } + + /** + * Success or error status from the most recent profile generation attempt. + * May be empty if the profile is still being generated. + * + * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 17; + * @param \Google\Cloud\Dlp\V2\ProfileStatus $var + * @return $this + */ + public function setProfileStatus($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ProfileStatus::class); + $this->profile_status = $var; + + return $this; + } + + /** + * State of a profile. + * + * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.State state = 18; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * State of a profile. + * + * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.State state = 18; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\ColumnDataProfile\State::class); + $this->state = $var; + + return $this; + } + + /** + * The last time the profile was generated. + * + * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 3; + * @return \Google\Protobuf\Timestamp|null + */ + public function getProfileLastGenerated() + { + return $this->profile_last_generated; + } + + public function hasProfileLastGenerated() + { + return isset($this->profile_last_generated); + } + + public function clearProfileLastGenerated() + { + unset($this->profile_last_generated); + } + + /** + * The last time the profile was generated. + * + * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 3; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setProfileLastGenerated($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->profile_last_generated = $var; + + return $this; + } + + /** + * The resource name of the table data profile. + * + * Generated from protobuf field string table_data_profile = 4; + * @return string + */ + public function getTableDataProfile() + { + return $this->table_data_profile; + } + + /** + * The resource name of the table data profile. + * + * Generated from protobuf field string table_data_profile = 4; + * @param string $var + * @return $this + */ + public function setTableDataProfile($var) + { + GPBUtil::checkString($var, True); + $this->table_data_profile = $var; + + return $this; + } + + /** + * The resource name of the resource this column is within. + * + * Generated from protobuf field string table_full_resource = 5; + * @return string + */ + public function getTableFullResource() + { + return $this->table_full_resource; + } + + /** + * The resource name of the resource this column is within. + * + * Generated from protobuf field string table_full_resource = 5; + * @param string $var + * @return $this + */ + public function setTableFullResource($var) + { + GPBUtil::checkString($var, True); + $this->table_full_resource = $var; + + return $this; + } + + /** + * The Google Cloud project ID that owns the profiled resource. + * + * Generated from protobuf field string dataset_project_id = 19; + * @return string + */ + public function getDatasetProjectId() + { + return $this->dataset_project_id; + } + + /** + * The Google Cloud project ID that owns the profiled resource. + * + * Generated from protobuf field string dataset_project_id = 19; + * @param string $var + * @return $this + */ + public function setDatasetProjectId($var) + { + GPBUtil::checkString($var, True); + $this->dataset_project_id = $var; + + return $this; + } + + /** + * The BigQuery location where the dataset's data is stored. + * See https://cloud.google.com/bigquery/docs/locations for supported + * locations. + * + * Generated from protobuf field string dataset_location = 20; + * @return string + */ + public function getDatasetLocation() + { + return $this->dataset_location; + } + + /** + * The BigQuery location where the dataset's data is stored. + * See https://cloud.google.com/bigquery/docs/locations for supported + * locations. + * + * Generated from protobuf field string dataset_location = 20; + * @param string $var + * @return $this + */ + public function setDatasetLocation($var) + { + GPBUtil::checkString($var, True); + $this->dataset_location = $var; + + return $this; + } + + /** + * The BigQuery dataset ID. + * + * Generated from protobuf field string dataset_id = 21; + * @return string + */ + public function getDatasetId() + { + return $this->dataset_id; + } + + /** + * The BigQuery dataset ID. + * + * Generated from protobuf field string dataset_id = 21; + * @param string $var + * @return $this + */ + public function setDatasetId($var) + { + GPBUtil::checkString($var, True); + $this->dataset_id = $var; + + return $this; + } + + /** + * The BigQuery table ID. + * + * Generated from protobuf field string table_id = 22; + * @return string + */ + public function getTableId() + { + return $this->table_id; + } + + /** + * The BigQuery table ID. + * + * Generated from protobuf field string table_id = 22; + * @param string $var + * @return $this + */ + public function setTableId($var) + { + GPBUtil::checkString($var, True); + $this->table_id = $var; + + return $this; + } + + /** + * The name of the column. + * + * Generated from protobuf field string column = 6; + * @return string + */ + public function getColumn() + { + return $this->column; + } + + /** + * The name of the column. + * + * Generated from protobuf field string column = 6; + * @param string $var + * @return $this + */ + public function setColumn($var) + { + GPBUtil::checkString($var, True); + $this->column = $var; + + return $this; + } + + /** + * The sensitivity of this column. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 7; + * @return \Google\Cloud\Dlp\V2\SensitivityScore|null + */ + public function getSensitivityScore() + { + return $this->sensitivity_score; + } + + public function hasSensitivityScore() + { + return isset($this->sensitivity_score); + } + + public function clearSensitivityScore() + { + unset($this->sensitivity_score); + } + + /** + * The sensitivity of this column. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 7; + * @param \Google\Cloud\Dlp\V2\SensitivityScore $var + * @return $this + */ + public function setSensitivityScore($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SensitivityScore::class); + $this->sensitivity_score = $var; + + return $this; + } + + /** + * The data risk level for this column. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 8; + * @return \Google\Cloud\Dlp\V2\DataRiskLevel|null + */ + public function getDataRiskLevel() + { + return $this->data_risk_level; + } + + public function hasDataRiskLevel() + { + return isset($this->data_risk_level); + } + + public function clearDataRiskLevel() + { + unset($this->data_risk_level); + } + + /** + * The data risk level for this column. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 8; + * @param \Google\Cloud\Dlp\V2\DataRiskLevel $var + * @return $this + */ + public function setDataRiskLevel($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataRiskLevel::class); + $this->data_risk_level = $var; + + return $this; + } + + /** + * If it's been determined this column can be identified as a single type, + * this will be set. Otherwise the column either has unidentifiable content + * or mixed types. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeSummary column_info_type = 9; + * @return \Google\Cloud\Dlp\V2\InfoTypeSummary|null + */ + public function getColumnInfoType() + { + return $this->column_info_type; + } + + public function hasColumnInfoType() + { + return isset($this->column_info_type); + } + + public function clearColumnInfoType() + { + unset($this->column_info_type); + } + + /** + * If it's been determined this column can be identified as a single type, + * this will be set. Otherwise the column either has unidentifiable content + * or mixed types. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeSummary column_info_type = 9; + * @param \Google\Cloud\Dlp\V2\InfoTypeSummary $var + * @return $this + */ + public function setColumnInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoTypeSummary::class); + $this->column_info_type = $var; + + return $this; + } + + /** + * Other types found within this column. List will be unordered. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.OtherInfoTypeSummary other_matches = 10; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOtherMatches() + { + return $this->other_matches; + } + + /** + * Other types found within this column. List will be unordered. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.OtherInfoTypeSummary other_matches = 10; + * @param array<\Google\Cloud\Dlp\V2\OtherInfoTypeSummary>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOtherMatches($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\OtherInfoTypeSummary::class); + $this->other_matches = $arr; + + return $this; + } + + /** + * Approximate percentage of entries being null in the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.NullPercentageLevel estimated_null_percentage = 23; + * @return int + */ + public function getEstimatedNullPercentage() + { + return $this->estimated_null_percentage; + } + + /** + * Approximate percentage of entries being null in the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.NullPercentageLevel estimated_null_percentage = 23; + * @param int $var + * @return $this + */ + public function setEstimatedNullPercentage($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\NullPercentageLevel::class); + $this->estimated_null_percentage = $var; + + return $this; + } + + /** + * Approximate uniqueness of the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.UniquenessScoreLevel estimated_uniqueness_score = 24; + * @return int + */ + public function getEstimatedUniquenessScore() + { + return $this->estimated_uniqueness_score; + } + + /** + * Approximate uniqueness of the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.UniquenessScoreLevel estimated_uniqueness_score = 24; + * @param int $var + * @return $this + */ + public function setEstimatedUniquenessScore($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\UniquenessScoreLevel::class); + $this->estimated_uniqueness_score = $var; + + return $this; + } + + /** + * The likelihood that this column contains free-form text. + * A value close to 1 may indicate the column is likely to contain + * free-form or natural language text. + * Range in 0-1. + * + * Generated from protobuf field double free_text_score = 13; + * @return float + */ + public function getFreeTextScore() + { + return $this->free_text_score; + } + + /** + * The likelihood that this column contains free-form text. + * A value close to 1 may indicate the column is likely to contain + * free-form or natural language text. + * Range in 0-1. + * + * Generated from protobuf field double free_text_score = 13; + * @param float $var + * @return $this + */ + public function setFreeTextScore($var) + { + GPBUtil::checkDouble($var); + $this->free_text_score = $var; + + return $this; + } + + /** + * The data type of a given column. + * + * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.ColumnDataType column_type = 14; + * @return int + */ + public function getColumnType() + { + return $this->column_type; + } + + /** + * The data type of a given column. + * + * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.ColumnDataType column_type = 14; + * @param int $var + * @return $this + */ + public function setColumnType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\ColumnDataProfile\ColumnDataType::class); + $this->column_type = $var; + + return $this; + } + + /** + * Indicates if a policy tag has been applied to the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.ColumnPolicyState policy_state = 15; + * @return int + */ + public function getPolicyState() + { + return $this->policy_state; + } + + /** + * Indicates if a policy tag has been applied to the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.ColumnPolicyState policy_state = 15; + * @param int $var + * @return $this + */ + public function setPolicyState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\ColumnDataProfile\ColumnPolicyState::class); + $this->policy_state = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnDataType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnDataType.php new file mode 100644 index 000000000000..83faea00b595 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnDataType.php @@ -0,0 +1,177 @@ +google.privacy.dlp.v2.ColumnDataProfile.ColumnDataType + */ +class ColumnDataType +{ + /** + * Invalid type. + * + * Generated from protobuf enum COLUMN_DATA_TYPE_UNSPECIFIED = 0; + */ + const COLUMN_DATA_TYPE_UNSPECIFIED = 0; + /** + * Encoded as a string in decimal format. + * + * Generated from protobuf enum TYPE_INT64 = 1; + */ + const TYPE_INT64 = 1; + /** + * Encoded as a boolean "false" or "true". + * + * Generated from protobuf enum TYPE_BOOL = 2; + */ + const TYPE_BOOL = 2; + /** + * Encoded as a number, or string "NaN", "Infinity" or "-Infinity". + * + * Generated from protobuf enum TYPE_FLOAT64 = 3; + */ + const TYPE_FLOAT64 = 3; + /** + * Encoded as a string value. + * + * Generated from protobuf enum TYPE_STRING = 4; + */ + const TYPE_STRING = 4; + /** + * Encoded as a base64 string per RFC 4648, section 4. + * + * Generated from protobuf enum TYPE_BYTES = 5; + */ + const TYPE_BYTES = 5; + /** + * Encoded as an RFC 3339 timestamp with mandatory "Z" time zone string: + * 1985-04-12T23:20:50.52Z + * + * Generated from protobuf enum TYPE_TIMESTAMP = 6; + */ + const TYPE_TIMESTAMP = 6; + /** + * Encoded as RFC 3339 full-date format string: 1985-04-12 + * + * Generated from protobuf enum TYPE_DATE = 7; + */ + const TYPE_DATE = 7; + /** + * Encoded as RFC 3339 partial-time format string: 23:20:50.52 + * + * Generated from protobuf enum TYPE_TIME = 8; + */ + const TYPE_TIME = 8; + /** + * Encoded as RFC 3339 full-date "T" partial-time: 1985-04-12T23:20:50.52 + * + * Generated from protobuf enum TYPE_DATETIME = 9; + */ + const TYPE_DATETIME = 9; + /** + * Encoded as WKT + * + * Generated from protobuf enum TYPE_GEOGRAPHY = 10; + */ + const TYPE_GEOGRAPHY = 10; + /** + * Encoded as a decimal string. + * + * Generated from protobuf enum TYPE_NUMERIC = 11; + */ + const TYPE_NUMERIC = 11; + /** + * Container of ordered fields, each with a type and field name. + * + * Generated from protobuf enum TYPE_RECORD = 12; + */ + const TYPE_RECORD = 12; + /** + * Decimal type. + * + * Generated from protobuf enum TYPE_BIGNUMERIC = 13; + */ + const TYPE_BIGNUMERIC = 13; + /** + * Json type. + * + * Generated from protobuf enum TYPE_JSON = 14; + */ + const TYPE_JSON = 14; + /** + * Interval type. + * + * Generated from protobuf enum TYPE_INTERVAL = 15; + */ + const TYPE_INTERVAL = 15; + /** + * `Range` type. + * + * Generated from protobuf enum TYPE_RANGE_DATE = 16; + */ + const TYPE_RANGE_DATE = 16; + /** + * `Range` type. + * + * Generated from protobuf enum TYPE_RANGE_DATETIME = 17; + */ + const TYPE_RANGE_DATETIME = 17; + /** + * `Range` type. + * + * Generated from protobuf enum TYPE_RANGE_TIMESTAMP = 18; + */ + const TYPE_RANGE_TIMESTAMP = 18; + + private static $valueToName = [ + self::COLUMN_DATA_TYPE_UNSPECIFIED => 'COLUMN_DATA_TYPE_UNSPECIFIED', + self::TYPE_INT64 => 'TYPE_INT64', + self::TYPE_BOOL => 'TYPE_BOOL', + self::TYPE_FLOAT64 => 'TYPE_FLOAT64', + self::TYPE_STRING => 'TYPE_STRING', + self::TYPE_BYTES => 'TYPE_BYTES', + self::TYPE_TIMESTAMP => 'TYPE_TIMESTAMP', + self::TYPE_DATE => 'TYPE_DATE', + self::TYPE_TIME => 'TYPE_TIME', + self::TYPE_DATETIME => 'TYPE_DATETIME', + self::TYPE_GEOGRAPHY => 'TYPE_GEOGRAPHY', + self::TYPE_NUMERIC => 'TYPE_NUMERIC', + self::TYPE_RECORD => 'TYPE_RECORD', + self::TYPE_BIGNUMERIC => 'TYPE_BIGNUMERIC', + self::TYPE_JSON => 'TYPE_JSON', + self::TYPE_INTERVAL => 'TYPE_INTERVAL', + self::TYPE_RANGE_DATE => 'TYPE_RANGE_DATE', + self::TYPE_RANGE_DATETIME => 'TYPE_RANGE_DATETIME', + self::TYPE_RANGE_TIMESTAMP => 'TYPE_RANGE_TIMESTAMP', + ]; + + 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(ColumnDataType::class, \Google\Cloud\Dlp\V2\ColumnDataProfile_ColumnDataType::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnPolicyState.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnPolicyState.php new file mode 100644 index 000000000000..b00c7d7e26b9 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnPolicyState.php @@ -0,0 +1,57 @@ +google.privacy.dlp.v2.ColumnDataProfile.ColumnPolicyState + */ +class ColumnPolicyState +{ + /** + * No policy tags. + * + * Generated from protobuf enum COLUMN_POLICY_STATE_UNSPECIFIED = 0; + */ + const COLUMN_POLICY_STATE_UNSPECIFIED = 0; + /** + * Column has policy tag applied. + * + * Generated from protobuf enum COLUMN_POLICY_TAGGED = 1; + */ + const COLUMN_POLICY_TAGGED = 1; + + private static $valueToName = [ + self::COLUMN_POLICY_STATE_UNSPECIFIED => 'COLUMN_POLICY_STATE_UNSPECIFIED', + self::COLUMN_POLICY_TAGGED => 'COLUMN_POLICY_TAGGED', + ]; + + 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(ColumnPolicyState::class, \Google\Cloud\Dlp\V2\ColumnDataProfile_ColumnPolicyState::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/State.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/State.php new file mode 100644 index 000000000000..a8698a1945a3 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/State.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.ColumnDataProfile.State + */ +class State +{ + /** + * Unused. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The profile is currently running. Once a profile has finished it will + * transition to DONE. + * + * Generated from protobuf enum RUNNING = 1; + */ + const RUNNING = 1; + /** + * The profile is no longer generating. + * If profile_status.status.code is 0, the profile succeeded, otherwise, it + * failed. + * + * Generated from protobuf enum DONE = 2; + */ + const DONE = 2; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::RUNNING => 'RUNNING', + self::DONE => 'DONE', + ]; + + 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, \Google\Cloud\Dlp\V2\ColumnDataProfile_State::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Connection.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Connection.php new file mode 100644 index 000000000000..911eb5b4d87d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Connection.php @@ -0,0 +1,186 @@ +google.privacy.dlp.v2.Connection + */ +class Connection extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Name of the connection: + * `projects/{project}/locations/{location}/connections/{name}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Required. The connection's state in its lifecycle. + * + * Generated from protobuf field .google.privacy.dlp.v2.ConnectionState state = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $state = 0; + /** + * Output only. Set if status == ERROR, to provide additional details. Will + * store the last 10 errors sorted with the most recent first. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $errors; + protected $properties; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. Name of the connection: + * `projects/{project}/locations/{location}/connections/{name}`. + * @type int $state + * Required. The connection's state in its lifecycle. + * @type array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $errors + * Output only. Set if status == ERROR, to provide additional details. Will + * store the last 10 errors sorted with the most recent first. + * @type \Google\Cloud\Dlp\V2\CloudSqlProperties $cloud_sql + * Connect to a Cloud SQL instance. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Name of the connection: + * `projects/{project}/locations/{location}/connections/{name}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. Name of the connection: + * `projects/{project}/locations/{location}/connections/{name}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Required. The connection's state in its lifecycle. + * + * Generated from protobuf field .google.privacy.dlp.v2.ConnectionState state = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Required. The connection's state in its lifecycle. + * + * Generated from protobuf field .google.privacy.dlp.v2.ConnectionState state = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\ConnectionState::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. Set if status == ERROR, to provide additional details. Will + * store the last 10 errors sorted with the most recent first. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getErrors() + { + return $this->errors; + } + + /** + * Output only. Set if status == ERROR, to provide additional details. Will + * store the last 10 errors sorted with the most recent first. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setErrors($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Error::class); + $this->errors = $arr; + + return $this; + } + + /** + * Connect to a Cloud SQL instance. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlProperties cloud_sql = 4; + * @return \Google\Cloud\Dlp\V2\CloudSqlProperties|null + */ + public function getCloudSql() + { + return $this->readOneof(4); + } + + public function hasCloudSql() + { + return $this->hasOneof(4); + } + + /** + * Connect to a Cloud SQL instance. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlProperties cloud_sql = 4; + * @param \Google\Cloud\Dlp\V2\CloudSqlProperties $var + * @return $this + */ + public function setCloudSql($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudSqlProperties::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getProperties() + { + return $this->whichOneof("properties"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ConnectionState.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ConnectionState.php new file mode 100644 index 000000000000..84cec3815510 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ConnectionState.php @@ -0,0 +1,75 @@ +google.privacy.dlp.v2.ConnectionState + */ +class ConnectionState +{ + /** + * Unused + * + * Generated from protobuf enum CONNECTION_STATE_UNSPECIFIED = 0; + */ + const CONNECTION_STATE_UNSPECIFIED = 0; + /** + * DLP automatically created this connection during an initial scan, and it is + * awaiting full configuration by a user. + * + * Generated from protobuf enum MISSING_CREDENTIALS = 1; + */ + const MISSING_CREDENTIALS = 1; + /** + * A configured connection that has not encountered any errors. + * + * Generated from protobuf enum AVAILABLE = 2; + */ + const AVAILABLE = 2; + /** + * A configured connection that encountered errors during its last use. It + * will not be used again until it is set to AVAILABLE. + * If the resolution requires external action, then the client must send a + * request to set the status to AVAILABLE when the connection is ready for + * use. If the resolution doesn't require external action, then any changes to + * the connection properties will automatically mark it as AVAILABLE. + * + * Generated from protobuf enum ERROR = 3; + */ + const ERROR = 3; + + private static $valueToName = [ + self::CONNECTION_STATE_UNSPECIFIED => 'CONNECTION_STATE_UNSPECIFIED', + self::MISSING_CREDENTIALS => 'MISSING_CREDENTIALS', + self::AVAILABLE => 'AVAILABLE', + self::ERROR => 'ERROR', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Container.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Container.php new file mode 100644 index 000000000000..2c70c94a5360 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Container.php @@ -0,0 +1,354 @@ +google.privacy.dlp.v2.Container + */ +class Container extends \Google\Protobuf\Internal\Message +{ + /** + * Container type, for example BigQuery or Cloud Storage. + * + * Generated from protobuf field string type = 1; + */ + protected $type = ''; + /** + * Project where the finding was found. + * Can be different from the project that owns the finding. + * + * Generated from protobuf field string project_id = 2; + */ + protected $project_id = ''; + /** + * A string representation of the full container name. + * Examples: + * - BigQuery: 'Project:DataSetId.TableId' + * - Cloud Storage: 'gs://Bucket/folders/filename.txt' + * + * Generated from protobuf field string full_path = 3; + */ + protected $full_path = ''; + /** + * The root of the container. + * Examples: + * - For BigQuery table `project_id:dataset_id.table_id`, the root is + * `dataset_id` + * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the root + * is `gs://bucket` + * + * Generated from protobuf field string root_path = 4; + */ + protected $root_path = ''; + /** + * The rest of the path after the root. + * Examples: + * - For BigQuery table `project_id:dataset_id.table_id`, the relative path is + * `table_id` + * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the relative + * path is `folder/filename.txt` + * + * Generated from protobuf field string relative_path = 5; + */ + protected $relative_path = ''; + /** + * Findings container modification timestamp, if applicable. For Cloud + * Storage, this field contains the last file modification timestamp. For a + * BigQuery table, this field contains the last_modified_time property. For + * Datastore, this field isn't populated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; + */ + protected $update_time = null; + /** + * Findings container version, if available + * ("generation" for Cloud Storage). + * + * Generated from protobuf field string version = 7; + */ + protected $version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $type + * Container type, for example BigQuery or Cloud Storage. + * @type string $project_id + * Project where the finding was found. + * Can be different from the project that owns the finding. + * @type string $full_path + * A string representation of the full container name. + * Examples: + * - BigQuery: 'Project:DataSetId.TableId' + * - Cloud Storage: 'gs://Bucket/folders/filename.txt' + * @type string $root_path + * The root of the container. + * Examples: + * - For BigQuery table `project_id:dataset_id.table_id`, the root is + * `dataset_id` + * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the root + * is `gs://bucket` + * @type string $relative_path + * The rest of the path after the root. + * Examples: + * - For BigQuery table `project_id:dataset_id.table_id`, the relative path is + * `table_id` + * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the relative + * path is `folder/filename.txt` + * @type \Google\Protobuf\Timestamp $update_time + * Findings container modification timestamp, if applicable. For Cloud + * Storage, this field contains the last file modification timestamp. For a + * BigQuery table, this field contains the last_modified_time property. For + * Datastore, this field isn't populated. + * @type string $version + * Findings container version, if available + * ("generation" for Cloud Storage). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Container type, for example BigQuery or Cloud Storage. + * + * Generated from protobuf field string type = 1; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * Container type, for example BigQuery or Cloud Storage. + * + * 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; + } + + /** + * Project where the finding was found. + * Can be different from the project that owns the finding. + * + * Generated from protobuf field string project_id = 2; + * @return string + */ + public function getProjectId() + { + return $this->project_id; + } + + /** + * Project where the finding was found. + * Can be different from the project that owns the finding. + * + * 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; + } + + /** + * A string representation of the full container name. + * Examples: + * - BigQuery: 'Project:DataSetId.TableId' + * - Cloud Storage: 'gs://Bucket/folders/filename.txt' + * + * Generated from protobuf field string full_path = 3; + * @return string + */ + public function getFullPath() + { + return $this->full_path; + } + + /** + * A string representation of the full container name. + * Examples: + * - BigQuery: 'Project:DataSetId.TableId' + * - Cloud Storage: 'gs://Bucket/folders/filename.txt' + * + * Generated from protobuf field string full_path = 3; + * @param string $var + * @return $this + */ + public function setFullPath($var) + { + GPBUtil::checkString($var, True); + $this->full_path = $var; + + return $this; + } + + /** + * The root of the container. + * Examples: + * - For BigQuery table `project_id:dataset_id.table_id`, the root is + * `dataset_id` + * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the root + * is `gs://bucket` + * + * Generated from protobuf field string root_path = 4; + * @return string + */ + public function getRootPath() + { + return $this->root_path; + } + + /** + * The root of the container. + * Examples: + * - For BigQuery table `project_id:dataset_id.table_id`, the root is + * `dataset_id` + * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the root + * is `gs://bucket` + * + * Generated from protobuf field string root_path = 4; + * @param string $var + * @return $this + */ + public function setRootPath($var) + { + GPBUtil::checkString($var, True); + $this->root_path = $var; + + return $this; + } + + /** + * The rest of the path after the root. + * Examples: + * - For BigQuery table `project_id:dataset_id.table_id`, the relative path is + * `table_id` + * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the relative + * path is `folder/filename.txt` + * + * Generated from protobuf field string relative_path = 5; + * @return string + */ + public function getRelativePath() + { + return $this->relative_path; + } + + /** + * The rest of the path after the root. + * Examples: + * - For BigQuery table `project_id:dataset_id.table_id`, the relative path is + * `table_id` + * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the relative + * path is `folder/filename.txt` + * + * Generated from protobuf field string relative_path = 5; + * @param string $var + * @return $this + */ + public function setRelativePath($var) + { + GPBUtil::checkString($var, True); + $this->relative_path = $var; + + return $this; + } + + /** + * Findings container modification timestamp, if applicable. For Cloud + * Storage, this field contains the last file modification timestamp. For a + * BigQuery table, this field contains the last_modified_time property. For + * Datastore, this field isn't populated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; + * @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); + } + + /** + * Findings container modification timestamp, if applicable. For Cloud + * Storage, this field contains the last file modification timestamp. For a + * BigQuery table, this field contains the last_modified_time property. For + * Datastore, this field isn't populated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Findings container version, if available + * ("generation" for Cloud Storage). + * + * Generated from protobuf field string version = 7; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * Findings container version, if available + * ("generation" for Cloud Storage). + * + * Generated from protobuf field string version = 7; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentItem.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentItem.php new file mode 100644 index 000000000000..272e11b07211 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentItem.php @@ -0,0 +1,147 @@ +google.privacy.dlp.v2.ContentItem + */ +class ContentItem extends \Google\Protobuf\Internal\Message +{ + protected $data_item; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $value + * String data to inspect or redact. + * @type \Google\Cloud\Dlp\V2\Table $table + * Structured content for inspection. See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-text#inspecting_a_table + * to learn more. + * @type \Google\Cloud\Dlp\V2\ByteContentItem $byte_item + * Content data to inspect or redact. Replaces `type` and `data`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * String data to inspect or redact. + * + * Generated from protobuf field string value = 3; + * @return string + */ + public function getValue() + { + return $this->readOneof(3); + } + + public function hasValue() + { + return $this->hasOneof(3); + } + + /** + * String data to inspect or redact. + * + * Generated from protobuf field string value = 3; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Structured content for inspection. See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-text#inspecting_a_table + * to learn more. + * + * Generated from protobuf field .google.privacy.dlp.v2.Table table = 4; + * @return \Google\Cloud\Dlp\V2\Table|null + */ + public function getTable() + { + return $this->readOneof(4); + } + + public function hasTable() + { + return $this->hasOneof(4); + } + + /** + * Structured content for inspection. See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-text#inspecting_a_table + * to learn more. + * + * Generated from protobuf field .google.privacy.dlp.v2.Table table = 4; + * @param \Google\Cloud\Dlp\V2\Table $var + * @return $this + */ + public function setTable($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Table::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Content data to inspect or redact. Replaces `type` and `data`. + * + * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem byte_item = 5; + * @return \Google\Cloud\Dlp\V2\ByteContentItem|null + */ + public function getByteItem() + { + return $this->readOneof(5); + } + + public function hasByteItem() + { + return $this->hasOneof(5); + } + + /** + * Content data to inspect or redact. Replaces `type` and `data`. + * + * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem byte_item = 5; + * @param \Google\Cloud\Dlp\V2\ByteContentItem $var + * @return $this + */ + public function setByteItem($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ByteContentItem::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * @return string + */ + public function getDataItem() + { + return $this->whichOneof("data_item"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentLocation.php new file mode 100644 index 000000000000..24ecf1d49145 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentLocation.php @@ -0,0 +1,331 @@ +google.privacy.dlp.v2.ContentLocation + */ +class ContentLocation extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the container where the finding is located. + * The top level name is the source file name or table name. Names of some + * common storage containers are formatted as follows: + * * BigQuery tables: `{project_id}:{dataset_id}.{table_id}` + * * Cloud Storage files: `gs://{bucket}/{path}` + * * Datastore namespace: {namespace} + * Nested names could be absent if the embedded object has no string + * identifier (for example, an image contained within a document). + * + * Generated from protobuf field string container_name = 1; + */ + protected $container_name = ''; + /** + * Finding container modification timestamp, if applicable. For Cloud Storage, + * this field contains the last file modification timestamp. For a BigQuery + * table, this field contains the last_modified_time property. For Datastore, + * this field isn't populated. + * + * Generated from protobuf field .google.protobuf.Timestamp container_timestamp = 6; + */ + protected $container_timestamp = null; + /** + * Finding container version, if available + * ("generation" for Cloud Storage). + * + * Generated from protobuf field string container_version = 7; + */ + protected $container_version = ''; + protected $location; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $container_name + * Name of the container where the finding is located. + * The top level name is the source file name or table name. Names of some + * common storage containers are formatted as follows: + * * BigQuery tables: `{project_id}:{dataset_id}.{table_id}` + * * Cloud Storage files: `gs://{bucket}/{path}` + * * Datastore namespace: {namespace} + * Nested names could be absent if the embedded object has no string + * identifier (for example, an image contained within a document). + * @type \Google\Cloud\Dlp\V2\RecordLocation $record_location + * Location within a row or record of a database table. + * @type \Google\Cloud\Dlp\V2\ImageLocation $image_location + * Location within an image's pixels. + * @type \Google\Cloud\Dlp\V2\DocumentLocation $document_location + * Location data for document files. + * @type \Google\Cloud\Dlp\V2\MetadataLocation $metadata_location + * Location within the metadata for inspected content. + * @type \Google\Protobuf\Timestamp $container_timestamp + * Finding container modification timestamp, if applicable. For Cloud Storage, + * this field contains the last file modification timestamp. For a BigQuery + * table, this field contains the last_modified_time property. For Datastore, + * this field isn't populated. + * @type string $container_version + * Finding container version, if available + * ("generation" for Cloud Storage). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Name of the container where the finding is located. + * The top level name is the source file name or table name. Names of some + * common storage containers are formatted as follows: + * * BigQuery tables: `{project_id}:{dataset_id}.{table_id}` + * * Cloud Storage files: `gs://{bucket}/{path}` + * * Datastore namespace: {namespace} + * Nested names could be absent if the embedded object has no string + * identifier (for example, an image contained within a document). + * + * Generated from protobuf field string container_name = 1; + * @return string + */ + public function getContainerName() + { + return $this->container_name; + } + + /** + * Name of the container where the finding is located. + * The top level name is the source file name or table name. Names of some + * common storage containers are formatted as follows: + * * BigQuery tables: `{project_id}:{dataset_id}.{table_id}` + * * Cloud Storage files: `gs://{bucket}/{path}` + * * Datastore namespace: {namespace} + * Nested names could be absent if the embedded object has no string + * identifier (for example, an image contained within a document). + * + * Generated from protobuf field string container_name = 1; + * @param string $var + * @return $this + */ + public function setContainerName($var) + { + GPBUtil::checkString($var, True); + $this->container_name = $var; + + return $this; + } + + /** + * Location within a row or record of a database table. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordLocation record_location = 2; + * @return \Google\Cloud\Dlp\V2\RecordLocation|null + */ + public function getRecordLocation() + { + return $this->readOneof(2); + } + + public function hasRecordLocation() + { + return $this->hasOneof(2); + } + + /** + * Location within a row or record of a database table. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordLocation record_location = 2; + * @param \Google\Cloud\Dlp\V2\RecordLocation $var + * @return $this + */ + public function setRecordLocation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordLocation::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Location within an image's pixels. + * + * Generated from protobuf field .google.privacy.dlp.v2.ImageLocation image_location = 3; + * @return \Google\Cloud\Dlp\V2\ImageLocation|null + */ + public function getImageLocation() + { + return $this->readOneof(3); + } + + public function hasImageLocation() + { + return $this->hasOneof(3); + } + + /** + * Location within an image's pixels. + * + * Generated from protobuf field .google.privacy.dlp.v2.ImageLocation image_location = 3; + * @param \Google\Cloud\Dlp\V2\ImageLocation $var + * @return $this + */ + public function setImageLocation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ImageLocation::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Location data for document files. + * + * Generated from protobuf field .google.privacy.dlp.v2.DocumentLocation document_location = 5; + * @return \Google\Cloud\Dlp\V2\DocumentLocation|null + */ + public function getDocumentLocation() + { + return $this->readOneof(5); + } + + public function hasDocumentLocation() + { + return $this->hasOneof(5); + } + + /** + * Location data for document files. + * + * Generated from protobuf field .google.privacy.dlp.v2.DocumentLocation document_location = 5; + * @param \Google\Cloud\Dlp\V2\DocumentLocation $var + * @return $this + */ + public function setDocumentLocation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DocumentLocation::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * Location within the metadata for inspected content. + * + * Generated from protobuf field .google.privacy.dlp.v2.MetadataLocation metadata_location = 8; + * @return \Google\Cloud\Dlp\V2\MetadataLocation|null + */ + public function getMetadataLocation() + { + return $this->readOneof(8); + } + + public function hasMetadataLocation() + { + return $this->hasOneof(8); + } + + /** + * Location within the metadata for inspected content. + * + * Generated from protobuf field .google.privacy.dlp.v2.MetadataLocation metadata_location = 8; + * @param \Google\Cloud\Dlp\V2\MetadataLocation $var + * @return $this + */ + public function setMetadataLocation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\MetadataLocation::class); + $this->writeOneof(8, $var); + + return $this; + } + + /** + * Finding container modification timestamp, if applicable. For Cloud Storage, + * this field contains the last file modification timestamp. For a BigQuery + * table, this field contains the last_modified_time property. For Datastore, + * this field isn't populated. + * + * Generated from protobuf field .google.protobuf.Timestamp container_timestamp = 6; + * @return \Google\Protobuf\Timestamp|null + */ + public function getContainerTimestamp() + { + return $this->container_timestamp; + } + + public function hasContainerTimestamp() + { + return isset($this->container_timestamp); + } + + public function clearContainerTimestamp() + { + unset($this->container_timestamp); + } + + /** + * Finding container modification timestamp, if applicable. For Cloud Storage, + * this field contains the last file modification timestamp. For a BigQuery + * table, this field contains the last_modified_time property. For Datastore, + * this field isn't populated. + * + * Generated from protobuf field .google.protobuf.Timestamp container_timestamp = 6; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setContainerTimestamp($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->container_timestamp = $var; + + return $this; + } + + /** + * Finding container version, if available + * ("generation" for Cloud Storage). + * + * Generated from protobuf field string container_version = 7; + * @return string + */ + public function getContainerVersion() + { + return $this->container_version; + } + + /** + * Finding container version, if available + * ("generation" for Cloud Storage). + * + * Generated from protobuf field string container_version = 7; + * @param string $var + * @return $this + */ + public function setContainerVersion($var) + { + GPBUtil::checkString($var, True); + $this->container_version = $var; + + return $this; + } + + /** + * @return string + */ + public function getLocation() + { + return $this->whichOneof("location"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentOption.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentOption.php new file mode 100644 index 000000000000..69a85fe92312 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentOption.php @@ -0,0 +1,61 @@ +google.privacy.dlp.v2.ContentOption + */ +class ContentOption +{ + /** + * Includes entire content of a file or a data stream. + * + * Generated from protobuf enum CONTENT_UNSPECIFIED = 0; + */ + const CONTENT_UNSPECIFIED = 0; + /** + * Text content within the data, excluding any metadata. + * + * Generated from protobuf enum CONTENT_TEXT = 1; + */ + const CONTENT_TEXT = 1; + /** + * Images found in the data. + * + * Generated from protobuf enum CONTENT_IMAGE = 2; + */ + const CONTENT_IMAGE = 2; + + private static $valueToName = [ + self::CONTENT_UNSPECIFIED => 'CONTENT_UNSPECIFIED', + self::CONTENT_TEXT => 'CONTENT_TEXT', + self::CONTENT_IMAGE => 'CONTENT_IMAGE', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateConnectionRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateConnectionRequest.php new file mode 100644 index 000000000000..1632c9f8e190 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateConnectionRequest.php @@ -0,0 +1,132 @@ +google.privacy.dlp.v2.CreateConnectionRequest + */ +class CreateConnectionRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name in the format: + * `projects/{project}/locations/{location}`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The connection resource. + * + * Generated from protobuf field .google.privacy.dlp.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $connection = null; + + /** + * @param string $parent Required. Parent resource name in the format: + * `projects/{project}/locations/{location}`. Please see + * {@see DlpServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\Connection $connection Required. The connection resource. + * + * @return \Google\Cloud\Dlp\V2\CreateConnectionRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Dlp\V2\Connection $connection): self + { + return (new self()) + ->setParent($parent) + ->setConnection($connection); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name in the format: + * `projects/{project}/locations/{location}`. + * @type \Google\Cloud\Dlp\V2\Connection $connection + * Required. The connection resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name in the format: + * `projects/{project}/locations/{location}`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name in the format: + * `projects/{project}/locations/{location}`. + * + * 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; + } + + /** + * Required. The connection resource. + * + * Generated from protobuf field .google.privacy.dlp.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\Connection|null + */ + public function getConnection() + { + return $this->connection; + } + + public function hasConnection() + { + return isset($this->connection); + } + + public function clearConnection() + { + unset($this->connection); + } + + /** + * Required. The connection resource. + * + * Generated from protobuf field .google.privacy.dlp.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\Connection $var + * @return $this + */ + public function setConnection($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Connection::class); + $this->connection = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDeidentifyTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDeidentifyTemplateRequest.php new file mode 100644 index 000000000000..37044c2cf4b7 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDeidentifyTemplateRequest.php @@ -0,0 +1,286 @@ +google.privacy.dlp.v2.CreateDeidentifyTemplateRequest + */ +class CreateDeidentifyTemplateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The DeidentifyTemplate to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate deidentify_template = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $deidentify_template = null; + /** + * The template id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string template_id = 3; + */ + protected $template_id = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 4; + */ + protected $location_id = ''; + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $deidentifyTemplate Required. The DeidentifyTemplate to create. + * + * @return \Google\Cloud\Dlp\V2\CreateDeidentifyTemplateRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Dlp\V2\DeidentifyTemplate $deidentifyTemplate): self + { + return (new self()) + ->setParent($parent) + ->setDeidentifyTemplate($deidentifyTemplate); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type \Google\Cloud\Dlp\V2\DeidentifyTemplate $deidentify_template + * Required. The DeidentifyTemplate to create. + * @type string $template_id + * The template id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * 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; + } + + /** + * Required. The DeidentifyTemplate to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate deidentify_template = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\DeidentifyTemplate|null + */ + public function getDeidentifyTemplate() + { + return $this->deidentify_template; + } + + public function hasDeidentifyTemplate() + { + return isset($this->deidentify_template); + } + + public function clearDeidentifyTemplate() + { + unset($this->deidentify_template); + } + + /** + * Required. The DeidentifyTemplate to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate deidentify_template = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $var + * @return $this + */ + public function setDeidentifyTemplate($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyTemplate::class); + $this->deidentify_template = $var; + + return $this; + } + + /** + * The template id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string template_id = 3; + * @return string + */ + public function getTemplateId() + { + return $this->template_id; + } + + /** + * The template id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string template_id = 3; + * @param string $var + * @return $this + */ + public function setTemplateId($var) + { + GPBUtil::checkString($var, True); + $this->template_id = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 4; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 4; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDiscoveryConfigRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDiscoveryConfigRequest.php new file mode 100644 index 000000000000..4d0d65696f58 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDiscoveryConfigRequest.php @@ -0,0 +1,206 @@ +google.privacy.dlp.v2.CreateDiscoveryConfigRequest + */ +class CreateDiscoveryConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value is as follows: + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The DiscoveryConfig to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $discovery_config = null; + /** + * The config ID can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string config_id = 3; + */ + protected $config_id = ''; + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value is as follows: + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\DiscoveryConfig $discoveryConfig Required. The DiscoveryConfig to create. + * + * @return \Google\Cloud\Dlp\V2\CreateDiscoveryConfigRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Dlp\V2\DiscoveryConfig $discoveryConfig): self + { + return (new self()) + ->setParent($parent) + ->setDiscoveryConfig($discoveryConfig); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value is as follows: + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type \Google\Cloud\Dlp\V2\DiscoveryConfig $discovery_config + * Required. The DiscoveryConfig to create. + * @type string $config_id + * The config ID can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value is as follows: + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value is as follows: + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * 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; + } + + /** + * Required. The DiscoveryConfig to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\DiscoveryConfig|null + */ + public function getDiscoveryConfig() + { + return $this->discovery_config; + } + + public function hasDiscoveryConfig() + { + return isset($this->discovery_config); + } + + public function clearDiscoveryConfig() + { + unset($this->discovery_config); + } + + /** + * Required. The DiscoveryConfig to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\DiscoveryConfig $var + * @return $this + */ + public function setDiscoveryConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryConfig::class); + $this->discovery_config = $var; + + return $this; + } + + /** + * The config ID can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string config_id = 3; + * @return string + */ + public function getConfigId() + { + return $this->config_id; + } + + /** + * The config ID can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string config_id = 3; + * @param string $var + * @return $this + */ + public function setConfigId($var) + { + GPBUtil::checkString($var, True); + $this->config_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDlpJobRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDlpJobRequest.php new file mode 100644 index 000000000000..b38ffc88310a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDlpJobRequest.php @@ -0,0 +1,334 @@ +google.privacy.dlp.v2.CreateDlpJobRequest + */ +class CreateDlpJobRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The job id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string job_id = 4; + */ + protected $job_id = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + */ + protected $location_id = ''; + protected $job; + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::projectName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\InspectJobConfig $inspectJob An inspection job scans a storage repository for InfoTypes. + * + * @return \Google\Cloud\Dlp\V2\CreateDlpJobRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Dlp\V2\InspectJobConfig $inspectJob): self + { + return (new self()) + ->setParent($parent) + ->setInspectJob($inspectJob); + } + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::projectName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig $riskJob A risk analysis job calculates re-identification risk metrics for a + * BigQuery table. + * + * @return \Google\Cloud\Dlp\V2\CreateDlpJobRequest + * + * @experimental + */ + public static function buildFromParentRiskJob(string $parent, \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig $riskJob): self + { + return (new self()) + ->setParent($parent) + ->setRiskJob($riskJob); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type \Google\Cloud\Dlp\V2\InspectJobConfig $inspect_job + * An inspection job scans a storage repository for InfoTypes. + * @type \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig $risk_job + * A risk analysis job calculates re-identification risk metrics for a + * BigQuery table. + * @type string $job_id + * The job id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * 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; + } + + /** + * An inspection job scans a storage repository for InfoTypes. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig inspect_job = 2; + * @return \Google\Cloud\Dlp\V2\InspectJobConfig|null + */ + public function getInspectJob() + { + return $this->readOneof(2); + } + + public function hasInspectJob() + { + return $this->hasOneof(2); + } + + /** + * An inspection job scans a storage repository for InfoTypes. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig inspect_job = 2; + * @param \Google\Cloud\Dlp\V2\InspectJobConfig $var + * @return $this + */ + public function setInspectJob($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectJobConfig::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * A risk analysis job calculates re-identification risk metrics for a + * BigQuery table. + * + * Generated from protobuf field .google.privacy.dlp.v2.RiskAnalysisJobConfig risk_job = 3; + * @return \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig|null + */ + public function getRiskJob() + { + return $this->readOneof(3); + } + + public function hasRiskJob() + { + return $this->hasOneof(3); + } + + /** + * A risk analysis job calculates re-identification risk metrics for a + * BigQuery table. + * + * Generated from protobuf field .google.privacy.dlp.v2.RiskAnalysisJobConfig risk_job = 3; + * @param \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig $var + * @return $this + */ + public function setRiskJob($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * The job id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string job_id = 4; + * @return string + */ + public function getJobId() + { + return $this->job_id; + } + + /** + * The job id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string job_id = 4; + * @param string $var + * @return $this + */ + public function setJobId($var) + { + GPBUtil::checkString($var, True); + $this->job_id = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + + /** + * @return string + */ + public function getJob() + { + return $this->whichOneof("job"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateInspectTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateInspectTemplateRequest.php new file mode 100644 index 000000000000..6919c3c0f689 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateInspectTemplateRequest.php @@ -0,0 +1,286 @@ +google.privacy.dlp.v2.CreateInspectTemplateRequest + */ +class CreateInspectTemplateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The InspectTemplate to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate inspect_template = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $inspect_template = null; + /** + * The template id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string template_id = 3; + */ + protected $template_id = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 4; + */ + protected $location_id = ''; + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\InspectTemplate $inspectTemplate Required. The InspectTemplate to create. + * + * @return \Google\Cloud\Dlp\V2\CreateInspectTemplateRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Dlp\V2\InspectTemplate $inspectTemplate): self + { + return (new self()) + ->setParent($parent) + ->setInspectTemplate($inspectTemplate); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type \Google\Cloud\Dlp\V2\InspectTemplate $inspect_template + * Required. The InspectTemplate to create. + * @type string $template_id + * The template id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * 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; + } + + /** + * Required. The InspectTemplate to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate inspect_template = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\InspectTemplate|null + */ + public function getInspectTemplate() + { + return $this->inspect_template; + } + + public function hasInspectTemplate() + { + return isset($this->inspect_template); + } + + public function clearInspectTemplate() + { + unset($this->inspect_template); + } + + /** + * Required. The InspectTemplate to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate inspect_template = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\InspectTemplate $var + * @return $this + */ + public function setInspectTemplate($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectTemplate::class); + $this->inspect_template = $var; + + return $this; + } + + /** + * The template id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string template_id = 3; + * @return string + */ + public function getTemplateId() + { + return $this->template_id; + } + + /** + * The template id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string template_id = 3; + * @param string $var + * @return $this + */ + public function setTemplateId($var) + { + GPBUtil::checkString($var, True); + $this->template_id = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 4; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 4; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateJobTriggerRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateJobTriggerRequest.php new file mode 100644 index 000000000000..ca2b09d9a86d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateJobTriggerRequest.php @@ -0,0 +1,266 @@ +google.privacy.dlp.v2.CreateJobTriggerRequest + */ +class CreateJobTriggerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The JobTrigger to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger job_trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $job_trigger = null; + /** + * The trigger id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string trigger_id = 3; + */ + protected $trigger_id = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 4; + */ + protected $location_id = ''; + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::projectName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\JobTrigger $jobTrigger Required. The JobTrigger to create. + * + * @return \Google\Cloud\Dlp\V2\CreateJobTriggerRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Dlp\V2\JobTrigger $jobTrigger): self + { + return (new self()) + ->setParent($parent) + ->setJobTrigger($jobTrigger); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type \Google\Cloud\Dlp\V2\JobTrigger $job_trigger + * Required. The JobTrigger to create. + * @type string $trigger_id + * The trigger id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * 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; + } + + /** + * Required. The JobTrigger to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger job_trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\JobTrigger|null + */ + public function getJobTrigger() + { + return $this->job_trigger; + } + + public function hasJobTrigger() + { + return isset($this->job_trigger); + } + + public function clearJobTrigger() + { + unset($this->job_trigger); + } + + /** + * Required. The JobTrigger to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger job_trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\JobTrigger $var + * @return $this + */ + public function setJobTrigger($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\JobTrigger::class); + $this->job_trigger = $var; + + return $this; + } + + /** + * The trigger id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string trigger_id = 3; + * @return string + */ + public function getTriggerId() + { + return $this->trigger_id; + } + + /** + * The trigger id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string trigger_id = 3; + * @param string $var + * @return $this + */ + public function setTriggerId($var) + { + GPBUtil::checkString($var, True); + $this->trigger_id = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 4; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 4; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateStoredInfoTypeRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateStoredInfoTypeRequest.php new file mode 100644 index 000000000000..62d8fa46a8e9 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateStoredInfoTypeRequest.php @@ -0,0 +1,286 @@ +google.privacy.dlp.v2.CreateStoredInfoTypeRequest + */ +class CreateStoredInfoTypeRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. Configuration of the storedInfoType to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $config = null; + /** + * The storedInfoType ID can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string stored_info_type_id = 3; + */ + protected $stored_info_type_id = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 4; + */ + protected $location_id = ''; + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config Required. Configuration of the storedInfoType to create. + * + * @return \Google\Cloud\Dlp\V2\CreateStoredInfoTypeRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config): self + { + return (new self()) + ->setParent($parent) + ->setConfig($config); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config + * Required. Configuration of the storedInfoType to create. + * @type string $stored_info_type_id + * The storedInfoType ID can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * 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; + } + + /** + * Required. Configuration of the storedInfoType to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\StoredInfoTypeConfig|null + */ + public function getConfig() + { + return $this->config; + } + + public function hasConfig() + { + return isset($this->config); + } + + public function clearConfig() + { + unset($this->config); + } + + /** + * Required. Configuration of the storedInfoType to create. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $var + * @return $this + */ + public function setConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StoredInfoTypeConfig::class); + $this->config = $var; + + return $this; + } + + /** + * The storedInfoType ID can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string stored_info_type_id = 3; + * @return string + */ + public function getStoredInfoTypeId() + { + return $this->stored_info_type_id; + } + + /** + * The storedInfoType ID can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * + * Generated from protobuf field string stored_info_type_id = 3; + * @param string $var + * @return $this + */ + public function setStoredInfoTypeId($var) + { + GPBUtil::checkString($var, True); + $this->stored_info_type_id = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 4; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 4; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoDeterministicConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoDeterministicConfig.php new file mode 100644 index 000000000000..fc425a4a7ee1 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoDeterministicConfig.php @@ -0,0 +1,327 @@ +google.privacy.dlp.v2.CryptoDeterministicConfig + */ +class CryptoDeterministicConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The key used by the encryption function. For deterministic encryption + * using AES-SIV, the provided key is internally expanded to 64 bytes prior to + * use. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1; + */ + protected $crypto_key = null; + /** + * The custom info type to annotate the surrogate with. + * This annotation will be applied to the surrogate by prefixing it with + * the name of the custom info type followed by the number of + * characters comprising the surrogate. The following scheme defines the + * format: {info type name}({surrogate character count}):{surrogate} + * For example, if the name of custom info type is 'MY_TOKEN_INFO_TYPE' and + * the surrogate is 'abc', the full replacement value + * will be: 'MY_TOKEN_INFO_TYPE(3):abc' + * This annotation identifies the surrogate when inspecting content using the + * custom info type 'Surrogate'. This facilitates reversal of the + * surrogate when it occurs in free text. + * Note: For record transformations where the entire cell in a table is being + * transformed, surrogates are not mandatory. Surrogates are used to denote + * the location of the token and are necessary for re-identification in free + * form text. + * In order for inspection to work properly, the name of this info type must + * not occur naturally anywhere in your data; otherwise, inspection may either + * - reverse a surrogate that does not correspond to an actual identifier + * - be unable to parse the surrogate and result in an error + * Therefore, choose your custom info type name carefully after considering + * what your data looks like. One way to select a name that has a high chance + * of yielding reliable detection is to include one or more unicode characters + * that are highly improbable to exist in your data. + * For example, assuming your data is entered from a regular ASCII keyboard, + * the symbol with the hex code point 29DD might be used like so: + * ⧝MY_TOKEN_TYPE. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType surrogate_info_type = 2; + */ + protected $surrogate_info_type = null; + /** + * A context may be used for higher security and maintaining + * referential integrity such that the same identifier in two different + * contexts will be given a distinct surrogate. The context is appended to + * plaintext value being encrypted. On decryption the provided context is + * validated against the value used during encryption. If a context was + * provided during encryption, same context must be provided during decryption + * as well. + * If the context is not set, plaintext would be used as is for encryption. + * If the context is set but: + * 1. there is no record present when transforming a given value or + * 2. the field is not present when transforming a given value, + * plaintext would be used as is for encryption. + * Note that case (1) is expected when an `InfoTypeTransformation` is + * applied to both structured and unstructured `ContentItem`s. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 3; + */ + protected $context = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\CryptoKey $crypto_key + * The key used by the encryption function. For deterministic encryption + * using AES-SIV, the provided key is internally expanded to 64 bytes prior to + * use. + * @type \Google\Cloud\Dlp\V2\InfoType $surrogate_info_type + * The custom info type to annotate the surrogate with. + * This annotation will be applied to the surrogate by prefixing it with + * the name of the custom info type followed by the number of + * characters comprising the surrogate. The following scheme defines the + * format: {info type name}({surrogate character count}):{surrogate} + * For example, if the name of custom info type is 'MY_TOKEN_INFO_TYPE' and + * the surrogate is 'abc', the full replacement value + * will be: 'MY_TOKEN_INFO_TYPE(3):abc' + * This annotation identifies the surrogate when inspecting content using the + * custom info type 'Surrogate'. This facilitates reversal of the + * surrogate when it occurs in free text. + * Note: For record transformations where the entire cell in a table is being + * transformed, surrogates are not mandatory. Surrogates are used to denote + * the location of the token and are necessary for re-identification in free + * form text. + * In order for inspection to work properly, the name of this info type must + * not occur naturally anywhere in your data; otherwise, inspection may either + * - reverse a surrogate that does not correspond to an actual identifier + * - be unable to parse the surrogate and result in an error + * Therefore, choose your custom info type name carefully after considering + * what your data looks like. One way to select a name that has a high chance + * of yielding reliable detection is to include one or more unicode characters + * that are highly improbable to exist in your data. + * For example, assuming your data is entered from a regular ASCII keyboard, + * the symbol with the hex code point 29DD might be used like so: + * ⧝MY_TOKEN_TYPE. + * @type \Google\Cloud\Dlp\V2\FieldId $context + * A context may be used for higher security and maintaining + * referential integrity such that the same identifier in two different + * contexts will be given a distinct surrogate. The context is appended to + * plaintext value being encrypted. On decryption the provided context is + * validated against the value used during encryption. If a context was + * provided during encryption, same context must be provided during decryption + * as well. + * If the context is not set, plaintext would be used as is for encryption. + * If the context is set but: + * 1. there is no record present when transforming a given value or + * 2. the field is not present when transforming a given value, + * plaintext would be used as is for encryption. + * Note that case (1) is expected when an `InfoTypeTransformation` is + * applied to both structured and unstructured `ContentItem`s. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The key used by the encryption function. For deterministic encryption + * using AES-SIV, the provided key is internally expanded to 64 bytes prior to + * use. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1; + * @return \Google\Cloud\Dlp\V2\CryptoKey|null + */ + public function getCryptoKey() + { + return $this->crypto_key; + } + + public function hasCryptoKey() + { + return isset($this->crypto_key); + } + + public function clearCryptoKey() + { + unset($this->crypto_key); + } + + /** + * The key used by the encryption function. For deterministic encryption + * using AES-SIV, the provided key is internally expanded to 64 bytes prior to + * use. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1; + * @param \Google\Cloud\Dlp\V2\CryptoKey $var + * @return $this + */ + public function setCryptoKey($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoKey::class); + $this->crypto_key = $var; + + return $this; + } + + /** + * The custom info type to annotate the surrogate with. + * This annotation will be applied to the surrogate by prefixing it with + * the name of the custom info type followed by the number of + * characters comprising the surrogate. The following scheme defines the + * format: {info type name}({surrogate character count}):{surrogate} + * For example, if the name of custom info type is 'MY_TOKEN_INFO_TYPE' and + * the surrogate is 'abc', the full replacement value + * will be: 'MY_TOKEN_INFO_TYPE(3):abc' + * This annotation identifies the surrogate when inspecting content using the + * custom info type 'Surrogate'. This facilitates reversal of the + * surrogate when it occurs in free text. + * Note: For record transformations where the entire cell in a table is being + * transformed, surrogates are not mandatory. Surrogates are used to denote + * the location of the token and are necessary for re-identification in free + * form text. + * In order for inspection to work properly, the name of this info type must + * not occur naturally anywhere in your data; otherwise, inspection may either + * - reverse a surrogate that does not correspond to an actual identifier + * - be unable to parse the surrogate and result in an error + * Therefore, choose your custom info type name carefully after considering + * what your data looks like. One way to select a name that has a high chance + * of yielding reliable detection is to include one or more unicode characters + * that are highly improbable to exist in your data. + * For example, assuming your data is entered from a regular ASCII keyboard, + * the symbol with the hex code point 29DD might be used like so: + * ⧝MY_TOKEN_TYPE. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType surrogate_info_type = 2; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getSurrogateInfoType() + { + return $this->surrogate_info_type; + } + + public function hasSurrogateInfoType() + { + return isset($this->surrogate_info_type); + } + + public function clearSurrogateInfoType() + { + unset($this->surrogate_info_type); + } + + /** + * The custom info type to annotate the surrogate with. + * This annotation will be applied to the surrogate by prefixing it with + * the name of the custom info type followed by the number of + * characters comprising the surrogate. The following scheme defines the + * format: {info type name}({surrogate character count}):{surrogate} + * For example, if the name of custom info type is 'MY_TOKEN_INFO_TYPE' and + * the surrogate is 'abc', the full replacement value + * will be: 'MY_TOKEN_INFO_TYPE(3):abc' + * This annotation identifies the surrogate when inspecting content using the + * custom info type 'Surrogate'. This facilitates reversal of the + * surrogate when it occurs in free text. + * Note: For record transformations where the entire cell in a table is being + * transformed, surrogates are not mandatory. Surrogates are used to denote + * the location of the token and are necessary for re-identification in free + * form text. + * In order for inspection to work properly, the name of this info type must + * not occur naturally anywhere in your data; otherwise, inspection may either + * - reverse a surrogate that does not correspond to an actual identifier + * - be unable to parse the surrogate and result in an error + * Therefore, choose your custom info type name carefully after considering + * what your data looks like. One way to select a name that has a high chance + * of yielding reliable detection is to include one or more unicode characters + * that are highly improbable to exist in your data. + * For example, assuming your data is entered from a regular ASCII keyboard, + * the symbol with the hex code point 29DD might be used like so: + * ⧝MY_TOKEN_TYPE. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType surrogate_info_type = 2; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setSurrogateInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->surrogate_info_type = $var; + + return $this; + } + + /** + * A context may be used for higher security and maintaining + * referential integrity such that the same identifier in two different + * contexts will be given a distinct surrogate. The context is appended to + * plaintext value being encrypted. On decryption the provided context is + * validated against the value used during encryption. If a context was + * provided during encryption, same context must be provided during decryption + * as well. + * If the context is not set, plaintext would be used as is for encryption. + * If the context is set but: + * 1. there is no record present when transforming a given value or + * 2. the field is not present when transforming a given value, + * plaintext would be used as is for encryption. + * Note that case (1) is expected when an `InfoTypeTransformation` is + * applied to both structured and unstructured `ContentItem`s. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 3; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getContext() + { + return $this->context; + } + + public function hasContext() + { + return isset($this->context); + } + + public function clearContext() + { + unset($this->context); + } + + /** + * A context may be used for higher security and maintaining + * referential integrity such that the same identifier in two different + * contexts will be given a distinct surrogate. The context is appended to + * plaintext value being encrypted. On decryption the provided context is + * validated against the value used during encryption. If a context was + * provided during encryption, same context must be provided during decryption + * as well. + * If the context is not set, plaintext would be used as is for encryption. + * If the context is set but: + * 1. there is no record present when transforming a given value or + * 2. the field is not present when transforming a given value, + * plaintext would be used as is for encryption. + * Note that case (1) is expected when an `InfoTypeTransformation` is + * applied to both structured and unstructured `ContentItem`s. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 3; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setContext($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->context = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoHashConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoHashConfig.php new file mode 100644 index 000000000000..3b749b878b35 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoHashConfig.php @@ -0,0 +1,84 @@ +google.privacy.dlp.v2.CryptoHashConfig + */ +class CryptoHashConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The key used by the hash function. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1; + */ + protected $crypto_key = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\CryptoKey $crypto_key + * The key used by the hash function. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The key used by the hash function. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1; + * @return \Google\Cloud\Dlp\V2\CryptoKey|null + */ + public function getCryptoKey() + { + return $this->crypto_key; + } + + public function hasCryptoKey() + { + return isset($this->crypto_key); + } + + public function clearCryptoKey() + { + unset($this->crypto_key); + } + + /** + * The key used by the hash function. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1; + * @param \Google\Cloud\Dlp\V2\CryptoKey $var + * @return $this + */ + public function setCryptoKey($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoKey::class); + $this->crypto_key = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoKey.php new file mode 100644 index 000000000000..403e1b4170a0 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoKey.php @@ -0,0 +1,146 @@ +google.privacy.dlp.v2.CryptoKey + */ +class CryptoKey extends \Google\Protobuf\Internal\Message +{ + protected $source; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\TransientCryptoKey $transient + * Transient crypto key + * @type \Google\Cloud\Dlp\V2\UnwrappedCryptoKey $unwrapped + * Unwrapped crypto key + * @type \Google\Cloud\Dlp\V2\KmsWrappedCryptoKey $kms_wrapped + * Key wrapped using Cloud KMS + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Transient crypto key + * + * Generated from protobuf field .google.privacy.dlp.v2.TransientCryptoKey transient = 1; + * @return \Google\Cloud\Dlp\V2\TransientCryptoKey|null + */ + public function getTransient() + { + return $this->readOneof(1); + } + + public function hasTransient() + { + return $this->hasOneof(1); + } + + /** + * Transient crypto key + * + * Generated from protobuf field .google.privacy.dlp.v2.TransientCryptoKey transient = 1; + * @param \Google\Cloud\Dlp\V2\TransientCryptoKey $var + * @return $this + */ + public function setTransient($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransientCryptoKey::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Unwrapped crypto key + * + * Generated from protobuf field .google.privacy.dlp.v2.UnwrappedCryptoKey unwrapped = 2; + * @return \Google\Cloud\Dlp\V2\UnwrappedCryptoKey|null + */ + public function getUnwrapped() + { + return $this->readOneof(2); + } + + public function hasUnwrapped() + { + return $this->hasOneof(2); + } + + /** + * Unwrapped crypto key + * + * Generated from protobuf field .google.privacy.dlp.v2.UnwrappedCryptoKey unwrapped = 2; + * @param \Google\Cloud\Dlp\V2\UnwrappedCryptoKey $var + * @return $this + */ + public function setUnwrapped($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\UnwrappedCryptoKey::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Key wrapped using Cloud KMS + * + * Generated from protobuf field .google.privacy.dlp.v2.KmsWrappedCryptoKey kms_wrapped = 3; + * @return \Google\Cloud\Dlp\V2\KmsWrappedCryptoKey|null + */ + public function getKmsWrapped() + { + return $this->readOneof(3); + } + + public function hasKmsWrapped() + { + return $this->hasOneof(3); + } + + /** + * Key wrapped using Cloud KMS + * + * Generated from protobuf field .google.privacy.dlp.v2.KmsWrappedCryptoKey kms_wrapped = 3; + * @param \Google\Cloud\Dlp\V2\KmsWrappedCryptoKey $var + * @return $this + */ + public function setKmsWrapped($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\KmsWrappedCryptoKey::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getSource() + { + return $this->whichOneof("source"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig.php new file mode 100644 index 000000000000..78a1f0ce9324 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig.php @@ -0,0 +1,448 @@ +google.privacy.dlp.v2.CryptoReplaceFfxFpeConfig + */ +class CryptoReplaceFfxFpeConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The key used by the encryption algorithm. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $crypto_key = null; + /** + * The 'tweak', a context may be used for higher security since the same + * identifier in two different contexts won't be given the same surrogate. If + * the context is not set, a default tweak will be used. + * If the context is set but: + * 1. there is no record present when transforming a given value or + * 1. the field is not present when transforming a given value, + * a default tweak will be used. + * Note that case (1) is expected when an `InfoTypeTransformation` is + * applied to both structured and unstructured `ContentItem`s. + * Currently, the referenced field may be of value type integer or string. + * The tweak is constructed as a sequence of bytes in big endian byte order + * such that: + * - a 64 bit integer is encoded followed by a single byte of value 1 + * - a string is encoded in UTF-8 format followed by a single byte of value 2 + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 2; + */ + protected $context = null; + /** + * The custom infoType to annotate the surrogate with. + * This annotation will be applied to the surrogate by prefixing it with + * the name of the custom infoType followed by the number of + * characters comprising the surrogate. The following scheme defines the + * format: info_type_name(surrogate_character_count):surrogate + * For example, if the name of custom infoType is 'MY_TOKEN_INFO_TYPE' and + * the surrogate is 'abc', the full replacement value + * will be: 'MY_TOKEN_INFO_TYPE(3):abc' + * This annotation identifies the surrogate when inspecting content using the + * custom infoType + * [`SurrogateType`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/InspectConfig#surrogatetype). + * This facilitates reversal of the surrogate when it occurs in free text. + * In order for inspection to work properly, the name of this infoType must + * not occur naturally anywhere in your data; otherwise, inspection may + * find a surrogate that does not correspond to an actual identifier. + * Therefore, choose your custom infoType name carefully after considering + * what your data looks like. One way to select a name that has a high chance + * of yielding reliable detection is to include one or more unicode characters + * that are highly improbable to exist in your data. + * For example, assuming your data is entered from a regular ASCII keyboard, + * the symbol with the hex code point 29DD might be used like so: + * ⧝MY_TOKEN_TYPE + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType surrogate_info_type = 8; + */ + protected $surrogate_info_type = null; + protected $alphabet; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\CryptoKey $crypto_key + * Required. The key used by the encryption algorithm. + * @type \Google\Cloud\Dlp\V2\FieldId $context + * The 'tweak', a context may be used for higher security since the same + * identifier in two different contexts won't be given the same surrogate. If + * the context is not set, a default tweak will be used. + * If the context is set but: + * 1. there is no record present when transforming a given value or + * 1. the field is not present when transforming a given value, + * a default tweak will be used. + * Note that case (1) is expected when an `InfoTypeTransformation` is + * applied to both structured and unstructured `ContentItem`s. + * Currently, the referenced field may be of value type integer or string. + * The tweak is constructed as a sequence of bytes in big endian byte order + * such that: + * - a 64 bit integer is encoded followed by a single byte of value 1 + * - a string is encoded in UTF-8 format followed by a single byte of value 2 + * @type int $common_alphabet + * Common alphabets. + * @type string $custom_alphabet + * This is supported by mapping these to the alphanumeric characters + * that the FFX mode natively supports. This happens before/after + * encryption/decryption. + * Each character listed must appear only once. + * Number of characters must be in the range [2, 95]. + * This must be encoded as ASCII. + * The order of characters does not matter. + * The full list of allowed characters is: + * 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz + * ~`!@#$%^&*()_-+={[}]|\:;"'<,>.?/ + * @type int $radix + * The native way to select the alphabet. Must be in the range [2, 95]. + * @type \Google\Cloud\Dlp\V2\InfoType $surrogate_info_type + * The custom infoType to annotate the surrogate with. + * This annotation will be applied to the surrogate by prefixing it with + * the name of the custom infoType followed by the number of + * characters comprising the surrogate. The following scheme defines the + * format: info_type_name(surrogate_character_count):surrogate + * For example, if the name of custom infoType is 'MY_TOKEN_INFO_TYPE' and + * the surrogate is 'abc', the full replacement value + * will be: 'MY_TOKEN_INFO_TYPE(3):abc' + * This annotation identifies the surrogate when inspecting content using the + * custom infoType + * [`SurrogateType`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/InspectConfig#surrogatetype). + * This facilitates reversal of the surrogate when it occurs in free text. + * In order for inspection to work properly, the name of this infoType must + * not occur naturally anywhere in your data; otherwise, inspection may + * find a surrogate that does not correspond to an actual identifier. + * Therefore, choose your custom infoType name carefully after considering + * what your data looks like. One way to select a name that has a high chance + * of yielding reliable detection is to include one or more unicode characters + * that are highly improbable to exist in your data. + * For example, assuming your data is entered from a regular ASCII keyboard, + * the symbol with the hex code point 29DD might be used like so: + * ⧝MY_TOKEN_TYPE + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. The key used by the encryption algorithm. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\CryptoKey|null + */ + public function getCryptoKey() + { + return $this->crypto_key; + } + + public function hasCryptoKey() + { + return isset($this->crypto_key); + } + + public function clearCryptoKey() + { + unset($this->crypto_key); + } + + /** + * Required. The key used by the encryption algorithm. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\CryptoKey $var + * @return $this + */ + public function setCryptoKey($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoKey::class); + $this->crypto_key = $var; + + return $this; + } + + /** + * The 'tweak', a context may be used for higher security since the same + * identifier in two different contexts won't be given the same surrogate. If + * the context is not set, a default tweak will be used. + * If the context is set but: + * 1. there is no record present when transforming a given value or + * 1. the field is not present when transforming a given value, + * a default tweak will be used. + * Note that case (1) is expected when an `InfoTypeTransformation` is + * applied to both structured and unstructured `ContentItem`s. + * Currently, the referenced field may be of value type integer or string. + * The tweak is constructed as a sequence of bytes in big endian byte order + * such that: + * - a 64 bit integer is encoded followed by a single byte of value 1 + * - a string is encoded in UTF-8 format followed by a single byte of value 2 + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 2; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getContext() + { + return $this->context; + } + + public function hasContext() + { + return isset($this->context); + } + + public function clearContext() + { + unset($this->context); + } + + /** + * The 'tweak', a context may be used for higher security since the same + * identifier in two different contexts won't be given the same surrogate. If + * the context is not set, a default tweak will be used. + * If the context is set but: + * 1. there is no record present when transforming a given value or + * 1. the field is not present when transforming a given value, + * a default tweak will be used. + * Note that case (1) is expected when an `InfoTypeTransformation` is + * applied to both structured and unstructured `ContentItem`s. + * Currently, the referenced field may be of value type integer or string. + * The tweak is constructed as a sequence of bytes in big endian byte order + * such that: + * - a 64 bit integer is encoded followed by a single byte of value 1 + * - a string is encoded in UTF-8 format followed by a single byte of value 2 + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 2; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setContext($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->context = $var; + + return $this; + } + + /** + * Common alphabets. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; + * @return int + */ + public function getCommonAlphabet() + { + return $this->readOneof(4); + } + + public function hasCommonAlphabet() + { + return $this->hasOneof(4); + } + + /** + * Common alphabets. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; + * @param int $var + * @return $this + */ + public function setCommonAlphabet($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\CryptoReplaceFfxFpeConfig\FfxCommonNativeAlphabet::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * This is supported by mapping these to the alphanumeric characters + * that the FFX mode natively supports. This happens before/after + * encryption/decryption. + * Each character listed must appear only once. + * Number of characters must be in the range [2, 95]. + * This must be encoded as ASCII. + * The order of characters does not matter. + * The full list of allowed characters is: + * 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz + * ~`!@#$%^&*()_-+={[}]|\:;"'<,>.?/ + * + * Generated from protobuf field string custom_alphabet = 5; + * @return string + */ + public function getCustomAlphabet() + { + return $this->readOneof(5); + } + + public function hasCustomAlphabet() + { + return $this->hasOneof(5); + } + + /** + * This is supported by mapping these to the alphanumeric characters + * that the FFX mode natively supports. This happens before/after + * encryption/decryption. + * Each character listed must appear only once. + * Number of characters must be in the range [2, 95]. + * This must be encoded as ASCII. + * The order of characters does not matter. + * The full list of allowed characters is: + * 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz + * ~`!@#$%^&*()_-+={[}]|\:;"'<,>.?/ + * + * Generated from protobuf field string custom_alphabet = 5; + * @param string $var + * @return $this + */ + public function setCustomAlphabet($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * The native way to select the alphabet. Must be in the range [2, 95]. + * + * Generated from protobuf field int32 radix = 6; + * @return int + */ + public function getRadix() + { + return $this->readOneof(6); + } + + public function hasRadix() + { + return $this->hasOneof(6); + } + + /** + * The native way to select the alphabet. Must be in the range [2, 95]. + * + * Generated from protobuf field int32 radix = 6; + * @param int $var + * @return $this + */ + public function setRadix($var) + { + GPBUtil::checkInt32($var); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * The custom infoType to annotate the surrogate with. + * This annotation will be applied to the surrogate by prefixing it with + * the name of the custom infoType followed by the number of + * characters comprising the surrogate. The following scheme defines the + * format: info_type_name(surrogate_character_count):surrogate + * For example, if the name of custom infoType is 'MY_TOKEN_INFO_TYPE' and + * the surrogate is 'abc', the full replacement value + * will be: 'MY_TOKEN_INFO_TYPE(3):abc' + * This annotation identifies the surrogate when inspecting content using the + * custom infoType + * [`SurrogateType`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/InspectConfig#surrogatetype). + * This facilitates reversal of the surrogate when it occurs in free text. + * In order for inspection to work properly, the name of this infoType must + * not occur naturally anywhere in your data; otherwise, inspection may + * find a surrogate that does not correspond to an actual identifier. + * Therefore, choose your custom infoType name carefully after considering + * what your data looks like. One way to select a name that has a high chance + * of yielding reliable detection is to include one or more unicode characters + * that are highly improbable to exist in your data. + * For example, assuming your data is entered from a regular ASCII keyboard, + * the symbol with the hex code point 29DD might be used like so: + * ⧝MY_TOKEN_TYPE + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType surrogate_info_type = 8; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getSurrogateInfoType() + { + return $this->surrogate_info_type; + } + + public function hasSurrogateInfoType() + { + return isset($this->surrogate_info_type); + } + + public function clearSurrogateInfoType() + { + unset($this->surrogate_info_type); + } + + /** + * The custom infoType to annotate the surrogate with. + * This annotation will be applied to the surrogate by prefixing it with + * the name of the custom infoType followed by the number of + * characters comprising the surrogate. The following scheme defines the + * format: info_type_name(surrogate_character_count):surrogate + * For example, if the name of custom infoType is 'MY_TOKEN_INFO_TYPE' and + * the surrogate is 'abc', the full replacement value + * will be: 'MY_TOKEN_INFO_TYPE(3):abc' + * This annotation identifies the surrogate when inspecting content using the + * custom infoType + * [`SurrogateType`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/InspectConfig#surrogatetype). + * This facilitates reversal of the surrogate when it occurs in free text. + * In order for inspection to work properly, the name of this infoType must + * not occur naturally anywhere in your data; otherwise, inspection may + * find a surrogate that does not correspond to an actual identifier. + * Therefore, choose your custom infoType name carefully after considering + * what your data looks like. One way to select a name that has a high chance + * of yielding reliable detection is to include one or more unicode characters + * that are highly improbable to exist in your data. + * For example, assuming your data is entered from a regular ASCII keyboard, + * the symbol with the hex code point 29DD might be used like so: + * ⧝MY_TOKEN_TYPE + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType surrogate_info_type = 8; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setSurrogateInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->surrogate_info_type = $var; + + return $this; + } + + /** + * @return string + */ + public function getAlphabet() + { + return $this->whichOneof("alphabet"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig/FfxCommonNativeAlphabet.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig/FfxCommonNativeAlphabet.php new file mode 100644 index 000000000000..c08c85b4dd25 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig/FfxCommonNativeAlphabet.php @@ -0,0 +1,80 @@ +google.privacy.dlp.v2.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet + */ +class FfxCommonNativeAlphabet +{ + /** + * Unused. + * + * Generated from protobuf enum FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED = 0; + */ + const FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED = 0; + /** + * `[0-9]` (radix of 10) + * + * Generated from protobuf enum NUMERIC = 1; + */ + const NUMERIC = 1; + /** + * `[0-9A-F]` (radix of 16) + * + * Generated from protobuf enum HEXADECIMAL = 2; + */ + const HEXADECIMAL = 2; + /** + * `[0-9A-Z]` (radix of 36) + * + * Generated from protobuf enum UPPER_CASE_ALPHA_NUMERIC = 3; + */ + const UPPER_CASE_ALPHA_NUMERIC = 3; + /** + * `[0-9A-Za-z]` (radix of 62) + * + * Generated from protobuf enum ALPHA_NUMERIC = 4; + */ + const ALPHA_NUMERIC = 4; + + private static $valueToName = [ + self::FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED => 'FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED', + self::NUMERIC => 'NUMERIC', + self::HEXADECIMAL => 'HEXADECIMAL', + self::UPPER_CASE_ALPHA_NUMERIC => 'UPPER_CASE_ALPHA_NUMERIC', + self::ALPHA_NUMERIC => 'ALPHA_NUMERIC', + ]; + + 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(FfxCommonNativeAlphabet::class, \Google\Cloud\Dlp\V2\CryptoReplaceFfxFpeConfig_FfxCommonNativeAlphabet::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType.php new file mode 100644 index 000000000000..741a2b367937 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType.php @@ -0,0 +1,427 @@ +google.privacy.dlp.v2.CustomInfoType + */ +class CustomInfoType extends \Google\Protobuf\Internal\Message +{ + /** + * CustomInfoType can either be a new infoType, or an extension of built-in + * infoType, when the name matches one of existing infoTypes and that infoType + * is specified in `InspectContent.info_types` field. Specifying the latter + * adds findings to the one detected by the system. If built-in info type is + * not specified in `InspectContent.info_types` list then the name is treated + * as a custom info type. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + */ + protected $info_type = null; + /** + * Likelihood to return for this CustomInfoType. This base value can be + * altered by a detection rule if the finding meets the criteria specified by + * the rule. Defaults to `VERY_LIKELY` if not specified. + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood likelihood = 6; + */ + protected $likelihood = 0; + /** + * Set of detection rules to apply to all findings of this CustomInfoType. + * Rules are applied in order that they are specified. Not supported for the + * `surrogate_type` CustomInfoType. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.CustomInfoType.DetectionRule detection_rules = 7; + */ + private $detection_rules; + /** + * If set to EXCLUSION_TYPE_EXCLUDE this infoType will not cause a finding + * to be returned. It still can be used for rules matching. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.ExclusionType exclusion_type = 8; + */ + protected $exclusion_type = 0; + /** + * Sensitivity for this CustomInfoType. If this CustomInfoType extends an + * existing InfoType, the sensitivity here will take precedence over that of + * the original InfoType. If unset for a CustomInfoType, it will default to + * HIGH. + * This only applies to data profiling. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 9; + */ + protected $sensitivity_score = null; + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InfoType $info_type + * CustomInfoType can either be a new infoType, or an extension of built-in + * infoType, when the name matches one of existing infoTypes and that infoType + * is specified in `InspectContent.info_types` field. Specifying the latter + * adds findings to the one detected by the system. If built-in info type is + * not specified in `InspectContent.info_types` list then the name is treated + * as a custom info type. + * @type int $likelihood + * Likelihood to return for this CustomInfoType. This base value can be + * altered by a detection rule if the finding meets the criteria specified by + * the rule. Defaults to `VERY_LIKELY` if not specified. + * @type \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary $dictionary + * A list of phrases to detect as a CustomInfoType. + * @type \Google\Cloud\Dlp\V2\CustomInfoType\Regex $regex + * Regular expression based CustomInfoType. + * @type \Google\Cloud\Dlp\V2\CustomInfoType\SurrogateType $surrogate_type + * Message for detecting output from deidentification transformations that + * support reversing. + * @type \Google\Cloud\Dlp\V2\StoredType $stored_type + * Load an existing `StoredInfoType` resource for use in + * `InspectDataSource`. Not currently supported in `InspectContent`. + * @type array<\Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule>|\Google\Protobuf\Internal\RepeatedField $detection_rules + * Set of detection rules to apply to all findings of this CustomInfoType. + * Rules are applied in order that they are specified. Not supported for the + * `surrogate_type` CustomInfoType. + * @type int $exclusion_type + * If set to EXCLUSION_TYPE_EXCLUDE this infoType will not cause a finding + * to be returned. It still can be used for rules matching. + * @type \Google\Cloud\Dlp\V2\SensitivityScore $sensitivity_score + * Sensitivity for this CustomInfoType. If this CustomInfoType extends an + * existing InfoType, the sensitivity here will take precedence over that of + * the original InfoType. If unset for a CustomInfoType, it will default to + * HIGH. + * This only applies to data profiling. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * CustomInfoType can either be a new infoType, or an extension of built-in + * infoType, when the name matches one of existing infoTypes and that infoType + * is specified in `InspectContent.info_types` field. Specifying the latter + * adds findings to the one detected by the system. If built-in info type is + * not specified in `InspectContent.info_types` list then the name is treated + * as a custom info type. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getInfoType() + { + return $this->info_type; + } + + public function hasInfoType() + { + return isset($this->info_type); + } + + public function clearInfoType() + { + unset($this->info_type); + } + + /** + * CustomInfoType can either be a new infoType, or an extension of built-in + * infoType, when the name matches one of existing infoTypes and that infoType + * is specified in `InspectContent.info_types` field. Specifying the latter + * adds findings to the one detected by the system. If built-in info type is + * not specified in `InspectContent.info_types` list then the name is treated + * as a custom info type. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_type = $var; + + return $this; + } + + /** + * Likelihood to return for this CustomInfoType. This base value can be + * altered by a detection rule if the finding meets the criteria specified by + * the rule. Defaults to `VERY_LIKELY` if not specified. + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood likelihood = 6; + * @return int + */ + public function getLikelihood() + { + return $this->likelihood; + } + + /** + * Likelihood to return for this CustomInfoType. This base value can be + * altered by a detection rule if the finding meets the criteria specified by + * the rule. Defaults to `VERY_LIKELY` if not specified. + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood likelihood = 6; + * @param int $var + * @return $this + */ + public function setLikelihood($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\Likelihood::class); + $this->likelihood = $var; + + return $this; + } + + /** + * A list of phrases to detect as a CustomInfoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary dictionary = 2; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary|null + */ + public function getDictionary() + { + return $this->readOneof(2); + } + + public function hasDictionary() + { + return $this->hasOneof(2); + } + + /** + * A list of phrases to detect as a CustomInfoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary dictionary = 2; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary $var + * @return $this + */ + public function setDictionary($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Regular expression based CustomInfoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex regex = 3; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\Regex|null + */ + public function getRegex() + { + return $this->readOneof(3); + } + + public function hasRegex() + { + return $this->hasOneof(3); + } + + /** + * Regular expression based CustomInfoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex regex = 3; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\Regex $var + * @return $this + */ + public function setRegex($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Regex::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Message for detecting output from deidentification transformations that + * support reversing. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.SurrogateType surrogate_type = 4; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\SurrogateType|null + */ + public function getSurrogateType() + { + return $this->readOneof(4); + } + + public function hasSurrogateType() + { + return $this->hasOneof(4); + } + + /** + * Message for detecting output from deidentification transformations that + * support reversing. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.SurrogateType surrogate_type = 4; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\SurrogateType $var + * @return $this + */ + public function setSurrogateType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\SurrogateType::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Load an existing `StoredInfoType` resource for use in + * `InspectDataSource`. Not currently supported in `InspectContent`. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredType stored_type = 5; + * @return \Google\Cloud\Dlp\V2\StoredType|null + */ + public function getStoredType() + { + return $this->readOneof(5); + } + + public function hasStoredType() + { + return $this->hasOneof(5); + } + + /** + * Load an existing `StoredInfoType` resource for use in + * `InspectDataSource`. Not currently supported in `InspectContent`. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredType stored_type = 5; + * @param \Google\Cloud\Dlp\V2\StoredType $var + * @return $this + */ + public function setStoredType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StoredType::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * Set of detection rules to apply to all findings of this CustomInfoType. + * Rules are applied in order that they are specified. Not supported for the + * `surrogate_type` CustomInfoType. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.CustomInfoType.DetectionRule detection_rules = 7; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDetectionRules() + { + return $this->detection_rules; + } + + /** + * Set of detection rules to apply to all findings of this CustomInfoType. + * Rules are applied in order that they are specified. Not supported for the + * `surrogate_type` CustomInfoType. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.CustomInfoType.DetectionRule detection_rules = 7; + * @param array<\Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDetectionRules($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule::class); + $this->detection_rules = $arr; + + return $this; + } + + /** + * If set to EXCLUSION_TYPE_EXCLUDE this infoType will not cause a finding + * to be returned. It still can be used for rules matching. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.ExclusionType exclusion_type = 8; + * @return int + */ + public function getExclusionType() + { + return $this->exclusion_type; + } + + /** + * If set to EXCLUSION_TYPE_EXCLUDE this infoType will not cause a finding + * to be returned. It still can be used for rules matching. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.ExclusionType exclusion_type = 8; + * @param int $var + * @return $this + */ + public function setExclusionType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\CustomInfoType\ExclusionType::class); + $this->exclusion_type = $var; + + return $this; + } + + /** + * Sensitivity for this CustomInfoType. If this CustomInfoType extends an + * existing InfoType, the sensitivity here will take precedence over that of + * the original InfoType. If unset for a CustomInfoType, it will default to + * HIGH. + * This only applies to data profiling. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 9; + * @return \Google\Cloud\Dlp\V2\SensitivityScore|null + */ + public function getSensitivityScore() + { + return $this->sensitivity_score; + } + + public function hasSensitivityScore() + { + return isset($this->sensitivity_score); + } + + public function clearSensitivityScore() + { + unset($this->sensitivity_score); + } + + /** + * Sensitivity for this CustomInfoType. If this CustomInfoType extends an + * existing InfoType, the sensitivity here will take precedence over that of + * the original InfoType. If unset for a CustomInfoType, it will default to + * HIGH. + * This only applies to data profiling. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 9; + * @param \Google\Cloud\Dlp\V2\SensitivityScore $var + * @return $this + */ + public function setSensitivityScore($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SensitivityScore::class); + $this->sensitivity_score = $var; + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule.php new file mode 100644 index 000000000000..88b6f48d1a0d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule.php @@ -0,0 +1,81 @@ +google.privacy.dlp.v2.CustomInfoType.DetectionRule + */ +class DetectionRule extends \Google\Protobuf\Internal\Message +{ + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule $hotword_rule + * Hotword-based detection rule. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Hotword-based detection rule. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.HotwordRule hotword_rule = 1; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule|null + */ + public function getHotwordRule() + { + return $this->readOneof(1); + } + + public function hasHotwordRule() + { + return $this->hasOneof(1); + } + + /** + * Hotword-based detection rule. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.HotwordRule hotword_rule = 1; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule $var + * @return $this + */ + public function setHotwordRule($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(DetectionRule::class, \Google\Cloud\Dlp\V2\CustomInfoType_DetectionRule::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/HotwordRule.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/HotwordRule.php new file mode 100644 index 000000000000..55e0494d670f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/HotwordRule.php @@ -0,0 +1,213 @@ +google.privacy.dlp.v2.CustomInfoType.DetectionRule.HotwordRule + */ +class HotwordRule extends \Google\Protobuf\Internal\Message +{ + /** + * Regular expression pattern defining what qualifies as a hotword. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex hotword_regex = 1; + */ + protected $hotword_regex = null; + /** + * Range of characters within which the entire hotword must reside. + * The total length of the window cannot exceed 1000 characters. + * The finding itself will be included in the window, so that hotwords can + * be used to match substrings of the finding itself. Suppose you + * want Cloud DLP to promote the likelihood of the phone number + * regex "\(\d{3}\) \d{3}-\d{4}" if the area code is known to be the + * area code of a company's office. In this case, use the hotword regex + * "\(xxx\)", where "xxx" is the area code in question. + * For tabular data, if you want to modify the likelihood of an entire + * column of findngs, see + * [Hotword example: Set the match likelihood of a table column] + * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity proximity = 2; + */ + protected $proximity = null; + /** + * Likelihood adjustment to apply to all matching findings. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.LikelihoodAdjustment likelihood_adjustment = 3; + */ + protected $likelihood_adjustment = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\CustomInfoType\Regex $hotword_regex + * Regular expression pattern defining what qualifies as a hotword. + * @type \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity $proximity + * Range of characters within which the entire hotword must reside. + * The total length of the window cannot exceed 1000 characters. + * The finding itself will be included in the window, so that hotwords can + * be used to match substrings of the finding itself. Suppose you + * want Cloud DLP to promote the likelihood of the phone number + * regex "\(\d{3}\) \d{3}-\d{4}" if the area code is known to be the + * area code of a company's office. In this case, use the hotword regex + * "\(xxx\)", where "xxx" is the area code in question. + * For tabular data, if you want to modify the likelihood of an entire + * column of findngs, see + * [Hotword example: Set the match likelihood of a table column] + * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). + * @type \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\LikelihoodAdjustment $likelihood_adjustment + * Likelihood adjustment to apply to all matching findings. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Regular expression pattern defining what qualifies as a hotword. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex hotword_regex = 1; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\Regex|null + */ + public function getHotwordRegex() + { + return $this->hotword_regex; + } + + public function hasHotwordRegex() + { + return isset($this->hotword_regex); + } + + public function clearHotwordRegex() + { + unset($this->hotword_regex); + } + + /** + * Regular expression pattern defining what qualifies as a hotword. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex hotword_regex = 1; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\Regex $var + * @return $this + */ + public function setHotwordRegex($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Regex::class); + $this->hotword_regex = $var; + + return $this; + } + + /** + * Range of characters within which the entire hotword must reside. + * The total length of the window cannot exceed 1000 characters. + * The finding itself will be included in the window, so that hotwords can + * be used to match substrings of the finding itself. Suppose you + * want Cloud DLP to promote the likelihood of the phone number + * regex "\(\d{3}\) \d{3}-\d{4}" if the area code is known to be the + * area code of a company's office. In this case, use the hotword regex + * "\(xxx\)", where "xxx" is the area code in question. + * For tabular data, if you want to modify the likelihood of an entire + * column of findngs, see + * [Hotword example: Set the match likelihood of a table column] + * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity proximity = 2; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity|null + */ + public function getProximity() + { + return $this->proximity; + } + + public function hasProximity() + { + return isset($this->proximity); + } + + public function clearProximity() + { + unset($this->proximity); + } + + /** + * Range of characters within which the entire hotword must reside. + * The total length of the window cannot exceed 1000 characters. + * The finding itself will be included in the window, so that hotwords can + * be used to match substrings of the finding itself. Suppose you + * want Cloud DLP to promote the likelihood of the phone number + * regex "\(\d{3}\) \d{3}-\d{4}" if the area code is known to be the + * area code of a company's office. In this case, use the hotword regex + * "\(xxx\)", where "xxx" is the area code in question. + * For tabular data, if you want to modify the likelihood of an entire + * column of findngs, see + * [Hotword example: Set the match likelihood of a table column] + * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity proximity = 2; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity $var + * @return $this + */ + public function setProximity($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity::class); + $this->proximity = $var; + + return $this; + } + + /** + * Likelihood adjustment to apply to all matching findings. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.LikelihoodAdjustment likelihood_adjustment = 3; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\LikelihoodAdjustment|null + */ + public function getLikelihoodAdjustment() + { + return $this->likelihood_adjustment; + } + + public function hasLikelihoodAdjustment() + { + return isset($this->likelihood_adjustment); + } + + public function clearLikelihoodAdjustment() + { + unset($this->likelihood_adjustment); + } + + /** + * Likelihood adjustment to apply to all matching findings. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.LikelihoodAdjustment likelihood_adjustment = 3; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\LikelihoodAdjustment $var + * @return $this + */ + public function setLikelihoodAdjustment($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\LikelihoodAdjustment::class); + $this->likelihood_adjustment = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(HotwordRule::class, \Google\Cloud\Dlp\V2\CustomInfoType_DetectionRule_HotwordRule::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/LikelihoodAdjustment.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/LikelihoodAdjustment.php new file mode 100644 index 000000000000..9532708c58cf --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/LikelihoodAdjustment.php @@ -0,0 +1,133 @@ +google.privacy.dlp.v2.CustomInfoType.DetectionRule.LikelihoodAdjustment + */ +class LikelihoodAdjustment extends \Google\Protobuf\Internal\Message +{ + protected $adjustment; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $fixed_likelihood + * Set the likelihood of a finding to a fixed value. + * @type int $relative_likelihood + * Increase or decrease the likelihood by the specified number of + * levels. For example, if a finding would be `POSSIBLE` without the + * detection rule and `relative_likelihood` is 1, then it is upgraded to + * `LIKELY`, while a value of -1 would downgrade it to `UNLIKELY`. + * Likelihood may never drop below `VERY_UNLIKELY` or exceed + * `VERY_LIKELY`, so applying an adjustment of 1 followed by an + * adjustment of -1 when base likelihood is `VERY_LIKELY` will result in + * a final likelihood of `LIKELY`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Set the likelihood of a finding to a fixed value. + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood fixed_likelihood = 1; + * @return int + */ + public function getFixedLikelihood() + { + return $this->readOneof(1); + } + + public function hasFixedLikelihood() + { + return $this->hasOneof(1); + } + + /** + * Set the likelihood of a finding to a fixed value. + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood fixed_likelihood = 1; + * @param int $var + * @return $this + */ + public function setFixedLikelihood($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\Likelihood::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Increase or decrease the likelihood by the specified number of + * levels. For example, if a finding would be `POSSIBLE` without the + * detection rule and `relative_likelihood` is 1, then it is upgraded to + * `LIKELY`, while a value of -1 would downgrade it to `UNLIKELY`. + * Likelihood may never drop below `VERY_UNLIKELY` or exceed + * `VERY_LIKELY`, so applying an adjustment of 1 followed by an + * adjustment of -1 when base likelihood is `VERY_LIKELY` will result in + * a final likelihood of `LIKELY`. + * + * Generated from protobuf field int32 relative_likelihood = 2; + * @return int + */ + public function getRelativeLikelihood() + { + return $this->readOneof(2); + } + + public function hasRelativeLikelihood() + { + return $this->hasOneof(2); + } + + /** + * Increase or decrease the likelihood by the specified number of + * levels. For example, if a finding would be `POSSIBLE` without the + * detection rule and `relative_likelihood` is 1, then it is upgraded to + * `LIKELY`, while a value of -1 would downgrade it to `UNLIKELY`. + * Likelihood may never drop below `VERY_UNLIKELY` or exceed + * `VERY_LIKELY`, so applying an adjustment of 1 followed by an + * adjustment of -1 when base likelihood is `VERY_LIKELY` will result in + * a final likelihood of `LIKELY`. + * + * Generated from protobuf field int32 relative_likelihood = 2; + * @param int $var + * @return $this + */ + public function setRelativeLikelihood($var) + { + GPBUtil::checkInt32($var); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getAdjustment() + { + return $this->whichOneof("adjustment"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(LikelihoodAdjustment::class, \Google\Cloud\Dlp\V2\CustomInfoType_DetectionRule_LikelihoodAdjustment::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/Proximity.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/Proximity.php new file mode 100644 index 000000000000..65e1f624e4f7 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/Proximity.php @@ -0,0 +1,121 @@ +google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity + */ +class Proximity extends \Google\Protobuf\Internal\Message +{ + /** + * Number of characters before the finding to consider. For tabular data, + * if you want to modify the likelihood of an entire column of findngs, + * set this to 1. For more information, see + * [Hotword example: Set the match likelihood of a table column] + * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). + * + * Generated from protobuf field int32 window_before = 1; + */ + protected $window_before = 0; + /** + * Number of characters after the finding to consider. + * + * Generated from protobuf field int32 window_after = 2; + */ + protected $window_after = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $window_before + * Number of characters before the finding to consider. For tabular data, + * if you want to modify the likelihood of an entire column of findngs, + * set this to 1. For more information, see + * [Hotword example: Set the match likelihood of a table column] + * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). + * @type int $window_after + * Number of characters after the finding to consider. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Number of characters before the finding to consider. For tabular data, + * if you want to modify the likelihood of an entire column of findngs, + * set this to 1. For more information, see + * [Hotword example: Set the match likelihood of a table column] + * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). + * + * Generated from protobuf field int32 window_before = 1; + * @return int + */ + public function getWindowBefore() + { + return $this->window_before; + } + + /** + * Number of characters before the finding to consider. For tabular data, + * if you want to modify the likelihood of an entire column of findngs, + * set this to 1. For more information, see + * [Hotword example: Set the match likelihood of a table column] + * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). + * + * Generated from protobuf field int32 window_before = 1; + * @param int $var + * @return $this + */ + public function setWindowBefore($var) + { + GPBUtil::checkInt32($var); + $this->window_before = $var; + + return $this; + } + + /** + * Number of characters after the finding to consider. + * + * Generated from protobuf field int32 window_after = 2; + * @return int + */ + public function getWindowAfter() + { + return $this->window_after; + } + + /** + * Number of characters after the finding to consider. + * + * Generated from protobuf field int32 window_after = 2; + * @param int $var + * @return $this + */ + public function setWindowAfter($var) + { + GPBUtil::checkInt32($var); + $this->window_after = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Proximity::class, \Google\Cloud\Dlp\V2\CustomInfoType_DetectionRule_Proximity::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary.php new file mode 100644 index 000000000000..049f1f42dff4 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary.php @@ -0,0 +1,134 @@ +google.privacy.dlp.v2.CustomInfoType.Dictionary + */ +class Dictionary extends \Google\Protobuf\Internal\Message +{ + protected $source; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList $word_list + * List of words or phrases to search for. + * @type \Google\Cloud\Dlp\V2\CloudStoragePath $cloud_storage_path + * Newline-delimited file of words in Cloud Storage. Only a single file + * is accepted. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * List of words or phrases to search for. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary.WordList word_list = 1; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList|null + */ + public function getWordList() + { + return $this->readOneof(1); + } + + public function hasWordList() + { + return $this->hasOneof(1); + } + + /** + * List of words or phrases to search for. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary.WordList word_list = 1; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList $var + * @return $this + */ + public function setWordList($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Newline-delimited file of words in Cloud Storage. Only a single file + * is accepted. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStoragePath cloud_storage_path = 3; + * @return \Google\Cloud\Dlp\V2\CloudStoragePath|null + */ + public function getCloudStoragePath() + { + return $this->readOneof(3); + } + + public function hasCloudStoragePath() + { + return $this->hasOneof(3); + } + + /** + * Newline-delimited file of words in Cloud Storage. Only a single file + * is accepted. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStoragePath cloud_storage_path = 3; + * @param \Google\Cloud\Dlp\V2\CloudStoragePath $var + * @return $this + */ + public function setCloudStoragePath($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudStoragePath::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getSource() + { + return $this->whichOneof("source"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Dictionary::class, \Google\Cloud\Dlp\V2\CustomInfoType_Dictionary::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary/WordList.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary/WordList.php new file mode 100644 index 000000000000..2b8f09b8a095 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary/WordList.php @@ -0,0 +1,78 @@ +google.privacy.dlp.v2.CustomInfoType.Dictionary.WordList + */ +class WordList extends \Google\Protobuf\Internal\Message +{ + /** + * Words or phrases defining the dictionary. The dictionary must contain + * at least one phrase and every phrase must contain at least 2 characters + * that are letters or digits. [required] + * + * Generated from protobuf field repeated string words = 1; + */ + private $words; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $words + * Words or phrases defining the dictionary. The dictionary must contain + * at least one phrase and every phrase must contain at least 2 characters + * that are letters or digits. [required] + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Words or phrases defining the dictionary. The dictionary must contain + * at least one phrase and every phrase must contain at least 2 characters + * that are letters or digits. [required] + * + * Generated from protobuf field repeated string words = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getWords() + { + return $this->words; + } + + /** + * Words or phrases defining the dictionary. The dictionary must contain + * at least one phrase and every phrase must contain at least 2 characters + * that are letters or digits. [required] + * + * Generated from protobuf field repeated string words = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setWords($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->words = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(WordList::class, \Google\Cloud\Dlp\V2\CustomInfoType_Dictionary_WordList::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/ExclusionType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/ExclusionType.php new file mode 100644 index 000000000000..7c0cee8c1898 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/ExclusionType.php @@ -0,0 +1,58 @@ +google.privacy.dlp.v2.CustomInfoType.ExclusionType + */ +class ExclusionType +{ + /** + * A finding of this custom info type will not be excluded from results. + * + * Generated from protobuf enum EXCLUSION_TYPE_UNSPECIFIED = 0; + */ + const EXCLUSION_TYPE_UNSPECIFIED = 0; + /** + * A finding of this custom info type will be excluded from final results, + * but can still affect rule execution. + * + * Generated from protobuf enum EXCLUSION_TYPE_EXCLUDE = 1; + */ + const EXCLUSION_TYPE_EXCLUDE = 1; + + private static $valueToName = [ + self::EXCLUSION_TYPE_UNSPECIFIED => 'EXCLUSION_TYPE_UNSPECIFIED', + self::EXCLUSION_TYPE_EXCLUDE => 'EXCLUSION_TYPE_EXCLUDE', + ]; + + 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(ExclusionType::class, \Google\Cloud\Dlp\V2\CustomInfoType_ExclusionType::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Regex.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Regex.php new file mode 100644 index 000000000000..b54260ff0a67 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Regex.php @@ -0,0 +1,116 @@ +google.privacy.dlp.v2.CustomInfoType.Regex + */ +class Regex extends \Google\Protobuf\Internal\Message +{ + /** + * Pattern defining the regular expression. Its syntax + * (https://github.com/google/re2/wiki/Syntax) can be found under the + * google/re2 repository on GitHub. + * + * Generated from protobuf field string pattern = 1; + */ + protected $pattern = ''; + /** + * The index of the submatch to extract as findings. When not + * specified, the entire match is returned. No more than 3 may be included. + * + * Generated from protobuf field repeated int32 group_indexes = 2; + */ + private $group_indexes; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $pattern + * Pattern defining the regular expression. Its syntax + * (https://github.com/google/re2/wiki/Syntax) can be found under the + * google/re2 repository on GitHub. + * @type array|\Google\Protobuf\Internal\RepeatedField $group_indexes + * The index of the submatch to extract as findings. When not + * specified, the entire match is returned. No more than 3 may be included. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Pattern defining the regular expression. Its syntax + * (https://github.com/google/re2/wiki/Syntax) can be found under the + * google/re2 repository on GitHub. + * + * Generated from protobuf field string pattern = 1; + * @return string + */ + public function getPattern() + { + return $this->pattern; + } + + /** + * Pattern defining the regular expression. Its syntax + * (https://github.com/google/re2/wiki/Syntax) can be found under the + * google/re2 repository on GitHub. + * + * Generated from protobuf field string pattern = 1; + * @param string $var + * @return $this + */ + public function setPattern($var) + { + GPBUtil::checkString($var, True); + $this->pattern = $var; + + return $this; + } + + /** + * The index of the submatch to extract as findings. When not + * specified, the entire match is returned. No more than 3 may be included. + * + * Generated from protobuf field repeated int32 group_indexes = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getGroupIndexes() + { + return $this->group_indexes; + } + + /** + * The index of the submatch to extract as findings. When not + * specified, the entire match is returned. No more than 3 may be included. + * + * Generated from protobuf field repeated int32 group_indexes = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setGroupIndexes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); + $this->group_indexes = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Regex::class, \Google\Cloud\Dlp\V2\CustomInfoType_Regex::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/SurrogateType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/SurrogateType.php new file mode 100644 index 000000000000..688c5e044728 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/SurrogateType.php @@ -0,0 +1,43 @@ +google.privacy.dlp.v2.CustomInfoType.SurrogateType + */ +class SurrogateType extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SurrogateType::class, \Google\Cloud\Dlp\V2\CustomInfoType_SurrogateType::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction.php new file mode 100644 index 000000000000..250af007bcf6 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction.php @@ -0,0 +1,108 @@ +google.privacy.dlp.v2.DataProfileAction + */ +class DataProfileAction extends \Google\Protobuf\Internal\Message +{ + protected $action; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DataProfileAction\Export $export_data + * Export data profiles into a provided location. + * @type \Google\Cloud\Dlp\V2\DataProfileAction\PubSubNotification $pub_sub_notification + * Publish a message into the Pub/Sub topic. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Export data profiles into a provided location. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.Export export_data = 1; + * @return \Google\Cloud\Dlp\V2\DataProfileAction\Export|null + */ + public function getExportData() + { + return $this->readOneof(1); + } + + public function hasExportData() + { + return $this->hasOneof(1); + } + + /** + * Export data profiles into a provided location. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.Export export_data = 1; + * @param \Google\Cloud\Dlp\V2\DataProfileAction\Export $var + * @return $this + */ + public function setExportData($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfileAction\Export::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Publish a message into the Pub/Sub topic. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.PubSubNotification pub_sub_notification = 2; + * @return \Google\Cloud\Dlp\V2\DataProfileAction\PubSubNotification|null + */ + public function getPubSubNotification() + { + return $this->readOneof(2); + } + + public function hasPubSubNotification() + { + return $this->hasOneof(2); + } + + /** + * Publish a message into the Pub/Sub topic. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.PubSubNotification pub_sub_notification = 2; + * @param \Google\Cloud\Dlp\V2\DataProfileAction\PubSubNotification $var + * @return $this + */ + public function setPubSubNotification($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfileAction\PubSubNotification::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getAction() + { + return $this->whichOneof("action"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/EventType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/EventType.php new file mode 100644 index 000000000000..0c49c9ad18c9 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/EventType.php @@ -0,0 +1,80 @@ +google.privacy.dlp.v2.DataProfileAction.EventType + */ +class EventType +{ + /** + * Unused. + * + * Generated from protobuf enum EVENT_TYPE_UNSPECIFIED = 0; + */ + const EVENT_TYPE_UNSPECIFIED = 0; + /** + * New profile (not a re-profile). + * + * Generated from protobuf enum NEW_PROFILE = 1; + */ + const NEW_PROFILE = 1; + /** + * One of the following profile metrics changed: Data risk score, + * Sensitivity score, Resource visibility, Encryption type, Predicted + * infoTypes, Other infoTypes + * + * Generated from protobuf enum CHANGED_PROFILE = 2; + */ + const CHANGED_PROFILE = 2; + /** + * Table data risk score or sensitivity score increased. + * + * Generated from protobuf enum SCORE_INCREASED = 3; + */ + const SCORE_INCREASED = 3; + /** + * A user (non-internal) error occurred. + * + * Generated from protobuf enum ERROR_CHANGED = 4; + */ + const ERROR_CHANGED = 4; + + private static $valueToName = [ + self::EVENT_TYPE_UNSPECIFIED => 'EVENT_TYPE_UNSPECIFIED', + self::NEW_PROFILE => 'NEW_PROFILE', + self::CHANGED_PROFILE => 'CHANGED_PROFILE', + self::SCORE_INCREASED => 'SCORE_INCREASED', + self::ERROR_CHANGED => 'ERROR_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(EventType::class, \Google\Cloud\Dlp\V2\DataProfileAction_EventType::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/Export.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/Export.php new file mode 100644 index 000000000000..f406b2dec6cf --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/Export.php @@ -0,0 +1,113 @@ +google.privacy.dlp.v2.DataProfileAction.Export + */ +class Export extends \Google\Protobuf\Internal\Message +{ + /** + * Store all table and column profiles in an existing table or a new table + * in an existing dataset. Each re-generation will result in new rows in + * BigQuery. Data is inserted using [streaming + * insert](https://cloud.google.com/blog/products/bigquery/life-of-a-bigquery-streaming-insert) + * and so data may be in the buffer for a period of time after the profile + * has finished. The Pub/Sub notification is sent before the streaming + * buffer is guaranteed to be written, so data may not be instantly + * visible to queries by the time your topic receives the Pub/Sub + * notification. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable profile_table = 1; + */ + protected $profile_table = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\BigQueryTable $profile_table + * Store all table and column profiles in an existing table or a new table + * in an existing dataset. Each re-generation will result in new rows in + * BigQuery. Data is inserted using [streaming + * insert](https://cloud.google.com/blog/products/bigquery/life-of-a-bigquery-streaming-insert) + * and so data may be in the buffer for a period of time after the profile + * has finished. The Pub/Sub notification is sent before the streaming + * buffer is guaranteed to be written, so data may not be instantly + * visible to queries by the time your topic receives the Pub/Sub + * notification. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Store all table and column profiles in an existing table or a new table + * in an existing dataset. Each re-generation will result in new rows in + * BigQuery. Data is inserted using [streaming + * insert](https://cloud.google.com/blog/products/bigquery/life-of-a-bigquery-streaming-insert) + * and so data may be in the buffer for a period of time after the profile + * has finished. The Pub/Sub notification is sent before the streaming + * buffer is guaranteed to be written, so data may not be instantly + * visible to queries by the time your topic receives the Pub/Sub + * notification. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable profile_table = 1; + * @return \Google\Cloud\Dlp\V2\BigQueryTable|null + */ + public function getProfileTable() + { + return $this->profile_table; + } + + public function hasProfileTable() + { + return isset($this->profile_table); + } + + public function clearProfileTable() + { + unset($this->profile_table); + } + + /** + * Store all table and column profiles in an existing table or a new table + * in an existing dataset. Each re-generation will result in new rows in + * BigQuery. Data is inserted using [streaming + * insert](https://cloud.google.com/blog/products/bigquery/life-of-a-bigquery-streaming-insert) + * and so data may be in the buffer for a period of time after the profile + * has finished. The Pub/Sub notification is sent before the streaming + * buffer is guaranteed to be written, so data may not be instantly + * visible to queries by the time your topic receives the Pub/Sub + * notification. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable profile_table = 1; + * @param \Google\Cloud\Dlp\V2\BigQueryTable $var + * @return $this + */ + public function setProfileTable($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); + $this->profile_table = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Export::class, \Google\Cloud\Dlp\V2\DataProfileAction_Export::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification.php new file mode 100644 index 000000000000..57a33ee43c26 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification.php @@ -0,0 +1,204 @@ +google.privacy.dlp.v2.DataProfileAction.PubSubNotification + */ +class PubSubNotification extends \Google\Protobuf\Internal\Message +{ + /** + * Cloud Pub/Sub topic to send notifications to. + * Format is projects/{project}/topics/{topic}. + * + * Generated from protobuf field string topic = 1; + */ + protected $topic = ''; + /** + * The type of event that triggers a Pub/Sub. At most one + * `PubSubNotification` per EventType is permitted. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.EventType event = 2; + */ + protected $event = 0; + /** + * Conditions (e.g., data risk or sensitivity level) for triggering a + * Pub/Sub. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition pubsub_condition = 3; + */ + protected $pubsub_condition = null; + /** + * How much data to include in the Pub/Sub message. If the user wishes to + * limit the size of the message, they can use resource_name and fetch the + * profile fields they wish to. Per table profile (not per column). + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.PubSubNotification.DetailLevel detail_of_message = 4; + */ + protected $detail_of_message = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $topic + * Cloud Pub/Sub topic to send notifications to. + * Format is projects/{project}/topics/{topic}. + * @type int $event + * The type of event that triggers a Pub/Sub. At most one + * `PubSubNotification` per EventType is permitted. + * @type \Google\Cloud\Dlp\V2\DataProfilePubSubCondition $pubsub_condition + * Conditions (e.g., data risk or sensitivity level) for triggering a + * Pub/Sub. + * @type int $detail_of_message + * How much data to include in the Pub/Sub message. If the user wishes to + * limit the size of the message, they can use resource_name and fetch the + * profile fields they wish to. Per table profile (not per column). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Cloud Pub/Sub topic to send notifications to. + * Format is projects/{project}/topics/{topic}. + * + * Generated from protobuf field string topic = 1; + * @return string + */ + public function getTopic() + { + return $this->topic; + } + + /** + * Cloud Pub/Sub topic to send notifications to. + * Format is projects/{project}/topics/{topic}. + * + * Generated from protobuf field string topic = 1; + * @param string $var + * @return $this + */ + public function setTopic($var) + { + GPBUtil::checkString($var, True); + $this->topic = $var; + + return $this; + } + + /** + * The type of event that triggers a Pub/Sub. At most one + * `PubSubNotification` per EventType is permitted. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.EventType event = 2; + * @return int + */ + public function getEvent() + { + return $this->event; + } + + /** + * The type of event that triggers a Pub/Sub. At most one + * `PubSubNotification` per EventType is permitted. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.EventType event = 2; + * @param int $var + * @return $this + */ + public function setEvent($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileAction\EventType::class); + $this->event = $var; + + return $this; + } + + /** + * Conditions (e.g., data risk or sensitivity level) for triggering a + * Pub/Sub. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition pubsub_condition = 3; + * @return \Google\Cloud\Dlp\V2\DataProfilePubSubCondition|null + */ + public function getPubsubCondition() + { + return $this->pubsub_condition; + } + + public function hasPubsubCondition() + { + return isset($this->pubsub_condition); + } + + public function clearPubsubCondition() + { + unset($this->pubsub_condition); + } + + /** + * Conditions (e.g., data risk or sensitivity level) for triggering a + * Pub/Sub. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition pubsub_condition = 3; + * @param \Google\Cloud\Dlp\V2\DataProfilePubSubCondition $var + * @return $this + */ + public function setPubsubCondition($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition::class); + $this->pubsub_condition = $var; + + return $this; + } + + /** + * How much data to include in the Pub/Sub message. If the user wishes to + * limit the size of the message, they can use resource_name and fetch the + * profile fields they wish to. Per table profile (not per column). + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.PubSubNotification.DetailLevel detail_of_message = 4; + * @return int + */ + public function getDetailOfMessage() + { + return $this->detail_of_message; + } + + /** + * How much data to include in the Pub/Sub message. If the user wishes to + * limit the size of the message, they can use resource_name and fetch the + * profile fields they wish to. Per table profile (not per column). + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.PubSubNotification.DetailLevel detail_of_message = 4; + * @param int $var + * @return $this + */ + public function setDetailOfMessage($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileAction\PubSubNotification\DetailLevel::class); + $this->detail_of_message = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PubSubNotification::class, \Google\Cloud\Dlp\V2\DataProfileAction_PubSubNotification::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification/DetailLevel.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification/DetailLevel.php new file mode 100644 index 000000000000..3367ba04d4e6 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification/DetailLevel.php @@ -0,0 +1,64 @@ +google.privacy.dlp.v2.DataProfileAction.PubSubNotification.DetailLevel + */ +class DetailLevel +{ + /** + * Unused. + * + * Generated from protobuf enum DETAIL_LEVEL_UNSPECIFIED = 0; + */ + const DETAIL_LEVEL_UNSPECIFIED = 0; + /** + * The full table data profile. + * + * Generated from protobuf enum TABLE_PROFILE = 1; + */ + const TABLE_PROFILE = 1; + /** + * The name of the profiled resource. + * + * Generated from protobuf enum RESOURCE_NAME = 2; + */ + const RESOURCE_NAME = 2; + + private static $valueToName = [ + self::DETAIL_LEVEL_UNSPECIFIED => 'DETAIL_LEVEL_UNSPECIFIED', + self::TABLE_PROFILE => 'TABLE_PROFILE', + self::RESOURCE_NAME => 'RESOURCE_NAME', + ]; + + 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(DetailLevel::class, \Google\Cloud\Dlp\V2\DataProfileAction_PubSubNotification_DetailLevel::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileBigQueryRowSchema.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileBigQueryRowSchema.php new file mode 100644 index 000000000000..c2460dbf4913 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileBigQueryRowSchema.php @@ -0,0 +1,109 @@ +google.privacy.dlp.v2.DataProfileBigQueryRowSchema + */ +class DataProfileBigQueryRowSchema extends \Google\Protobuf\Internal\Message +{ + protected $data_profile; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\TableDataProfile $table_profile + * Table data profile column + * @type \Google\Cloud\Dlp\V2\ColumnDataProfile $column_profile + * Column data profile column + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Table data profile column + * + * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile table_profile = 1; + * @return \Google\Cloud\Dlp\V2\TableDataProfile|null + */ + public function getTableProfile() + { + return $this->readOneof(1); + } + + public function hasTableProfile() + { + return $this->hasOneof(1); + } + + /** + * Table data profile column + * + * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile table_profile = 1; + * @param \Google\Cloud\Dlp\V2\TableDataProfile $var + * @return $this + */ + public function setTableProfile($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableDataProfile::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Column data profile column + * + * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile column_profile = 2; + * @return \Google\Cloud\Dlp\V2\ColumnDataProfile|null + */ + public function getColumnProfile() + { + return $this->readOneof(2); + } + + public function hasColumnProfile() + { + return $this->hasOneof(2); + } + + /** + * Column data profile column + * + * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile column_profile = 2; + * @param \Google\Cloud\Dlp\V2\ColumnDataProfile $var + * @return $this + */ + public function setColumnProfile($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ColumnDataProfile::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getDataProfile() + { + return $this->whichOneof("data_profile"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileConfigSnapshot.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileConfigSnapshot.php new file mode 100644 index 000000000000..77e66e42ffe8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileConfigSnapshot.php @@ -0,0 +1,270 @@ +google.privacy.dlp.v2.DataProfileConfigSnapshot + */ +class DataProfileConfigSnapshot extends \Google\Protobuf\Internal\Message +{ + /** + * A copy of the inspection config used to generate this profile. This + * is a copy of the inspect_template specified in `DataProfileJobConfig`. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; + */ + protected $inspect_config = null; + /** + * A copy of the configuration used to generate this profile. This is + * deprecated, and the DiscoveryConfig field is preferred moving forward. + * DataProfileJobConfig will still be written here for Discovery in BigQuery + * for backwards compatibility, but will not be updated with new fields, while + * DiscoveryConfig will. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileJobConfig data_profile_job = 3 [deprecated = true]; + * @deprecated + */ + protected $data_profile_job = null; + /** + * A copy of the configuration used to generate this profile. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 4; + */ + protected $discovery_config = null; + /** + * Name of the inspection template used to generate this profile + * + * Generated from protobuf field string inspect_template_name = 5; + */ + protected $inspect_template_name = ''; + /** + * Timestamp when the template was modified + * + * Generated from protobuf field .google.protobuf.Timestamp inspect_template_modified_time = 6; + */ + protected $inspect_template_modified_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config + * A copy of the inspection config used to generate this profile. This + * is a copy of the inspect_template specified in `DataProfileJobConfig`. + * @type \Google\Cloud\Dlp\V2\DataProfileJobConfig $data_profile_job + * A copy of the configuration used to generate this profile. This is + * deprecated, and the DiscoveryConfig field is preferred moving forward. + * DataProfileJobConfig will still be written here for Discovery in BigQuery + * for backwards compatibility, but will not be updated with new fields, while + * DiscoveryConfig will. + * @type \Google\Cloud\Dlp\V2\DiscoveryConfig $discovery_config + * A copy of the configuration used to generate this profile. + * @type string $inspect_template_name + * Name of the inspection template used to generate this profile + * @type \Google\Protobuf\Timestamp $inspect_template_modified_time + * Timestamp when the template was modified + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A copy of the inspection config used to generate this profile. This + * is a copy of the inspect_template specified in `DataProfileJobConfig`. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; + * @return \Google\Cloud\Dlp\V2\InspectConfig|null + */ + public function getInspectConfig() + { + return $this->inspect_config; + } + + public function hasInspectConfig() + { + return isset($this->inspect_config); + } + + public function clearInspectConfig() + { + unset($this->inspect_config); + } + + /** + * A copy of the inspection config used to generate this profile. This + * is a copy of the inspect_template specified in `DataProfileJobConfig`. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; + * @param \Google\Cloud\Dlp\V2\InspectConfig $var + * @return $this + */ + public function setInspectConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); + $this->inspect_config = $var; + + return $this; + } + + /** + * A copy of the configuration used to generate this profile. This is + * deprecated, and the DiscoveryConfig field is preferred moving forward. + * DataProfileJobConfig will still be written here for Discovery in BigQuery + * for backwards compatibility, but will not be updated with new fields, while + * DiscoveryConfig will. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileJobConfig data_profile_job = 3 [deprecated = true]; + * @return \Google\Cloud\Dlp\V2\DataProfileJobConfig|null + * @deprecated + */ + public function getDataProfileJob() + { + @trigger_error('data_profile_job is deprecated.', E_USER_DEPRECATED); + return $this->data_profile_job; + } + + public function hasDataProfileJob() + { + @trigger_error('data_profile_job is deprecated.', E_USER_DEPRECATED); + return isset($this->data_profile_job); + } + + public function clearDataProfileJob() + { + @trigger_error('data_profile_job is deprecated.', E_USER_DEPRECATED); + unset($this->data_profile_job); + } + + /** + * A copy of the configuration used to generate this profile. This is + * deprecated, and the DiscoveryConfig field is preferred moving forward. + * DataProfileJobConfig will still be written here for Discovery in BigQuery + * for backwards compatibility, but will not be updated with new fields, while + * DiscoveryConfig will. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileJobConfig data_profile_job = 3 [deprecated = true]; + * @param \Google\Cloud\Dlp\V2\DataProfileJobConfig $var + * @return $this + * @deprecated + */ + public function setDataProfileJob($var) + { + @trigger_error('data_profile_job is deprecated.', E_USER_DEPRECATED); + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfileJobConfig::class); + $this->data_profile_job = $var; + + return $this; + } + + /** + * A copy of the configuration used to generate this profile. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 4; + * @return \Google\Cloud\Dlp\V2\DiscoveryConfig|null + */ + public function getDiscoveryConfig() + { + return $this->discovery_config; + } + + public function hasDiscoveryConfig() + { + return isset($this->discovery_config); + } + + public function clearDiscoveryConfig() + { + unset($this->discovery_config); + } + + /** + * A copy of the configuration used to generate this profile. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 4; + * @param \Google\Cloud\Dlp\V2\DiscoveryConfig $var + * @return $this + */ + public function setDiscoveryConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryConfig::class); + $this->discovery_config = $var; + + return $this; + } + + /** + * Name of the inspection template used to generate this profile + * + * Generated from protobuf field string inspect_template_name = 5; + * @return string + */ + public function getInspectTemplateName() + { + return $this->inspect_template_name; + } + + /** + * Name of the inspection template used to generate this profile + * + * Generated from protobuf field string inspect_template_name = 5; + * @param string $var + * @return $this + */ + public function setInspectTemplateName($var) + { + GPBUtil::checkString($var, True); + $this->inspect_template_name = $var; + + return $this; + } + + /** + * Timestamp when the template was modified + * + * Generated from protobuf field .google.protobuf.Timestamp inspect_template_modified_time = 6; + * @return \Google\Protobuf\Timestamp|null + */ + public function getInspectTemplateModifiedTime() + { + return $this->inspect_template_modified_time; + } + + public function hasInspectTemplateModifiedTime() + { + return isset($this->inspect_template_modified_time); + } + + public function clearInspectTemplateModifiedTime() + { + unset($this->inspect_template_modified_time); + } + + /** + * Timestamp when the template was modified + * + * Generated from protobuf field .google.protobuf.Timestamp inspect_template_modified_time = 6; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setInspectTemplateModifiedTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->inspect_template_modified_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileJobConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileJobConfig.php new file mode 100644 index 000000000000..d65e517fa702 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileJobConfig.php @@ -0,0 +1,240 @@ +google.privacy.dlp.v2.DataProfileJobConfig + */ +class DataProfileJobConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The data to scan. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileLocation location = 1; + */ + protected $location = null; + /** + * The project that will run the scan. The DLP service + * account that exists within this project must have access to all resources + * that are profiled, and the Cloud DLP API must be enabled. + * + * Generated from protobuf field string project_id = 5; + */ + protected $project_id = ''; + /** + * Detection logic for profile generation. + * Not all template features are used by profiles. FindingLimits, + * include_quote and exclude_info_types have no impact on + * data profiling. + * Multiple templates may be provided if there is data in multiple regions. + * At most one template must be specified per-region (including "global"). + * Each region is scanned using the applicable template. If no region-specific + * template is specified, but a "global" template is specified, it will be + * copied to that region and used instead. If no global or region-specific + * template is provided for a region with data, that region's data will not be + * scanned. + * For more information, see + * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. + * + * Generated from protobuf field repeated string inspect_templates = 7; + */ + private $inspect_templates; + /** + * Actions to execute at the completion of the job. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfileAction data_profile_actions = 6; + */ + private $data_profile_actions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DataProfileLocation $location + * The data to scan. + * @type string $project_id + * The project that will run the scan. The DLP service + * account that exists within this project must have access to all resources + * that are profiled, and the Cloud DLP API must be enabled. + * @type array|\Google\Protobuf\Internal\RepeatedField $inspect_templates + * Detection logic for profile generation. + * Not all template features are used by profiles. FindingLimits, + * include_quote and exclude_info_types have no impact on + * data profiling. + * Multiple templates may be provided if there is data in multiple regions. + * At most one template must be specified per-region (including "global"). + * Each region is scanned using the applicable template. If no region-specific + * template is specified, but a "global" template is specified, it will be + * copied to that region and used instead. If no global or region-specific + * template is provided for a region with data, that region's data will not be + * scanned. + * For more information, see + * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. + * @type array<\Google\Cloud\Dlp\V2\DataProfileAction>|\Google\Protobuf\Internal\RepeatedField $data_profile_actions + * Actions to execute at the completion of the job. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The data to scan. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileLocation location = 1; + * @return \Google\Cloud\Dlp\V2\DataProfileLocation|null + */ + public function getLocation() + { + return $this->location; + } + + public function hasLocation() + { + return isset($this->location); + } + + public function clearLocation() + { + unset($this->location); + } + + /** + * The data to scan. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileLocation location = 1; + * @param \Google\Cloud\Dlp\V2\DataProfileLocation $var + * @return $this + */ + public function setLocation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfileLocation::class); + $this->location = $var; + + return $this; + } + + /** + * The project that will run the scan. The DLP service + * account that exists within this project must have access to all resources + * that are profiled, and the Cloud DLP API must be enabled. + * + * Generated from protobuf field string project_id = 5; + * @return string + */ + public function getProjectId() + { + return $this->project_id; + } + + /** + * The project that will run the scan. The DLP service + * account that exists within this project must have access to all resources + * that are profiled, and the Cloud DLP API must be enabled. + * + * Generated from protobuf field string project_id = 5; + * @param string $var + * @return $this + */ + public function setProjectId($var) + { + GPBUtil::checkString($var, True); + $this->project_id = $var; + + return $this; + } + + /** + * Detection logic for profile generation. + * Not all template features are used by profiles. FindingLimits, + * include_quote and exclude_info_types have no impact on + * data profiling. + * Multiple templates may be provided if there is data in multiple regions. + * At most one template must be specified per-region (including "global"). + * Each region is scanned using the applicable template. If no region-specific + * template is specified, but a "global" template is specified, it will be + * copied to that region and used instead. If no global or region-specific + * template is provided for a region with data, that region's data will not be + * scanned. + * For more information, see + * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. + * + * Generated from protobuf field repeated string inspect_templates = 7; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getInspectTemplates() + { + return $this->inspect_templates; + } + + /** + * Detection logic for profile generation. + * Not all template features are used by profiles. FindingLimits, + * include_quote and exclude_info_types have no impact on + * data profiling. + * Multiple templates may be provided if there is data in multiple regions. + * At most one template must be specified per-region (including "global"). + * Each region is scanned using the applicable template. If no region-specific + * template is specified, but a "global" template is specified, it will be + * copied to that region and used instead. If no global or region-specific + * template is provided for a region with data, that region's data will not be + * scanned. + * For more information, see + * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. + * + * Generated from protobuf field repeated string inspect_templates = 7; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setInspectTemplates($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->inspect_templates = $arr; + + return $this; + } + + /** + * Actions to execute at the completion of the job. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfileAction data_profile_actions = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDataProfileActions() + { + return $this->data_profile_actions; + } + + /** + * Actions to execute at the completion of the job. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfileAction data_profile_actions = 6; + * @param array<\Google\Cloud\Dlp\V2\DataProfileAction>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDataProfileActions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DataProfileAction::class); + $this->data_profile_actions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileLocation.php new file mode 100644 index 000000000000..926bce69a79e --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileLocation.php @@ -0,0 +1,108 @@ +google.privacy.dlp.v2.DataProfileLocation + */ +class DataProfileLocation extends \Google\Protobuf\Internal\Message +{ + protected $location; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $organization_id + * The ID of an organization to scan. + * @type int|string $folder_id + * The ID of the Folder within an organization to scan. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The ID of an organization to scan. + * + * Generated from protobuf field int64 organization_id = 1; + * @return int|string + */ + public function getOrganizationId() + { + return $this->readOneof(1); + } + + public function hasOrganizationId() + { + return $this->hasOneof(1); + } + + /** + * The ID of an organization to scan. + * + * Generated from protobuf field int64 organization_id = 1; + * @param int|string $var + * @return $this + */ + public function setOrganizationId($var) + { + GPBUtil::checkInt64($var); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * The ID of the Folder within an organization to scan. + * + * Generated from protobuf field int64 folder_id = 2; + * @return int|string + */ + public function getFolderId() + { + return $this->readOneof(2); + } + + public function hasFolderId() + { + return $this->hasOneof(2); + } + + /** + * The ID of the Folder within an organization to scan. + * + * Generated from protobuf field int64 folder_id = 2; + * @param int|string $var + * @return $this + */ + public function setFolderId($var) + { + GPBUtil::checkInt64($var); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getLocation() + { + return $this->whichOneof("location"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition.php new file mode 100644 index 000000000000..c5858b4bb75d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition.php @@ -0,0 +1,77 @@ +google.privacy.dlp.v2.DataProfilePubSubCondition + */ +class DataProfilePubSubCondition extends \Google\Protobuf\Internal\Message +{ + /** + * An expression. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions expressions = 1; + */ + protected $expressions = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubExpressions $expressions + * An expression. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * An expression. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions expressions = 1; + * @return \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubExpressions|null + */ + public function getExpressions() + { + return $this->expressions; + } + + public function hasExpressions() + { + return isset($this->expressions); + } + + public function clearExpressions() + { + unset($this->expressions); + } + + /** + * An expression. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions expressions = 1; + * @param \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubExpressions $var + * @return $this + */ + public function setExpressions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubExpressions::class); + $this->expressions = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/ProfileScoreBucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/ProfileScoreBucket.php new file mode 100644 index 000000000000..3badf79759e1 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/ProfileScoreBucket.php @@ -0,0 +1,64 @@ +google.privacy.dlp.v2.DataProfilePubSubCondition.ProfileScoreBucket + */ +class ProfileScoreBucket +{ + /** + * Unused. + * + * Generated from protobuf enum PROFILE_SCORE_BUCKET_UNSPECIFIED = 0; + */ + const PROFILE_SCORE_BUCKET_UNSPECIFIED = 0; + /** + * High risk/sensitivity detected. + * + * Generated from protobuf enum HIGH = 1; + */ + const HIGH = 1; + /** + * Medium or high risk/sensitivity detected. + * + * Generated from protobuf enum MEDIUM_OR_HIGH = 2; + */ + const MEDIUM_OR_HIGH = 2; + + private static $valueToName = [ + self::PROFILE_SCORE_BUCKET_UNSPECIFIED => 'PROFILE_SCORE_BUCKET_UNSPECIFIED', + self::HIGH => 'HIGH', + self::MEDIUM_OR_HIGH => 'MEDIUM_OR_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(ProfileScoreBucket::class, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition_ProfileScoreBucket::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubCondition.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubCondition.php new file mode 100644 index 000000000000..5cff0909ffa3 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubCondition.php @@ -0,0 +1,111 @@ +google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubCondition + */ +class PubSubCondition extends \Google\Protobuf\Internal\Message +{ + protected $value; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $minimum_risk_score + * The minimum data risk score that triggers the condition. + * @type int $minimum_sensitivity_score + * The minimum sensitivity level that triggers the condition. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The minimum data risk score that triggers the condition. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.ProfileScoreBucket minimum_risk_score = 1; + * @return int + */ + public function getMinimumRiskScore() + { + return $this->readOneof(1); + } + + public function hasMinimumRiskScore() + { + return $this->hasOneof(1); + } + + /** + * The minimum data risk score that triggers the condition. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.ProfileScoreBucket minimum_risk_score = 1; + * @param int $var + * @return $this + */ + public function setMinimumRiskScore($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\ProfileScoreBucket::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * The minimum sensitivity level that triggers the condition. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.ProfileScoreBucket minimum_sensitivity_score = 2; + * @return int + */ + public function getMinimumSensitivityScore() + { + return $this->readOneof(2); + } + + public function hasMinimumSensitivityScore() + { + return $this->hasOneof(2); + } + + /** + * The minimum sensitivity level that triggers the condition. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.ProfileScoreBucket minimum_sensitivity_score = 2; + * @param int $var + * @return $this + */ + public function setMinimumSensitivityScore($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\ProfileScoreBucket::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getValue() + { + return $this->whichOneof("value"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PubSubCondition::class, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition_PubSubCondition::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions.php new file mode 100644 index 000000000000..5db8a91afd83 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions.php @@ -0,0 +1,104 @@ +google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions + */ +class PubSubExpressions extends \Google\Protobuf\Internal\Message +{ + /** + * The operator to apply to the collection of conditions. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions.PubSubLogicalOperator logical_operator = 1; + */ + protected $logical_operator = 0; + /** + * Conditions to apply to the expression. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubCondition conditions = 2; + */ + private $conditions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $logical_operator + * The operator to apply to the collection of conditions. + * @type array<\Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubCondition>|\Google\Protobuf\Internal\RepeatedField $conditions + * Conditions to apply to the expression. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The operator to apply to the collection of conditions. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions.PubSubLogicalOperator logical_operator = 1; + * @return int + */ + public function getLogicalOperator() + { + return $this->logical_operator; + } + + /** + * The operator to apply to the collection of conditions. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions.PubSubLogicalOperator logical_operator = 1; + * @param int $var + * @return $this + */ + public function setLogicalOperator($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubExpressions\PubSubLogicalOperator::class); + $this->logical_operator = $var; + + return $this; + } + + /** + * Conditions to apply to the expression. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubCondition conditions = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getConditions() + { + return $this->conditions; + } + + /** + * Conditions to apply to the expression. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubCondition conditions = 2; + * @param array<\Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubCondition>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setConditions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubCondition::class); + $this->conditions = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PubSubExpressions::class, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition_PubSubExpressions::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions/PubSubLogicalOperator.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions/PubSubLogicalOperator.php new file mode 100644 index 000000000000..47586059b5bf --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions/PubSubLogicalOperator.php @@ -0,0 +1,68 @@ +google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions.PubSubLogicalOperator + */ +class PubSubLogicalOperator +{ + /** + * Unused. + * + * Generated from protobuf enum LOGICAL_OPERATOR_UNSPECIFIED = 0; + */ + const LOGICAL_OPERATOR_UNSPECIFIED = 0; + /** + * Conditional OR. + * + * Generated from protobuf enum OR = 1; + */ + const PBOR = 1; + /** + * Conditional AND. + * + * Generated from protobuf enum AND = 2; + */ + const PBAND = 2; + + private static $valueToName = [ + self::LOGICAL_OPERATOR_UNSPECIFIED => 'LOGICAL_OPERATOR_UNSPECIFIED', + self::PBOR => 'OR', + self::PBAND => 'AND', + ]; + + 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)) { + $pbconst = __CLASS__. '::PB' . strtoupper($name); + if (!defined($pbconst)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($pbconst); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PubSubLogicalOperator::class, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition_PubSubExpressions_PubSubLogicalOperator::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubMessage.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubMessage.php new file mode 100644 index 000000000000..1117f6b2b513 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubMessage.php @@ -0,0 +1,121 @@ +google.privacy.dlp.v2.DataProfilePubSubMessage + */ +class DataProfilePubSubMessage extends \Google\Protobuf\Internal\Message +{ + /** + * If `DetailLevel` is `TABLE_PROFILE` this will be fully populated. + * Otherwise, if `DetailLevel` is `RESOURCE_NAME`, then only `name` and + * `full_resource` will be populated. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile profile = 1; + */ + protected $profile = null; + /** + * The event that caused the Pub/Sub message to be sent. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.EventType event = 2; + */ + protected $event = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\TableDataProfile $profile + * If `DetailLevel` is `TABLE_PROFILE` this will be fully populated. + * Otherwise, if `DetailLevel` is `RESOURCE_NAME`, then only `name` and + * `full_resource` will be populated. + * @type int $event + * The event that caused the Pub/Sub message to be sent. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * If `DetailLevel` is `TABLE_PROFILE` this will be fully populated. + * Otherwise, if `DetailLevel` is `RESOURCE_NAME`, then only `name` and + * `full_resource` will be populated. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile profile = 1; + * @return \Google\Cloud\Dlp\V2\TableDataProfile|null + */ + public function getProfile() + { + return $this->profile; + } + + public function hasProfile() + { + return isset($this->profile); + } + + public function clearProfile() + { + unset($this->profile); + } + + /** + * If `DetailLevel` is `TABLE_PROFILE` this will be fully populated. + * Otherwise, if `DetailLevel` is `RESOURCE_NAME`, then only `name` and + * `full_resource` will be populated. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile profile = 1; + * @param \Google\Cloud\Dlp\V2\TableDataProfile $var + * @return $this + */ + public function setProfile($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableDataProfile::class); + $this->profile = $var; + + return $this; + } + + /** + * The event that caused the Pub/Sub message to be sent. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.EventType event = 2; + * @return int + */ + public function getEvent() + { + return $this->event; + } + + /** + * The event that caused the Pub/Sub message to be sent. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.EventType event = 2; + * @param int $var + * @return $this + */ + public function setEvent($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileAction\EventType::class); + $this->event = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileUpdateFrequency.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileUpdateFrequency.php new file mode 100644 index 000000000000..4b4fc355a7b8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileUpdateFrequency.php @@ -0,0 +1,69 @@ +google.privacy.dlp.v2.DataProfileUpdateFrequency + */ +class DataProfileUpdateFrequency +{ + /** + * Unspecified. + * + * Generated from protobuf enum UPDATE_FREQUENCY_UNSPECIFIED = 0; + */ + const UPDATE_FREQUENCY_UNSPECIFIED = 0; + /** + * After the data profile is created, it will never be updated. + * + * Generated from protobuf enum UPDATE_FREQUENCY_NEVER = 1; + */ + const UPDATE_FREQUENCY_NEVER = 1; + /** + * The data profile can be updated up to once every 24 hours. + * + * Generated from protobuf enum UPDATE_FREQUENCY_DAILY = 2; + */ + const UPDATE_FREQUENCY_DAILY = 2; + /** + * The data profile can be updated up to once every 30 days. Default. + * + * Generated from protobuf enum UPDATE_FREQUENCY_MONTHLY = 4; + */ + const UPDATE_FREQUENCY_MONTHLY = 4; + + private static $valueToName = [ + self::UPDATE_FREQUENCY_UNSPECIFIED => 'UPDATE_FREQUENCY_UNSPECIFIED', + self::UPDATE_FREQUENCY_NEVER => 'UPDATE_FREQUENCY_NEVER', + self::UPDATE_FREQUENCY_DAILY => 'UPDATE_FREQUENCY_DAILY', + self::UPDATE_FREQUENCY_MONTHLY => 'UPDATE_FREQUENCY_MONTHLY', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel.php new file mode 100644 index 000000000000..5736ca6f76a3 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel.php @@ -0,0 +1,68 @@ +google.privacy.dlp.v2.DataRiskLevel + */ +class DataRiskLevel extends \Google\Protobuf\Internal\Message +{ + /** + * The score applied to the resource. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel.DataRiskLevelScore score = 1; + */ + protected $score = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $score + * The score applied to the resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The score applied to the resource. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel.DataRiskLevelScore score = 1; + * @return int + */ + public function getScore() + { + return $this->score; + } + + /** + * The score applied to the resource. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel.DataRiskLevelScore score = 1; + * @param int $var + * @return $this + */ + public function setScore($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataRiskLevel\DataRiskLevelScore::class); + $this->score = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel/DataRiskLevelScore.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel/DataRiskLevelScore.php new file mode 100644 index 000000000000..e5b2081ddb95 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel/DataRiskLevelScore.php @@ -0,0 +1,77 @@ +google.privacy.dlp.v2.DataRiskLevel.DataRiskLevelScore + */ +class DataRiskLevelScore +{ + /** + * Unused. + * + * Generated from protobuf enum RISK_SCORE_UNSPECIFIED = 0; + */ + const RISK_SCORE_UNSPECIFIED = 0; + /** + * Low risk - Lower indication of sensitive data that appears to have + * additional access restrictions in place or no indication of sensitive + * data found. + * + * Generated from protobuf enum RISK_LOW = 10; + */ + const RISK_LOW = 10; + /** + * Medium risk - Sensitive data may be present but additional access or fine + * grain access restrictions appear to be present. Consider limiting + * access even further or transform data to mask. + * + * Generated from protobuf enum RISK_MODERATE = 20; + */ + const RISK_MODERATE = 20; + /** + * High risk – SPII may be present. Access controls may include public + * ACLs. Exfiltration of data may lead to user data loss. Re-identification + * of users may be possible. Consider limiting usage and or removing SPII. + * + * Generated from protobuf enum RISK_HIGH = 30; + */ + const RISK_HIGH = 30; + + private static $valueToName = [ + self::RISK_SCORE_UNSPECIFIED => 'RISK_SCORE_UNSPECIFIED', + self::RISK_LOW => 'RISK_LOW', + self::RISK_MODERATE => 'RISK_MODERATE', + self::RISK_HIGH => 'RISK_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(DataRiskLevelScore::class, \Google\Cloud\Dlp\V2\DataRiskLevel_DataRiskLevelScore::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataSourceType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataSourceType.php new file mode 100644 index 000000000000..6b4531da05df --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataSourceType.php @@ -0,0 +1,71 @@ +google.privacy.dlp.v2.DataSourceType + */ +class DataSourceType extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. An identifying string to the type of resource being profiled. + * Current values: google/bigquery/table, google/project + * + * Generated from protobuf field string data_source = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $data_source = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $data_source + * Output only. An identifying string to the type of resource being profiled. + * Current values: google/bigquery/table, google/project + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Output only. An identifying string to the type of resource being profiled. + * Current values: google/bigquery/table, google/project + * + * Generated from protobuf field string data_source = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getDataSource() + { + return $this->data_source; + } + + /** + * Output only. An identifying string to the type of resource being profiled. + * Current values: google/bigquery/table, google/project + * + * Generated from protobuf field string data_source = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setDataSource($var) + { + GPBUtil::checkString($var, True); + $this->data_source = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceCollection.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceCollection.php new file mode 100644 index 000000000000..61a1ce7130dd --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceCollection.php @@ -0,0 +1,76 @@ +google.privacy.dlp.v2.DatabaseResourceCollection + */ +class DatabaseResourceCollection extends \Google\Protobuf\Internal\Message +{ + protected $pattern; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DatabaseResourceRegexes $include_regexes + * A collection of regular expressions to match a database resource against. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A collection of regular expressions to match a database resource against. + * + * Generated from protobuf field .google.privacy.dlp.v2.DatabaseResourceRegexes include_regexes = 1; + * @return \Google\Cloud\Dlp\V2\DatabaseResourceRegexes|null + */ + public function getIncludeRegexes() + { + return $this->readOneof(1); + } + + public function hasIncludeRegexes() + { + return $this->hasOneof(1); + } + + /** + * A collection of regular expressions to match a database resource against. + * + * Generated from protobuf field .google.privacy.dlp.v2.DatabaseResourceRegexes include_regexes = 1; + * @param \Google\Cloud\Dlp\V2\DatabaseResourceRegexes $var + * @return $this + */ + public function setIncludeRegexes($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DatabaseResourceRegexes::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getPattern() + { + return $this->whichOneof("pattern"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceReference.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceReference.php new file mode 100644 index 000000000000..e04211fa322d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceReference.php @@ -0,0 +1,181 @@ +google.privacy.dlp.v2.DatabaseResourceReference + */ +class DatabaseResourceReference extends \Google\Protobuf\Internal\Message +{ + /** + * Required. If within a project-level config, then this must match the + * config's project ID. + * + * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $project_id = ''; + /** + * Required. The instance where this resource is located. For example: Cloud + * SQL instance ID. + * + * Generated from protobuf field string instance = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $instance = ''; + /** + * Required. Name of a database within the instance. + * + * Generated from protobuf field string database = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $database = ''; + /** + * Required. Name of a database resource, for example, a table within the + * database. + * + * Generated from protobuf field string database_resource = 4 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $database_resource = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $project_id + * Required. If within a project-level config, then this must match the + * config's project ID. + * @type string $instance + * Required. The instance where this resource is located. For example: Cloud + * SQL instance ID. + * @type string $database + * Required. Name of a database within the instance. + * @type string $database_resource + * Required. Name of a database resource, for example, a table within the + * database. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. If within a project-level config, then this must match the + * config's project ID. + * + * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getProjectId() + { + return $this->project_id; + } + + /** + * Required. If within a project-level config, then this must match the + * config's project ID. + * + * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setProjectId($var) + { + GPBUtil::checkString($var, True); + $this->project_id = $var; + + return $this; + } + + /** + * Required. The instance where this resource is located. For example: Cloud + * SQL instance ID. + * + * Generated from protobuf field string instance = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getInstance() + { + return $this->instance; + } + + /** + * Required. The instance where this resource is located. For example: Cloud + * SQL instance ID. + * + * Generated from protobuf field string instance = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setInstance($var) + { + GPBUtil::checkString($var, True); + $this->instance = $var; + + return $this; + } + + /** + * Required. Name of a database within the instance. + * + * Generated from protobuf field string database = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getDatabase() + { + return $this->database; + } + + /** + * Required. Name of a database within the instance. + * + * Generated from protobuf field string database = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setDatabase($var) + { + GPBUtil::checkString($var, True); + $this->database = $var; + + return $this; + } + + /** + * Required. Name of a database resource, for example, a table within the + * database. + * + * Generated from protobuf field string database_resource = 4 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getDatabaseResource() + { + return $this->database_resource; + } + + /** + * Required. Name of a database resource, for example, a table within the + * database. + * + * Generated from protobuf field string database_resource = 4 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setDatabaseResource($var) + { + GPBUtil::checkString($var, True); + $this->database_resource = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegex.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegex.php new file mode 100644 index 000000000000..87663fec9fd7 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegex.php @@ -0,0 +1,188 @@ +google.privacy.dlp.v2.DatabaseResourceRegex + */ +class DatabaseResourceRegex extends \Google\Protobuf\Internal\Message +{ + /** + * For organizations, if unset, will match all projects. Has no effect + * for configurations created within a project. + * + * Generated from protobuf field string project_id_regex = 1; + */ + protected $project_id_regex = ''; + /** + * Regex to test the instance name against. If empty, all instances match. + * + * Generated from protobuf field string instance_regex = 2; + */ + protected $instance_regex = ''; + /** + * Regex to test the database name against. If empty, all databases match. + * + * Generated from protobuf field string database_regex = 3; + */ + protected $database_regex = ''; + /** + * Regex to test the database resource's name against. An example of a + * database resource name is a table's name. Other database resource names + * like view names could be included in the future. If empty, all database + * resources match. + * + * Generated from protobuf field string database_resource_name_regex = 4; + */ + protected $database_resource_name_regex = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $project_id_regex + * For organizations, if unset, will match all projects. Has no effect + * for configurations created within a project. + * @type string $instance_regex + * Regex to test the instance name against. If empty, all instances match. + * @type string $database_regex + * Regex to test the database name against. If empty, all databases match. + * @type string $database_resource_name_regex + * Regex to test the database resource's name against. An example of a + * database resource name is a table's name. Other database resource names + * like view names could be included in the future. If empty, all database + * resources match. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * For organizations, if unset, will match all projects. Has no effect + * for configurations created within a project. + * + * Generated from protobuf field string project_id_regex = 1; + * @return string + */ + public function getProjectIdRegex() + { + return $this->project_id_regex; + } + + /** + * For organizations, if unset, will match all projects. Has no effect + * for configurations created within a project. + * + * Generated from protobuf field string project_id_regex = 1; + * @param string $var + * @return $this + */ + public function setProjectIdRegex($var) + { + GPBUtil::checkString($var, True); + $this->project_id_regex = $var; + + return $this; + } + + /** + * Regex to test the instance name against. If empty, all instances match. + * + * Generated from protobuf field string instance_regex = 2; + * @return string + */ + public function getInstanceRegex() + { + return $this->instance_regex; + } + + /** + * Regex to test the instance name against. If empty, all instances match. + * + * Generated from protobuf field string instance_regex = 2; + * @param string $var + * @return $this + */ + public function setInstanceRegex($var) + { + GPBUtil::checkString($var, True); + $this->instance_regex = $var; + + return $this; + } + + /** + * Regex to test the database name against. If empty, all databases match. + * + * Generated from protobuf field string database_regex = 3; + * @return string + */ + public function getDatabaseRegex() + { + return $this->database_regex; + } + + /** + * Regex to test the database name against. If empty, all databases match. + * + * Generated from protobuf field string database_regex = 3; + * @param string $var + * @return $this + */ + public function setDatabaseRegex($var) + { + GPBUtil::checkString($var, True); + $this->database_regex = $var; + + return $this; + } + + /** + * Regex to test the database resource's name against. An example of a + * database resource name is a table's name. Other database resource names + * like view names could be included in the future. If empty, all database + * resources match. + * + * Generated from protobuf field string database_resource_name_regex = 4; + * @return string + */ + public function getDatabaseResourceNameRegex() + { + return $this->database_resource_name_regex; + } + + /** + * Regex to test the database resource's name against. An example of a + * database resource name is a table's name. Other database resource names + * like view names could be included in the future. If empty, all database + * resources match. + * + * Generated from protobuf field string database_resource_name_regex = 4; + * @param string $var + * @return $this + */ + public function setDatabaseResourceNameRegex($var) + { + GPBUtil::checkString($var, True); + $this->database_resource_name_regex = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegexes.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegexes.php new file mode 100644 index 000000000000..c9a5d6122541 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegexes.php @@ -0,0 +1,80 @@ +google.privacy.dlp.v2.DatabaseResourceRegexes + */ +class DatabaseResourceRegexes extends \Google\Protobuf\Internal\Message +{ + /** + * A group of regular expression patterns to match against one or more + * database resources. + * Maximum of 100 entries. The sum of all regular expression's length can't + * exceed 10 KiB. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DatabaseResourceRegex patterns = 1; + */ + private $patterns; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\DatabaseResourceRegex>|\Google\Protobuf\Internal\RepeatedField $patterns + * A group of regular expression patterns to match against one or more + * database resources. + * Maximum of 100 entries. The sum of all regular expression's length can't + * exceed 10 KiB. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A group of regular expression patterns to match against one or more + * database resources. + * Maximum of 100 entries. The sum of all regular expression's length can't + * exceed 10 KiB. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DatabaseResourceRegex patterns = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPatterns() + { + return $this->patterns; + } + + /** + * A group of regular expression patterns to match against one or more + * database resources. + * Maximum of 100 entries. The sum of all regular expression's length can't + * exceed 10 KiB. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DatabaseResourceRegex patterns = 1; + * @param array<\Google\Cloud\Dlp\V2\DatabaseResourceRegex>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPatterns($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DatabaseResourceRegex::class); + $this->patterns = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreKey.php new file mode 100644 index 000000000000..a4eec6118bf7 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreKey.php @@ -0,0 +1,77 @@ +google.privacy.dlp.v2.DatastoreKey + */ +class DatastoreKey extends \Google\Protobuf\Internal\Message +{ + /** + * Datastore entity key. + * + * Generated from protobuf field .google.privacy.dlp.v2.Key entity_key = 1; + */ + protected $entity_key = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\Key $entity_key + * Datastore entity key. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Datastore entity key. + * + * Generated from protobuf field .google.privacy.dlp.v2.Key entity_key = 1; + * @return \Google\Cloud\Dlp\V2\Key|null + */ + public function getEntityKey() + { + return $this->entity_key; + } + + public function hasEntityKey() + { + return isset($this->entity_key); + } + + public function clearEntityKey() + { + unset($this->entity_key); + } + + /** + * Datastore entity key. + * + * Generated from protobuf field .google.privacy.dlp.v2.Key entity_key = 1; + * @param \Google\Cloud\Dlp\V2\Key $var + * @return $this + */ + public function setEntityKey($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Key::class); + $this->entity_key = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreOptions.php new file mode 100644 index 000000000000..2bcb48315e54 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreOptions.php @@ -0,0 +1,125 @@ +google.privacy.dlp.v2.DatastoreOptions + */ +class DatastoreOptions extends \Google\Protobuf\Internal\Message +{ + /** + * A partition ID identifies a grouping of entities. The grouping is always + * by project and namespace, however the namespace ID may be empty. + * + * Generated from protobuf field .google.privacy.dlp.v2.PartitionId partition_id = 1; + */ + protected $partition_id = null; + /** + * The kind to process. + * + * Generated from protobuf field .google.privacy.dlp.v2.KindExpression kind = 2; + */ + protected $kind = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\PartitionId $partition_id + * A partition ID identifies a grouping of entities. The grouping is always + * by project and namespace, however the namespace ID may be empty. + * @type \Google\Cloud\Dlp\V2\KindExpression $kind + * The kind to process. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * A partition ID identifies a grouping of entities. The grouping is always + * by project and namespace, however the namespace ID may be empty. + * + * Generated from protobuf field .google.privacy.dlp.v2.PartitionId partition_id = 1; + * @return \Google\Cloud\Dlp\V2\PartitionId|null + */ + public function getPartitionId() + { + return $this->partition_id; + } + + public function hasPartitionId() + { + return isset($this->partition_id); + } + + public function clearPartitionId() + { + unset($this->partition_id); + } + + /** + * A partition ID identifies a grouping of entities. The grouping is always + * by project and namespace, however the namespace ID may be empty. + * + * Generated from protobuf field .google.privacy.dlp.v2.PartitionId partition_id = 1; + * @param \Google\Cloud\Dlp\V2\PartitionId $var + * @return $this + */ + public function setPartitionId($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PartitionId::class); + $this->partition_id = $var; + + return $this; + } + + /** + * The kind to process. + * + * Generated from protobuf field .google.privacy.dlp.v2.KindExpression kind = 2; + * @return \Google\Cloud\Dlp\V2\KindExpression|null + */ + public function getKind() + { + return $this->kind; + } + + public function hasKind() + { + return isset($this->kind); + } + + public function clearKind() + { + unset($this->kind); + } + + /** + * The kind to process. + * + * Generated from protobuf field .google.privacy.dlp.v2.KindExpression kind = 2; + * @param \Google\Cloud\Dlp\V2\KindExpression $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\KindExpression::class); + $this->kind = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateShiftConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateShiftConfig.php new file mode 100644 index 000000000000..710be7fdb1a7 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateShiftConfig.php @@ -0,0 +1,220 @@ +google.privacy.dlp.v2.DateShiftConfig + */ +class DateShiftConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Range of shift in days. Actual shift will be selected at random + * within this range (inclusive ends). Negative means shift to earlier in + * time. Must not be more than 365250 days (1000 years) each direction. + * For example, 3 means shift date to at most 3 days into the future. + * + * Generated from protobuf field int32 upper_bound_days = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $upper_bound_days = 0; + /** + * Required. For example, -5 means shift date to at most 5 days back in the + * past. + * + * Generated from protobuf field int32 lower_bound_days = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $lower_bound_days = 0; + /** + * Points to the field that contains the context, for example, an entity id. + * If set, must also set cryptoKey. If set, shift will be consistent for the + * given context. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 3; + */ + protected $context = null; + protected $method; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $upper_bound_days + * Required. Range of shift in days. Actual shift will be selected at random + * within this range (inclusive ends). Negative means shift to earlier in + * time. Must not be more than 365250 days (1000 years) each direction. + * For example, 3 means shift date to at most 3 days into the future. + * @type int $lower_bound_days + * Required. For example, -5 means shift date to at most 5 days back in the + * past. + * @type \Google\Cloud\Dlp\V2\FieldId $context + * Points to the field that contains the context, for example, an entity id. + * If set, must also set cryptoKey. If set, shift will be consistent for the + * given context. + * @type \Google\Cloud\Dlp\V2\CryptoKey $crypto_key + * Causes the shift to be computed based on this key and the context. This + * results in the same shift for the same context and crypto_key. If + * set, must also set context. Can only be applied to table items. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Range of shift in days. Actual shift will be selected at random + * within this range (inclusive ends). Negative means shift to earlier in + * time. Must not be more than 365250 days (1000 years) each direction. + * For example, 3 means shift date to at most 3 days into the future. + * + * Generated from protobuf field int32 upper_bound_days = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getUpperBoundDays() + { + return $this->upper_bound_days; + } + + /** + * Required. Range of shift in days. Actual shift will be selected at random + * within this range (inclusive ends). Negative means shift to earlier in + * time. Must not be more than 365250 days (1000 years) each direction. + * For example, 3 means shift date to at most 3 days into the future. + * + * Generated from protobuf field int32 upper_bound_days = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setUpperBoundDays($var) + { + GPBUtil::checkInt32($var); + $this->upper_bound_days = $var; + + return $this; + } + + /** + * Required. For example, -5 means shift date to at most 5 days back in the + * past. + * + * Generated from protobuf field int32 lower_bound_days = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getLowerBoundDays() + { + return $this->lower_bound_days; + } + + /** + * Required. For example, -5 means shift date to at most 5 days back in the + * past. + * + * Generated from protobuf field int32 lower_bound_days = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setLowerBoundDays($var) + { + GPBUtil::checkInt32($var); + $this->lower_bound_days = $var; + + return $this; + } + + /** + * Points to the field that contains the context, for example, an entity id. + * If set, must also set cryptoKey. If set, shift will be consistent for the + * given context. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 3; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getContext() + { + return $this->context; + } + + public function hasContext() + { + return isset($this->context); + } + + public function clearContext() + { + unset($this->context); + } + + /** + * Points to the field that contains the context, for example, an entity id. + * If set, must also set cryptoKey. If set, shift will be consistent for the + * given context. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 3; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setContext($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->context = $var; + + return $this; + } + + /** + * Causes the shift to be computed based on this key and the context. This + * results in the same shift for the same context and crypto_key. If + * set, must also set context. Can only be applied to table items. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 4; + * @return \Google\Cloud\Dlp\V2\CryptoKey|null + */ + public function getCryptoKey() + { + return $this->readOneof(4); + } + + public function hasCryptoKey() + { + return $this->hasOneof(4); + } + + /** + * Causes the shift to be computed based on this key and the context. This + * results in the same shift for the same context and crypto_key. If + * set, must also set context. Can only be applied to table items. + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 4; + * @param \Google\Cloud\Dlp\V2\CryptoKey $var + * @return $this + */ + public function setCryptoKey($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoKey::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getMethod() + { + return $this->whichOneof("method"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime.php new file mode 100644 index 000000000000..da1a586cf1a2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime.php @@ -0,0 +1,204 @@ +google.privacy.dlp.v2.DateTime + */ +class DateTime extends \Google\Protobuf\Internal\Message +{ + /** + * One or more of the following must be set. + * Must be a valid date or time value. + * + * Generated from protobuf field .google.type.Date date = 1; + */ + protected $date = null; + /** + * Day of week + * + * Generated from protobuf field .google.type.DayOfWeek day_of_week = 2; + */ + protected $day_of_week = 0; + /** + * Time of day + * + * Generated from protobuf field .google.type.TimeOfDay time = 3; + */ + protected $time = null; + /** + * Time zone + * + * Generated from protobuf field .google.privacy.dlp.v2.DateTime.TimeZone time_zone = 4; + */ + protected $time_zone = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Type\Date $date + * One or more of the following must be set. + * Must be a valid date or time value. + * @type int $day_of_week + * Day of week + * @type \Google\Type\TimeOfDay $time + * Time of day + * @type \Google\Cloud\Dlp\V2\DateTime\TimeZone $time_zone + * Time zone + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * One or more of the following must be set. + * Must be a valid date or time value. + * + * Generated from protobuf field .google.type.Date date = 1; + * @return \Google\Type\Date|null + */ + public function getDate() + { + return $this->date; + } + + public function hasDate() + { + return isset($this->date); + } + + public function clearDate() + { + unset($this->date); + } + + /** + * One or more of the following must be set. + * Must be a valid date or time value. + * + * Generated from protobuf field .google.type.Date date = 1; + * @param \Google\Type\Date $var + * @return $this + */ + public function setDate($var) + { + GPBUtil::checkMessage($var, \Google\Type\Date::class); + $this->date = $var; + + return $this; + } + + /** + * Day of week + * + * Generated from protobuf field .google.type.DayOfWeek day_of_week = 2; + * @return int + */ + public function getDayOfWeek() + { + return $this->day_of_week; + } + + /** + * Day of week + * + * Generated from protobuf field .google.type.DayOfWeek day_of_week = 2; + * @param int $var + * @return $this + */ + public function setDayOfWeek($var) + { + GPBUtil::checkEnum($var, \Google\Type\DayOfWeek::class); + $this->day_of_week = $var; + + return $this; + } + + /** + * Time of day + * + * Generated from protobuf field .google.type.TimeOfDay time = 3; + * @return \Google\Type\TimeOfDay|null + */ + public function getTime() + { + return $this->time; + } + + public function hasTime() + { + return isset($this->time); + } + + public function clearTime() + { + unset($this->time); + } + + /** + * Time of day + * + * Generated from protobuf field .google.type.TimeOfDay time = 3; + * @param \Google\Type\TimeOfDay $var + * @return $this + */ + public function setTime($var) + { + GPBUtil::checkMessage($var, \Google\Type\TimeOfDay::class); + $this->time = $var; + + return $this; + } + + /** + * Time zone + * + * Generated from protobuf field .google.privacy.dlp.v2.DateTime.TimeZone time_zone = 4; + * @return \Google\Cloud\Dlp\V2\DateTime\TimeZone|null + */ + public function getTimeZone() + { + return $this->time_zone; + } + + public function hasTimeZone() + { + return isset($this->time_zone); + } + + public function clearTimeZone() + { + unset($this->time_zone); + } + + /** + * Time zone + * + * Generated from protobuf field .google.privacy.dlp.v2.DateTime.TimeZone time_zone = 4; + * @param \Google\Cloud\Dlp\V2\DateTime\TimeZone $var + * @return $this + */ + public function setTimeZone($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DateTime\TimeZone::class); + $this->time_zone = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime/TimeZone.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime/TimeZone.php new file mode 100644 index 000000000000..e371a018541a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime/TimeZone.php @@ -0,0 +1,74 @@ +google.privacy.dlp.v2.DateTime.TimeZone + */ +class TimeZone extends \Google\Protobuf\Internal\Message +{ + /** + * Set only if the offset can be determined. Positive for time ahead of UTC. + * E.g. For "UTC-9", this value is -540. + * + * Generated from protobuf field int32 offset_minutes = 1; + */ + protected $offset_minutes = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $offset_minutes + * Set only if the offset can be determined. Positive for time ahead of UTC. + * E.g. For "UTC-9", this value is -540. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Set only if the offset can be determined. Positive for time ahead of UTC. + * E.g. For "UTC-9", this value is -540. + * + * Generated from protobuf field int32 offset_minutes = 1; + * @return int + */ + public function getOffsetMinutes() + { + return $this->offset_minutes; + } + + /** + * Set only if the offset can be determined. Positive for time ahead of UTC. + * E.g. For "UTC-9", this value is -540. + * + * Generated from protobuf field int32 offset_minutes = 1; + * @param int $var + * @return $this + */ + public function setOffsetMinutes($var) + { + GPBUtil::checkInt32($var); + $this->offset_minutes = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(TimeZone::class, \Google\Cloud\Dlp\V2\DateTime_TimeZone::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyConfig.php new file mode 100644 index 000000000000..0ffdb2d9697d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyConfig.php @@ -0,0 +1,198 @@ +google.privacy.dlp.v2.DeidentifyConfig + */ +class DeidentifyConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Mode for handling transformation errors. If left unspecified, the default + * mode is `TransformationErrorHandling.ThrowError`. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling transformation_error_handling = 3; + */ + protected $transformation_error_handling = null; + protected $transformation; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InfoTypeTransformations $info_type_transformations + * Treat the dataset as free-form text and apply the same free text + * transformation everywhere. + * @type \Google\Cloud\Dlp\V2\RecordTransformations $record_transformations + * Treat the dataset as structured. Transformations can be applied to + * specific locations within structured datasets, such as transforming + * a column within a table. + * @type \Google\Cloud\Dlp\V2\ImageTransformations $image_transformations + * Treat the dataset as an image and redact. + * @type \Google\Cloud\Dlp\V2\TransformationErrorHandling $transformation_error_handling + * Mode for handling transformation errors. If left unspecified, the default + * mode is `TransformationErrorHandling.ThrowError`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Treat the dataset as free-form text and apply the same free text + * transformation everywhere. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeTransformations info_type_transformations = 1; + * @return \Google\Cloud\Dlp\V2\InfoTypeTransformations|null + */ + public function getInfoTypeTransformations() + { + return $this->readOneof(1); + } + + public function hasInfoTypeTransformations() + { + return $this->hasOneof(1); + } + + /** + * Treat the dataset as free-form text and apply the same free text + * transformation everywhere. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeTransformations info_type_transformations = 1; + * @param \Google\Cloud\Dlp\V2\InfoTypeTransformations $var + * @return $this + */ + public function setInfoTypeTransformations($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoTypeTransformations::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Treat the dataset as structured. Transformations can be applied to + * specific locations within structured datasets, such as transforming + * a column within a table. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordTransformations record_transformations = 2; + * @return \Google\Cloud\Dlp\V2\RecordTransformations|null + */ + public function getRecordTransformations() + { + return $this->readOneof(2); + } + + public function hasRecordTransformations() + { + return $this->hasOneof(2); + } + + /** + * Treat the dataset as structured. Transformations can be applied to + * specific locations within structured datasets, such as transforming + * a column within a table. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordTransformations record_transformations = 2; + * @param \Google\Cloud\Dlp\V2\RecordTransformations $var + * @return $this + */ + public function setRecordTransformations($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordTransformations::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Treat the dataset as an image and redact. + * + * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations image_transformations = 4; + * @return \Google\Cloud\Dlp\V2\ImageTransformations|null + */ + public function getImageTransformations() + { + return $this->readOneof(4); + } + + public function hasImageTransformations() + { + return $this->hasOneof(4); + } + + /** + * Treat the dataset as an image and redact. + * + * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations image_transformations = 4; + * @param \Google\Cloud\Dlp\V2\ImageTransformations $var + * @return $this + */ + public function setImageTransformations($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ImageTransformations::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Mode for handling transformation errors. If left unspecified, the default + * mode is `TransformationErrorHandling.ThrowError`. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling transformation_error_handling = 3; + * @return \Google\Cloud\Dlp\V2\TransformationErrorHandling|null + */ + public function getTransformationErrorHandling() + { + return $this->transformation_error_handling; + } + + public function hasTransformationErrorHandling() + { + return isset($this->transformation_error_handling); + } + + public function clearTransformationErrorHandling() + { + unset($this->transformation_error_handling); + } + + /** + * Mode for handling transformation errors. If left unspecified, the default + * mode is `TransformationErrorHandling.ThrowError`. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling transformation_error_handling = 3; + * @param \Google\Cloud\Dlp\V2\TransformationErrorHandling $var + * @return $this + */ + public function setTransformationErrorHandling($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationErrorHandling::class); + $this->transformation_error_handling = $var; + + return $this; + } + + /** + * @return string + */ + public function getTransformation() + { + return $this->whichOneof("transformation"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentRequest.php new file mode 100644 index 000000000000..220d50dd05cf --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentRequest.php @@ -0,0 +1,417 @@ +google.privacy.dlp.v2.DeidentifyContentRequest + */ +class DeidentifyContentRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Configuration for the de-identification of the content item. + * Items specified here will override the template referenced by the + * deidentify_template_name argument. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig deidentify_config = 2; + */ + protected $deidentify_config = null; + /** + * Configuration for the inspector. + * Items specified here will override the template referenced by the + * inspect_template_name argument. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 3; + */ + protected $inspect_config = null; + /** + * The item to de-identify. Will be treated as text. + * This value must be of type + * [Table][google.privacy.dlp.v2.Table] if your + * [deidentify_config][google.privacy.dlp.v2.DeidentifyContentRequest.deidentify_config] + * is a + * [RecordTransformations][google.privacy.dlp.v2.RecordTransformations] + * object. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 4; + */ + protected $item = null; + /** + * Template to use. Any configuration directly specified in + * inspect_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * + * Generated from protobuf field string inspect_template_name = 5; + */ + protected $inspect_template_name = ''; + /** + * Template to use. Any configuration directly specified in + * deidentify_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * + * Generated from protobuf field string deidentify_template_name = 6; + */ + protected $deidentify_template_name = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 7; + */ + protected $location_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type \Google\Cloud\Dlp\V2\DeidentifyConfig $deidentify_config + * Configuration for the de-identification of the content item. + * Items specified here will override the template referenced by the + * deidentify_template_name argument. + * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config + * Configuration for the inspector. + * Items specified here will override the template referenced by the + * inspect_template_name argument. + * @type \Google\Cloud\Dlp\V2\ContentItem $item + * The item to de-identify. Will be treated as text. + * This value must be of type + * [Table][google.privacy.dlp.v2.Table] if your + * [deidentify_config][google.privacy.dlp.v2.DeidentifyContentRequest.deidentify_config] + * is a + * [RecordTransformations][google.privacy.dlp.v2.RecordTransformations] + * object. + * @type string $inspect_template_name + * Template to use. Any configuration directly specified in + * inspect_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * @type string $deidentify_template_name + * Template to use. Any configuration directly specified in + * deidentify_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Configuration for the de-identification of the content item. + * Items specified here will override the template referenced by the + * deidentify_template_name argument. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig deidentify_config = 2; + * @return \Google\Cloud\Dlp\V2\DeidentifyConfig|null + */ + public function getDeidentifyConfig() + { + return $this->deidentify_config; + } + + public function hasDeidentifyConfig() + { + return isset($this->deidentify_config); + } + + public function clearDeidentifyConfig() + { + unset($this->deidentify_config); + } + + /** + * Configuration for the de-identification of the content item. + * Items specified here will override the template referenced by the + * deidentify_template_name argument. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig deidentify_config = 2; + * @param \Google\Cloud\Dlp\V2\DeidentifyConfig $var + * @return $this + */ + public function setDeidentifyConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyConfig::class); + $this->deidentify_config = $var; + + return $this; + } + + /** + * Configuration for the inspector. + * Items specified here will override the template referenced by the + * inspect_template_name argument. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 3; + * @return \Google\Cloud\Dlp\V2\InspectConfig|null + */ + public function getInspectConfig() + { + return $this->inspect_config; + } + + public function hasInspectConfig() + { + return isset($this->inspect_config); + } + + public function clearInspectConfig() + { + unset($this->inspect_config); + } + + /** + * Configuration for the inspector. + * Items specified here will override the template referenced by the + * inspect_template_name argument. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 3; + * @param \Google\Cloud\Dlp\V2\InspectConfig $var + * @return $this + */ + public function setInspectConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); + $this->inspect_config = $var; + + return $this; + } + + /** + * The item to de-identify. Will be treated as text. + * This value must be of type + * [Table][google.privacy.dlp.v2.Table] if your + * [deidentify_config][google.privacy.dlp.v2.DeidentifyContentRequest.deidentify_config] + * is a + * [RecordTransformations][google.privacy.dlp.v2.RecordTransformations] + * object. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 4; + * @return \Google\Cloud\Dlp\V2\ContentItem|null + */ + public function getItem() + { + return $this->item; + } + + public function hasItem() + { + return isset($this->item); + } + + public function clearItem() + { + unset($this->item); + } + + /** + * The item to de-identify. Will be treated as text. + * This value must be of type + * [Table][google.privacy.dlp.v2.Table] if your + * [deidentify_config][google.privacy.dlp.v2.DeidentifyContentRequest.deidentify_config] + * is a + * [RecordTransformations][google.privacy.dlp.v2.RecordTransformations] + * object. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 4; + * @param \Google\Cloud\Dlp\V2\ContentItem $var + * @return $this + */ + public function setItem($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ContentItem::class); + $this->item = $var; + + return $this; + } + + /** + * Template to use. Any configuration directly specified in + * inspect_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * + * Generated from protobuf field string inspect_template_name = 5; + * @return string + */ + public function getInspectTemplateName() + { + return $this->inspect_template_name; + } + + /** + * Template to use. Any configuration directly specified in + * inspect_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * + * Generated from protobuf field string inspect_template_name = 5; + * @param string $var + * @return $this + */ + public function setInspectTemplateName($var) + { + GPBUtil::checkString($var, True); + $this->inspect_template_name = $var; + + return $this; + } + + /** + * Template to use. Any configuration directly specified in + * deidentify_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * + * Generated from protobuf field string deidentify_template_name = 6; + * @return string + */ + public function getDeidentifyTemplateName() + { + return $this->deidentify_template_name; + } + + /** + * Template to use. Any configuration directly specified in + * deidentify_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * + * Generated from protobuf field string deidentify_template_name = 6; + * @param string $var + * @return $this + */ + public function setDeidentifyTemplateName($var) + { + GPBUtil::checkString($var, True); + $this->deidentify_template_name = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 7; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 7; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentResponse.php new file mode 100644 index 000000000000..dd41fd9c0f4d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentResponse.php @@ -0,0 +1,121 @@ +google.privacy.dlp.v2.DeidentifyContentResponse + */ +class DeidentifyContentResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The de-identified item. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; + */ + protected $item = null; + /** + * An overview of the changes that were made on the `item`. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationOverview overview = 2; + */ + protected $overview = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\ContentItem $item + * The de-identified item. + * @type \Google\Cloud\Dlp\V2\TransformationOverview $overview + * An overview of the changes that were made on the `item`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The de-identified item. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; + * @return \Google\Cloud\Dlp\V2\ContentItem|null + */ + public function getItem() + { + return $this->item; + } + + public function hasItem() + { + return isset($this->item); + } + + public function clearItem() + { + unset($this->item); + } + + /** + * The de-identified item. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; + * @param \Google\Cloud\Dlp\V2\ContentItem $var + * @return $this + */ + public function setItem($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ContentItem::class); + $this->item = $var; + + return $this; + } + + /** + * An overview of the changes that were made on the `item`. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationOverview overview = 2; + * @return \Google\Cloud\Dlp\V2\TransformationOverview|null + */ + public function getOverview() + { + return $this->overview; + } + + public function hasOverview() + { + return isset($this->overview); + } + + public function clearOverview() + { + unset($this->overview); + } + + /** + * An overview of the changes that were made on the `item`. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationOverview overview = 2; + * @param \Google\Cloud\Dlp\V2\TransformationOverview $var + * @return $this + */ + public function setOverview($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationOverview::class); + $this->overview = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails.php new file mode 100644 index 000000000000..7df95b625939 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails.php @@ -0,0 +1,122 @@ +google.privacy.dlp.v2.DeidentifyDataSourceDetails + */ +class DeidentifyDataSourceDetails extends \Google\Protobuf\Internal\Message +{ + /** + * De-identification config used for the request. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceDetails.RequestedDeidentifyOptions requested_options = 1; + */ + protected $requested_options = null; + /** + * Stats about the de-identification operation. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceStats deidentify_stats = 2; + */ + protected $deidentify_stats = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails\RequestedDeidentifyOptions $requested_options + * De-identification config used for the request. + * @type \Google\Cloud\Dlp\V2\DeidentifyDataSourceStats $deidentify_stats + * Stats about the de-identification operation. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * De-identification config used for the request. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceDetails.RequestedDeidentifyOptions requested_options = 1; + * @return \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails\RequestedDeidentifyOptions|null + */ + public function getRequestedOptions() + { + return $this->requested_options; + } + + public function hasRequestedOptions() + { + return isset($this->requested_options); + } + + public function clearRequestedOptions() + { + unset($this->requested_options); + } + + /** + * De-identification config used for the request. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceDetails.RequestedDeidentifyOptions requested_options = 1; + * @param \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails\RequestedDeidentifyOptions $var + * @return $this + */ + public function setRequestedOptions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails\RequestedDeidentifyOptions::class); + $this->requested_options = $var; + + return $this; + } + + /** + * Stats about the de-identification operation. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceStats deidentify_stats = 2; + * @return \Google\Cloud\Dlp\V2\DeidentifyDataSourceStats|null + */ + public function getDeidentifyStats() + { + return $this->deidentify_stats; + } + + public function hasDeidentifyStats() + { + return isset($this->deidentify_stats); + } + + public function clearDeidentifyStats() + { + unset($this->deidentify_stats); + } + + /** + * Stats about the de-identification operation. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceStats deidentify_stats = 2; + * @param \Google\Cloud\Dlp\V2\DeidentifyDataSourceStats $var + * @return $this + */ + public function setDeidentifyStats($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyDataSourceStats::class); + $this->deidentify_stats = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails/RequestedDeidentifyOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails/RequestedDeidentifyOptions.php new file mode 100644 index 000000000000..e19b4098468f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails/RequestedDeidentifyOptions.php @@ -0,0 +1,184 @@ +google.privacy.dlp.v2.DeidentifyDataSourceDetails.RequestedDeidentifyOptions + */ +class RequestedDeidentifyOptions extends \Google\Protobuf\Internal\Message +{ + /** + * Snapshot of the state of the `DeidentifyTemplate` from the + * [Deidentify][google.privacy.dlp.v2.Action.Deidentify] action at the time + * this job was run. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_deidentify_template = 1; + */ + protected $snapshot_deidentify_template = null; + /** + * Snapshot of the state of the structured `DeidentifyTemplate` from the + * `Deidentify` action at the time this job was run. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_structured_deidentify_template = 2; + */ + protected $snapshot_structured_deidentify_template = null; + /** + * Snapshot of the state of the image transformation `DeidentifyTemplate` + * from the `Deidentify` action at the time this job was run. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_image_redact_template = 3; + */ + protected $snapshot_image_redact_template = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DeidentifyTemplate $snapshot_deidentify_template + * Snapshot of the state of the `DeidentifyTemplate` from the + * [Deidentify][google.privacy.dlp.v2.Action.Deidentify] action at the time + * this job was run. + * @type \Google\Cloud\Dlp\V2\DeidentifyTemplate $snapshot_structured_deidentify_template + * Snapshot of the state of the structured `DeidentifyTemplate` from the + * `Deidentify` action at the time this job was run. + * @type \Google\Cloud\Dlp\V2\DeidentifyTemplate $snapshot_image_redact_template + * Snapshot of the state of the image transformation `DeidentifyTemplate` + * from the `Deidentify` action at the time this job was run. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Snapshot of the state of the `DeidentifyTemplate` from the + * [Deidentify][google.privacy.dlp.v2.Action.Deidentify] action at the time + * this job was run. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_deidentify_template = 1; + * @return \Google\Cloud\Dlp\V2\DeidentifyTemplate|null + */ + public function getSnapshotDeidentifyTemplate() + { + return $this->snapshot_deidentify_template; + } + + public function hasSnapshotDeidentifyTemplate() + { + return isset($this->snapshot_deidentify_template); + } + + public function clearSnapshotDeidentifyTemplate() + { + unset($this->snapshot_deidentify_template); + } + + /** + * Snapshot of the state of the `DeidentifyTemplate` from the + * [Deidentify][google.privacy.dlp.v2.Action.Deidentify] action at the time + * this job was run. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_deidentify_template = 1; + * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $var + * @return $this + */ + public function setSnapshotDeidentifyTemplate($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyTemplate::class); + $this->snapshot_deidentify_template = $var; + + return $this; + } + + /** + * Snapshot of the state of the structured `DeidentifyTemplate` from the + * `Deidentify` action at the time this job was run. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_structured_deidentify_template = 2; + * @return \Google\Cloud\Dlp\V2\DeidentifyTemplate|null + */ + public function getSnapshotStructuredDeidentifyTemplate() + { + return $this->snapshot_structured_deidentify_template; + } + + public function hasSnapshotStructuredDeidentifyTemplate() + { + return isset($this->snapshot_structured_deidentify_template); + } + + public function clearSnapshotStructuredDeidentifyTemplate() + { + unset($this->snapshot_structured_deidentify_template); + } + + /** + * Snapshot of the state of the structured `DeidentifyTemplate` from the + * `Deidentify` action at the time this job was run. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_structured_deidentify_template = 2; + * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $var + * @return $this + */ + public function setSnapshotStructuredDeidentifyTemplate($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyTemplate::class); + $this->snapshot_structured_deidentify_template = $var; + + return $this; + } + + /** + * Snapshot of the state of the image transformation `DeidentifyTemplate` + * from the `Deidentify` action at the time this job was run. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_image_redact_template = 3; + * @return \Google\Cloud\Dlp\V2\DeidentifyTemplate|null + */ + public function getSnapshotImageRedactTemplate() + { + return $this->snapshot_image_redact_template; + } + + public function hasSnapshotImageRedactTemplate() + { + return isset($this->snapshot_image_redact_template); + } + + public function clearSnapshotImageRedactTemplate() + { + unset($this->snapshot_image_redact_template); + } + + /** + * Snapshot of the state of the image transformation `DeidentifyTemplate` + * from the `Deidentify` action at the time this job was run. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_image_redact_template = 3; + * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $var + * @return $this + */ + public function setSnapshotImageRedactTemplate($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyTemplate::class); + $this->snapshot_image_redact_template = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(RequestedDeidentifyOptions::class, \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails_RequestedDeidentifyOptions::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceStats.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceStats.php new file mode 100644 index 000000000000..59a55b5aa27b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceStats.php @@ -0,0 +1,135 @@ +google.privacy.dlp.v2.DeidentifyDataSourceStats + */ +class DeidentifyDataSourceStats extends \Google\Protobuf\Internal\Message +{ + /** + * Total size in bytes that were transformed in some way. + * + * Generated from protobuf field int64 transformed_bytes = 1; + */ + protected $transformed_bytes = 0; + /** + * Number of successfully applied transformations. + * + * Generated from protobuf field int64 transformation_count = 2; + */ + protected $transformation_count = 0; + /** + * Number of errors encountered while trying to apply transformations. + * + * Generated from protobuf field int64 transformation_error_count = 3; + */ + protected $transformation_error_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $transformed_bytes + * Total size in bytes that were transformed in some way. + * @type int|string $transformation_count + * Number of successfully applied transformations. + * @type int|string $transformation_error_count + * Number of errors encountered while trying to apply transformations. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Total size in bytes that were transformed in some way. + * + * Generated from protobuf field int64 transformed_bytes = 1; + * @return int|string + */ + public function getTransformedBytes() + { + return $this->transformed_bytes; + } + + /** + * Total size in bytes that were transformed in some way. + * + * Generated from protobuf field int64 transformed_bytes = 1; + * @param int|string $var + * @return $this + */ + public function setTransformedBytes($var) + { + GPBUtil::checkInt64($var); + $this->transformed_bytes = $var; + + return $this; + } + + /** + * Number of successfully applied transformations. + * + * Generated from protobuf field int64 transformation_count = 2; + * @return int|string + */ + public function getTransformationCount() + { + return $this->transformation_count; + } + + /** + * Number of successfully applied transformations. + * + * Generated from protobuf field int64 transformation_count = 2; + * @param int|string $var + * @return $this + */ + public function setTransformationCount($var) + { + GPBUtil::checkInt64($var); + $this->transformation_count = $var; + + return $this; + } + + /** + * Number of errors encountered while trying to apply transformations. + * + * Generated from protobuf field int64 transformation_error_count = 3; + * @return int|string + */ + public function getTransformationErrorCount() + { + return $this->transformation_error_count; + } + + /** + * Number of errors encountered while trying to apply transformations. + * + * Generated from protobuf field int64 transformation_error_count = 3; + * @param int|string $var + * @return $this + */ + public function setTransformationErrorCount($var) + { + GPBUtil::checkInt64($var); + $this->transformation_error_count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyTemplate.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyTemplate.php new file mode 100644 index 000000000000..ed0862cbcb2b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyTemplate.php @@ -0,0 +1,282 @@ +google.privacy.dlp.v2.DeidentifyTemplate + */ +class DeidentifyTemplate extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The template name. + * The template will have one of the following formats: + * `projects/PROJECT_ID/deidentifyTemplates/TEMPLATE_ID` OR + * `organizations/ORGANIZATION_ID/deidentifyTemplates/TEMPLATE_ID` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Display name (max 256 chars). + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + /** + * Short description (max 256 chars). + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * Output only. The creation timestamp of an inspectTemplate. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The last update timestamp of an inspectTemplate. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * The core content of the template. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig deidentify_config = 6; + */ + protected $deidentify_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The template name. + * The template will have one of the following formats: + * `projects/PROJECT_ID/deidentifyTemplates/TEMPLATE_ID` OR + * `organizations/ORGANIZATION_ID/deidentifyTemplates/TEMPLATE_ID` + * @type string $display_name + * Display name (max 256 chars). + * @type string $description + * Short description (max 256 chars). + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The creation timestamp of an inspectTemplate. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The last update timestamp of an inspectTemplate. + * @type \Google\Cloud\Dlp\V2\DeidentifyConfig $deidentify_config + * The core content of the template. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The template name. + * The template will have one of the following formats: + * `projects/PROJECT_ID/deidentifyTemplates/TEMPLATE_ID` OR + * `organizations/ORGANIZATION_ID/deidentifyTemplates/TEMPLATE_ID` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. The template name. + * The template will have one of the following formats: + * `projects/PROJECT_ID/deidentifyTemplates/TEMPLATE_ID` OR + * `organizations/ORGANIZATION_ID/deidentifyTemplates/TEMPLATE_ID` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Display name (max 256 chars). + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Display name (max 256 chars). + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * Short description (max 256 chars). + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Short description (max 256 chars). + * + * 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; + } + + /** + * Output only. The creation timestamp of an inspectTemplate. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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 creation timestamp of an inspectTemplate. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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 last update timestamp of an inspectTemplate. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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 last update timestamp of an inspectTemplate. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * The core content of the template. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig deidentify_config = 6; + * @return \Google\Cloud\Dlp\V2\DeidentifyConfig|null + */ + public function getDeidentifyConfig() + { + return $this->deidentify_config; + } + + public function hasDeidentifyConfig() + { + return isset($this->deidentify_config); + } + + public function clearDeidentifyConfig() + { + unset($this->deidentify_config); + } + + /** + * The core content of the template. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig deidentify_config = 6; + * @param \Google\Cloud\Dlp\V2\DeidentifyConfig $var + * @return $this + */ + public function setDeidentifyConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyConfig::class); + $this->deidentify_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteConnectionRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteConnectionRequest.php new file mode 100644 index 000000000000..bb91b2b567db --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteConnectionRequest.php @@ -0,0 +1,86 @@ +google.privacy.dlp.v2.DeleteConnectionRequest + */ +class DeleteConnectionRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the Connection to be deleted, in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name of the Connection to be deleted, in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. Please see + * {@see DlpServiceClient::connectionName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\DeleteConnectionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the Connection to be deleted, in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the Connection to be deleted, in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the Connection to be deleted, in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDeidentifyTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDeidentifyTemplateRequest.php new file mode 100644 index 000000000000..0b3e5e031c0a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDeidentifyTemplateRequest.php @@ -0,0 +1,96 @@ +google.privacy.dlp.v2.DeleteDeidentifyTemplateRequest + */ +class DeleteDeidentifyTemplateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the organization and deidentify template to be + * deleted, for example + * `organizations/433245324/deidentifyTemplates/432452342` or + * projects/project-id/deidentifyTemplates/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name of the organization and deidentify template to be + * deleted, for example + * `organizations/433245324/deidentifyTemplates/432452342` or + * projects/project-id/deidentifyTemplates/432452342. Please see + * {@see DlpServiceClient::deidentifyTemplateName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\DeleteDeidentifyTemplateRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the organization and deidentify template to be + * deleted, for example + * `organizations/433245324/deidentifyTemplates/432452342` or + * projects/project-id/deidentifyTemplates/432452342. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the organization and deidentify template to be + * deleted, for example + * `organizations/433245324/deidentifyTemplates/432452342` or + * projects/project-id/deidentifyTemplates/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the organization and deidentify template to be + * deleted, for example + * `organizations/433245324/deidentifyTemplates/432452342` or + * projects/project-id/deidentifyTemplates/432452342. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDiscoveryConfigRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDiscoveryConfigRequest.php new file mode 100644 index 000000000000..6a20b7235350 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDiscoveryConfigRequest.php @@ -0,0 +1,86 @@ +google.privacy.dlp.v2.DeleteDiscoveryConfigRequest + */ +class DeleteDiscoveryConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the project and the config, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name of the project and the config, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. Please see + * {@see DlpServiceClient::discoveryConfigName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\DeleteDiscoveryConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the project and the config, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the project and the config, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the project and the config, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDlpJobRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDlpJobRequest.php new file mode 100644 index 000000000000..973c1c27b837 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDlpJobRequest.php @@ -0,0 +1,81 @@ +google.privacy.dlp.v2.DeleteDlpJobRequest + */ +class DeleteDlpJobRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the DlpJob resource to be deleted. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. The name of the DlpJob resource to be deleted. Please see + * {@see DlpServiceClient::dlpJobName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\DeleteDlpJobRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The name of the DlpJob resource to be deleted. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the DlpJob resource to be deleted. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The name of the DlpJob resource to be deleted. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteInspectTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteInspectTemplateRequest.php new file mode 100644 index 000000000000..247a31ff2442 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteInspectTemplateRequest.php @@ -0,0 +1,91 @@ +google.privacy.dlp.v2.DeleteInspectTemplateRequest + */ +class DeleteInspectTemplateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the organization and inspectTemplate to be + * deleted, for example `organizations/433245324/inspectTemplates/432452342` + * or projects/project-id/inspectTemplates/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name of the organization and inspectTemplate to be + * deleted, for example `organizations/433245324/inspectTemplates/432452342` + * or projects/project-id/inspectTemplates/432452342. Please see + * {@see DlpServiceClient::inspectTemplateName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\DeleteInspectTemplateRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the organization and inspectTemplate to be + * deleted, for example `organizations/433245324/inspectTemplates/432452342` + * or projects/project-id/inspectTemplates/432452342. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the organization and inspectTemplate to be + * deleted, for example `organizations/433245324/inspectTemplates/432452342` + * or projects/project-id/inspectTemplates/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the organization and inspectTemplate to be + * deleted, for example `organizations/433245324/inspectTemplates/432452342` + * or projects/project-id/inspectTemplates/432452342. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteJobTriggerRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteJobTriggerRequest.php new file mode 100644 index 000000000000..a5b16ef7a905 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteJobTriggerRequest.php @@ -0,0 +1,86 @@ +google.privacy.dlp.v2.DeleteJobTriggerRequest + */ +class DeleteJobTriggerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. Please see + * {@see DlpServiceClient::jobTriggerName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\DeleteJobTriggerRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteStoredInfoTypeRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteStoredInfoTypeRequest.php new file mode 100644 index 000000000000..d8d4c68e7530 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteStoredInfoTypeRequest.php @@ -0,0 +1,91 @@ +google.privacy.dlp.v2.DeleteStoredInfoTypeRequest + */ +class DeleteStoredInfoTypeRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the organization and storedInfoType to be + * deleted, for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name of the organization and storedInfoType to be + * deleted, for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. Please see + * {@see DlpServiceClient::storedInfoTypeName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\DeleteStoredInfoTypeRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the organization and storedInfoType to be + * deleted, for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the organization and storedInfoType to be + * deleted, for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the organization and storedInfoType to be + * deleted, for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteTableDataProfileRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteTableDataProfileRequest.php new file mode 100644 index 000000000000..e270dbd6466f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteTableDataProfileRequest.php @@ -0,0 +1,81 @@ +google.privacy.dlp.v2.DeleteTableDataProfileRequest + */ +class DeleteTableDataProfileRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the table data profile. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name of the table data profile. Please see + * {@see DlpServiceClient::tableDataProfileName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\DeleteTableDataProfileRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the table data profile. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the table data profile. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the table data profile. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Disabled.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Disabled.php new file mode 100644 index 000000000000..41edd890b7f6 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Disabled.php @@ -0,0 +1,33 @@ +google.privacy.dlp.v2.Disabled + */ +class Disabled extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions.php new file mode 100644 index 000000000000..79aa5b244deb --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions.php @@ -0,0 +1,204 @@ +google.privacy.dlp.v2.DiscoveryBigQueryConditions + */ +class DiscoveryBigQueryConditions extends \Google\Protobuf\Internal\Message +{ + /** + * BigQuery table must have been created after this date. Used to avoid + * backfilling. + * + * Generated from protobuf field .google.protobuf.Timestamp created_after = 1; + */ + protected $created_after = null; + /** + * At least one of the conditions must be true for a table to be scanned. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryConditions.OrConditions or_conditions = 4; + */ + protected $or_conditions = null; + protected $included_types; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Protobuf\Timestamp $created_after + * BigQuery table must have been created after this date. Used to avoid + * backfilling. + * @type \Google\Cloud\Dlp\V2\BigQueryTableTypes $types + * Restrict discovery to specific table types. + * @type int $type_collection + * Restrict discovery to categories of table types. + * @type \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions\OrConditions $or_conditions + * At least one of the conditions must be true for a table to be scanned. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * BigQuery table must have been created after this date. Used to avoid + * backfilling. + * + * Generated from protobuf field .google.protobuf.Timestamp created_after = 1; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreatedAfter() + { + return $this->created_after; + } + + public function hasCreatedAfter() + { + return isset($this->created_after); + } + + public function clearCreatedAfter() + { + unset($this->created_after); + } + + /** + * BigQuery table must have been created after this date. Used to avoid + * backfilling. + * + * Generated from protobuf field .google.protobuf.Timestamp created_after = 1; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreatedAfter($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->created_after = $var; + + return $this; + } + + /** + * Restrict discovery to specific table types. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTableTypes types = 2; + * @return \Google\Cloud\Dlp\V2\BigQueryTableTypes|null + */ + public function getTypes() + { + return $this->readOneof(2); + } + + public function hasTypes() + { + return $this->hasOneof(2); + } + + /** + * Restrict discovery to specific table types. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTableTypes types = 2; + * @param \Google\Cloud\Dlp\V2\BigQueryTableTypes $var + * @return $this + */ + public function setTypes($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTableTypes::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Restrict discovery to categories of table types. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTableTypeCollection type_collection = 3; + * @return int + */ + public function getTypeCollection() + { + return $this->readOneof(3); + } + + public function hasTypeCollection() + { + return $this->hasOneof(3); + } + + /** + * Restrict discovery to categories of table types. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTableTypeCollection type_collection = 3; + * @param int $var + * @return $this + */ + public function setTypeCollection($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\BigQueryTableTypeCollection::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * At least one of the conditions must be true for a table to be scanned. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryConditions.OrConditions or_conditions = 4; + * @return \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions\OrConditions|null + */ + public function getOrConditions() + { + return $this->or_conditions; + } + + public function hasOrConditions() + { + return isset($this->or_conditions); + } + + public function clearOrConditions() + { + unset($this->or_conditions); + } + + /** + * At least one of the conditions must be true for a table to be scanned. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryConditions.OrConditions or_conditions = 4; + * @param \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions\OrConditions $var + * @return $this + */ + public function setOrConditions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions\OrConditions::class); + $this->or_conditions = $var; + + return $this; + } + + /** + * @return string + */ + public function getIncludedTypes() + { + return $this->whichOneof("included_types"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions/OrConditions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions/OrConditions.php new file mode 100644 index 000000000000..be485bc77246 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions/OrConditions.php @@ -0,0 +1,123 @@ +google.privacy.dlp.v2.DiscoveryBigQueryConditions.OrConditions + */ +class OrConditions extends \Google\Protobuf\Internal\Message +{ + /** + * Minimum number of rows that should be present before Cloud DLP + * profiles a table + * + * Generated from protobuf field int32 min_row_count = 1; + */ + protected $min_row_count = 0; + /** + * Minimum age a table must have before Cloud DLP can profile it. Value must + * be 1 hour or greater. + * + * Generated from protobuf field .google.protobuf.Duration min_age = 2; + */ + protected $min_age = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $min_row_count + * Minimum number of rows that should be present before Cloud DLP + * profiles a table + * @type \Google\Protobuf\Duration $min_age + * Minimum age a table must have before Cloud DLP can profile it. Value must + * be 1 hour or greater. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Minimum number of rows that should be present before Cloud DLP + * profiles a table + * + * Generated from protobuf field int32 min_row_count = 1; + * @return int + */ + public function getMinRowCount() + { + return $this->min_row_count; + } + + /** + * Minimum number of rows that should be present before Cloud DLP + * profiles a table + * + * Generated from protobuf field int32 min_row_count = 1; + * @param int $var + * @return $this + */ + public function setMinRowCount($var) + { + GPBUtil::checkInt32($var); + $this->min_row_count = $var; + + return $this; + } + + /** + * Minimum age a table must have before Cloud DLP can profile it. Value must + * be 1 hour or greater. + * + * Generated from protobuf field .google.protobuf.Duration min_age = 2; + * @return \Google\Protobuf\Duration|null + */ + public function getMinAge() + { + return $this->min_age; + } + + public function hasMinAge() + { + return isset($this->min_age); + } + + public function clearMinAge() + { + unset($this->min_age); + } + + /** + * Minimum age a table must have before Cloud DLP can profile it. Value must + * be 1 hour or greater. + * + * Generated from protobuf field .google.protobuf.Duration min_age = 2; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setMinAge($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->min_age = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(OrConditions::class, \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions_OrConditions::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter.php new file mode 100644 index 000000000000..a87ee0ec1d3b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter.php @@ -0,0 +1,167 @@ +google.privacy.dlp.v2.DiscoveryBigQueryFilter + */ +class DiscoveryBigQueryFilter extends \Google\Protobuf\Internal\Message +{ + protected $filter; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\BigQueryTableCollection $tables + * A specific set of tables for this filter to apply to. A table collection + * must be specified in only one filter per config. + * If a table id or dataset is empty, Cloud DLP assumes all tables in that + * collection must be profiled. Must specify a project ID. + * @type \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter\AllOtherBigQueryTables $other_tables + * Catch-all. This should always be the last filter in the list because + * anything above it will apply first. Should only appear once in a + * configuration. If none is specified, a default one will be added + * automatically. + * @type \Google\Cloud\Dlp\V2\TableReference $table_reference + * The table to scan. Discovery configurations including this can only + * include one DiscoveryTarget (the DiscoveryTarget with this + * TableReference). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A specific set of tables for this filter to apply to. A table collection + * must be specified in only one filter per config. + * If a table id or dataset is empty, Cloud DLP assumes all tables in that + * collection must be profiled. Must specify a project ID. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTableCollection tables = 1; + * @return \Google\Cloud\Dlp\V2\BigQueryTableCollection|null + */ + public function getTables() + { + return $this->readOneof(1); + } + + public function hasTables() + { + return $this->hasOneof(1); + } + + /** + * A specific set of tables for this filter to apply to. A table collection + * must be specified in only one filter per config. + * If a table id or dataset is empty, Cloud DLP assumes all tables in that + * collection must be profiled. Must specify a project ID. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTableCollection tables = 1; + * @param \Google\Cloud\Dlp\V2\BigQueryTableCollection $var + * @return $this + */ + public function setTables($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTableCollection::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Catch-all. This should always be the last filter in the list because + * anything above it will apply first. Should only appear once in a + * configuration. If none is specified, a default one will be added + * automatically. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryFilter.AllOtherBigQueryTables other_tables = 2; + * @return \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter\AllOtherBigQueryTables|null + */ + public function getOtherTables() + { + return $this->readOneof(2); + } + + public function hasOtherTables() + { + return $this->hasOneof(2); + } + + /** + * Catch-all. This should always be the last filter in the list because + * anything above it will apply first. Should only appear once in a + * configuration. If none is specified, a default one will be added + * automatically. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryFilter.AllOtherBigQueryTables other_tables = 2; + * @param \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter\AllOtherBigQueryTables $var + * @return $this + */ + public function setOtherTables($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter\AllOtherBigQueryTables::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The table to scan. Discovery configurations including this can only + * include one DiscoveryTarget (the DiscoveryTarget with this + * TableReference). + * + * Generated from protobuf field .google.privacy.dlp.v2.TableReference table_reference = 3; + * @return \Google\Cloud\Dlp\V2\TableReference|null + */ + public function getTableReference() + { + return $this->readOneof(3); + } + + public function hasTableReference() + { + return $this->hasOneof(3); + } + + /** + * The table to scan. Discovery configurations including this can only + * include one DiscoveryTarget (the DiscoveryTarget with this + * TableReference). + * + * Generated from protobuf field .google.privacy.dlp.v2.TableReference table_reference = 3; + * @param \Google\Cloud\Dlp\V2\TableReference $var + * @return $this + */ + public function setTableReference($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableReference::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getFilter() + { + return $this->whichOneof("filter"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter/AllOtherBigQueryTables.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter/AllOtherBigQueryTables.php new file mode 100644 index 000000000000..10dc3a6a889a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter/AllOtherBigQueryTables.php @@ -0,0 +1,38 @@ +google.privacy.dlp.v2.DiscoveryBigQueryFilter.AllOtherBigQueryTables + */ +class AllOtherBigQueryTables extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AllOtherBigQueryTables::class, \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter_AllOtherBigQueryTables::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions.php new file mode 100644 index 000000000000..0697e79227ac --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions.php @@ -0,0 +1,114 @@ +google.privacy.dlp.v2.DiscoveryCloudSqlConditions + */ +class DiscoveryCloudSqlConditions extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Database engines that should be profiled. + * Optional. Defaults to ALL_SUPPORTED_DATABASE_ENGINES if unspecified. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseEngine database_engines = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $database_engines; + /** + * Data profiles will only be generated for the database resource types + * specified in this field. + * If not specified, defaults to [DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES]. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseResourceType types = 3; + */ + private $types; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $database_engines + * Optional. Database engines that should be profiled. + * Optional. Defaults to ALL_SUPPORTED_DATABASE_ENGINES if unspecified. + * @type array|\Google\Protobuf\Internal\RepeatedField $types + * Data profiles will only be generated for the database resource types + * specified in this field. + * If not specified, defaults to [DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES]. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Optional. Database engines that should be profiled. + * Optional. Defaults to ALL_SUPPORTED_DATABASE_ENGINES if unspecified. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseEngine database_engines = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDatabaseEngines() + { + return $this->database_engines; + } + + /** + * Optional. Database engines that should be profiled. + * Optional. Defaults to ALL_SUPPORTED_DATABASE_ENGINES if unspecified. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseEngine database_engines = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDatabaseEngines($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions\DatabaseEngine::class); + $this->database_engines = $arr; + + return $this; + } + + /** + * Data profiles will only be generated for the database resource types + * specified in this field. + * If not specified, defaults to [DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES]. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseResourceType types = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTypes() + { + return $this->types; + } + + /** + * Data profiles will only be generated for the database resource types + * specified in this field. + * If not specified, defaults to [DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES]. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseResourceType types = 3; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions\DatabaseResourceType::class); + $this->types = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseEngine.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseEngine.php new file mode 100644 index 000000000000..8438c6877e4a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseEngine.php @@ -0,0 +1,71 @@ +google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseEngine + */ +class DatabaseEngine +{ + /** + * Unused. + * + * Generated from protobuf enum DATABASE_ENGINE_UNSPECIFIED = 0; + */ + const DATABASE_ENGINE_UNSPECIFIED = 0; + /** + * Include all supported database engines. + * + * Generated from protobuf enum ALL_SUPPORTED_DATABASE_ENGINES = 1; + */ + const ALL_SUPPORTED_DATABASE_ENGINES = 1; + /** + * MySQL database. + * + * Generated from protobuf enum MYSQL = 2; + */ + const MYSQL = 2; + /** + * PostgreSQL database. + * + * Generated from protobuf enum POSTGRES = 3; + */ + const POSTGRES = 3; + + private static $valueToName = [ + self::DATABASE_ENGINE_UNSPECIFIED => 'DATABASE_ENGINE_UNSPECIFIED', + self::ALL_SUPPORTED_DATABASE_ENGINES => 'ALL_SUPPORTED_DATABASE_ENGINES', + self::MYSQL => 'MYSQL', + self::POSTGRES => 'POSTGRES', + ]; + + 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(DatabaseEngine::class, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions_DatabaseEngine::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseResourceType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseResourceType.php new file mode 100644 index 000000000000..50969361416d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseResourceType.php @@ -0,0 +1,64 @@ +google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseResourceType + */ +class DatabaseResourceType +{ + /** + * Unused. + * + * Generated from protobuf enum DATABASE_RESOURCE_TYPE_UNSPECIFIED = 0; + */ + const DATABASE_RESOURCE_TYPE_UNSPECIFIED = 0; + /** + * Includes database resource types that become supported at a later time. + * + * Generated from protobuf enum DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES = 1; + */ + const DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES = 1; + /** + * Tables. + * + * Generated from protobuf enum DATABASE_RESOURCE_TYPE_TABLE = 2; + */ + const DATABASE_RESOURCE_TYPE_TABLE = 2; + + private static $valueToName = [ + self::DATABASE_RESOURCE_TYPE_UNSPECIFIED => 'DATABASE_RESOURCE_TYPE_UNSPECIFIED', + self::DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES => 'DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES', + self::DATABASE_RESOURCE_TYPE_TABLE => 'DATABASE_RESOURCE_TYPE_TABLE', + ]; + + 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(DatabaseResourceType::class, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions_DatabaseResourceType::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlFilter.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlFilter.php new file mode 100644 index 000000000000..c2d34c2f8649 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlFilter.php @@ -0,0 +1,155 @@ +google.privacy.dlp.v2.DiscoveryCloudSqlFilter + */ +class DiscoveryCloudSqlFilter extends \Google\Protobuf\Internal\Message +{ + protected $filter; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DatabaseResourceCollection $collection + * A specific set of database resources for this filter to apply to. + * @type \Google\Cloud\Dlp\V2\AllOtherDatabaseResources $others + * Catch-all. This should always be the last target in the list because + * anything above it will apply first. Should only appear once in a + * configuration. If none is specified, a default one will be added + * automatically. + * @type \Google\Cloud\Dlp\V2\DatabaseResourceReference $database_resource_reference + * The database resource to scan. Targets including this can only include + * one target (the target with this database resource reference). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A specific set of database resources for this filter to apply to. + * + * Generated from protobuf field .google.privacy.dlp.v2.DatabaseResourceCollection collection = 1; + * @return \Google\Cloud\Dlp\V2\DatabaseResourceCollection|null + */ + public function getCollection() + { + return $this->readOneof(1); + } + + public function hasCollection() + { + return $this->hasOneof(1); + } + + /** + * A specific set of database resources for this filter to apply to. + * + * Generated from protobuf field .google.privacy.dlp.v2.DatabaseResourceCollection collection = 1; + * @param \Google\Cloud\Dlp\V2\DatabaseResourceCollection $var + * @return $this + */ + public function setCollection($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DatabaseResourceCollection::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Catch-all. This should always be the last target in the list because + * anything above it will apply first. Should only appear once in a + * configuration. If none is specified, a default one will be added + * automatically. + * + * Generated from protobuf field .google.privacy.dlp.v2.AllOtherDatabaseResources others = 2; + * @return \Google\Cloud\Dlp\V2\AllOtherDatabaseResources|null + */ + public function getOthers() + { + return $this->readOneof(2); + } + + public function hasOthers() + { + return $this->hasOneof(2); + } + + /** + * Catch-all. This should always be the last target in the list because + * anything above it will apply first. Should only appear once in a + * configuration. If none is specified, a default one will be added + * automatically. + * + * Generated from protobuf field .google.privacy.dlp.v2.AllOtherDatabaseResources others = 2; + * @param \Google\Cloud\Dlp\V2\AllOtherDatabaseResources $var + * @return $this + */ + public function setOthers($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AllOtherDatabaseResources::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The database resource to scan. Targets including this can only include + * one target (the target with this database resource reference). + * + * Generated from protobuf field .google.privacy.dlp.v2.DatabaseResourceReference database_resource_reference = 3; + * @return \Google\Cloud\Dlp\V2\DatabaseResourceReference|null + */ + public function getDatabaseResourceReference() + { + return $this->readOneof(3); + } + + public function hasDatabaseResourceReference() + { + return $this->hasOneof(3); + } + + /** + * The database resource to scan. Targets including this can only include + * one target (the target with this database resource reference). + * + * Generated from protobuf field .google.privacy.dlp.v2.DatabaseResourceReference database_resource_reference = 3; + * @param \Google\Cloud\Dlp\V2\DatabaseResourceReference $var + * @return $this + */ + public function setDatabaseResourceReference($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DatabaseResourceReference::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getFilter() + { + return $this->whichOneof("filter"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence.php new file mode 100644 index 000000000000..dd3a9545fe18 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence.php @@ -0,0 +1,125 @@ +google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence + */ +class DiscoveryCloudSqlGenerationCadence extends \Google\Protobuf\Internal\Message +{ + /** + * When to reprofile if the schema has changed. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence schema_modified_cadence = 1; + */ + protected $schema_modified_cadence = null; + /** + * Data changes (non-schema changes) in Cloud SQL tables can't trigger + * reprofiling. If you set this field, profiles are refreshed at this + * frequency regardless of whether the underlying tables have changed. + * Defaults to never. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency refresh_frequency = 2; + */ + protected $refresh_frequency = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence\SchemaModifiedCadence $schema_modified_cadence + * When to reprofile if the schema has changed. + * @type int $refresh_frequency + * Data changes (non-schema changes) in Cloud SQL tables can't trigger + * reprofiling. If you set this field, profiles are refreshed at this + * frequency regardless of whether the underlying tables have changed. + * Defaults to never. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * When to reprofile if the schema has changed. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence schema_modified_cadence = 1; + * @return \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence\SchemaModifiedCadence|null + */ + public function getSchemaModifiedCadence() + { + return $this->schema_modified_cadence; + } + + public function hasSchemaModifiedCadence() + { + return isset($this->schema_modified_cadence); + } + + public function clearSchemaModifiedCadence() + { + unset($this->schema_modified_cadence); + } + + /** + * When to reprofile if the schema has changed. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence schema_modified_cadence = 1; + * @param \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence\SchemaModifiedCadence $var + * @return $this + */ + public function setSchemaModifiedCadence($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence\SchemaModifiedCadence::class); + $this->schema_modified_cadence = $var; + + return $this; + } + + /** + * Data changes (non-schema changes) in Cloud SQL tables can't trigger + * reprofiling. If you set this field, profiles are refreshed at this + * frequency regardless of whether the underlying tables have changed. + * Defaults to never. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency refresh_frequency = 2; + * @return int + */ + public function getRefreshFrequency() + { + return $this->refresh_frequency; + } + + /** + * Data changes (non-schema changes) in Cloud SQL tables can't trigger + * reprofiling. If you set this field, profiles are refreshed at this + * frequency regardless of whether the underlying tables have changed. + * Defaults to never. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency refresh_frequency = 2; + * @param int $var + * @return $this + */ + public function setRefreshFrequency($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileUpdateFrequency::class); + $this->refresh_frequency = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence.php new file mode 100644 index 000000000000..60ebef96f635 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence.php @@ -0,0 +1,112 @@ +google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence + */ +class SchemaModifiedCadence extends \Google\Protobuf\Internal\Message +{ + /** + * The types of schema modifications to consider. + * Defaults to NEW_COLUMNS. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence.CloudSqlSchemaModification types = 1; + */ + private $types; + /** + * Frequency to regenerate data profiles when the schema is modified. + * Defaults to monthly. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; + */ + protected $frequency = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $types + * The types of schema modifications to consider. + * Defaults to NEW_COLUMNS. + * @type int $frequency + * Frequency to regenerate data profiles when the schema is modified. + * Defaults to monthly. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The types of schema modifications to consider. + * Defaults to NEW_COLUMNS. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence.CloudSqlSchemaModification types = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTypes() + { + return $this->types; + } + + /** + * The types of schema modifications to consider. + * Defaults to NEW_COLUMNS. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence.CloudSqlSchemaModification types = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence\SchemaModifiedCadence\CloudSqlSchemaModification::class); + $this->types = $arr; + + return $this; + } + + /** + * Frequency to regenerate data profiles when the schema is modified. + * Defaults to monthly. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; + * @return int + */ + public function getFrequency() + { + return $this->frequency; + } + + /** + * Frequency to regenerate data profiles when the schema is modified. + * Defaults to monthly. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; + * @param int $var + * @return $this + */ + public function setFrequency($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileUpdateFrequency::class); + $this->frequency = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SchemaModifiedCadence::class, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence_SchemaModifiedCadence::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence/CloudSqlSchemaModification.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence/CloudSqlSchemaModification.php new file mode 100644 index 000000000000..38682145dfb2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence/CloudSqlSchemaModification.php @@ -0,0 +1,64 @@ +google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence.CloudSqlSchemaModification + */ +class CloudSqlSchemaModification +{ + /** + * Unused. + * + * Generated from protobuf enum SQL_SCHEMA_MODIFICATION_UNSPECIFIED = 0; + */ + const SQL_SCHEMA_MODIFICATION_UNSPECIFIED = 0; + /** + * New columns have appeared. + * + * Generated from protobuf enum NEW_COLUMNS = 1; + */ + const NEW_COLUMNS = 1; + /** + * Columns have been removed from the table. + * + * Generated from protobuf enum REMOVED_COLUMNS = 2; + */ + const REMOVED_COLUMNS = 2; + + private static $valueToName = [ + self::SQL_SCHEMA_MODIFICATION_UNSPECIFIED => 'SQL_SCHEMA_MODIFICATION_UNSPECIFIED', + self::NEW_COLUMNS => 'NEW_COLUMNS', + self::REMOVED_COLUMNS => 'REMOVED_COLUMNS', + ]; + + 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(CloudSqlSchemaModification::class, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence_SchemaModifiedCadence_CloudSqlSchemaModification::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig.php new file mode 100644 index 000000000000..c78a915b00dd --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig.php @@ -0,0 +1,520 @@ +google.privacy.dlp.v2.DiscoveryConfig + */ +class DiscoveryConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Unique resource name for the DiscoveryConfig, assigned by the service when + * the DiscoveryConfig is created, for example + * `projects/dlp-test-project/locations/global/discoveryConfigs/53234423`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Display name (max 100 chars) + * + * Generated from protobuf field string display_name = 11; + */ + protected $display_name = ''; + /** + * Only set when the parent is an org. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig.OrgConfig org_config = 2; + */ + protected $org_config = null; + /** + * Detection logic for profile generation. + * Not all template features are used by Discovery. FindingLimits, + * include_quote and exclude_info_types have no impact on + * Discovery. + * Multiple templates may be provided if there is data in multiple regions. + * At most one template must be specified per-region (including "global"). + * Each region is scanned using the applicable template. If no region-specific + * template is specified, but a "global" template is specified, it will be + * copied to that region and used instead. If no global or region-specific + * template is provided for a region with data, that region's data will not be + * scanned. + * For more information, see + * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. + * + * Generated from protobuf field repeated string inspect_templates = 3; + */ + private $inspect_templates; + /** + * Actions to execute at the completion of scanning. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfileAction actions = 4; + */ + private $actions; + /** + * Target to match against for determining what to scan and how frequently. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryTarget targets = 5; + */ + private $targets; + /** + * Output only. A stream of errors encountered when the config was activated. + * Repeated errors may result in the config automatically being paused. Output + * only field. Will return the last 100 errors. Whenever the config is + * modified this list will be cleared. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $errors; + /** + * Output only. The creation timestamp of a DiscoveryConfig. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The last update timestamp of a DiscoveryConfig. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. The timestamp of the last time this config was executed. + * + * Generated from protobuf field .google.protobuf.Timestamp last_run_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $last_run_time = null; + /** + * Required. A status for this configuration. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig.Status status = 10 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $status = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Unique resource name for the DiscoveryConfig, assigned by the service when + * the DiscoveryConfig is created, for example + * `projects/dlp-test-project/locations/global/discoveryConfigs/53234423`. + * @type string $display_name + * Display name (max 100 chars) + * @type \Google\Cloud\Dlp\V2\DiscoveryConfig\OrgConfig $org_config + * Only set when the parent is an org. + * @type array|\Google\Protobuf\Internal\RepeatedField $inspect_templates + * Detection logic for profile generation. + * Not all template features are used by Discovery. FindingLimits, + * include_quote and exclude_info_types have no impact on + * Discovery. + * Multiple templates may be provided if there is data in multiple regions. + * At most one template must be specified per-region (including "global"). + * Each region is scanned using the applicable template. If no region-specific + * template is specified, but a "global" template is specified, it will be + * copied to that region and used instead. If no global or region-specific + * template is provided for a region with data, that region's data will not be + * scanned. + * For more information, see + * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. + * @type array<\Google\Cloud\Dlp\V2\DataProfileAction>|\Google\Protobuf\Internal\RepeatedField $actions + * Actions to execute at the completion of scanning. + * @type array<\Google\Cloud\Dlp\V2\DiscoveryTarget>|\Google\Protobuf\Internal\RepeatedField $targets + * Target to match against for determining what to scan and how frequently. + * @type array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $errors + * Output only. A stream of errors encountered when the config was activated. + * Repeated errors may result in the config automatically being paused. Output + * only field. Will return the last 100 errors. Whenever the config is + * modified this list will be cleared. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The creation timestamp of a DiscoveryConfig. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The last update timestamp of a DiscoveryConfig. + * @type \Google\Protobuf\Timestamp $last_run_time + * Output only. The timestamp of the last time this config was executed. + * @type int $status + * Required. A status for this configuration. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Unique resource name for the DiscoveryConfig, assigned by the service when + * the DiscoveryConfig is created, for example + * `projects/dlp-test-project/locations/global/discoveryConfigs/53234423`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Unique resource name for the DiscoveryConfig, assigned by the service when + * the DiscoveryConfig is created, for example + * `projects/dlp-test-project/locations/global/discoveryConfigs/53234423`. + * + * 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; + } + + /** + * Display name (max 100 chars) + * + * Generated from protobuf field string display_name = 11; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Display name (max 100 chars) + * + * Generated from protobuf field string display_name = 11; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * Only set when the parent is an org. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig.OrgConfig org_config = 2; + * @return \Google\Cloud\Dlp\V2\DiscoveryConfig\OrgConfig|null + */ + public function getOrgConfig() + { + return $this->org_config; + } + + public function hasOrgConfig() + { + return isset($this->org_config); + } + + public function clearOrgConfig() + { + unset($this->org_config); + } + + /** + * Only set when the parent is an org. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig.OrgConfig org_config = 2; + * @param \Google\Cloud\Dlp\V2\DiscoveryConfig\OrgConfig $var + * @return $this + */ + public function setOrgConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryConfig\OrgConfig::class); + $this->org_config = $var; + + return $this; + } + + /** + * Detection logic for profile generation. + * Not all template features are used by Discovery. FindingLimits, + * include_quote and exclude_info_types have no impact on + * Discovery. + * Multiple templates may be provided if there is data in multiple regions. + * At most one template must be specified per-region (including "global"). + * Each region is scanned using the applicable template. If no region-specific + * template is specified, but a "global" template is specified, it will be + * copied to that region and used instead. If no global or region-specific + * template is provided for a region with data, that region's data will not be + * scanned. + * For more information, see + * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. + * + * Generated from protobuf field repeated string inspect_templates = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getInspectTemplates() + { + return $this->inspect_templates; + } + + /** + * Detection logic for profile generation. + * Not all template features are used by Discovery. FindingLimits, + * include_quote and exclude_info_types have no impact on + * Discovery. + * Multiple templates may be provided if there is data in multiple regions. + * At most one template must be specified per-region (including "global"). + * Each region is scanned using the applicable template. If no region-specific + * template is specified, but a "global" template is specified, it will be + * copied to that region and used instead. If no global or region-specific + * template is provided for a region with data, that region's data will not be + * scanned. + * For more information, see + * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. + * + * Generated from protobuf field repeated string inspect_templates = 3; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setInspectTemplates($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->inspect_templates = $arr; + + return $this; + } + + /** + * Actions to execute at the completion of scanning. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfileAction actions = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getActions() + { + return $this->actions; + } + + /** + * Actions to execute at the completion of scanning. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfileAction actions = 4; + * @param array<\Google\Cloud\Dlp\V2\DataProfileAction>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setActions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DataProfileAction::class); + $this->actions = $arr; + + return $this; + } + + /** + * Target to match against for determining what to scan and how frequently. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryTarget targets = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTargets() + { + return $this->targets; + } + + /** + * Target to match against for determining what to scan and how frequently. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryTarget targets = 5; + * @param array<\Google\Cloud\Dlp\V2\DiscoveryTarget>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTargets($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DiscoveryTarget::class); + $this->targets = $arr; + + return $this; + } + + /** + * Output only. A stream of errors encountered when the config was activated. + * Repeated errors may result in the config automatically being paused. Output + * only field. Will return the last 100 errors. Whenever the config is + * modified this list will be cleared. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getErrors() + { + return $this->errors; + } + + /** + * Output only. A stream of errors encountered when the config was activated. + * Repeated errors may result in the config automatically being paused. Output + * only field. Will return the last 100 errors. Whenever the config is + * modified this list will be cleared. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setErrors($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Error::class); + $this->errors = $arr; + + return $this; + } + + /** + * Output only. The creation timestamp of a DiscoveryConfig. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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 creation timestamp of a DiscoveryConfig. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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 last update timestamp of a DiscoveryConfig. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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 last update timestamp of a DiscoveryConfig. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Output only. The timestamp of the last time this config was executed. + * + * Generated from protobuf field .google.protobuf.Timestamp last_run_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getLastRunTime() + { + return $this->last_run_time; + } + + public function hasLastRunTime() + { + return isset($this->last_run_time); + } + + public function clearLastRunTime() + { + unset($this->last_run_time); + } + + /** + * Output only. The timestamp of the last time this config was executed. + * + * Generated from protobuf field .google.protobuf.Timestamp last_run_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setLastRunTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->last_run_time = $var; + + return $this; + } + + /** + * Required. A status for this configuration. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig.Status status = 10 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getStatus() + { + return $this->status; + } + + /** + * Required. A status for this configuration. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig.Status status = 10 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setStatus($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DiscoveryConfig\Status::class); + $this->status = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/OrgConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/OrgConfig.php new file mode 100644 index 000000000000..f562a26a05a6 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/OrgConfig.php @@ -0,0 +1,122 @@ +google.privacy.dlp.v2.DiscoveryConfig.OrgConfig + */ +class OrgConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The data to scan: folder, org, or project + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryStartingLocation location = 1; + */ + protected $location = null; + /** + * The project that will run the scan. The DLP service + * account that exists within this project must have access to all resources + * that are profiled, and the Cloud DLP API must be enabled. + * + * Generated from protobuf field string project_id = 2; + */ + protected $project_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DiscoveryStartingLocation $location + * The data to scan: folder, org, or project + * @type string $project_id + * The project that will run the scan. The DLP service + * account that exists within this project must have access to all resources + * that are profiled, and the Cloud DLP API must be enabled. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The data to scan: folder, org, or project + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryStartingLocation location = 1; + * @return \Google\Cloud\Dlp\V2\DiscoveryStartingLocation|null + */ + public function getLocation() + { + return $this->location; + } + + public function hasLocation() + { + return isset($this->location); + } + + public function clearLocation() + { + unset($this->location); + } + + /** + * The data to scan: folder, org, or project + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryStartingLocation location = 1; + * @param \Google\Cloud\Dlp\V2\DiscoveryStartingLocation $var + * @return $this + */ + public function setLocation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryStartingLocation::class); + $this->location = $var; + + return $this; + } + + /** + * The project that will run the scan. The DLP service + * account that exists within this project must have access to all resources + * that are profiled, and the Cloud DLP API must be enabled. + * + * Generated from protobuf field string project_id = 2; + * @return string + */ + public function getProjectId() + { + return $this->project_id; + } + + /** + * The project that will run the scan. The DLP service + * account that exists within this project must have access to all resources + * that are profiled, and the Cloud DLP API must be enabled. + * + * 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; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(OrgConfig::class, \Google\Cloud\Dlp\V2\DiscoveryConfig_OrgConfig::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/Status.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/Status.php new file mode 100644 index 000000000000..64226233f6e9 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/Status.php @@ -0,0 +1,65 @@ +google.privacy.dlp.v2.DiscoveryConfig.Status + */ +class Status +{ + /** + * Unused + * + * Generated from protobuf enum STATUS_UNSPECIFIED = 0; + */ + const STATUS_UNSPECIFIED = 0; + /** + * The discovery config is currently active. + * + * Generated from protobuf enum RUNNING = 1; + */ + const RUNNING = 1; + /** + * The discovery config is paused temporarily. + * + * Generated from protobuf enum PAUSED = 2; + */ + const PAUSED = 2; + + private static $valueToName = [ + self::STATUS_UNSPECIFIED => 'STATUS_UNSPECIFIED', + self::RUNNING => 'RUNNING', + self::PAUSED => 'PAUSED', + ]; + + 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(Status::class, \Google\Cloud\Dlp\V2\DiscoveryConfig_Status::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryGenerationCadence.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryGenerationCadence.php new file mode 100644 index 000000000000..5e0977e435b4 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryGenerationCadence.php @@ -0,0 +1,124 @@ +google.privacy.dlp.v2.DiscoveryGenerationCadence + */ +class DiscoveryGenerationCadence extends \Google\Protobuf\Internal\Message +{ + /** + * Governs when to update data profiles when a schema is modified. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoverySchemaModifiedCadence schema_modified_cadence = 1; + */ + protected $schema_modified_cadence = null; + /** + * Governs when to update data profiles when a table is modified. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryTableModifiedCadence table_modified_cadence = 2; + */ + protected $table_modified_cadence = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DiscoverySchemaModifiedCadence $schema_modified_cadence + * Governs when to update data profiles when a schema is modified. + * @type \Google\Cloud\Dlp\V2\DiscoveryTableModifiedCadence $table_modified_cadence + * Governs when to update data profiles when a table is modified. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Governs when to update data profiles when a schema is modified. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoverySchemaModifiedCadence schema_modified_cadence = 1; + * @return \Google\Cloud\Dlp\V2\DiscoverySchemaModifiedCadence|null + */ + public function getSchemaModifiedCadence() + { + return $this->schema_modified_cadence; + } + + public function hasSchemaModifiedCadence() + { + return isset($this->schema_modified_cadence); + } + + public function clearSchemaModifiedCadence() + { + unset($this->schema_modified_cadence); + } + + /** + * Governs when to update data profiles when a schema is modified. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoverySchemaModifiedCadence schema_modified_cadence = 1; + * @param \Google\Cloud\Dlp\V2\DiscoverySchemaModifiedCadence $var + * @return $this + */ + public function setSchemaModifiedCadence($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoverySchemaModifiedCadence::class); + $this->schema_modified_cadence = $var; + + return $this; + } + + /** + * Governs when to update data profiles when a table is modified. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryTableModifiedCadence table_modified_cadence = 2; + * @return \Google\Cloud\Dlp\V2\DiscoveryTableModifiedCadence|null + */ + public function getTableModifiedCadence() + { + return $this->table_modified_cadence; + } + + public function hasTableModifiedCadence() + { + return isset($this->table_modified_cadence); + } + + public function clearTableModifiedCadence() + { + unset($this->table_modified_cadence); + } + + /** + * Governs when to update data profiles when a table is modified. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryTableModifiedCadence table_modified_cadence = 2; + * @param \Google\Cloud\Dlp\V2\DiscoveryTableModifiedCadence $var + * @return $this + */ + public function setTableModifiedCadence($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryTableModifiedCadence::class); + $this->table_modified_cadence = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoverySchemaModifiedCadence.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoverySchemaModifiedCadence.php new file mode 100644 index 000000000000..0fa1784d3daf --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoverySchemaModifiedCadence.php @@ -0,0 +1,113 @@ +google.privacy.dlp.v2.DiscoverySchemaModifiedCadence + */ +class DiscoverySchemaModifiedCadence extends \Google\Protobuf\Internal\Message +{ + /** + * The type of events to consider when deciding if the table's schema + * has been modified and should have the profile updated. Defaults to + * NEW_COLUMNS. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQuerySchemaModification types = 1; + */ + private $types; + /** + * How frequently profiles may be updated when schemas are + * modified. Defaults to monthly. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; + */ + protected $frequency = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $types + * The type of events to consider when deciding if the table's schema + * has been modified and should have the profile updated. Defaults to + * NEW_COLUMNS. + * @type int $frequency + * How frequently profiles may be updated when schemas are + * modified. Defaults to monthly. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The type of events to consider when deciding if the table's schema + * has been modified and should have the profile updated. Defaults to + * NEW_COLUMNS. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQuerySchemaModification types = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTypes() + { + return $this->types; + } + + /** + * The type of events to consider when deciding if the table's schema + * has been modified and should have the profile updated. Defaults to + * NEW_COLUMNS. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQuerySchemaModification types = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\BigQuerySchemaModification::class); + $this->types = $arr; + + return $this; + } + + /** + * How frequently profiles may be updated when schemas are + * modified. Defaults to monthly. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; + * @return int + */ + public function getFrequency() + { + return $this->frequency; + } + + /** + * How frequently profiles may be updated when schemas are + * modified. Defaults to monthly. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; + * @param int $var + * @return $this + */ + public function setFrequency($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileUpdateFrequency::class); + $this->frequency = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryStartingLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryStartingLocation.php new file mode 100644 index 000000000000..702d9f4d5bbc --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryStartingLocation.php @@ -0,0 +1,109 @@ +google.privacy.dlp.v2.DiscoveryStartingLocation + */ +class DiscoveryStartingLocation extends \Google\Protobuf\Internal\Message +{ + protected $location; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $organization_id + * The ID of an organization to scan. + * @type int|string $folder_id + * The ID of the Folder within an organization to scan. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The ID of an organization to scan. + * + * Generated from protobuf field int64 organization_id = 1; + * @return int|string + */ + public function getOrganizationId() + { + return $this->readOneof(1); + } + + public function hasOrganizationId() + { + return $this->hasOneof(1); + } + + /** + * The ID of an organization to scan. + * + * Generated from protobuf field int64 organization_id = 1; + * @param int|string $var + * @return $this + */ + public function setOrganizationId($var) + { + GPBUtil::checkInt64($var); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * The ID of the Folder within an organization to scan. + * + * Generated from protobuf field int64 folder_id = 2; + * @return int|string + */ + public function getFolderId() + { + return $this->readOneof(2); + } + + public function hasFolderId() + { + return $this->hasOneof(2); + } + + /** + * The ID of the Folder within an organization to scan. + * + * Generated from protobuf field int64 folder_id = 2; + * @param int|string $var + * @return $this + */ + public function setFolderId($var) + { + GPBUtil::checkInt64($var); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getLocation() + { + return $this->whichOneof("location"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTableModifiedCadence.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTableModifiedCadence.php new file mode 100644 index 000000000000..41c4460b6233 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTableModifiedCadence.php @@ -0,0 +1,113 @@ +google.privacy.dlp.v2.DiscoveryTableModifiedCadence + */ +class DiscoveryTableModifiedCadence extends \Google\Protobuf\Internal\Message +{ + /** + * The type of events to consider when deciding if the table has been + * modified and should have the profile updated. Defaults to + * MODIFIED_TIMESTAMP. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryTableModification types = 1; + */ + private $types; + /** + * How frequently data profiles can be updated when tables are modified. + * Defaults to never. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; + */ + protected $frequency = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $types + * The type of events to consider when deciding if the table has been + * modified and should have the profile updated. Defaults to + * MODIFIED_TIMESTAMP. + * @type int $frequency + * How frequently data profiles can be updated when tables are modified. + * Defaults to never. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The type of events to consider when deciding if the table has been + * modified and should have the profile updated. Defaults to + * MODIFIED_TIMESTAMP. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryTableModification types = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTypes() + { + return $this->types; + } + + /** + * The type of events to consider when deciding if the table has been + * modified and should have the profile updated. Defaults to + * MODIFIED_TIMESTAMP. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryTableModification types = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\BigQueryTableModification::class); + $this->types = $arr; + + return $this; + } + + /** + * How frequently data profiles can be updated when tables are modified. + * Defaults to never. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; + * @return int + */ + public function getFrequency() + { + return $this->frequency; + } + + /** + * How frequently data profiles can be updated when tables are modified. + * Defaults to never. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; + * @param int $var + * @return $this + */ + public function setFrequency($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileUpdateFrequency::class); + $this->frequency = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTarget.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTarget.php new file mode 100644 index 000000000000..b9b4cc728e9b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTarget.php @@ -0,0 +1,153 @@ +google.privacy.dlp.v2.DiscoveryTarget + */ +class DiscoveryTarget extends \Google\Protobuf\Internal\Message +{ + protected $target; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\BigQueryDiscoveryTarget $big_query_target + * BigQuery target for Discovery. The first target to match a table will be + * the one applied. + * @type \Google\Cloud\Dlp\V2\CloudSqlDiscoveryTarget $cloud_sql_target + * Cloud SQL target for Discovery. The first target to match a table will be + * the one applied. + * @type \Google\Cloud\Dlp\V2\SecretsDiscoveryTarget $secrets_target + * Discovery target that looks for credentials and secrets stored in cloud + * resource metadata and reports them as vulnerabilities to Security Command + * Center. Only one target of this type is allowed. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * BigQuery target for Discovery. The first target to match a table will be + * the one applied. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryDiscoveryTarget big_query_target = 1; + * @return \Google\Cloud\Dlp\V2\BigQueryDiscoveryTarget|null + */ + public function getBigQueryTarget() + { + return $this->readOneof(1); + } + + public function hasBigQueryTarget() + { + return $this->hasOneof(1); + } + + /** + * BigQuery target for Discovery. The first target to match a table will be + * the one applied. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryDiscoveryTarget big_query_target = 1; + * @param \Google\Cloud\Dlp\V2\BigQueryDiscoveryTarget $var + * @return $this + */ + public function setBigQueryTarget($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryDiscoveryTarget::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Cloud SQL target for Discovery. The first target to match a table will be + * the one applied. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlDiscoveryTarget cloud_sql_target = 2; + * @return \Google\Cloud\Dlp\V2\CloudSqlDiscoveryTarget|null + */ + public function getCloudSqlTarget() + { + return $this->readOneof(2); + } + + public function hasCloudSqlTarget() + { + return $this->hasOneof(2); + } + + /** + * Cloud SQL target for Discovery. The first target to match a table will be + * the one applied. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlDiscoveryTarget cloud_sql_target = 2; + * @param \Google\Cloud\Dlp\V2\CloudSqlDiscoveryTarget $var + * @return $this + */ + public function setCloudSqlTarget($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudSqlDiscoveryTarget::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Discovery target that looks for credentials and secrets stored in cloud + * resource metadata and reports them as vulnerabilities to Security Command + * Center. Only one target of this type is allowed. + * + * Generated from protobuf field .google.privacy.dlp.v2.SecretsDiscoveryTarget secrets_target = 3; + * @return \Google\Cloud\Dlp\V2\SecretsDiscoveryTarget|null + */ + public function getSecretsTarget() + { + return $this->readOneof(3); + } + + public function hasSecretsTarget() + { + return $this->hasOneof(3); + } + + /** + * Discovery target that looks for credentials and secrets stored in cloud + * resource metadata and reports them as vulnerabilities to Security Command + * Center. Only one target of this type is allowed. + * + * Generated from protobuf field .google.privacy.dlp.v2.SecretsDiscoveryTarget secrets_target = 3; + * @param \Google\Cloud\Dlp\V2\SecretsDiscoveryTarget $var + * @return $this + */ + public function setSecretsTarget($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SecretsDiscoveryTarget::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getTarget() + { + return $this->whichOneof("target"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob.php new file mode 100644 index 000000000000..9bd92b2beccb --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob.php @@ -0,0 +1,492 @@ +google.privacy.dlp.v2.DlpJob + */ +class DlpJob extends \Google\Protobuf\Internal\Message +{ + /** + * The server-assigned name. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The type of job. + * + * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 2; + */ + protected $type = 0; + /** + * State of a job. + * + * Generated from protobuf field .google.privacy.dlp.v2.DlpJob.JobState state = 3; + */ + protected $state = 0; + /** + * Time when the job was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; + */ + protected $create_time = null; + /** + * Time when the job started. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 7; + */ + protected $start_time = null; + /** + * Time when the job finished. + * + * Generated from protobuf field .google.protobuf.Timestamp end_time = 8; + */ + protected $end_time = null; + /** + * Time when the job was last modified by the system. + * + * Generated from protobuf field .google.protobuf.Timestamp last_modified = 15; + */ + protected $last_modified = null; + /** + * If created by a job trigger, the resource name of the trigger that + * instantiated the job. + * + * Generated from protobuf field string job_trigger_name = 10; + */ + protected $job_trigger_name = ''; + /** + * A stream of errors encountered running the job. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 11; + */ + private $errors; + /** + * Events that should occur after the job has completed. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ActionDetails action_details = 12; + */ + private $action_details; + protected $details; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The server-assigned name. + * @type int $type + * The type of job. + * @type int $state + * State of a job. + * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails $risk_details + * Results from analyzing risk of a data source. + * @type \Google\Cloud\Dlp\V2\InspectDataSourceDetails $inspect_details + * Results from inspecting a data source. + * @type \Google\Protobuf\Timestamp $create_time + * Time when the job was created. + * @type \Google\Protobuf\Timestamp $start_time + * Time when the job started. + * @type \Google\Protobuf\Timestamp $end_time + * Time when the job finished. + * @type \Google\Protobuf\Timestamp $last_modified + * Time when the job was last modified by the system. + * @type string $job_trigger_name + * If created by a job trigger, the resource name of the trigger that + * instantiated the job. + * @type array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $errors + * A stream of errors encountered running the job. + * @type array<\Google\Cloud\Dlp\V2\ActionDetails>|\Google\Protobuf\Internal\RepeatedField $action_details + * Events that should occur after the job has completed. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The server-assigned name. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The server-assigned 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; + } + + /** + * The type of job. + * + * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 2; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * The type of job. + * + * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 2; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DlpJobType::class); + $this->type = $var; + + return $this; + } + + /** + * State of a job. + * + * Generated from protobuf field .google.privacy.dlp.v2.DlpJob.JobState state = 3; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * State of a job. + * + * Generated from protobuf field .google.privacy.dlp.v2.DlpJob.JobState state = 3; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DlpJob\JobState::class); + $this->state = $var; + + return $this; + } + + /** + * Results from analyzing risk of a data source. + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails risk_details = 4; + * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails|null + */ + public function getRiskDetails() + { + return $this->readOneof(4); + } + + public function hasRiskDetails() + { + return $this->hasOneof(4); + } + + /** + * Results from analyzing risk of a data source. + * + * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails risk_details = 4; + * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails $var + * @return $this + */ + public function setRiskDetails($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Results from inspecting a data source. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails inspect_details = 5; + * @return \Google\Cloud\Dlp\V2\InspectDataSourceDetails|null + */ + public function getInspectDetails() + { + return $this->readOneof(5); + } + + public function hasInspectDetails() + { + return $this->hasOneof(5); + } + + /** + * Results from inspecting a data source. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails inspect_details = 5; + * @param \Google\Cloud\Dlp\V2\InspectDataSourceDetails $var + * @return $this + */ + public function setInspectDetails($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectDataSourceDetails::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * Time when the job 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); + } + + /** + * Time when the job 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; + } + + /** + * Time when the job started. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 7; + * @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 when the job started. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 7; + * @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 when the job finished. + * + * Generated from protobuf field .google.protobuf.Timestamp end_time = 8; + * @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 when the job finished. + * + * Generated from protobuf field .google.protobuf.Timestamp end_time = 8; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setEndTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->end_time = $var; + + return $this; + } + + /** + * Time when the job was last modified by the system. + * + * Generated from protobuf field .google.protobuf.Timestamp last_modified = 15; + * @return \Google\Protobuf\Timestamp|null + */ + public function getLastModified() + { + return $this->last_modified; + } + + public function hasLastModified() + { + return isset($this->last_modified); + } + + public function clearLastModified() + { + unset($this->last_modified); + } + + /** + * Time when the job was last modified by the system. + * + * Generated from protobuf field .google.protobuf.Timestamp last_modified = 15; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setLastModified($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->last_modified = $var; + + return $this; + } + + /** + * If created by a job trigger, the resource name of the trigger that + * instantiated the job. + * + * Generated from protobuf field string job_trigger_name = 10; + * @return string + */ + public function getJobTriggerName() + { + return $this->job_trigger_name; + } + + /** + * If created by a job trigger, the resource name of the trigger that + * instantiated the job. + * + * Generated from protobuf field string job_trigger_name = 10; + * @param string $var + * @return $this + */ + public function setJobTriggerName($var) + { + GPBUtil::checkString($var, True); + $this->job_trigger_name = $var; + + return $this; + } + + /** + * A stream of errors encountered running the job. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 11; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getErrors() + { + return $this->errors; + } + + /** + * A stream of errors encountered running the job. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 11; + * @param array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setErrors($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Error::class); + $this->errors = $arr; + + return $this; + } + + /** + * Events that should occur after the job has completed. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ActionDetails action_details = 12; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getActionDetails() + { + return $this->action_details; + } + + /** + * Events that should occur after the job has completed. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ActionDetails action_details = 12; + * @param array<\Google\Cloud\Dlp\V2\ActionDetails>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setActionDetails($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ActionDetails::class); + $this->action_details = $arr; + + return $this; + } + + /** + * @return string + */ + public function getDetails() + { + return $this->whichOneof("details"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob/JobState.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob/JobState.php new file mode 100644 index 000000000000..5ba68c696f63 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob/JobState.php @@ -0,0 +1,96 @@ +google.privacy.dlp.v2.DlpJob.JobState + */ +class JobState +{ + /** + * Unused. + * + * Generated from protobuf enum JOB_STATE_UNSPECIFIED = 0; + */ + const JOB_STATE_UNSPECIFIED = 0; + /** + * The job has not yet started. + * + * Generated from protobuf enum PENDING = 1; + */ + const PENDING = 1; + /** + * The job is currently running. Once a job has finished it will transition + * to FAILED or DONE. + * + * Generated from protobuf enum RUNNING = 2; + */ + const RUNNING = 2; + /** + * The job is no longer running. + * + * Generated from protobuf enum DONE = 3; + */ + const DONE = 3; + /** + * The job was canceled before it could be completed. + * + * Generated from protobuf enum CANCELED = 4; + */ + const CANCELED = 4; + /** + * The job had an error and did not complete. + * + * Generated from protobuf enum FAILED = 5; + */ + const FAILED = 5; + /** + * The job is currently accepting findings via hybridInspect. + * A hybrid job in ACTIVE state may continue to have findings added to it + * through the calling of hybridInspect. After the job has finished no more + * calls to hybridInspect may be made. ACTIVE jobs can transition to DONE. + * + * Generated from protobuf enum ACTIVE = 6; + */ + const ACTIVE = 6; + + private static $valueToName = [ + self::JOB_STATE_UNSPECIFIED => 'JOB_STATE_UNSPECIFIED', + self::PENDING => 'PENDING', + self::RUNNING => 'RUNNING', + self::DONE => 'DONE', + self::CANCELED => 'CANCELED', + self::FAILED => 'FAILED', + self::ACTIVE => 'ACTIVE', + ]; + + 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(JobState::class, \Google\Cloud\Dlp\V2\DlpJob_JobState::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJobType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJobType.php new file mode 100644 index 000000000000..c34fc91f3d4f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJobType.php @@ -0,0 +1,61 @@ +google.privacy.dlp.v2.DlpJobType + */ +class DlpJobType +{ + /** + * Defaults to INSPECT_JOB. + * + * Generated from protobuf enum DLP_JOB_TYPE_UNSPECIFIED = 0; + */ + const DLP_JOB_TYPE_UNSPECIFIED = 0; + /** + * The job inspected Google Cloud for sensitive data. + * + * Generated from protobuf enum INSPECT_JOB = 1; + */ + const INSPECT_JOB = 1; + /** + * The job executed a Risk Analysis computation. + * + * Generated from protobuf enum RISK_ANALYSIS_JOB = 2; + */ + const RISK_ANALYSIS_JOB = 2; + + private static $valueToName = [ + self::DLP_JOB_TYPE_UNSPECIFIED => 'DLP_JOB_TYPE_UNSPECIFIED', + self::INSPECT_JOB => 'INSPECT_JOB', + self::RISK_ANALYSIS_JOB => 'RISK_ANALYSIS_JOB', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DocumentLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DocumentLocation.php new file mode 100644 index 000000000000..1abf21ab6a0b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DocumentLocation.php @@ -0,0 +1,71 @@ +google.privacy.dlp.v2.DocumentLocation + */ +class DocumentLocation extends \Google\Protobuf\Internal\Message +{ + /** + * Offset of the line, from the beginning of the file, where the finding + * is located. + * + * Generated from protobuf field int64 file_offset = 1; + */ + protected $file_offset = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $file_offset + * Offset of the line, from the beginning of the file, where the finding + * is located. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Offset of the line, from the beginning of the file, where the finding + * is located. + * + * Generated from protobuf field int64 file_offset = 1; + * @return int|string + */ + public function getFileOffset() + { + return $this->file_offset; + } + + /** + * Offset of the line, from the beginning of the file, where the finding + * is located. + * + * Generated from protobuf field int64 file_offset = 1; + * @param int|string $var + * @return $this + */ + public function setFileOffset($var) + { + GPBUtil::checkInt64($var); + $this->file_offset = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EncryptionStatus.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EncryptionStatus.php new file mode 100644 index 000000000000..a21080206e59 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EncryptionStatus.php @@ -0,0 +1,61 @@ +google.privacy.dlp.v2.EncryptionStatus + */ +class EncryptionStatus +{ + /** + * Unused. + * + * Generated from protobuf enum ENCRYPTION_STATUS_UNSPECIFIED = 0; + */ + const ENCRYPTION_STATUS_UNSPECIFIED = 0; + /** + * Google manages server-side encryption keys on your behalf. + * + * Generated from protobuf enum ENCRYPTION_GOOGLE_MANAGED = 1; + */ + const ENCRYPTION_GOOGLE_MANAGED = 1; + /** + * Customer provides the key. + * + * Generated from protobuf enum ENCRYPTION_CUSTOMER_MANAGED = 2; + */ + const ENCRYPTION_CUSTOMER_MANAGED = 2; + + private static $valueToName = [ + self::ENCRYPTION_STATUS_UNSPECIFIED => 'ENCRYPTION_STATUS_UNSPECIFIED', + self::ENCRYPTION_GOOGLE_MANAGED => 'ENCRYPTION_GOOGLE_MANAGED', + self::ENCRYPTION_CUSTOMER_MANAGED => 'ENCRYPTION_CUSTOMER_MANAGED', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EntityId.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EntityId.php new file mode 100644 index 000000000000..5600e90f2b91 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EntityId.php @@ -0,0 +1,81 @@ +google.privacy.dlp.v2.EntityId + */ +class EntityId extends \Google\Protobuf\Internal\Message +{ + /** + * Composite key indicating which field contains the entity identifier. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + */ + protected $field = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\FieldId $field + * Composite key indicating which field contains the entity identifier. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Composite key indicating which field contains the entity identifier. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getField() + { + return $this->field; + } + + public function hasField() + { + return isset($this->field); + } + + public function clearField() + { + unset($this->field); + } + + /** + * Composite key indicating which field contains the entity identifier. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setField($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->field = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Error.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Error.php new file mode 100644 index 000000000000..c05eba7d7098 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Error.php @@ -0,0 +1,116 @@ +google.privacy.dlp.v2.Error + */ +class Error extends \Google\Protobuf\Internal\Message +{ + /** + * Detailed error codes and messages. + * + * Generated from protobuf field .google.rpc.Status details = 1; + */ + protected $details = null; + /** + * The times the error occurred. List includes the oldest timestamp and the + * last 9 timestamps. + * + * Generated from protobuf field repeated .google.protobuf.Timestamp timestamps = 2; + */ + private $timestamps; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Rpc\Status $details + * Detailed error codes and messages. + * @type array<\Google\Protobuf\Timestamp>|\Google\Protobuf\Internal\RepeatedField $timestamps + * The times the error occurred. List includes the oldest timestamp and the + * last 9 timestamps. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Detailed error codes and messages. + * + * Generated from protobuf field .google.rpc.Status details = 1; + * @return \Google\Rpc\Status|null + */ + public function getDetails() + { + return $this->details; + } + + public function hasDetails() + { + return isset($this->details); + } + + public function clearDetails() + { + unset($this->details); + } + + /** + * Detailed error codes and messages. + * + * Generated from protobuf field .google.rpc.Status details = 1; + * @param \Google\Rpc\Status $var + * @return $this + */ + public function setDetails($var) + { + GPBUtil::checkMessage($var, \Google\Rpc\Status::class); + $this->details = $var; + + return $this; + } + + /** + * The times the error occurred. List includes the oldest timestamp and the + * last 9 timestamps. + * + * Generated from protobuf field repeated .google.protobuf.Timestamp timestamps = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTimestamps() + { + return $this->timestamps; + } + + /** + * The times the error occurred. List includes the oldest timestamp and the + * last 9 timestamps. + * + * Generated from protobuf field repeated .google.protobuf.Timestamp timestamps = 2; + * @param array<\Google\Protobuf\Timestamp>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTimestamps($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Timestamp::class); + $this->timestamps = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeByHotword.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeByHotword.php new file mode 100644 index 000000000000..b36a1ee82195 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeByHotword.php @@ -0,0 +1,136 @@ +google.privacy.dlp.v2.ExcludeByHotword + */ +class ExcludeByHotword extends \Google\Protobuf\Internal\Message +{ + /** + * Regular expression pattern defining what qualifies as a hotword. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex hotword_regex = 1; + */ + protected $hotword_regex = null; + /** + * Range of characters within which the entire hotword must reside. + * The total length of the window cannot exceed 1000 characters. + * The windowBefore property in proximity should be set to 1 if the hotword + * needs to be included in a column header. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity proximity = 2; + */ + protected $proximity = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\CustomInfoType\Regex $hotword_regex + * Regular expression pattern defining what qualifies as a hotword. + * @type \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity $proximity + * Range of characters within which the entire hotword must reside. + * The total length of the window cannot exceed 1000 characters. + * The windowBefore property in proximity should be set to 1 if the hotword + * needs to be included in a column header. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Regular expression pattern defining what qualifies as a hotword. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex hotword_regex = 1; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\Regex|null + */ + public function getHotwordRegex() + { + return $this->hotword_regex; + } + + public function hasHotwordRegex() + { + return isset($this->hotword_regex); + } + + public function clearHotwordRegex() + { + unset($this->hotword_regex); + } + + /** + * Regular expression pattern defining what qualifies as a hotword. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex hotword_regex = 1; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\Regex $var + * @return $this + */ + public function setHotwordRegex($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Regex::class); + $this->hotword_regex = $var; + + return $this; + } + + /** + * Range of characters within which the entire hotword must reside. + * The total length of the window cannot exceed 1000 characters. + * The windowBefore property in proximity should be set to 1 if the hotword + * needs to be included in a column header. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity proximity = 2; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity|null + */ + public function getProximity() + { + return $this->proximity; + } + + public function hasProximity() + { + return isset($this->proximity); + } + + public function clearProximity() + { + unset($this->proximity); + } + + /** + * Range of characters within which the entire hotword must reside. + * The total length of the window cannot exceed 1000 characters. + * The windowBefore property in proximity should be set to 1 if the hotword + * needs to be included in a column header. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity proximity = 2; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity $var + * @return $this + */ + public function setProximity($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity::class); + $this->proximity = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeInfoTypes.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeInfoTypes.php new file mode 100644 index 000000000000..bf9b02b680a5 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeInfoTypes.php @@ -0,0 +1,95 @@ +google.privacy.dlp.v2.ExcludeInfoTypes + */ +class ExcludeInfoTypes extends \Google\Protobuf\Internal\Message +{ + /** + * InfoType list in ExclusionRule rule drops a finding when it overlaps or + * contained within with a finding of an infoType from this list. For + * example, for `InspectionRuleSet.info_types` containing "PHONE_NUMBER"` and + * `exclusion_rule` containing `exclude_info_types.info_types` with + * "EMAIL_ADDRESS" the phone number findings are dropped if they overlap + * with EMAIL_ADDRESS finding. + * That leads to "555-222-2222@example.org" to generate only a single + * finding, namely email address. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; + */ + private $info_types; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $info_types + * InfoType list in ExclusionRule rule drops a finding when it overlaps or + * contained within with a finding of an infoType from this list. For + * example, for `InspectionRuleSet.info_types` containing "PHONE_NUMBER"` and + * `exclusion_rule` containing `exclude_info_types.info_types` with + * "EMAIL_ADDRESS" the phone number findings are dropped if they overlap + * with EMAIL_ADDRESS finding. + * That leads to "555-222-2222@example.org" to generate only a single + * finding, namely email address. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * InfoType list in ExclusionRule rule drops a finding when it overlaps or + * contained within with a finding of an infoType from this list. For + * example, for `InspectionRuleSet.info_types` containing "PHONE_NUMBER"` and + * `exclusion_rule` containing `exclude_info_types.info_types` with + * "EMAIL_ADDRESS" the phone number findings are dropped if they overlap + * with EMAIL_ADDRESS finding. + * That leads to "555-222-2222@example.org" to generate only a single + * finding, namely email address. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getInfoTypes() + { + return $this->info_types; + } + + /** + * InfoType list in ExclusionRule rule drops a finding when it overlaps or + * contained within with a finding of an infoType from this list. For + * example, for `InspectionRuleSet.info_types` containing "PHONE_NUMBER"` and + * `exclusion_rule` containing `exclude_info_types.info_types` with + * "EMAIL_ADDRESS" the phone number findings are dropped if they overlap + * with EMAIL_ADDRESS finding. + * That leads to "555-222-2222@example.org" to generate only a single + * finding, namely email address. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; + * @param array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setInfoTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_types = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExclusionRule.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExclusionRule.php new file mode 100644 index 000000000000..c238c2b9417d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExclusionRule.php @@ -0,0 +1,212 @@ +google.privacy.dlp.v2.ExclusionRule + */ +class ExclusionRule extends \Google\Protobuf\Internal\Message +{ + /** + * How the rule is applied, see MatchingType documentation for details. + * + * Generated from protobuf field .google.privacy.dlp.v2.MatchingType matching_type = 4; + */ + protected $matching_type = 0; + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary $dictionary + * Dictionary which defines the rule. + * @type \Google\Cloud\Dlp\V2\CustomInfoType\Regex $regex + * Regular expression which defines the rule. + * @type \Google\Cloud\Dlp\V2\ExcludeInfoTypes $exclude_info_types + * Set of infoTypes for which findings would affect this rule. + * @type \Google\Cloud\Dlp\V2\ExcludeByHotword $exclude_by_hotword + * Drop if the hotword rule is contained in the proximate context. For + * tabular data, the context includes the column name. + * @type int $matching_type + * How the rule is applied, see MatchingType documentation for details. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Dictionary which defines the rule. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary dictionary = 1; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary|null + */ + public function getDictionary() + { + return $this->readOneof(1); + } + + public function hasDictionary() + { + return $this->hasOneof(1); + } + + /** + * Dictionary which defines the rule. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary dictionary = 1; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary $var + * @return $this + */ + public function setDictionary($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Regular expression which defines the rule. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex regex = 2; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\Regex|null + */ + public function getRegex() + { + return $this->readOneof(2); + } + + public function hasRegex() + { + return $this->hasOneof(2); + } + + /** + * Regular expression which defines the rule. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex regex = 2; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\Regex $var + * @return $this + */ + public function setRegex($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Regex::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Set of infoTypes for which findings would affect this rule. + * + * Generated from protobuf field .google.privacy.dlp.v2.ExcludeInfoTypes exclude_info_types = 3; + * @return \Google\Cloud\Dlp\V2\ExcludeInfoTypes|null + */ + public function getExcludeInfoTypes() + { + return $this->readOneof(3); + } + + public function hasExcludeInfoTypes() + { + return $this->hasOneof(3); + } + + /** + * Set of infoTypes for which findings would affect this rule. + * + * Generated from protobuf field .google.privacy.dlp.v2.ExcludeInfoTypes exclude_info_types = 3; + * @param \Google\Cloud\Dlp\V2\ExcludeInfoTypes $var + * @return $this + */ + public function setExcludeInfoTypes($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ExcludeInfoTypes::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Drop if the hotword rule is contained in the proximate context. For + * tabular data, the context includes the column name. + * + * Generated from protobuf field .google.privacy.dlp.v2.ExcludeByHotword exclude_by_hotword = 5; + * @return \Google\Cloud\Dlp\V2\ExcludeByHotword|null + */ + public function getExcludeByHotword() + { + return $this->readOneof(5); + } + + public function hasExcludeByHotword() + { + return $this->hasOneof(5); + } + + /** + * Drop if the hotword rule is contained in the proximate context. For + * tabular data, the context includes the column name. + * + * Generated from protobuf field .google.privacy.dlp.v2.ExcludeByHotword exclude_by_hotword = 5; + * @param \Google\Cloud\Dlp\V2\ExcludeByHotword $var + * @return $this + */ + public function setExcludeByHotword($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ExcludeByHotword::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * How the rule is applied, see MatchingType documentation for details. + * + * Generated from protobuf field .google.privacy.dlp.v2.MatchingType matching_type = 4; + * @return int + */ + public function getMatchingType() + { + return $this->matching_type; + } + + /** + * How the rule is applied, see MatchingType documentation for details. + * + * Generated from protobuf field .google.privacy.dlp.v2.MatchingType matching_type = 4; + * @param int $var + * @return $this + */ + public function setMatchingType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\MatchingType::class); + $this->matching_type = $var; + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldId.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldId.php new file mode 100644 index 000000000000..2cdfe5bc25cf --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldId.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.FieldId + */ +class FieldId extends \Google\Protobuf\Internal\Message +{ + /** + * Name describing the field. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name describing the field. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Name describing the field. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name describing the field. + * + * 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; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldTransformation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldTransformation.php new file mode 100644 index 000000000000..3f7a9a39e9e2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldTransformation.php @@ -0,0 +1,225 @@ +google.privacy.dlp.v2.FieldTransformation + */ +class FieldTransformation extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Input field(s) to apply the transformation to. + * When you have columns that reference their position within a list, + * omit the index from the FieldId. FieldId name matching ignores the index. + * For example, instead of "contact.nums[0].type", use "contact.nums.type". + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId fields = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + private $fields; + /** + * Only apply the transformation if the condition evaluates to true for the + * given `RecordCondition`. The conditions are allowed to reference fields + * that are not used in the actual transformation. + * Example Use Cases: + * - Apply a different bucket transformation to an age column if the zip code + * column for the same record is within a specific range. + * - Redact a field if the date of birth field is greater than 85. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition condition = 3; + */ + protected $condition = null; + protected $transformation; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $fields + * Required. Input field(s) to apply the transformation to. + * When you have columns that reference their position within a list, + * omit the index from the FieldId. FieldId name matching ignores the index. + * For example, instead of "contact.nums[0].type", use "contact.nums.type". + * @type \Google\Cloud\Dlp\V2\RecordCondition $condition + * Only apply the transformation if the condition evaluates to true for the + * given `RecordCondition`. The conditions are allowed to reference fields + * that are not used in the actual transformation. + * Example Use Cases: + * - Apply a different bucket transformation to an age column if the zip code + * column for the same record is within a specific range. + * - Redact a field if the date of birth field is greater than 85. + * @type \Google\Cloud\Dlp\V2\PrimitiveTransformation $primitive_transformation + * Apply the transformation to the entire field. + * @type \Google\Cloud\Dlp\V2\InfoTypeTransformations $info_type_transformations + * Treat the contents of the field as free text, and selectively + * transform content that matches an `InfoType`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Input field(s) to apply the transformation to. + * When you have columns that reference their position within a list, + * omit the index from the FieldId. FieldId name matching ignores the index. + * For example, instead of "contact.nums[0].type", use "contact.nums.type". + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId fields = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFields() + { + return $this->fields; + } + + /** + * Required. Input field(s) to apply the transformation to. + * When you have columns that reference their position within a list, + * omit the index from the FieldId. FieldId name matching ignores the index. + * For example, instead of "contact.nums[0].type", use "contact.nums.type". + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId fields = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFields($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); + $this->fields = $arr; + + return $this; + } + + /** + * Only apply the transformation if the condition evaluates to true for the + * given `RecordCondition`. The conditions are allowed to reference fields + * that are not used in the actual transformation. + * Example Use Cases: + * - Apply a different bucket transformation to an age column if the zip code + * column for the same record is within a specific range. + * - Redact a field if the date of birth field is greater than 85. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition condition = 3; + * @return \Google\Cloud\Dlp\V2\RecordCondition|null + */ + public function getCondition() + { + return $this->condition; + } + + public function hasCondition() + { + return isset($this->condition); + } + + public function clearCondition() + { + unset($this->condition); + } + + /** + * Only apply the transformation if the condition evaluates to true for the + * given `RecordCondition`. The conditions are allowed to reference fields + * that are not used in the actual transformation. + * Example Use Cases: + * - Apply a different bucket transformation to an age column if the zip code + * column for the same record is within a specific range. + * - Redact a field if the date of birth field is greater than 85. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition condition = 3; + * @param \Google\Cloud\Dlp\V2\RecordCondition $var + * @return $this + */ + public function setCondition($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordCondition::class); + $this->condition = $var; + + return $this; + } + + /** + * Apply the transformation to the entire field. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation primitive_transformation = 4; + * @return \Google\Cloud\Dlp\V2\PrimitiveTransformation|null + */ + public function getPrimitiveTransformation() + { + return $this->readOneof(4); + } + + public function hasPrimitiveTransformation() + { + return $this->hasOneof(4); + } + + /** + * Apply the transformation to the entire field. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation primitive_transformation = 4; + * @param \Google\Cloud\Dlp\V2\PrimitiveTransformation $var + * @return $this + */ + public function setPrimitiveTransformation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrimitiveTransformation::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Treat the contents of the field as free text, and selectively + * transform content that matches an `InfoType`. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeTransformations info_type_transformations = 5; + * @return \Google\Cloud\Dlp\V2\InfoTypeTransformations|null + */ + public function getInfoTypeTransformations() + { + return $this->readOneof(5); + } + + public function hasInfoTypeTransformations() + { + return $this->hasOneof(5); + } + + /** + * Treat the contents of the field as free text, and selectively + * transform content that matches an `InfoType`. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeTransformations info_type_transformations = 5; + * @param \Google\Cloud\Dlp\V2\InfoTypeTransformations $var + * @return $this + */ + public function setInfoTypeTransformations($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoTypeTransformations::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * @return string + */ + public function getTransformation() + { + return $this->whichOneof("transformation"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FileType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FileType.php new file mode 100644 index 000000000000..4cf2e8f31733 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FileType.php @@ -0,0 +1,150 @@ +google.privacy.dlp.v2.FileType + */ +class FileType +{ + /** + * Includes all files. + * + * Generated from protobuf enum FILE_TYPE_UNSPECIFIED = 0; + */ + const FILE_TYPE_UNSPECIFIED = 0; + /** + * Includes all file extensions not covered by another entry. Binary + * scanning attempts to convert the content of the file to utf_8 to scan + * the file. + * If you wish to avoid this fall back, specify one or more of the other + * file types in your storage scan. + * + * Generated from protobuf enum BINARY_FILE = 1; + */ + const BINARY_FILE = 1; + /** + * Included file extensions: + * asc,asp, aspx, brf, c, cc,cfm, cgi, cpp, csv, cxx, c++, cs, css, dart, + * dat, dot, eml,, epbub, ged, go, h, hh, hpp, hxx, h++, hs, html, htm, + * mkd, markdown, m, ml, mli, perl, pl, plist, pm, php, phtml, pht, + * properties, py, pyw, rb, rbw, rs, rss, rc, scala, sh, sql, swift, tex, + * shtml, shtm, xhtml, lhs, ics, ini, java, js, json, jsonl, kix, kml, + * ocaml, md, txt, text, tsv, vb, vcard, vcs, wml, xcodeproj, xml, xsl, xsd, + * yml, yaml. + * + * Generated from protobuf enum TEXT_FILE = 2; + */ + const TEXT_FILE = 2; + /** + * Included file extensions: + * bmp, gif, jpg, jpeg, jpe, png. Setting + * [bytes_limit_per_file][google.privacy.dlp.v2.CloudStorageOptions.bytes_limit_per_file] + * or + * [bytes_limit_per_file_percent][google.privacy.dlp.v2.CloudStorageOptions.bytes_limit_per_file] + * has no effect on image files. Image inspection is restricted to the + * `global`, `us`, `asia`, and `europe` regions. + * + * Generated from protobuf enum IMAGE = 3; + */ + const IMAGE = 3; + /** + * Microsoft Word files larger than 30 MB will be scanned as binary files. + * Included file extensions: + * docx, dotx, docm, dotm. Setting `bytes_limit_per_file` or + * `bytes_limit_per_file_percent` has no effect on Word files. + * + * Generated from protobuf enum WORD = 5; + */ + const WORD = 5; + /** + * PDF files larger than 30 MB will be scanned as binary files. + * Included file extensions: + * pdf. Setting `bytes_limit_per_file` or `bytes_limit_per_file_percent` + * has no effect on PDF files. + * + * Generated from protobuf enum PDF = 6; + */ + const PDF = 6; + /** + * Included file extensions: + * avro + * + * Generated from protobuf enum AVRO = 7; + */ + const AVRO = 7; + /** + * Included file extensions: + * csv + * + * Generated from protobuf enum CSV = 8; + */ + const CSV = 8; + /** + * Included file extensions: + * tsv + * + * Generated from protobuf enum TSV = 9; + */ + const TSV = 9; + /** + * Microsoft PowerPoint files larger than 30 MB will be scanned as binary + * files. Included file extensions: + * pptx, pptm, potx, potm, pot. Setting `bytes_limit_per_file` or + * `bytes_limit_per_file_percent` has no effect on PowerPoint files. + * + * Generated from protobuf enum POWERPOINT = 11; + */ + const POWERPOINT = 11; + /** + * Microsoft Excel files larger than 30 MB will be scanned as binary files. + * Included file extensions: + * xlsx, xlsm, xltx, xltm. Setting `bytes_limit_per_file` or + * `bytes_limit_per_file_percent` has no effect on Excel files. + * + * Generated from protobuf enum EXCEL = 12; + */ + const EXCEL = 12; + + private static $valueToName = [ + self::FILE_TYPE_UNSPECIFIED => 'FILE_TYPE_UNSPECIFIED', + self::BINARY_FILE => 'BINARY_FILE', + self::TEXT_FILE => 'TEXT_FILE', + self::IMAGE => 'IMAGE', + self::WORD => 'WORD', + self::PDF => 'PDF', + self::AVRO => 'AVRO', + self::CSV => 'CSV', + self::TSV => 'TSV', + self::POWERPOINT => 'POWERPOINT', + self::EXCEL => 'EXCEL', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Finding.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Finding.php new file mode 100644 index 000000000000..96e95ce3b7da --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Finding.php @@ -0,0 +1,593 @@ +google.privacy.dlp.v2.Finding + */ +class Finding extends \Google\Protobuf\Internal\Message +{ + /** + * Resource name in format + * projects/{project}/locations/{location}/findings/{finding} Populated only + * when viewing persisted findings. + * + * Generated from protobuf field string name = 14; + */ + protected $name = ''; + /** + * The content that was found. Even if the content is not textual, it + * may be converted to a textual representation here. + * Provided if `include_quote` is true and the finding is + * less than or equal to 4096 bytes long. If the finding exceeds 4096 bytes + * in length, the quote may be omitted. + * + * Generated from protobuf field string quote = 1; + */ + protected $quote = ''; + /** + * The type of content that might have been found. + * Provided if `excluded_types` is false. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; + */ + protected $info_type = null; + /** + * Confidence of how likely it is that the `info_type` is correct. + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood likelihood = 3; + */ + protected $likelihood = 0; + /** + * Where the content was found. + * + * Generated from protobuf field .google.privacy.dlp.v2.Location location = 4; + */ + protected $location = null; + /** + * Timestamp when finding was detected. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; + */ + protected $create_time = null; + /** + * Contains data parsed from quotes. Only populated if include_quote was set + * to true and a supported infoType was requested. Currently supported + * infoTypes: DATE, DATE_OF_BIRTH and TIME. + * + * Generated from protobuf field .google.privacy.dlp.v2.QuoteInfo quote_info = 7; + */ + protected $quote_info = null; + /** + * The job that stored the finding. + * + * Generated from protobuf field string resource_name = 8 [(.google.api.resource_reference) = { + */ + protected $resource_name = ''; + /** + * Job trigger name, if applicable, for this finding. + * + * Generated from protobuf field string trigger_name = 9 [(.google.api.resource_reference) = { + */ + protected $trigger_name = ''; + /** + * The labels associated with this `Finding`. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * Label values must be between 0 and 63 characters long and must conform + * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. + * No more than 10 labels can be associated with a given finding. + * Examples: + * * `"environment" : "production"` + * * `"pipeline" : "etl"` + * + * Generated from protobuf field map labels = 10; + */ + private $labels; + /** + * Time the job started that produced this finding. + * + * Generated from protobuf field .google.protobuf.Timestamp job_create_time = 11; + */ + protected $job_create_time = null; + /** + * The job that stored the finding. + * + * Generated from protobuf field string job_name = 13 [(.google.api.resource_reference) = { + */ + protected $job_name = ''; + /** + * The unique finding id. + * + * Generated from protobuf field string finding_id = 15; + */ + protected $finding_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Resource name in format + * projects/{project}/locations/{location}/findings/{finding} Populated only + * when viewing persisted findings. + * @type string $quote + * The content that was found. Even if the content is not textual, it + * may be converted to a textual representation here. + * Provided if `include_quote` is true and the finding is + * less than or equal to 4096 bytes long. If the finding exceeds 4096 bytes + * in length, the quote may be omitted. + * @type \Google\Cloud\Dlp\V2\InfoType $info_type + * The type of content that might have been found. + * Provided if `excluded_types` is false. + * @type int $likelihood + * Confidence of how likely it is that the `info_type` is correct. + * @type \Google\Cloud\Dlp\V2\Location $location + * Where the content was found. + * @type \Google\Protobuf\Timestamp $create_time + * Timestamp when finding was detected. + * @type \Google\Cloud\Dlp\V2\QuoteInfo $quote_info + * Contains data parsed from quotes. Only populated if include_quote was set + * to true and a supported infoType was requested. Currently supported + * infoTypes: DATE, DATE_OF_BIRTH and TIME. + * @type string $resource_name + * The job that stored the finding. + * @type string $trigger_name + * Job trigger name, if applicable, for this finding. + * @type array|\Google\Protobuf\Internal\MapField $labels + * The labels associated with this `Finding`. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * Label values must be between 0 and 63 characters long and must conform + * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. + * No more than 10 labels can be associated with a given finding. + * Examples: + * * `"environment" : "production"` + * * `"pipeline" : "etl"` + * @type \Google\Protobuf\Timestamp $job_create_time + * Time the job started that produced this finding. + * @type string $job_name + * The job that stored the finding. + * @type string $finding_id + * The unique finding id. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Resource name in format + * projects/{project}/locations/{location}/findings/{finding} Populated only + * when viewing persisted findings. + * + * Generated from protobuf field string name = 14; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Resource name in format + * projects/{project}/locations/{location}/findings/{finding} Populated only + * when viewing persisted findings. + * + * Generated from protobuf field string name = 14; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The content that was found. Even if the content is not textual, it + * may be converted to a textual representation here. + * Provided if `include_quote` is true and the finding is + * less than or equal to 4096 bytes long. If the finding exceeds 4096 bytes + * in length, the quote may be omitted. + * + * Generated from protobuf field string quote = 1; + * @return string + */ + public function getQuote() + { + return $this->quote; + } + + /** + * The content that was found. Even if the content is not textual, it + * may be converted to a textual representation here. + * Provided if `include_quote` is true and the finding is + * less than or equal to 4096 bytes long. If the finding exceeds 4096 bytes + * in length, the quote may be omitted. + * + * Generated from protobuf field string quote = 1; + * @param string $var + * @return $this + */ + public function setQuote($var) + { + GPBUtil::checkString($var, True); + $this->quote = $var; + + return $this; + } + + /** + * The type of content that might have been found. + * Provided if `excluded_types` is false. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getInfoType() + { + return $this->info_type; + } + + public function hasInfoType() + { + return isset($this->info_type); + } + + public function clearInfoType() + { + unset($this->info_type); + } + + /** + * The type of content that might have been found. + * Provided if `excluded_types` is false. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_type = $var; + + return $this; + } + + /** + * Confidence of how likely it is that the `info_type` is correct. + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood likelihood = 3; + * @return int + */ + public function getLikelihood() + { + return $this->likelihood; + } + + /** + * Confidence of how likely it is that the `info_type` is correct. + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood likelihood = 3; + * @param int $var + * @return $this + */ + public function setLikelihood($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\Likelihood::class); + $this->likelihood = $var; + + return $this; + } + + /** + * Where the content was found. + * + * Generated from protobuf field .google.privacy.dlp.v2.Location location = 4; + * @return \Google\Cloud\Dlp\V2\Location|null + */ + public function getLocation() + { + return $this->location; + } + + public function hasLocation() + { + return isset($this->location); + } + + public function clearLocation() + { + unset($this->location); + } + + /** + * Where the content was found. + * + * Generated from protobuf field .google.privacy.dlp.v2.Location location = 4; + * @param \Google\Cloud\Dlp\V2\Location $var + * @return $this + */ + public function setLocation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Location::class); + $this->location = $var; + + return $this; + } + + /** + * Timestamp when finding was detected. + * + * 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); + } + + /** + * Timestamp when finding was detected. + * + * 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; + } + + /** + * Contains data parsed from quotes. Only populated if include_quote was set + * to true and a supported infoType was requested. Currently supported + * infoTypes: DATE, DATE_OF_BIRTH and TIME. + * + * Generated from protobuf field .google.privacy.dlp.v2.QuoteInfo quote_info = 7; + * @return \Google\Cloud\Dlp\V2\QuoteInfo|null + */ + public function getQuoteInfo() + { + return $this->quote_info; + } + + public function hasQuoteInfo() + { + return isset($this->quote_info); + } + + public function clearQuoteInfo() + { + unset($this->quote_info); + } + + /** + * Contains data parsed from quotes. Only populated if include_quote was set + * to true and a supported infoType was requested. Currently supported + * infoTypes: DATE, DATE_OF_BIRTH and TIME. + * + * Generated from protobuf field .google.privacy.dlp.v2.QuoteInfo quote_info = 7; + * @param \Google\Cloud\Dlp\V2\QuoteInfo $var + * @return $this + */ + public function setQuoteInfo($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\QuoteInfo::class); + $this->quote_info = $var; + + return $this; + } + + /** + * The job that stored the finding. + * + * Generated from protobuf field string resource_name = 8 [(.google.api.resource_reference) = { + * @return string + */ + public function getResourceName() + { + return $this->resource_name; + } + + /** + * The job that stored the finding. + * + * Generated from protobuf field string resource_name = 8 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setResourceName($var) + { + GPBUtil::checkString($var, True); + $this->resource_name = $var; + + return $this; + } + + /** + * Job trigger name, if applicable, for this finding. + * + * Generated from protobuf field string trigger_name = 9 [(.google.api.resource_reference) = { + * @return string + */ + public function getTriggerName() + { + return $this->trigger_name; + } + + /** + * Job trigger name, if applicable, for this finding. + * + * Generated from protobuf field string trigger_name = 9 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setTriggerName($var) + { + GPBUtil::checkString($var, True); + $this->trigger_name = $var; + + return $this; + } + + /** + * The labels associated with this `Finding`. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * Label values must be between 0 and 63 characters long and must conform + * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. + * No more than 10 labels can be associated with a given finding. + * Examples: + * * `"environment" : "production"` + * * `"pipeline" : "etl"` + * + * Generated from protobuf field map labels = 10; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * The labels associated with this `Finding`. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * Label values must be between 0 and 63 characters long and must conform + * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. + * No more than 10 labels can be associated with a given finding. + * Examples: + * * `"environment" : "production"` + * * `"pipeline" : "etl"` + * + * Generated from protobuf field map labels = 10; + * @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; + } + + /** + * Time the job started that produced this finding. + * + * Generated from protobuf field .google.protobuf.Timestamp job_create_time = 11; + * @return \Google\Protobuf\Timestamp|null + */ + public function getJobCreateTime() + { + return $this->job_create_time; + } + + public function hasJobCreateTime() + { + return isset($this->job_create_time); + } + + public function clearJobCreateTime() + { + unset($this->job_create_time); + } + + /** + * Time the job started that produced this finding. + * + * Generated from protobuf field .google.protobuf.Timestamp job_create_time = 11; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setJobCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->job_create_time = $var; + + return $this; + } + + /** + * The job that stored the finding. + * + * Generated from protobuf field string job_name = 13 [(.google.api.resource_reference) = { + * @return string + */ + public function getJobName() + { + return $this->job_name; + } + + /** + * The job that stored the finding. + * + * Generated from protobuf field string job_name = 13 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setJobName($var) + { + GPBUtil::checkString($var, True); + $this->job_name = $var; + + return $this; + } + + /** + * The unique finding id. + * + * Generated from protobuf field string finding_id = 15; + * @return string + */ + public function getFindingId() + { + return $this->finding_id; + } + + /** + * The unique finding id. + * + * Generated from protobuf field string finding_id = 15; + * @param string $var + * @return $this + */ + public function setFindingId($var) + { + GPBUtil::checkString($var, True); + $this->finding_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FinishDlpJobRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FinishDlpJobRequest.php new file mode 100644 index 000000000000..278e8faf1fe8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FinishDlpJobRequest.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.FinishDlpJobRequest + */ +class FinishDlpJobRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the DlpJob resource to be finished. + * + * 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 + * Required. The name of the DlpJob resource to be finished. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the DlpJob resource to be finished. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The name of the DlpJob resource to be finished. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FixedSizeBucketingConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FixedSizeBucketingConfig.php new file mode 100644 index 000000000000..e7b42158b828 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FixedSizeBucketingConfig.php @@ -0,0 +1,196 @@ +google.privacy.dlp.v2.FixedSizeBucketingConfig + */ +class FixedSizeBucketingConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Lower bound value of buckets. All values less than `lower_bound` + * are grouped together into a single bucket; for example if `lower_bound` = + * 10, then all values less than 10 are replaced with the value "-10". + * + * Generated from protobuf field .google.privacy.dlp.v2.Value lower_bound = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $lower_bound = null; + /** + * Required. Upper bound value of buckets. All values greater than upper_bound + * are grouped together into a single bucket; for example if `upper_bound` = + * 89, then all values greater than 89 are replaced with the value "89+". + * + * Generated from protobuf field .google.privacy.dlp.v2.Value upper_bound = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $upper_bound = null; + /** + * Required. Size of each bucket (except for minimum and maximum buckets). So + * if `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the + * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60, + * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. + * + * Generated from protobuf field double bucket_size = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $bucket_size = 0.0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\Value $lower_bound + * Required. Lower bound value of buckets. All values less than `lower_bound` + * are grouped together into a single bucket; for example if `lower_bound` = + * 10, then all values less than 10 are replaced with the value "-10". + * @type \Google\Cloud\Dlp\V2\Value $upper_bound + * Required. Upper bound value of buckets. All values greater than upper_bound + * are grouped together into a single bucket; for example if `upper_bound` = + * 89, then all values greater than 89 are replaced with the value "89+". + * @type float $bucket_size + * Required. Size of each bucket (except for minimum and maximum buckets). So + * if `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the + * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60, + * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Lower bound value of buckets. All values less than `lower_bound` + * are grouped together into a single bucket; for example if `lower_bound` = + * 10, then all values less than 10 are replaced with the value "-10". + * + * Generated from protobuf field .google.privacy.dlp.v2.Value lower_bound = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\Value|null + */ + public function getLowerBound() + { + return $this->lower_bound; + } + + public function hasLowerBound() + { + return isset($this->lower_bound); + } + + public function clearLowerBound() + { + unset($this->lower_bound); + } + + /** + * Required. Lower bound value of buckets. All values less than `lower_bound` + * are grouped together into a single bucket; for example if `lower_bound` = + * 10, then all values less than 10 are replaced with the value "-10". + * + * Generated from protobuf field .google.privacy.dlp.v2.Value lower_bound = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\Value $var + * @return $this + */ + public function setLowerBound($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); + $this->lower_bound = $var; + + return $this; + } + + /** + * Required. Upper bound value of buckets. All values greater than upper_bound + * are grouped together into a single bucket; for example if `upper_bound` = + * 89, then all values greater than 89 are replaced with the value "89+". + * + * Generated from protobuf field .google.privacy.dlp.v2.Value upper_bound = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\Value|null + */ + public function getUpperBound() + { + return $this->upper_bound; + } + + public function hasUpperBound() + { + return isset($this->upper_bound); + } + + public function clearUpperBound() + { + unset($this->upper_bound); + } + + /** + * Required. Upper bound value of buckets. All values greater than upper_bound + * are grouped together into a single bucket; for example if `upper_bound` = + * 89, then all values greater than 89 are replaced with the value "89+". + * + * Generated from protobuf field .google.privacy.dlp.v2.Value upper_bound = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\Value $var + * @return $this + */ + public function setUpperBound($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); + $this->upper_bound = $var; + + return $this; + } + + /** + * Required. Size of each bucket (except for minimum and maximum buckets). So + * if `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the + * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60, + * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. + * + * Generated from protobuf field double bucket_size = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return float + */ + public function getBucketSize() + { + return $this->bucket_size; + } + + /** + * Required. Size of each bucket (except for minimum and maximum buckets). So + * if `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the + * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60, + * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. + * + * Generated from protobuf field double bucket_size = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param float $var + * @return $this + */ + public function setBucketSize($var) + { + GPBUtil::checkDouble($var); + $this->bucket_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetColumnDataProfileRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetColumnDataProfileRequest.php new file mode 100644 index 000000000000..06e176a0c4d7 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetColumnDataProfileRequest.php @@ -0,0 +1,86 @@ +google.privacy.dlp.v2.GetColumnDataProfileRequest + */ +class GetColumnDataProfileRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name, for example + * `organizations/12345/locations/us/columnDataProfiles/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name, for example + * `organizations/12345/locations/us/columnDataProfiles/53234423`. Please see + * {@see DlpServiceClient::columnDataProfileName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\GetColumnDataProfileRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name, for example + * `organizations/12345/locations/us/columnDataProfiles/53234423`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name, for example + * `organizations/12345/locations/us/columnDataProfiles/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name, for example + * `organizations/12345/locations/us/columnDataProfiles/53234423`. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetConnectionRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetConnectionRequest.php new file mode 100644 index 000000000000..abceabf3a8bb --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetConnectionRequest.php @@ -0,0 +1,86 @@ +google.privacy.dlp.v2.GetConnectionRequest + */ +class GetConnectionRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. Please see + * {@see DlpServiceClient::connectionName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\GetConnectionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDeidentifyTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDeidentifyTemplateRequest.php new file mode 100644 index 000000000000..33f8f78f48c9 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDeidentifyTemplateRequest.php @@ -0,0 +1,91 @@ +google.privacy.dlp.v2.GetDeidentifyTemplateRequest + */ +class GetDeidentifyTemplateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the organization and deidentify template to be + * read, for example `organizations/433245324/deidentifyTemplates/432452342` + * or projects/project-id/deidentifyTemplates/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name of the organization and deidentify template to be + * read, for example `organizations/433245324/deidentifyTemplates/432452342` + * or projects/project-id/deidentifyTemplates/432452342. Please see + * {@see DlpServiceClient::deidentifyTemplateName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\GetDeidentifyTemplateRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the organization and deidentify template to be + * read, for example `organizations/433245324/deidentifyTemplates/432452342` + * or projects/project-id/deidentifyTemplates/432452342. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the organization and deidentify template to be + * read, for example `organizations/433245324/deidentifyTemplates/432452342` + * or projects/project-id/deidentifyTemplates/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the organization and deidentify template to be + * read, for example `organizations/433245324/deidentifyTemplates/432452342` + * or projects/project-id/deidentifyTemplates/432452342. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDiscoveryConfigRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDiscoveryConfigRequest.php new file mode 100644 index 000000000000..74e5008be7ec --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDiscoveryConfigRequest.php @@ -0,0 +1,86 @@ +google.privacy.dlp.v2.GetDiscoveryConfigRequest + */ +class GetDiscoveryConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the project and the configuration, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name of the project and the configuration, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. Please see + * {@see DlpServiceClient::discoveryConfigName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\GetDiscoveryConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the project and the configuration, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the project and the configuration, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the project and the configuration, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDlpJobRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDlpJobRequest.php new file mode 100644 index 000000000000..272eaaf940b2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDlpJobRequest.php @@ -0,0 +1,81 @@ +google.privacy.dlp.v2.GetDlpJobRequest + */ +class GetDlpJobRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the DlpJob resource. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. The name of the DlpJob resource. Please see + * {@see DlpServiceClient::dlpJobName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\GetDlpJobRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The name of the DlpJob resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the DlpJob resource. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The name of the DlpJob resource. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetInspectTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetInspectTemplateRequest.php new file mode 100644 index 000000000000..14b95682d6cb --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetInspectTemplateRequest.php @@ -0,0 +1,91 @@ +google.privacy.dlp.v2.GetInspectTemplateRequest + */ +class GetInspectTemplateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the organization and inspectTemplate to be read, + * for example `organizations/433245324/inspectTemplates/432452342` or + * projects/project-id/inspectTemplates/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name of the organization and inspectTemplate to be read, + * for example `organizations/433245324/inspectTemplates/432452342` or + * projects/project-id/inspectTemplates/432452342. Please see + * {@see DlpServiceClient::inspectTemplateName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\GetInspectTemplateRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the organization and inspectTemplate to be read, + * for example `organizations/433245324/inspectTemplates/432452342` or + * projects/project-id/inspectTemplates/432452342. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the organization and inspectTemplate to be read, + * for example `organizations/433245324/inspectTemplates/432452342` or + * projects/project-id/inspectTemplates/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the organization and inspectTemplate to be read, + * for example `organizations/433245324/inspectTemplates/432452342` or + * projects/project-id/inspectTemplates/432452342. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetJobTriggerRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetJobTriggerRequest.php new file mode 100644 index 000000000000..3b8f6fcddf1a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetJobTriggerRequest.php @@ -0,0 +1,86 @@ +google.privacy.dlp.v2.GetJobTriggerRequest + */ +class GetJobTriggerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. Please see + * {@see DlpServiceClient::jobTriggerName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\GetJobTriggerRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetProjectDataProfileRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetProjectDataProfileRequest.php new file mode 100644 index 000000000000..853ec07bdbd7 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetProjectDataProfileRequest.php @@ -0,0 +1,86 @@ +google.privacy.dlp.v2.GetProjectDataProfileRequest + */ +class GetProjectDataProfileRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name, for example + * `organizations/12345/locations/us/projectDataProfiles/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name, for example + * `organizations/12345/locations/us/projectDataProfiles/53234423`. Please see + * {@see DlpServiceClient::projectDataProfileName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\GetProjectDataProfileRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name, for example + * `organizations/12345/locations/us/projectDataProfiles/53234423`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name, for example + * `organizations/12345/locations/us/projectDataProfiles/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name, for example + * `organizations/12345/locations/us/projectDataProfiles/53234423`. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetStoredInfoTypeRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetStoredInfoTypeRequest.php new file mode 100644 index 000000000000..c1fc45586b54 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetStoredInfoTypeRequest.php @@ -0,0 +1,91 @@ +google.privacy.dlp.v2.GetStoredInfoTypeRequest + */ +class GetStoredInfoTypeRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the organization and storedInfoType to be read, + * for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name of the organization and storedInfoType to be read, + * for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. Please see + * {@see DlpServiceClient::storedInfoTypeName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\GetStoredInfoTypeRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the organization and storedInfoType to be read, + * for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the organization and storedInfoType to be read, + * for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the organization and storedInfoType to be read, + * for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetTableDataProfileRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetTableDataProfileRequest.php new file mode 100644 index 000000000000..60adfcef114a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetTableDataProfileRequest.php @@ -0,0 +1,86 @@ +google.privacy.dlp.v2.GetTableDataProfileRequest + */ +class GetTableDataProfileRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name, for example + * `organizations/12345/locations/us/tableDataProfiles/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Resource name, for example + * `organizations/12345/locations/us/tableDataProfiles/53234423`. Please see + * {@see DlpServiceClient::tableDataProfileName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\GetTableDataProfileRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name, for example + * `organizations/12345/locations/us/tableDataProfiles/53234423`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name, for example + * `organizations/12345/locations/us/tableDataProfiles/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name, for example + * `organizations/12345/locations/us/tableDataProfiles/53234423`. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridContentItem.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridContentItem.php new file mode 100644 index 000000000000..9aa65f72ffd7 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridContentItem.php @@ -0,0 +1,122 @@ +google.privacy.dlp.v2.HybridContentItem + */ +class HybridContentItem extends \Google\Protobuf\Internal\Message +{ + /** + * The item to inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; + */ + protected $item = null; + /** + * Supplementary information that will be added to each finding. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridFindingDetails finding_details = 2; + */ + protected $finding_details = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\ContentItem $item + * The item to inspect. + * @type \Google\Cloud\Dlp\V2\HybridFindingDetails $finding_details + * Supplementary information that will be added to each finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The item to inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; + * @return \Google\Cloud\Dlp\V2\ContentItem|null + */ + public function getItem() + { + return $this->item; + } + + public function hasItem() + { + return isset($this->item); + } + + public function clearItem() + { + unset($this->item); + } + + /** + * The item to inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; + * @param \Google\Cloud\Dlp\V2\ContentItem $var + * @return $this + */ + public function setItem($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ContentItem::class); + $this->item = $var; + + return $this; + } + + /** + * Supplementary information that will be added to each finding. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridFindingDetails finding_details = 2; + * @return \Google\Cloud\Dlp\V2\HybridFindingDetails|null + */ + public function getFindingDetails() + { + return $this->finding_details; + } + + public function hasFindingDetails() + { + return isset($this->finding_details); + } + + public function clearFindingDetails() + { + unset($this->finding_details); + } + + /** + * Supplementary information that will be added to each finding. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridFindingDetails finding_details = 2; + * @param \Google\Cloud\Dlp\V2\HybridFindingDetails $var + * @return $this + */ + public function setFindingDetails($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\HybridFindingDetails::class); + $this->finding_details = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridFindingDetails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridFindingDetails.php new file mode 100644 index 000000000000..e27434622dd3 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridFindingDetails.php @@ -0,0 +1,303 @@ +google.privacy.dlp.v2.HybridFindingDetails + */ +class HybridFindingDetails extends \Google\Protobuf\Internal\Message +{ + /** + * Details about the container where the content being inspected is from. + * + * Generated from protobuf field .google.privacy.dlp.v2.Container container_details = 1; + */ + protected $container_details = null; + /** + * Offset in bytes of the line, from the beginning of the file, where the + * finding is located. Populate if the item being scanned is only part of a + * bigger item, such as a shard of a file and you want to track the absolute + * position of the finding. + * + * Generated from protobuf field int64 file_offset = 2; + */ + protected $file_offset = 0; + /** + * Offset of the row for tables. Populate if the row(s) being scanned are + * part of a bigger dataset and you want to keep track of their absolute + * position. + * + * Generated from protobuf field int64 row_offset = 3; + */ + protected $row_offset = 0; + /** + * If the container is a table, additional information to make findings + * meaningful such as the columns that are primary keys. If not known ahead + * of time, can also be set within each inspect hybrid call and the two + * will be merged. Note that identifying_fields will only be stored to + * BigQuery, and only if the BigQuery action has been included. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableOptions table_options = 4; + */ + protected $table_options = null; + /** + * Labels to represent user provided metadata about the data being inspected. + * If configured by the job, some key values may be required. + * The labels associated with `Finding`'s produced by hybrid + * inspection. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * Label values must be between 0 and 63 characters long and must conform + * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. + * No more than 10 labels can be associated with a given finding. + * Examples: + * * `"environment" : "production"` + * * `"pipeline" : "etl"` + * + * Generated from protobuf field map labels = 5; + */ + private $labels; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\Container $container_details + * Details about the container where the content being inspected is from. + * @type int|string $file_offset + * Offset in bytes of the line, from the beginning of the file, where the + * finding is located. Populate if the item being scanned is only part of a + * bigger item, such as a shard of a file and you want to track the absolute + * position of the finding. + * @type int|string $row_offset + * Offset of the row for tables. Populate if the row(s) being scanned are + * part of a bigger dataset and you want to keep track of their absolute + * position. + * @type \Google\Cloud\Dlp\V2\TableOptions $table_options + * If the container is a table, additional information to make findings + * meaningful such as the columns that are primary keys. If not known ahead + * of time, can also be set within each inspect hybrid call and the two + * will be merged. Note that identifying_fields will only be stored to + * BigQuery, and only if the BigQuery action has been included. + * @type array|\Google\Protobuf\Internal\MapField $labels + * Labels to represent user provided metadata about the data being inspected. + * If configured by the job, some key values may be required. + * The labels associated with `Finding`'s produced by hybrid + * inspection. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * Label values must be between 0 and 63 characters long and must conform + * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. + * No more than 10 labels can be associated with a given finding. + * Examples: + * * `"environment" : "production"` + * * `"pipeline" : "etl"` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Details about the container where the content being inspected is from. + * + * Generated from protobuf field .google.privacy.dlp.v2.Container container_details = 1; + * @return \Google\Cloud\Dlp\V2\Container|null + */ + public function getContainerDetails() + { + return $this->container_details; + } + + public function hasContainerDetails() + { + return isset($this->container_details); + } + + public function clearContainerDetails() + { + unset($this->container_details); + } + + /** + * Details about the container where the content being inspected is from. + * + * Generated from protobuf field .google.privacy.dlp.v2.Container container_details = 1; + * @param \Google\Cloud\Dlp\V2\Container $var + * @return $this + */ + public function setContainerDetails($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Container::class); + $this->container_details = $var; + + return $this; + } + + /** + * Offset in bytes of the line, from the beginning of the file, where the + * finding is located. Populate if the item being scanned is only part of a + * bigger item, such as a shard of a file and you want to track the absolute + * position of the finding. + * + * Generated from protobuf field int64 file_offset = 2; + * @return int|string + */ + public function getFileOffset() + { + return $this->file_offset; + } + + /** + * Offset in bytes of the line, from the beginning of the file, where the + * finding is located. Populate if the item being scanned is only part of a + * bigger item, such as a shard of a file and you want to track the absolute + * position of the finding. + * + * Generated from protobuf field int64 file_offset = 2; + * @param int|string $var + * @return $this + */ + public function setFileOffset($var) + { + GPBUtil::checkInt64($var); + $this->file_offset = $var; + + return $this; + } + + /** + * Offset of the row for tables. Populate if the row(s) being scanned are + * part of a bigger dataset and you want to keep track of their absolute + * position. + * + * Generated from protobuf field int64 row_offset = 3; + * @return int|string + */ + public function getRowOffset() + { + return $this->row_offset; + } + + /** + * Offset of the row for tables. Populate if the row(s) being scanned are + * part of a bigger dataset and you want to keep track of their absolute + * position. + * + * Generated from protobuf field int64 row_offset = 3; + * @param int|string $var + * @return $this + */ + public function setRowOffset($var) + { + GPBUtil::checkInt64($var); + $this->row_offset = $var; + + return $this; + } + + /** + * If the container is a table, additional information to make findings + * meaningful such as the columns that are primary keys. If not known ahead + * of time, can also be set within each inspect hybrid call and the two + * will be merged. Note that identifying_fields will only be stored to + * BigQuery, and only if the BigQuery action has been included. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableOptions table_options = 4; + * @return \Google\Cloud\Dlp\V2\TableOptions|null + */ + public function getTableOptions() + { + return $this->table_options; + } + + public function hasTableOptions() + { + return isset($this->table_options); + } + + public function clearTableOptions() + { + unset($this->table_options); + } + + /** + * If the container is a table, additional information to make findings + * meaningful such as the columns that are primary keys. If not known ahead + * of time, can also be set within each inspect hybrid call and the two + * will be merged. Note that identifying_fields will only be stored to + * BigQuery, and only if the BigQuery action has been included. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableOptions table_options = 4; + * @param \Google\Cloud\Dlp\V2\TableOptions $var + * @return $this + */ + public function setTableOptions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableOptions::class); + $this->table_options = $var; + + return $this; + } + + /** + * Labels to represent user provided metadata about the data being inspected. + * If configured by the job, some key values may be required. + * The labels associated with `Finding`'s produced by hybrid + * inspection. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * Label values must be between 0 and 63 characters long and must conform + * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. + * No more than 10 labels can be associated with a given finding. + * Examples: + * * `"environment" : "production"` + * * `"pipeline" : "etl"` + * + * Generated from protobuf field map labels = 5; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Labels to represent user provided metadata about the data being inspected. + * If configured by the job, some key values may be required. + * The labels associated with `Finding`'s produced by hybrid + * inspection. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * Label values must be between 0 and 63 characters long and must conform + * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. + * No more than 10 labels can be associated with a given finding. + * Examples: + * * `"environment" : "production"` + * * `"pipeline" : "etl"` + * + * Generated from protobuf field map labels = 5; + * @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; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectDlpJobRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectDlpJobRequest.php new file mode 100644 index 000000000000..f1ed062cc4e2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectDlpJobRequest.php @@ -0,0 +1,130 @@ +google.privacy.dlp.v2.HybridInspectDlpJobRequest + */ +class HybridInspectDlpJobRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the job to execute a hybrid inspect on, for + * example `projects/dlp-test-project/dlpJob/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * The item to inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridContentItem hybrid_item = 3; + */ + protected $hybrid_item = null; + + /** + * @param string $name Required. Resource name of the job to execute a hybrid inspect on, for + * example `projects/dlp-test-project/dlpJob/53234423`. Please see + * {@see DlpServiceClient::dlpJobName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\HybridInspectDlpJobRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the job to execute a hybrid inspect on, for + * example `projects/dlp-test-project/dlpJob/53234423`. + * @type \Google\Cloud\Dlp\V2\HybridContentItem $hybrid_item + * The item to inspect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the job to execute a hybrid inspect on, for + * example `projects/dlp-test-project/dlpJob/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the job to execute a hybrid inspect on, for + * example `projects/dlp-test-project/dlpJob/53234423`. + * + * 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 item to inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridContentItem hybrid_item = 3; + * @return \Google\Cloud\Dlp\V2\HybridContentItem|null + */ + public function getHybridItem() + { + return $this->hybrid_item; + } + + public function hasHybridItem() + { + return isset($this->hybrid_item); + } + + public function clearHybridItem() + { + unset($this->hybrid_item); + } + + /** + * The item to inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridContentItem hybrid_item = 3; + * @param \Google\Cloud\Dlp\V2\HybridContentItem $var + * @return $this + */ + public function setHybridItem($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\HybridContentItem::class); + $this->hybrid_item = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectJobTriggerRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectJobTriggerRequest.php new file mode 100644 index 000000000000..4bca83aaf179 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectJobTriggerRequest.php @@ -0,0 +1,130 @@ +google.privacy.dlp.v2.HybridInspectJobTriggerRequest + */ +class HybridInspectJobTriggerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the trigger to execute a hybrid inspect on, for + * example `projects/dlp-test-project/jobTriggers/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * The item to inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridContentItem hybrid_item = 3; + */ + protected $hybrid_item = null; + + /** + * @param string $name Required. Resource name of the trigger to execute a hybrid inspect on, for + * example `projects/dlp-test-project/jobTriggers/53234423`. Please see + * {@see DlpServiceClient::jobTriggerName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\HybridInspectJobTriggerRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the trigger to execute a hybrid inspect on, for + * example `projects/dlp-test-project/jobTriggers/53234423`. + * @type \Google\Cloud\Dlp\V2\HybridContentItem $hybrid_item + * The item to inspect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the trigger to execute a hybrid inspect on, for + * example `projects/dlp-test-project/jobTriggers/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the trigger to execute a hybrid inspect on, for + * example `projects/dlp-test-project/jobTriggers/53234423`. + * + * 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 item to inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridContentItem hybrid_item = 3; + * @return \Google\Cloud\Dlp\V2\HybridContentItem|null + */ + public function getHybridItem() + { + return $this->hybrid_item; + } + + public function hasHybridItem() + { + return isset($this->hybrid_item); + } + + public function clearHybridItem() + { + unset($this->hybrid_item); + } + + /** + * The item to inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridContentItem hybrid_item = 3; + * @param \Google\Cloud\Dlp\V2\HybridContentItem $var + * @return $this + */ + public function setHybridItem($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\HybridContentItem::class); + $this->hybrid_item = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectResponse.php new file mode 100644 index 000000000000..0589ade65d3c --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectResponse.php @@ -0,0 +1,33 @@ +google.privacy.dlp.v2.HybridInspectResponse + */ +class HybridInspectResponse extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectStatistics.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectStatistics.php new file mode 100644 index 000000000000..9533c8b38f28 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectStatistics.php @@ -0,0 +1,155 @@ +google.privacy.dlp.v2.HybridInspectStatistics + */ +class HybridInspectStatistics extends \Google\Protobuf\Internal\Message +{ + /** + * The number of hybrid inspection requests processed within this job. + * + * Generated from protobuf field int64 processed_count = 1; + */ + protected $processed_count = 0; + /** + * The number of hybrid inspection requests aborted because the job ran + * out of quota or was ended before they could be processed. + * + * Generated from protobuf field int64 aborted_count = 2; + */ + protected $aborted_count = 0; + /** + * The number of hybrid requests currently being processed. Only populated + * when called via method `getDlpJob`. + * A burst of traffic may cause hybrid inspect requests to be enqueued. + * Processing will take place as quickly as possible, but resource limitations + * may impact how long a request is enqueued for. + * + * Generated from protobuf field int64 pending_count = 3; + */ + protected $pending_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $processed_count + * The number of hybrid inspection requests processed within this job. + * @type int|string $aborted_count + * The number of hybrid inspection requests aborted because the job ran + * out of quota or was ended before they could be processed. + * @type int|string $pending_count + * The number of hybrid requests currently being processed. Only populated + * when called via method `getDlpJob`. + * A burst of traffic may cause hybrid inspect requests to be enqueued. + * Processing will take place as quickly as possible, but resource limitations + * may impact how long a request is enqueued for. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The number of hybrid inspection requests processed within this job. + * + * Generated from protobuf field int64 processed_count = 1; + * @return int|string + */ + public function getProcessedCount() + { + return $this->processed_count; + } + + /** + * The number of hybrid inspection requests processed within this job. + * + * Generated from protobuf field int64 processed_count = 1; + * @param int|string $var + * @return $this + */ + public function setProcessedCount($var) + { + GPBUtil::checkInt64($var); + $this->processed_count = $var; + + return $this; + } + + /** + * The number of hybrid inspection requests aborted because the job ran + * out of quota or was ended before they could be processed. + * + * Generated from protobuf field int64 aborted_count = 2; + * @return int|string + */ + public function getAbortedCount() + { + return $this->aborted_count; + } + + /** + * The number of hybrid inspection requests aborted because the job ran + * out of quota or was ended before they could be processed. + * + * Generated from protobuf field int64 aborted_count = 2; + * @param int|string $var + * @return $this + */ + public function setAbortedCount($var) + { + GPBUtil::checkInt64($var); + $this->aborted_count = $var; + + return $this; + } + + /** + * The number of hybrid requests currently being processed. Only populated + * when called via method `getDlpJob`. + * A burst of traffic may cause hybrid inspect requests to be enqueued. + * Processing will take place as quickly as possible, but resource limitations + * may impact how long a request is enqueued for. + * + * Generated from protobuf field int64 pending_count = 3; + * @return int|string + */ + public function getPendingCount() + { + return $this->pending_count; + } + + /** + * The number of hybrid requests currently being processed. Only populated + * when called via method `getDlpJob`. + * A burst of traffic may cause hybrid inspect requests to be enqueued. + * Processing will take place as quickly as possible, but resource limitations + * may impact how long a request is enqueued for. + * + * Generated from protobuf field int64 pending_count = 3; + * @param int|string $var + * @return $this + */ + public function setPendingCount($var) + { + GPBUtil::checkInt64($var); + $this->pending_count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridOptions.php new file mode 100644 index 000000000000..d5167855184a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridOptions.php @@ -0,0 +1,240 @@ +google.privacy.dlp.v2.HybridOptions + */ +class HybridOptions extends \Google\Protobuf\Internal\Message +{ + /** + * A short description of where the data is coming from. Will be stored once + * in the job. 256 max length. + * + * Generated from protobuf field string description = 1; + */ + protected $description = ''; + /** + * These are labels that each inspection request must include within their + * 'finding_labels' map. Request may contain others, but any missing one of + * these will be rejected. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * No more than 10 keys can be required. + * + * Generated from protobuf field repeated string required_finding_label_keys = 2; + */ + private $required_finding_label_keys; + /** + * To organize findings, these labels will be added to each finding. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * Label values must be between 0 and 63 characters long and must conform + * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. + * No more than 10 labels can be associated with a given finding. + * Examples: + * * `"environment" : "production"` + * * `"pipeline" : "etl"` + * + * Generated from protobuf field map labels = 3; + */ + private $labels; + /** + * If the container is a table, additional information to make findings + * meaningful such as the columns that are primary keys. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableOptions table_options = 4; + */ + protected $table_options = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $description + * A short description of where the data is coming from. Will be stored once + * in the job. 256 max length. + * @type array|\Google\Protobuf\Internal\RepeatedField $required_finding_label_keys + * These are labels that each inspection request must include within their + * 'finding_labels' map. Request may contain others, but any missing one of + * these will be rejected. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * No more than 10 keys can be required. + * @type array|\Google\Protobuf\Internal\MapField $labels + * To organize findings, these labels will be added to each finding. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * Label values must be between 0 and 63 characters long and must conform + * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. + * No more than 10 labels can be associated with a given finding. + * Examples: + * * `"environment" : "production"` + * * `"pipeline" : "etl"` + * @type \Google\Cloud\Dlp\V2\TableOptions $table_options + * If the container is a table, additional information to make findings + * meaningful such as the columns that are primary keys. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * A short description of where the data is coming from. Will be stored once + * in the job. 256 max length. + * + * Generated from protobuf field string description = 1; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * A short description of where the data is coming from. Will be stored once + * in the job. 256 max length. + * + * Generated from protobuf field string description = 1; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * These are labels that each inspection request must include within their + * 'finding_labels' map. Request may contain others, but any missing one of + * these will be rejected. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * No more than 10 keys can be required. + * + * Generated from protobuf field repeated string required_finding_label_keys = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRequiredFindingLabelKeys() + { + return $this->required_finding_label_keys; + } + + /** + * These are labels that each inspection request must include within their + * 'finding_labels' map. Request may contain others, but any missing one of + * these will be rejected. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * No more than 10 keys can be required. + * + * Generated from protobuf field repeated string required_finding_label_keys = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRequiredFindingLabelKeys($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->required_finding_label_keys = $arr; + + return $this; + } + + /** + * To organize findings, these labels will be added to each finding. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * Label values must be between 0 and 63 characters long and must conform + * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. + * No more than 10 labels can be associated with a given finding. + * Examples: + * * `"environment" : "production"` + * * `"pipeline" : "etl"` + * + * Generated from protobuf field map labels = 3; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * To organize findings, these labels will be added to each finding. + * Label keys must be between 1 and 63 characters long and must conform + * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. + * Label values must be between 0 and 63 characters long and must conform + * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. + * No more than 10 labels can be associated with a given finding. + * Examples: + * * `"environment" : "production"` + * * `"pipeline" : "etl"` + * + * Generated from protobuf field map labels = 3; + * @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; + } + + /** + * If the container is a table, additional information to make findings + * meaningful such as the columns that are primary keys. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableOptions table_options = 4; + * @return \Google\Cloud\Dlp\V2\TableOptions|null + */ + public function getTableOptions() + { + return $this->table_options; + } + + public function hasTableOptions() + { + return isset($this->table_options); + } + + public function clearTableOptions() + { + unset($this->table_options); + } + + /** + * If the container is a table, additional information to make findings + * meaningful such as the columns that are primary keys. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableOptions table_options = 4; + * @param \Google\Cloud\Dlp\V2\TableOptions $var + * @return $this + */ + public function setTableOptions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableOptions::class); + $this->table_options = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageLocation.php new file mode 100644 index 000000000000..60678827e0b5 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageLocation.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.ImageLocation + */ +class ImageLocation extends \Google\Protobuf\Internal\Message +{ + /** + * Bounding boxes locating the pixels within the image containing the finding. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BoundingBox bounding_boxes = 1; + */ + private $bounding_boxes; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\BoundingBox>|\Google\Protobuf\Internal\RepeatedField $bounding_boxes + * Bounding boxes locating the pixels within the image containing the finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Bounding boxes locating the pixels within the image containing the finding. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BoundingBox bounding_boxes = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBoundingBoxes() + { + return $this->bounding_boxes; + } + + /** + * Bounding boxes locating the pixels within the image containing the finding. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.BoundingBox bounding_boxes = 1; + * @param array<\Google\Cloud\Dlp\V2\BoundingBox>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBoundingBoxes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\BoundingBox::class); + $this->bounding_boxes = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations.php new file mode 100644 index 000000000000..816899665ead --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.ImageTransformations + */ +class ImageTransformations extends \Google\Protobuf\Internal\Message +{ + /** + * List of transforms to make. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ImageTransformations.ImageTransformation transforms = 2; + */ + private $transforms; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation>|\Google\Protobuf\Internal\RepeatedField $transforms + * List of transforms to make. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of transforms to make. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ImageTransformations.ImageTransformation transforms = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTransforms() + { + return $this->transforms; + } + + /** + * List of transforms to make. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ImageTransformations.ImageTransformation transforms = 2; + * @param array<\Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTransforms($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation::class); + $this->transforms = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation.php new file mode 100644 index 000000000000..51539ea89bd7 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation.php @@ -0,0 +1,201 @@ +google.privacy.dlp.v2.ImageTransformations.ImageTransformation + */ +class ImageTransformation extends \Google\Protobuf\Internal\Message +{ + /** + * The color to use when redacting content from an image. If not + * specified, the default is black. + * + * Generated from protobuf field .google.privacy.dlp.v2.Color redaction_color = 3; + */ + protected $redaction_color = null; + protected $target; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\SelectedInfoTypes $selected_info_types + * Apply transformation to the selected info_types. + * @type \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllInfoTypes $all_info_types + * Apply transformation to all findings not specified in other + * ImageTransformation's selected_info_types. Only one instance is allowed + * within the ImageTransformations message. + * @type \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllText $all_text + * Apply transformation to all text that doesn't match an infoType. Only + * one instance is allowed within the ImageTransformations message. + * @type \Google\Cloud\Dlp\V2\Color $redaction_color + * The color to use when redacting content from an image. If not + * specified, the default is black. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Apply transformation to the selected info_types. + * + * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations.ImageTransformation.SelectedInfoTypes selected_info_types = 4; + * @return \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\SelectedInfoTypes|null + */ + public function getSelectedInfoTypes() + { + return $this->readOneof(4); + } + + public function hasSelectedInfoTypes() + { + return $this->hasOneof(4); + } + + /** + * Apply transformation to the selected info_types. + * + * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations.ImageTransformation.SelectedInfoTypes selected_info_types = 4; + * @param \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\SelectedInfoTypes $var + * @return $this + */ + public function setSelectedInfoTypes($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\SelectedInfoTypes::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Apply transformation to all findings not specified in other + * ImageTransformation's selected_info_types. Only one instance is allowed + * within the ImageTransformations message. + * + * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations.ImageTransformation.AllInfoTypes all_info_types = 5; + * @return \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllInfoTypes|null + */ + public function getAllInfoTypes() + { + return $this->readOneof(5); + } + + public function hasAllInfoTypes() + { + return $this->hasOneof(5); + } + + /** + * Apply transformation to all findings not specified in other + * ImageTransformation's selected_info_types. Only one instance is allowed + * within the ImageTransformations message. + * + * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations.ImageTransformation.AllInfoTypes all_info_types = 5; + * @param \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllInfoTypes $var + * @return $this + */ + public function setAllInfoTypes($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllInfoTypes::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * Apply transformation to all text that doesn't match an infoType. Only + * one instance is allowed within the ImageTransformations message. + * + * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations.ImageTransformation.AllText all_text = 6; + * @return \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllText|null + */ + public function getAllText() + { + return $this->readOneof(6); + } + + public function hasAllText() + { + return $this->hasOneof(6); + } + + /** + * Apply transformation to all text that doesn't match an infoType. Only + * one instance is allowed within the ImageTransformations message. + * + * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations.ImageTransformation.AllText all_text = 6; + * @param \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllText $var + * @return $this + */ + public function setAllText($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllText::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * The color to use when redacting content from an image. If not + * specified, the default is black. + * + * Generated from protobuf field .google.privacy.dlp.v2.Color redaction_color = 3; + * @return \Google\Cloud\Dlp\V2\Color|null + */ + public function getRedactionColor() + { + return $this->redaction_color; + } + + public function hasRedactionColor() + { + return isset($this->redaction_color); + } + + public function clearRedactionColor() + { + unset($this->redaction_color); + } + + /** + * The color to use when redacting content from an image. If not + * specified, the default is black. + * + * Generated from protobuf field .google.privacy.dlp.v2.Color redaction_color = 3; + * @param \Google\Cloud\Dlp\V2\Color $var + * @return $this + */ + public function setRedactionColor($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Color::class); + $this->redaction_color = $var; + + return $this; + } + + /** + * @return string + */ + public function getTarget() + { + return $this->whichOneof("target"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ImageTransformation::class, \Google\Cloud\Dlp\V2\ImageTransformations_ImageTransformation::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllInfoTypes.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllInfoTypes.php new file mode 100644 index 000000000000..67e3f138716d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllInfoTypes.php @@ -0,0 +1,36 @@ +google.privacy.dlp.v2.ImageTransformations.ImageTransformation.AllInfoTypes + */ +class AllInfoTypes extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AllInfoTypes::class, \Google\Cloud\Dlp\V2\ImageTransformations_ImageTransformation_AllInfoTypes::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllText.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllText.php new file mode 100644 index 000000000000..dc4389a8d1ea --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllText.php @@ -0,0 +1,36 @@ +google.privacy.dlp.v2.ImageTransformations.ImageTransformation.AllText + */ +class AllText extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AllText::class, \Google\Cloud\Dlp\V2\ImageTransformations_ImageTransformation_AllText::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/SelectedInfoTypes.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/SelectedInfoTypes.php new file mode 100644 index 000000000000..4561d0012782 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/SelectedInfoTypes.php @@ -0,0 +1,74 @@ +google.privacy.dlp.v2.ImageTransformations.ImageTransformation.SelectedInfoTypes + */ +class SelectedInfoTypes extends \Google\Protobuf\Internal\Message +{ + /** + * Required. InfoTypes to apply the transformation to. Required. Provided + * InfoType must be unique within the ImageTransformations message. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 5 [(.google.api.field_behavior) = REQUIRED]; + */ + private $info_types; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $info_types + * Required. InfoTypes to apply the transformation to. Required. Provided + * InfoType must be unique within the ImageTransformations message. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. InfoTypes to apply the transformation to. Required. Provided + * InfoType must be unique within the ImageTransformations message. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 5 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getInfoTypes() + { + return $this->info_types; + } + + /** + * Required. InfoTypes to apply the transformation to. Required. Provided + * InfoType must be unique within the ImageTransformations message. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 5 [(.google.api.field_behavior) = REQUIRED]; + * @param array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setInfoTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_types = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SelectedInfoTypes::class, \Google\Cloud\Dlp\V2\ImageTransformations_ImageTransformation_SelectedInfoTypes::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoType.php new file mode 100644 index 000000000000..7d1307eecacd --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoType.php @@ -0,0 +1,173 @@ +google.privacy.dlp.v2.InfoType + */ +class InfoType extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the information type. Either a name of your choosing when + * creating a CustomInfoType, or one of the names listed + * at + * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference + * when specifying a built-in type. When sending Cloud DLP results to Data + * Catalog, infoType names should conform to the pattern + * `[A-Za-z0-9$_-]{1,64}`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Optional version name for this InfoType. + * + * Generated from protobuf field string version = 2; + */ + protected $version = ''; + /** + * Optional custom sensitivity for this InfoType. + * This only applies to data profiling. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 3; + */ + protected $sensitivity_score = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name of the information type. Either a name of your choosing when + * creating a CustomInfoType, or one of the names listed + * at + * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference + * when specifying a built-in type. When sending Cloud DLP results to Data + * Catalog, infoType names should conform to the pattern + * `[A-Za-z0-9$_-]{1,64}`. + * @type string $version + * Optional version name for this InfoType. + * @type \Google\Cloud\Dlp\V2\SensitivityScore $sensitivity_score + * Optional custom sensitivity for this InfoType. + * This only applies to data profiling. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Name of the information type. Either a name of your choosing when + * creating a CustomInfoType, or one of the names listed + * at + * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference + * when specifying a built-in type. When sending Cloud DLP results to Data + * Catalog, infoType names should conform to the pattern + * `[A-Za-z0-9$_-]{1,64}`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name of the information type. Either a name of your choosing when + * creating a CustomInfoType, or one of the names listed + * at + * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference + * when specifying a built-in type. When sending Cloud DLP results to Data + * Catalog, infoType names should conform to the pattern + * `[A-Za-z0-9$_-]{1,64}`. + * + * 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; + } + + /** + * Optional version name for this InfoType. + * + * Generated from protobuf field string version = 2; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * Optional version name for this InfoType. + * + * 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; + } + + /** + * Optional custom sensitivity for this InfoType. + * This only applies to data profiling. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 3; + * @return \Google\Cloud\Dlp\V2\SensitivityScore|null + */ + public function getSensitivityScore() + { + return $this->sensitivity_score; + } + + public function hasSensitivityScore() + { + return isset($this->sensitivity_score); + } + + public function clearSensitivityScore() + { + unset($this->sensitivity_score); + } + + /** + * Optional custom sensitivity for this InfoType. + * This only applies to data profiling. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 3; + * @param \Google\Cloud\Dlp\V2\SensitivityScore $var + * @return $this + */ + public function setSensitivityScore($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SensitivityScore::class); + $this->sensitivity_score = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory.php new file mode 100644 index 000000000000..c1579ef0baed --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory.php @@ -0,0 +1,145 @@ +google.privacy.dlp.v2.InfoTypeCategory + */ +class InfoTypeCategory extends \Google\Protobuf\Internal\Message +{ + protected $category; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $location_category + * The region or country that issued the ID or document represented by the + * infoType. + * @type int $industry_category + * The group of relevant businesses where this infoType is commonly used + * @type int $type_category + * The class of identifiers where this infoType belongs + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The region or country that issued the ID or document represented by the + * infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeCategory.LocationCategory location_category = 1; + * @return int + */ + public function getLocationCategory() + { + return $this->readOneof(1); + } + + public function hasLocationCategory() + { + return $this->hasOneof(1); + } + + /** + * The region or country that issued the ID or document represented by the + * infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeCategory.LocationCategory location_category = 1; + * @param int $var + * @return $this + */ + public function setLocationCategory($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\InfoTypeCategory\LocationCategory::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * The group of relevant businesses where this infoType is commonly used + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeCategory.IndustryCategory industry_category = 2; + * @return int + */ + public function getIndustryCategory() + { + return $this->readOneof(2); + } + + public function hasIndustryCategory() + { + return $this->hasOneof(2); + } + + /** + * The group of relevant businesses where this infoType is commonly used + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeCategory.IndustryCategory industry_category = 2; + * @param int $var + * @return $this + */ + public function setIndustryCategory($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\InfoTypeCategory\IndustryCategory::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The class of identifiers where this infoType belongs + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeCategory.TypeCategory type_category = 3; + * @return int + */ + public function getTypeCategory() + { + return $this->readOneof(3); + } + + public function hasTypeCategory() + { + return $this->hasOneof(3); + } + + /** + * The class of identifiers where this infoType belongs + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeCategory.TypeCategory type_category = 3; + * @param int $var + * @return $this + */ + public function setTypeCategory($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\InfoTypeCategory\TypeCategory::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getCategory() + { + return $this->whichOneof("category"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/IndustryCategory.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/IndustryCategory.php new file mode 100644 index 000000000000..429186610d6f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/IndustryCategory.php @@ -0,0 +1,72 @@ +google.privacy.dlp.v2.InfoTypeCategory.IndustryCategory + */ +class IndustryCategory +{ + /** + * Unused industry + * + * Generated from protobuf enum INDUSTRY_UNSPECIFIED = 0; + */ + const INDUSTRY_UNSPECIFIED = 0; + /** + * The infoType is typically used in the finance industry. + * + * Generated from protobuf enum FINANCE = 1; + */ + const FINANCE = 1; + /** + * The infoType is typically used in the health industry. + * + * Generated from protobuf enum HEALTH = 2; + */ + const HEALTH = 2; + /** + * The infoType is typically used in the telecommunications industry. + * + * Generated from protobuf enum TELECOMMUNICATIONS = 3; + */ + const TELECOMMUNICATIONS = 3; + + private static $valueToName = [ + self::INDUSTRY_UNSPECIFIED => 'INDUSTRY_UNSPECIFIED', + self::FINANCE => 'FINANCE', + self::HEALTH => 'HEALTH', + self::TELECOMMUNICATIONS => 'TELECOMMUNICATIONS', + ]; + + 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(IndustryCategory::class, \Google\Cloud\Dlp\V2\InfoTypeCategory_IndustryCategory::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/LocationCategory.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/LocationCategory.php new file mode 100644 index 000000000000..5d6155f21604 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/LocationCategory.php @@ -0,0 +1,392 @@ +google.privacy.dlp.v2.InfoTypeCategory.LocationCategory + */ +class LocationCategory +{ + /** + * Unused location + * + * Generated from protobuf enum LOCATION_UNSPECIFIED = 0; + */ + const LOCATION_UNSPECIFIED = 0; + /** + * The infoType is not issued by or tied to a specific region, but is used + * almost everywhere. + * + * Generated from protobuf enum GLOBAL = 1; + */ + const PBGLOBAL = 1; + /** + * The infoType is typically used in Argentina. + * + * Generated from protobuf enum ARGENTINA = 2; + */ + const ARGENTINA = 2; + /** + * The infoType is typically used in Australia. + * + * Generated from protobuf enum AUSTRALIA = 3; + */ + const AUSTRALIA = 3; + /** + * The infoType is typically used in Azerbaijan. + * + * Generated from protobuf enum AZERBAIJAN = 48; + */ + const AZERBAIJAN = 48; + /** + * The infoType is typically used in Belgium. + * + * Generated from protobuf enum BELGIUM = 4; + */ + const BELGIUM = 4; + /** + * The infoType is typically used in Brazil. + * + * Generated from protobuf enum BRAZIL = 5; + */ + const BRAZIL = 5; + /** + * The infoType is typically used in Canada. + * + * Generated from protobuf enum CANADA = 6; + */ + const CANADA = 6; + /** + * The infoType is typically used in Chile. + * + * Generated from protobuf enum CHILE = 7; + */ + const CHILE = 7; + /** + * The infoType is typically used in China. + * + * Generated from protobuf enum CHINA = 8; + */ + const CHINA = 8; + /** + * The infoType is typically used in Colombia. + * + * Generated from protobuf enum COLOMBIA = 9; + */ + const COLOMBIA = 9; + /** + * The infoType is typically used in Croatia. + * + * Generated from protobuf enum CROATIA = 42; + */ + const CROATIA = 42; + /** + * The infoType is typically used in Denmark. + * + * Generated from protobuf enum DENMARK = 10; + */ + const DENMARK = 10; + /** + * The infoType is typically used in France. + * + * Generated from protobuf enum FRANCE = 11; + */ + const FRANCE = 11; + /** + * The infoType is typically used in Finland. + * + * Generated from protobuf enum FINLAND = 12; + */ + const FINLAND = 12; + /** + * The infoType is typically used in Germany. + * + * Generated from protobuf enum GERMANY = 13; + */ + const GERMANY = 13; + /** + * The infoType is typically used in Hong Kong. + * + * Generated from protobuf enum HONG_KONG = 14; + */ + const HONG_KONG = 14; + /** + * The infoType is typically used in India. + * + * Generated from protobuf enum INDIA = 15; + */ + const INDIA = 15; + /** + * The infoType is typically used in Indonesia. + * + * Generated from protobuf enum INDONESIA = 16; + */ + const INDONESIA = 16; + /** + * The infoType is typically used in Ireland. + * + * Generated from protobuf enum IRELAND = 17; + */ + const IRELAND = 17; + /** + * The infoType is typically used in Israel. + * + * Generated from protobuf enum ISRAEL = 18; + */ + const ISRAEL = 18; + /** + * The infoType is typically used in Italy. + * + * Generated from protobuf enum ITALY = 19; + */ + const ITALY = 19; + /** + * The infoType is typically used in Japan. + * + * Generated from protobuf enum JAPAN = 20; + */ + const JAPAN = 20; + /** + * The infoType is typically used in Kazakhstan. + * + * Generated from protobuf enum KAZAKHSTAN = 47; + */ + const KAZAKHSTAN = 47; + /** + * The infoType is typically used in Korea. + * + * Generated from protobuf enum KOREA = 21; + */ + const KOREA = 21; + /** + * The infoType is typically used in Mexico. + * + * Generated from protobuf enum MEXICO = 22; + */ + const MEXICO = 22; + /** + * The infoType is typically used in the Netherlands. + * + * Generated from protobuf enum THE_NETHERLANDS = 23; + */ + const THE_NETHERLANDS = 23; + /** + * The infoType is typically used in New Zealand. + * + * Generated from protobuf enum NEW_ZEALAND = 41; + */ + const NEW_ZEALAND = 41; + /** + * The infoType is typically used in Norway. + * + * Generated from protobuf enum NORWAY = 24; + */ + const NORWAY = 24; + /** + * The infoType is typically used in Paraguay. + * + * Generated from protobuf enum PARAGUAY = 25; + */ + const PARAGUAY = 25; + /** + * The infoType is typically used in Peru. + * + * Generated from protobuf enum PERU = 26; + */ + const PERU = 26; + /** + * The infoType is typically used in Poland. + * + * Generated from protobuf enum POLAND = 27; + */ + const POLAND = 27; + /** + * The infoType is typically used in Portugal. + * + * Generated from protobuf enum PORTUGAL = 28; + */ + const PORTUGAL = 28; + /** + * The infoType is typically used in Russia. + * + * Generated from protobuf enum RUSSIA = 44; + */ + const RUSSIA = 44; + /** + * The infoType is typically used in Singapore. + * + * Generated from protobuf enum SINGAPORE = 29; + */ + const SINGAPORE = 29; + /** + * The infoType is typically used in South Africa. + * + * Generated from protobuf enum SOUTH_AFRICA = 30; + */ + const SOUTH_AFRICA = 30; + /** + * The infoType is typically used in Spain. + * + * Generated from protobuf enum SPAIN = 31; + */ + const SPAIN = 31; + /** + * The infoType is typically used in Sweden. + * + * Generated from protobuf enum SWEDEN = 32; + */ + const SWEDEN = 32; + /** + * The infoType is typically used in Switzerland. + * + * Generated from protobuf enum SWITZERLAND = 43; + */ + const SWITZERLAND = 43; + /** + * The infoType is typically used in Taiwan. + * + * Generated from protobuf enum TAIWAN = 33; + */ + const TAIWAN = 33; + /** + * The infoType is typically used in Thailand. + * + * Generated from protobuf enum THAILAND = 34; + */ + const THAILAND = 34; + /** + * The infoType is typically used in Turkey. + * + * Generated from protobuf enum TURKEY = 35; + */ + const TURKEY = 35; + /** + * The infoType is typically used in Ukraine. + * + * Generated from protobuf enum UKRAINE = 45; + */ + const UKRAINE = 45; + /** + * The infoType is typically used in the United Kingdom. + * + * Generated from protobuf enum UNITED_KINGDOM = 36; + */ + const UNITED_KINGDOM = 36; + /** + * The infoType is typically used in the United States. + * + * Generated from protobuf enum UNITED_STATES = 37; + */ + const UNITED_STATES = 37; + /** + * The infoType is typically used in Uruguay. + * + * Generated from protobuf enum URUGUAY = 38; + */ + const URUGUAY = 38; + /** + * The infoType is typically used in Uzbekistan. + * + * Generated from protobuf enum UZBEKISTAN = 46; + */ + const UZBEKISTAN = 46; + /** + * The infoType is typically used in Venezuela. + * + * Generated from protobuf enum VENEZUELA = 39; + */ + const VENEZUELA = 39; + /** + * The infoType is typically used in Google internally. + * + * Generated from protobuf enum INTERNAL = 40; + */ + const INTERNAL = 40; + + private static $valueToName = [ + self::LOCATION_UNSPECIFIED => 'LOCATION_UNSPECIFIED', + self::PBGLOBAL => 'GLOBAL', + self::ARGENTINA => 'ARGENTINA', + self::AUSTRALIA => 'AUSTRALIA', + self::AZERBAIJAN => 'AZERBAIJAN', + self::BELGIUM => 'BELGIUM', + self::BRAZIL => 'BRAZIL', + self::CANADA => 'CANADA', + self::CHILE => 'CHILE', + self::CHINA => 'CHINA', + self::COLOMBIA => 'COLOMBIA', + self::CROATIA => 'CROATIA', + self::DENMARK => 'DENMARK', + self::FRANCE => 'FRANCE', + self::FINLAND => 'FINLAND', + self::GERMANY => 'GERMANY', + self::HONG_KONG => 'HONG_KONG', + self::INDIA => 'INDIA', + self::INDONESIA => 'INDONESIA', + self::IRELAND => 'IRELAND', + self::ISRAEL => 'ISRAEL', + self::ITALY => 'ITALY', + self::JAPAN => 'JAPAN', + self::KAZAKHSTAN => 'KAZAKHSTAN', + self::KOREA => 'KOREA', + self::MEXICO => 'MEXICO', + self::THE_NETHERLANDS => 'THE_NETHERLANDS', + self::NEW_ZEALAND => 'NEW_ZEALAND', + self::NORWAY => 'NORWAY', + self::PARAGUAY => 'PARAGUAY', + self::PERU => 'PERU', + self::POLAND => 'POLAND', + self::PORTUGAL => 'PORTUGAL', + self::RUSSIA => 'RUSSIA', + self::SINGAPORE => 'SINGAPORE', + self::SOUTH_AFRICA => 'SOUTH_AFRICA', + self::SPAIN => 'SPAIN', + self::SWEDEN => 'SWEDEN', + self::SWITZERLAND => 'SWITZERLAND', + self::TAIWAN => 'TAIWAN', + self::THAILAND => 'THAILAND', + self::TURKEY => 'TURKEY', + self::UKRAINE => 'UKRAINE', + self::UNITED_KINGDOM => 'UNITED_KINGDOM', + self::UNITED_STATES => 'UNITED_STATES', + self::URUGUAY => 'URUGUAY', + self::UZBEKISTAN => 'UZBEKISTAN', + self::VENEZUELA => 'VENEZUELA', + self::INTERNAL => 'INTERNAL', + ]; + + 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)) { + $pbconst = __CLASS__. '::PB' . strtoupper($name); + if (!defined($pbconst)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($pbconst); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(LocationCategory::class, \Google\Cloud\Dlp\V2\InfoTypeCategory_LocationCategory::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/TypeCategory.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/TypeCategory.php new file mode 100644 index 000000000000..bbc6fd462069 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/TypeCategory.php @@ -0,0 +1,104 @@ +google.privacy.dlp.v2.InfoTypeCategory.TypeCategory + */ +class TypeCategory +{ + /** + * Unused type + * + * Generated from protobuf enum TYPE_UNSPECIFIED = 0; + */ + const TYPE_UNSPECIFIED = 0; + /** + * Personally identifiable information, for example, a + * name or phone number + * + * Generated from protobuf enum PII = 1; + */ + const PII = 1; + /** + * Personally identifiable information that is especially sensitive, for + * example, a passport number. + * + * Generated from protobuf enum SPII = 2; + */ + const SPII = 2; + /** + * Attributes that can partially identify someone, especially in + * combination with other attributes, like age, height, and gender. + * + * Generated from protobuf enum DEMOGRAPHIC = 3; + */ + const DEMOGRAPHIC = 3; + /** + * Confidential or secret information, for example, a password. + * + * Generated from protobuf enum CREDENTIAL = 4; + */ + const CREDENTIAL = 4; + /** + * An identification document issued by a government. + * + * Generated from protobuf enum GOVERNMENT_ID = 5; + */ + const GOVERNMENT_ID = 5; + /** + * A document, for example, a resume or source code. + * + * Generated from protobuf enum DOCUMENT = 6; + */ + const DOCUMENT = 6; + /** + * Information that is not sensitive on its own, but provides details about + * the circumstances surrounding an entity or an event. + * + * Generated from protobuf enum CONTEXTUAL_INFORMATION = 7; + */ + const CONTEXTUAL_INFORMATION = 7; + + private static $valueToName = [ + self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', + self::PII => 'PII', + self::SPII => 'SPII', + self::DEMOGRAPHIC => 'DEMOGRAPHIC', + self::CREDENTIAL => 'CREDENTIAL', + self::GOVERNMENT_ID => 'GOVERNMENT_ID', + self::DOCUMENT => 'DOCUMENT', + self::CONTEXTUAL_INFORMATION => 'CONTEXTUAL_INFORMATION', + ]; + + 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(TypeCategory::class, \Google\Cloud\Dlp\V2\InfoTypeCategory_TypeCategory::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeDescription.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeDescription.php new file mode 100644 index 000000000000..68864fe9391f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeDescription.php @@ -0,0 +1,285 @@ +google.privacy.dlp.v2.InfoTypeDescription + */ +class InfoTypeDescription extends \Google\Protobuf\Internal\Message +{ + /** + * Internal name of the infoType. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Human readable form of the infoType name. + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + /** + * Which parts of the API supports this InfoType. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeSupportedBy supported_by = 3; + */ + private $supported_by; + /** + * Description of the infotype. Translated when language is provided in the + * request. + * + * Generated from protobuf field string description = 4; + */ + protected $description = ''; + /** + * A list of available versions for the infotype. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.VersionDescription versions = 9; + */ + private $versions; + /** + * The category of the infoType. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeCategory categories = 10; + */ + private $categories; + /** + * The default sensitivity of the infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 11; + */ + protected $sensitivity_score = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Internal name of the infoType. + * @type string $display_name + * Human readable form of the infoType name. + * @type array|\Google\Protobuf\Internal\RepeatedField $supported_by + * Which parts of the API supports this InfoType. + * @type string $description + * Description of the infotype. Translated when language is provided in the + * request. + * @type array<\Google\Cloud\Dlp\V2\VersionDescription>|\Google\Protobuf\Internal\RepeatedField $versions + * A list of available versions for the infotype. + * @type array<\Google\Cloud\Dlp\V2\InfoTypeCategory>|\Google\Protobuf\Internal\RepeatedField $categories + * The category of the infoType. + * @type \Google\Cloud\Dlp\V2\SensitivityScore $sensitivity_score + * The default sensitivity of the infoType. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Internal name of the infoType. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Internal name of the infoType. + * + * 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; + } + + /** + * Human readable form of the infoType name. + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Human readable form of the infoType name. + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * Which parts of the API supports this InfoType. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeSupportedBy supported_by = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSupportedBy() + { + return $this->supported_by; + } + + /** + * Which parts of the API supports this InfoType. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeSupportedBy supported_by = 3; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSupportedBy($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\InfoTypeSupportedBy::class); + $this->supported_by = $arr; + + return $this; + } + + /** + * Description of the infotype. Translated when language is provided in the + * request. + * + * Generated from protobuf field string description = 4; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Description of the infotype. Translated when language is provided in the + * request. + * + * Generated from protobuf field string description = 4; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * A list of available versions for the infotype. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.VersionDescription versions = 9; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getVersions() + { + return $this->versions; + } + + /** + * A list of available versions for the infotype. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.VersionDescription versions = 9; + * @param array<\Google\Cloud\Dlp\V2\VersionDescription>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setVersions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\VersionDescription::class); + $this->versions = $arr; + + return $this; + } + + /** + * The category of the infoType. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeCategory categories = 10; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getCategories() + { + return $this->categories; + } + + /** + * The category of the infoType. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeCategory categories = 10; + * @param array<\Google\Cloud\Dlp\V2\InfoTypeCategory>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setCategories($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoTypeCategory::class); + $this->categories = $arr; + + return $this; + } + + /** + * The default sensitivity of the infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 11; + * @return \Google\Cloud\Dlp\V2\SensitivityScore|null + */ + public function getSensitivityScore() + { + return $this->sensitivity_score; + } + + public function hasSensitivityScore() + { + return isset($this->sensitivity_score); + } + + public function clearSensitivityScore() + { + unset($this->sensitivity_score); + } + + /** + * The default sensitivity of the infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 11; + * @param \Google\Cloud\Dlp\V2\SensitivityScore $var + * @return $this + */ + public function setSensitivityScore($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SensitivityScore::class); + $this->sensitivity_score = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeStats.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeStats.php new file mode 100644 index 000000000000..d597096908b4 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeStats.php @@ -0,0 +1,111 @@ +google.privacy.dlp.v2.InfoTypeStats + */ +class InfoTypeStats extends \Google\Protobuf\Internal\Message +{ + /** + * The type of finding this stat is for. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + */ + protected $info_type = null; + /** + * Number of findings for this infoType. + * + * Generated from protobuf field int64 count = 2; + */ + protected $count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InfoType $info_type + * The type of finding this stat is for. + * @type int|string $count + * Number of findings for this infoType. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The type of finding this stat is for. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getInfoType() + { + return $this->info_type; + } + + public function hasInfoType() + { + return isset($this->info_type); + } + + public function clearInfoType() + { + unset($this->info_type); + } + + /** + * The type of finding this stat is for. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_type = $var; + + return $this; + } + + /** + * Number of findings for this infoType. + * + * Generated from protobuf field int64 count = 2; + * @return int|string + */ + public function getCount() + { + return $this->count; + } + + /** + * Number of findings for this infoType. + * + * Generated from protobuf field int64 count = 2; + * @param int|string $var + * @return $this + */ + public function setCount($var) + { + GPBUtil::checkInt64($var); + $this->count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSummary.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSummary.php new file mode 100644 index 000000000000..e99cc8206155 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSummary.php @@ -0,0 +1,116 @@ +google.privacy.dlp.v2.InfoTypeSummary + */ +class InfoTypeSummary extends \Google\Protobuf\Internal\Message +{ + /** + * The infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + */ + protected $info_type = null; + /** + * Not populated for predicted infotypes. + * + * Generated from protobuf field int32 estimated_prevalence = 2 [deprecated = true]; + * @deprecated + */ + protected $estimated_prevalence = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InfoType $info_type + * The infoType. + * @type int $estimated_prevalence + * Not populated for predicted infotypes. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getInfoType() + { + return $this->info_type; + } + + public function hasInfoType() + { + return isset($this->info_type); + } + + public function clearInfoType() + { + unset($this->info_type); + } + + /** + * The infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_type = $var; + + return $this; + } + + /** + * Not populated for predicted infotypes. + * + * Generated from protobuf field int32 estimated_prevalence = 2 [deprecated = true]; + * @return int + * @deprecated + */ + public function getEstimatedPrevalence() + { + @trigger_error('estimated_prevalence is deprecated.', E_USER_DEPRECATED); + return $this->estimated_prevalence; + } + + /** + * Not populated for predicted infotypes. + * + * Generated from protobuf field int32 estimated_prevalence = 2 [deprecated = true]; + * @param int $var + * @return $this + * @deprecated + */ + public function setEstimatedPrevalence($var) + { + @trigger_error('estimated_prevalence is deprecated.', E_USER_DEPRECATED); + GPBUtil::checkInt32($var); + $this->estimated_prevalence = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSupportedBy.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSupportedBy.php new file mode 100644 index 000000000000..57ea0fb34dad --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSupportedBy.php @@ -0,0 +1,61 @@ +google.privacy.dlp.v2.InfoTypeSupportedBy + */ +class InfoTypeSupportedBy +{ + /** + * Unused. + * + * Generated from protobuf enum ENUM_TYPE_UNSPECIFIED = 0; + */ + const ENUM_TYPE_UNSPECIFIED = 0; + /** + * Supported by the inspect operations. + * + * Generated from protobuf enum INSPECT = 1; + */ + const INSPECT = 1; + /** + * Supported by the risk analysis operations. + * + * Generated from protobuf enum RISK_ANALYSIS = 2; + */ + const RISK_ANALYSIS = 2; + + private static $valueToName = [ + self::ENUM_TYPE_UNSPECIFIED => 'ENUM_TYPE_UNSPECIFIED', + self::INSPECT => 'INSPECT', + self::RISK_ANALYSIS => 'RISK_ANALYSIS', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations.php new file mode 100644 index 000000000000..c35f65c972d4 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations.php @@ -0,0 +1,74 @@ +google.privacy.dlp.v2.InfoTypeTransformations + */ +class InfoTypeTransformations extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Transformation for each infoType. Cannot specify more than one + * for a given infoType. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeTransformations.InfoTypeTransformation transformations = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + private $transformations; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\InfoTypeTransformations\InfoTypeTransformation>|\Google\Protobuf\Internal\RepeatedField $transformations + * Required. Transformation for each infoType. Cannot specify more than one + * for a given infoType. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Transformation for each infoType. Cannot specify more than one + * for a given infoType. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeTransformations.InfoTypeTransformation transformations = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTransformations() + { + return $this->transformations; + } + + /** + * Required. Transformation for each infoType. Cannot specify more than one + * for a given infoType. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeTransformations.InfoTypeTransformation transformations = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param array<\Google\Cloud\Dlp\V2\InfoTypeTransformations\InfoTypeTransformation>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTransformations($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoTypeTransformations\InfoTypeTransformation::class); + $this->transformations = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations/InfoTypeTransformation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations/InfoTypeTransformation.php new file mode 100644 index 000000000000..a3d95ca85835 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations/InfoTypeTransformation.php @@ -0,0 +1,123 @@ +google.privacy.dlp.v2.InfoTypeTransformations.InfoTypeTransformation + */ +class InfoTypeTransformation extends \Google\Protobuf\Internal\Message +{ + /** + * InfoTypes to apply the transformation to. An empty list will cause + * this transformation to apply to all findings that correspond to + * infoTypes that were requested in `InspectConfig`. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; + */ + private $info_types; + /** + * Required. Primitive transformation to apply to the infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation primitive_transformation = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $primitive_transformation = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $info_types + * InfoTypes to apply the transformation to. An empty list will cause + * this transformation to apply to all findings that correspond to + * infoTypes that were requested in `InspectConfig`. + * @type \Google\Cloud\Dlp\V2\PrimitiveTransformation $primitive_transformation + * Required. Primitive transformation to apply to the infoType. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * InfoTypes to apply the transformation to. An empty list will cause + * this transformation to apply to all findings that correspond to + * infoTypes that were requested in `InspectConfig`. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getInfoTypes() + { + return $this->info_types; + } + + /** + * InfoTypes to apply the transformation to. An empty list will cause + * this transformation to apply to all findings that correspond to + * infoTypes that were requested in `InspectConfig`. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; + * @param array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setInfoTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_types = $arr; + + return $this; + } + + /** + * Required. Primitive transformation to apply to the infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation primitive_transformation = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\PrimitiveTransformation|null + */ + public function getPrimitiveTransformation() + { + return $this->primitive_transformation; + } + + public function hasPrimitiveTransformation() + { + return isset($this->primitive_transformation); + } + + public function clearPrimitiveTransformation() + { + unset($this->primitive_transformation); + } + + /** + * Required. Primitive transformation to apply to the infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation primitive_transformation = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\PrimitiveTransformation $var + * @return $this + */ + public function setPrimitiveTransformation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrimitiveTransformation::class); + $this->primitive_transformation = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(InfoTypeTransformation::class, \Google\Cloud\Dlp\V2\InfoTypeTransformations_InfoTypeTransformation::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig.php new file mode 100644 index 000000000000..a715717d009f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig.php @@ -0,0 +1,495 @@ +google.privacy.dlp.v2.InspectConfig + */ +class InspectConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Restricts what info_types to look for. The values must correspond to + * InfoType values returned by ListInfoTypes or listed at + * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference. + * When no InfoTypes or CustomInfoTypes are specified in a request, the + * system may automatically choose a default list of detectors to run, which + * may change over time. + * If you need precise control and predictability as to what detectors are + * run you should specify specific InfoTypes listed in the reference, + * otherwise a default list will be used, which may change over time. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; + */ + private $info_types; + /** + * Only returns findings equal to or above this threshold. The default is + * POSSIBLE. + * In general, the highest likelihood setting yields the fewest findings in + * results and the lowest chance of a false positive. For more information, + * see [Match + * likelihood](https://cloud.google.com/sensitive-data-protection/docs/likelihood). + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood min_likelihood = 2; + */ + protected $min_likelihood = 0; + /** + * Minimum likelihood per infotype. For each infotype, a user can specify a + * minimum likelihood. The system only returns a finding if its likelihood is + * above this threshold. If this field is not set, the system uses the + * InspectConfig min_likelihood. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectConfig.InfoTypeLikelihood min_likelihood_per_info_type = 11; + */ + private $min_likelihood_per_info_type; + /** + * Configuration to control the number of findings returned. + * This is not used for data profiling. + * When redacting sensitive data from images, finding limits don't apply. They + * can cause unexpected or inconsistent results, where only some data is + * redacted. Don't include finding limits in + * [RedactImage][google.privacy.dlp.v2.DlpService.RedactImage] + * requests. Otherwise, Cloud DLP returns an error. + * When set within an + * [InspectJobConfig][google.privacy.dlp.v2.InspectJobConfig], the specified + * maximum values aren't hard limits. If an inspection job reaches these + * limits, the job ends gradually, not abruptly. Therefore, the actual number + * of findings that Cloud DLP returns can be multiple times higher than these + * maximum values. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig.FindingLimits limits = 3; + */ + protected $limits = null; + /** + * When true, a contextual quote from the data that triggered a finding is + * included in the response; see + * [Finding.quote][google.privacy.dlp.v2.Finding.quote]. This is not used for + * data profiling. + * + * Generated from protobuf field bool include_quote = 4; + */ + protected $include_quote = false; + /** + * When true, excludes type information of the findings. + * This is not used for data profiling. + * + * Generated from protobuf field bool exclude_info_types = 5; + */ + protected $exclude_info_types = false; + /** + * CustomInfoTypes provided by the user. See + * https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes + * to learn more. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.CustomInfoType custom_info_types = 6; + */ + private $custom_info_types; + /** + * Deprecated and unused. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ContentOption content_options = 8; + */ + private $content_options; + /** + * Set of rules to apply to the findings for this InspectConfig. + * Exclusion rules, contained in the set are executed in the end, other + * rules are executed in the order they are specified for each info type. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectionRuleSet rule_set = 10; + */ + private $rule_set; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $info_types + * Restricts what info_types to look for. The values must correspond to + * InfoType values returned by ListInfoTypes or listed at + * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference. + * When no InfoTypes or CustomInfoTypes are specified in a request, the + * system may automatically choose a default list of detectors to run, which + * may change over time. + * If you need precise control and predictability as to what detectors are + * run you should specify specific InfoTypes listed in the reference, + * otherwise a default list will be used, which may change over time. + * @type int $min_likelihood + * Only returns findings equal to or above this threshold. The default is + * POSSIBLE. + * In general, the highest likelihood setting yields the fewest findings in + * results and the lowest chance of a false positive. For more information, + * see [Match + * likelihood](https://cloud.google.com/sensitive-data-protection/docs/likelihood). + * @type array<\Google\Cloud\Dlp\V2\InspectConfig\InfoTypeLikelihood>|\Google\Protobuf\Internal\RepeatedField $min_likelihood_per_info_type + * Minimum likelihood per infotype. For each infotype, a user can specify a + * minimum likelihood. The system only returns a finding if its likelihood is + * above this threshold. If this field is not set, the system uses the + * InspectConfig min_likelihood. + * @type \Google\Cloud\Dlp\V2\InspectConfig\FindingLimits $limits + * Configuration to control the number of findings returned. + * This is not used for data profiling. + * When redacting sensitive data from images, finding limits don't apply. They + * can cause unexpected or inconsistent results, where only some data is + * redacted. Don't include finding limits in + * [RedactImage][google.privacy.dlp.v2.DlpService.RedactImage] + * requests. Otherwise, Cloud DLP returns an error. + * When set within an + * [InspectJobConfig][google.privacy.dlp.v2.InspectJobConfig], the specified + * maximum values aren't hard limits. If an inspection job reaches these + * limits, the job ends gradually, not abruptly. Therefore, the actual number + * of findings that Cloud DLP returns can be multiple times higher than these + * maximum values. + * @type bool $include_quote + * When true, a contextual quote from the data that triggered a finding is + * included in the response; see + * [Finding.quote][google.privacy.dlp.v2.Finding.quote]. This is not used for + * data profiling. + * @type bool $exclude_info_types + * When true, excludes type information of the findings. + * This is not used for data profiling. + * @type array<\Google\Cloud\Dlp\V2\CustomInfoType>|\Google\Protobuf\Internal\RepeatedField $custom_info_types + * CustomInfoTypes provided by the user. See + * https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes + * to learn more. + * @type array|\Google\Protobuf\Internal\RepeatedField $content_options + * Deprecated and unused. + * @type array<\Google\Cloud\Dlp\V2\InspectionRuleSet>|\Google\Protobuf\Internal\RepeatedField $rule_set + * Set of rules to apply to the findings for this InspectConfig. + * Exclusion rules, contained in the set are executed in the end, other + * rules are executed in the order they are specified for each info type. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Restricts what info_types to look for. The values must correspond to + * InfoType values returned by ListInfoTypes or listed at + * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference. + * When no InfoTypes or CustomInfoTypes are specified in a request, the + * system may automatically choose a default list of detectors to run, which + * may change over time. + * If you need precise control and predictability as to what detectors are + * run you should specify specific InfoTypes listed in the reference, + * otherwise a default list will be used, which may change over time. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getInfoTypes() + { + return $this->info_types; + } + + /** + * Restricts what info_types to look for. The values must correspond to + * InfoType values returned by ListInfoTypes or listed at + * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference. + * When no InfoTypes or CustomInfoTypes are specified in a request, the + * system may automatically choose a default list of detectors to run, which + * may change over time. + * If you need precise control and predictability as to what detectors are + * run you should specify specific InfoTypes listed in the reference, + * otherwise a default list will be used, which may change over time. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; + * @param array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setInfoTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_types = $arr; + + return $this; + } + + /** + * Only returns findings equal to or above this threshold. The default is + * POSSIBLE. + * In general, the highest likelihood setting yields the fewest findings in + * results and the lowest chance of a false positive. For more information, + * see [Match + * likelihood](https://cloud.google.com/sensitive-data-protection/docs/likelihood). + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood min_likelihood = 2; + * @return int + */ + public function getMinLikelihood() + { + return $this->min_likelihood; + } + + /** + * Only returns findings equal to or above this threshold. The default is + * POSSIBLE. + * In general, the highest likelihood setting yields the fewest findings in + * results and the lowest chance of a false positive. For more information, + * see [Match + * likelihood](https://cloud.google.com/sensitive-data-protection/docs/likelihood). + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood min_likelihood = 2; + * @param int $var + * @return $this + */ + public function setMinLikelihood($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\Likelihood::class); + $this->min_likelihood = $var; + + return $this; + } + + /** + * Minimum likelihood per infotype. For each infotype, a user can specify a + * minimum likelihood. The system only returns a finding if its likelihood is + * above this threshold. If this field is not set, the system uses the + * InspectConfig min_likelihood. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectConfig.InfoTypeLikelihood min_likelihood_per_info_type = 11; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMinLikelihoodPerInfoType() + { + return $this->min_likelihood_per_info_type; + } + + /** + * Minimum likelihood per infotype. For each infotype, a user can specify a + * minimum likelihood. The system only returns a finding if its likelihood is + * above this threshold. If this field is not set, the system uses the + * InspectConfig min_likelihood. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectConfig.InfoTypeLikelihood min_likelihood_per_info_type = 11; + * @param array<\Google\Cloud\Dlp\V2\InspectConfig\InfoTypeLikelihood>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMinLikelihoodPerInfoType($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InspectConfig\InfoTypeLikelihood::class); + $this->min_likelihood_per_info_type = $arr; + + return $this; + } + + /** + * Configuration to control the number of findings returned. + * This is not used for data profiling. + * When redacting sensitive data from images, finding limits don't apply. They + * can cause unexpected or inconsistent results, where only some data is + * redacted. Don't include finding limits in + * [RedactImage][google.privacy.dlp.v2.DlpService.RedactImage] + * requests. Otherwise, Cloud DLP returns an error. + * When set within an + * [InspectJobConfig][google.privacy.dlp.v2.InspectJobConfig], the specified + * maximum values aren't hard limits. If an inspection job reaches these + * limits, the job ends gradually, not abruptly. Therefore, the actual number + * of findings that Cloud DLP returns can be multiple times higher than these + * maximum values. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig.FindingLimits limits = 3; + * @return \Google\Cloud\Dlp\V2\InspectConfig\FindingLimits|null + */ + public function getLimits() + { + return $this->limits; + } + + public function hasLimits() + { + return isset($this->limits); + } + + public function clearLimits() + { + unset($this->limits); + } + + /** + * Configuration to control the number of findings returned. + * This is not used for data profiling. + * When redacting sensitive data from images, finding limits don't apply. They + * can cause unexpected or inconsistent results, where only some data is + * redacted. Don't include finding limits in + * [RedactImage][google.privacy.dlp.v2.DlpService.RedactImage] + * requests. Otherwise, Cloud DLP returns an error. + * When set within an + * [InspectJobConfig][google.privacy.dlp.v2.InspectJobConfig], the specified + * maximum values aren't hard limits. If an inspection job reaches these + * limits, the job ends gradually, not abruptly. Therefore, the actual number + * of findings that Cloud DLP returns can be multiple times higher than these + * maximum values. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig.FindingLimits limits = 3; + * @param \Google\Cloud\Dlp\V2\InspectConfig\FindingLimits $var + * @return $this + */ + public function setLimits($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig\FindingLimits::class); + $this->limits = $var; + + return $this; + } + + /** + * When true, a contextual quote from the data that triggered a finding is + * included in the response; see + * [Finding.quote][google.privacy.dlp.v2.Finding.quote]. This is not used for + * data profiling. + * + * Generated from protobuf field bool include_quote = 4; + * @return bool + */ + public function getIncludeQuote() + { + return $this->include_quote; + } + + /** + * When true, a contextual quote from the data that triggered a finding is + * included in the response; see + * [Finding.quote][google.privacy.dlp.v2.Finding.quote]. This is not used for + * data profiling. + * + * Generated from protobuf field bool include_quote = 4; + * @param bool $var + * @return $this + */ + public function setIncludeQuote($var) + { + GPBUtil::checkBool($var); + $this->include_quote = $var; + + return $this; + } + + /** + * When true, excludes type information of the findings. + * This is not used for data profiling. + * + * Generated from protobuf field bool exclude_info_types = 5; + * @return bool + */ + public function getExcludeInfoTypes() + { + return $this->exclude_info_types; + } + + /** + * When true, excludes type information of the findings. + * This is not used for data profiling. + * + * Generated from protobuf field bool exclude_info_types = 5; + * @param bool $var + * @return $this + */ + public function setExcludeInfoTypes($var) + { + GPBUtil::checkBool($var); + $this->exclude_info_types = $var; + + return $this; + } + + /** + * CustomInfoTypes provided by the user. See + * https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes + * to learn more. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.CustomInfoType custom_info_types = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getCustomInfoTypes() + { + return $this->custom_info_types; + } + + /** + * CustomInfoTypes provided by the user. See + * https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes + * to learn more. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.CustomInfoType custom_info_types = 6; + * @param array<\Google\Cloud\Dlp\V2\CustomInfoType>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setCustomInfoTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\CustomInfoType::class); + $this->custom_info_types = $arr; + + return $this; + } + + /** + * Deprecated and unused. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ContentOption content_options = 8; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getContentOptions() + { + return $this->content_options; + } + + /** + * Deprecated and unused. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ContentOption content_options = 8; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setContentOptions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\ContentOption::class); + $this->content_options = $arr; + + return $this; + } + + /** + * Set of rules to apply to the findings for this InspectConfig. + * Exclusion rules, contained in the set are executed in the end, other + * rules are executed in the order they are specified for each info type. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectionRuleSet rule_set = 10; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRuleSet() + { + return $this->rule_set; + } + + /** + * Set of rules to apply to the findings for this InspectConfig. + * Exclusion rules, contained in the set are executed in the end, other + * rules are executed in the order they are specified for each info type. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectionRuleSet rule_set = 10; + * @param array<\Google\Cloud\Dlp\V2\InspectionRuleSet>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRuleSet($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InspectionRuleSet::class); + $this->rule_set = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits.php new file mode 100644 index 000000000000..6c89c0b17c00 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits.php @@ -0,0 +1,204 @@ +google.privacy.dlp.v2.InspectConfig.FindingLimits + */ +class FindingLimits extends \Google\Protobuf\Internal\Message +{ + /** + * Max number of findings that are returned for each item scanned. + * When set within an + * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], + * this field is ignored. + * This value isn't a hard limit. If the number of findings for an item + * reaches this limit, the inspection of that item ends gradually, not + * abruptly. Therefore, the actual number of findings that Cloud DLP returns + * for the item can be multiple times higher than this value. + * + * Generated from protobuf field int32 max_findings_per_item = 1; + */ + protected $max_findings_per_item = 0; + /** + * Max number of findings that are returned per request or job. + * If you set this field in an + * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], the + * resulting maximum value is the value that you set or 3,000, whichever is + * lower. + * This value isn't a hard limit. If an inspection reaches this limit, the + * inspection ends gradually, not abruptly. Therefore, the actual number of + * findings that Cloud DLP returns can be multiple times higher than this + * value. + * + * Generated from protobuf field int32 max_findings_per_request = 2; + */ + protected $max_findings_per_request = 0; + /** + * Configuration of findings limit given for specified infoTypes. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectConfig.FindingLimits.InfoTypeLimit max_findings_per_info_type = 3; + */ + private $max_findings_per_info_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $max_findings_per_item + * Max number of findings that are returned for each item scanned. + * When set within an + * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], + * this field is ignored. + * This value isn't a hard limit. If the number of findings for an item + * reaches this limit, the inspection of that item ends gradually, not + * abruptly. Therefore, the actual number of findings that Cloud DLP returns + * for the item can be multiple times higher than this value. + * @type int $max_findings_per_request + * Max number of findings that are returned per request or job. + * If you set this field in an + * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], the + * resulting maximum value is the value that you set or 3,000, whichever is + * lower. + * This value isn't a hard limit. If an inspection reaches this limit, the + * inspection ends gradually, not abruptly. Therefore, the actual number of + * findings that Cloud DLP returns can be multiple times higher than this + * value. + * @type array<\Google\Cloud\Dlp\V2\InspectConfig\FindingLimits\InfoTypeLimit>|\Google\Protobuf\Internal\RepeatedField $max_findings_per_info_type + * Configuration of findings limit given for specified infoTypes. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Max number of findings that are returned for each item scanned. + * When set within an + * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], + * this field is ignored. + * This value isn't a hard limit. If the number of findings for an item + * reaches this limit, the inspection of that item ends gradually, not + * abruptly. Therefore, the actual number of findings that Cloud DLP returns + * for the item can be multiple times higher than this value. + * + * Generated from protobuf field int32 max_findings_per_item = 1; + * @return int + */ + public function getMaxFindingsPerItem() + { + return $this->max_findings_per_item; + } + + /** + * Max number of findings that are returned for each item scanned. + * When set within an + * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], + * this field is ignored. + * This value isn't a hard limit. If the number of findings for an item + * reaches this limit, the inspection of that item ends gradually, not + * abruptly. Therefore, the actual number of findings that Cloud DLP returns + * for the item can be multiple times higher than this value. + * + * Generated from protobuf field int32 max_findings_per_item = 1; + * @param int $var + * @return $this + */ + public function setMaxFindingsPerItem($var) + { + GPBUtil::checkInt32($var); + $this->max_findings_per_item = $var; + + return $this; + } + + /** + * Max number of findings that are returned per request or job. + * If you set this field in an + * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], the + * resulting maximum value is the value that you set or 3,000, whichever is + * lower. + * This value isn't a hard limit. If an inspection reaches this limit, the + * inspection ends gradually, not abruptly. Therefore, the actual number of + * findings that Cloud DLP returns can be multiple times higher than this + * value. + * + * Generated from protobuf field int32 max_findings_per_request = 2; + * @return int + */ + public function getMaxFindingsPerRequest() + { + return $this->max_findings_per_request; + } + + /** + * Max number of findings that are returned per request or job. + * If you set this field in an + * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], the + * resulting maximum value is the value that you set or 3,000, whichever is + * lower. + * This value isn't a hard limit. If an inspection reaches this limit, the + * inspection ends gradually, not abruptly. Therefore, the actual number of + * findings that Cloud DLP returns can be multiple times higher than this + * value. + * + * Generated from protobuf field int32 max_findings_per_request = 2; + * @param int $var + * @return $this + */ + public function setMaxFindingsPerRequest($var) + { + GPBUtil::checkInt32($var); + $this->max_findings_per_request = $var; + + return $this; + } + + /** + * Configuration of findings limit given for specified infoTypes. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectConfig.FindingLimits.InfoTypeLimit max_findings_per_info_type = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMaxFindingsPerInfoType() + { + return $this->max_findings_per_info_type; + } + + /** + * Configuration of findings limit given for specified infoTypes. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectConfig.FindingLimits.InfoTypeLimit max_findings_per_info_type = 3; + * @param array<\Google\Cloud\Dlp\V2\InspectConfig\FindingLimits\InfoTypeLimit>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMaxFindingsPerInfoType($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InspectConfig\FindingLimits\InfoTypeLimit::class); + $this->max_findings_per_info_type = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(FindingLimits::class, \Google\Cloud\Dlp\V2\InspectConfig_FindingLimits::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits/InfoTypeLimit.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits/InfoTypeLimit.php new file mode 100644 index 000000000000..cfab8ab3f528 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits/InfoTypeLimit.php @@ -0,0 +1,127 @@ +google.privacy.dlp.v2.InspectConfig.FindingLimits.InfoTypeLimit + */ +class InfoTypeLimit extends \Google\Protobuf\Internal\Message +{ + /** + * Type of information the findings limit applies to. Only one limit per + * info_type should be provided. If InfoTypeLimit does not have an + * info_type, the DLP API applies the limit against all info_types that + * are found but not specified in another InfoTypeLimit. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + */ + protected $info_type = null; + /** + * Max findings limit for the given infoType. + * + * Generated from protobuf field int32 max_findings = 2; + */ + protected $max_findings = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InfoType $info_type + * Type of information the findings limit applies to. Only one limit per + * info_type should be provided. If InfoTypeLimit does not have an + * info_type, the DLP API applies the limit against all info_types that + * are found but not specified in another InfoTypeLimit. + * @type int $max_findings + * Max findings limit for the given infoType. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Type of information the findings limit applies to. Only one limit per + * info_type should be provided. If InfoTypeLimit does not have an + * info_type, the DLP API applies the limit against all info_types that + * are found but not specified in another InfoTypeLimit. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getInfoType() + { + return $this->info_type; + } + + public function hasInfoType() + { + return isset($this->info_type); + } + + public function clearInfoType() + { + unset($this->info_type); + } + + /** + * Type of information the findings limit applies to. Only one limit per + * info_type should be provided. If InfoTypeLimit does not have an + * info_type, the DLP API applies the limit against all info_types that + * are found but not specified in another InfoTypeLimit. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_type = $var; + + return $this; + } + + /** + * Max findings limit for the given infoType. + * + * Generated from protobuf field int32 max_findings = 2; + * @return int + */ + public function getMaxFindings() + { + return $this->max_findings; + } + + /** + * Max findings limit for the given infoType. + * + * Generated from protobuf field int32 max_findings = 2; + * @param int $var + * @return $this + */ + public function setMaxFindings($var) + { + GPBUtil::checkInt32($var); + $this->max_findings = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(InfoTypeLimit::class, \Google\Cloud\Dlp\V2\InspectConfig_FindingLimits_InfoTypeLimit::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/InfoTypeLikelihood.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/InfoTypeLikelihood.php new file mode 100644 index 000000000000..2de7fc9c089c --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/InfoTypeLikelihood.php @@ -0,0 +1,130 @@ +google.privacy.dlp.v2.InspectConfig.InfoTypeLikelihood + */ +class InfoTypeLikelihood extends \Google\Protobuf\Internal\Message +{ + /** + * Type of information the likelihood threshold applies to. Only one + * likelihood per info_type should be provided. If InfoTypeLikelihood does + * not have an info_type, the configuration fails. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + */ + protected $info_type = null; + /** + * Only returns findings equal to or above this threshold. This field is + * required or else the configuration fails. + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood min_likelihood = 2; + */ + protected $min_likelihood = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InfoType $info_type + * Type of information the likelihood threshold applies to. Only one + * likelihood per info_type should be provided. If InfoTypeLikelihood does + * not have an info_type, the configuration fails. + * @type int $min_likelihood + * Only returns findings equal to or above this threshold. This field is + * required or else the configuration fails. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Type of information the likelihood threshold applies to. Only one + * likelihood per info_type should be provided. If InfoTypeLikelihood does + * not have an info_type, the configuration fails. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getInfoType() + { + return $this->info_type; + } + + public function hasInfoType() + { + return isset($this->info_type); + } + + public function clearInfoType() + { + unset($this->info_type); + } + + /** + * Type of information the likelihood threshold applies to. Only one + * likelihood per info_type should be provided. If InfoTypeLikelihood does + * not have an info_type, the configuration fails. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_type = $var; + + return $this; + } + + /** + * Only returns findings equal to or above this threshold. This field is + * required or else the configuration fails. + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood min_likelihood = 2; + * @return int + */ + public function getMinLikelihood() + { + return $this->min_likelihood; + } + + /** + * Only returns findings equal to or above this threshold. This field is + * required or else the configuration fails. + * + * Generated from protobuf field .google.privacy.dlp.v2.Likelihood min_likelihood = 2; + * @param int $var + * @return $this + */ + public function setMinLikelihood($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\Likelihood::class); + $this->min_likelihood = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(InfoTypeLikelihood::class, \Google\Cloud\Dlp\V2\InspectConfig_InfoTypeLikelihood::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentRequest.php new file mode 100644 index 000000000000..16159653005f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentRequest.php @@ -0,0 +1,287 @@ +google.privacy.dlp.v2.InspectContentRequest + */ +class InspectContentRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Configuration for the inspector. What specified here will override + * the template referenced by the inspect_template_name argument. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; + */ + protected $inspect_config = null; + /** + * The item to inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 3; + */ + protected $item = null; + /** + * Template to use. Any configuration directly specified in + * inspect_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * + * Generated from protobuf field string inspect_template_name = 4; + */ + protected $inspect_template_name = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + */ + protected $location_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config + * Configuration for the inspector. What specified here will override + * the template referenced by the inspect_template_name argument. + * @type \Google\Cloud\Dlp\V2\ContentItem $item + * The item to inspect. + * @type string $inspect_template_name + * Template to use. Any configuration directly specified in + * inspect_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Configuration for the inspector. What specified here will override + * the template referenced by the inspect_template_name argument. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; + * @return \Google\Cloud\Dlp\V2\InspectConfig|null + */ + public function getInspectConfig() + { + return $this->inspect_config; + } + + public function hasInspectConfig() + { + return isset($this->inspect_config); + } + + public function clearInspectConfig() + { + unset($this->inspect_config); + } + + /** + * Configuration for the inspector. What specified here will override + * the template referenced by the inspect_template_name argument. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; + * @param \Google\Cloud\Dlp\V2\InspectConfig $var + * @return $this + */ + public function setInspectConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); + $this->inspect_config = $var; + + return $this; + } + + /** + * The item to inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 3; + * @return \Google\Cloud\Dlp\V2\ContentItem|null + */ + public function getItem() + { + return $this->item; + } + + public function hasItem() + { + return isset($this->item); + } + + public function clearItem() + { + unset($this->item); + } + + /** + * The item to inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 3; + * @param \Google\Cloud\Dlp\V2\ContentItem $var + * @return $this + */ + public function setItem($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ContentItem::class); + $this->item = $var; + + return $this; + } + + /** + * Template to use. Any configuration directly specified in + * inspect_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * + * Generated from protobuf field string inspect_template_name = 4; + * @return string + */ + public function getInspectTemplateName() + { + return $this->inspect_template_name; + } + + /** + * Template to use. Any configuration directly specified in + * inspect_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * + * Generated from protobuf field string inspect_template_name = 4; + * @param string $var + * @return $this + */ + public function setInspectTemplateName($var) + { + GPBUtil::checkString($var, True); + $this->inspect_template_name = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentResponse.php new file mode 100644 index 000000000000..1bb36f9c611f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentResponse.php @@ -0,0 +1,77 @@ +google.privacy.dlp.v2.InspectContentResponse + */ +class InspectContentResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The findings. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectResult result = 1; + */ + protected $result = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InspectResult $result + * The findings. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The findings. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectResult result = 1; + * @return \Google\Cloud\Dlp\V2\InspectResult|null + */ + public function getResult() + { + return $this->result; + } + + public function hasResult() + { + return isset($this->result); + } + + public function clearResult() + { + unset($this->result); + } + + /** + * The findings. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectResult result = 1; + * @param \Google\Cloud\Dlp\V2\InspectResult $var + * @return $this + */ + public function setResult($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectResult::class); + $this->result = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails.php new file mode 100644 index 000000000000..4c234301fb6e --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails.php @@ -0,0 +1,121 @@ +google.privacy.dlp.v2.InspectDataSourceDetails + */ +class InspectDataSourceDetails extends \Google\Protobuf\Internal\Message +{ + /** + * The configuration used for this job. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails.RequestedOptions requested_options = 2; + */ + protected $requested_options = null; + /** + * A summary of the outcome of this inspection job. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails.Result result = 3; + */ + protected $result = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InspectDataSourceDetails\RequestedOptions $requested_options + * The configuration used for this job. + * @type \Google\Cloud\Dlp\V2\InspectDataSourceDetails\Result $result + * A summary of the outcome of this inspection job. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The configuration used for this job. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails.RequestedOptions requested_options = 2; + * @return \Google\Cloud\Dlp\V2\InspectDataSourceDetails\RequestedOptions|null + */ + public function getRequestedOptions() + { + return $this->requested_options; + } + + public function hasRequestedOptions() + { + return isset($this->requested_options); + } + + public function clearRequestedOptions() + { + unset($this->requested_options); + } + + /** + * The configuration used for this job. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails.RequestedOptions requested_options = 2; + * @param \Google\Cloud\Dlp\V2\InspectDataSourceDetails\RequestedOptions $var + * @return $this + */ + public function setRequestedOptions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectDataSourceDetails\RequestedOptions::class); + $this->requested_options = $var; + + return $this; + } + + /** + * A summary of the outcome of this inspection job. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails.Result result = 3; + * @return \Google\Cloud\Dlp\V2\InspectDataSourceDetails\Result|null + */ + public function getResult() + { + return $this->result; + } + + public function hasResult() + { + return isset($this->result); + } + + public function clearResult() + { + unset($this->result); + } + + /** + * A summary of the outcome of this inspection job. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails.Result result = 3; + * @param \Google\Cloud\Dlp\V2\InspectDataSourceDetails\Result $var + * @return $this + */ + public function setResult($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectDataSourceDetails\Result::class); + $this->result = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/RequestedOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/RequestedOptions.php new file mode 100644 index 000000000000..c0e230424154 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/RequestedOptions.php @@ -0,0 +1,128 @@ +google.privacy.dlp.v2.InspectDataSourceDetails.RequestedOptions + */ +class RequestedOptions extends \Google\Protobuf\Internal\Message +{ + /** + * If run with an InspectTemplate, a snapshot of its state at the time of + * this run. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate snapshot_inspect_template = 1; + */ + protected $snapshot_inspect_template = null; + /** + * Inspect config. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig job_config = 3; + */ + protected $job_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InspectTemplate $snapshot_inspect_template + * If run with an InspectTemplate, a snapshot of its state at the time of + * this run. + * @type \Google\Cloud\Dlp\V2\InspectJobConfig $job_config + * Inspect config. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * If run with an InspectTemplate, a snapshot of its state at the time of + * this run. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate snapshot_inspect_template = 1; + * @return \Google\Cloud\Dlp\V2\InspectTemplate|null + */ + public function getSnapshotInspectTemplate() + { + return $this->snapshot_inspect_template; + } + + public function hasSnapshotInspectTemplate() + { + return isset($this->snapshot_inspect_template); + } + + public function clearSnapshotInspectTemplate() + { + unset($this->snapshot_inspect_template); + } + + /** + * If run with an InspectTemplate, a snapshot of its state at the time of + * this run. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate snapshot_inspect_template = 1; + * @param \Google\Cloud\Dlp\V2\InspectTemplate $var + * @return $this + */ + public function setSnapshotInspectTemplate($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectTemplate::class); + $this->snapshot_inspect_template = $var; + + return $this; + } + + /** + * Inspect config. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig job_config = 3; + * @return \Google\Cloud\Dlp\V2\InspectJobConfig|null + */ + public function getJobConfig() + { + return $this->job_config; + } + + public function hasJobConfig() + { + return isset($this->job_config); + } + + public function clearJobConfig() + { + unset($this->job_config); + } + + /** + * Inspect config. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig job_config = 3; + * @param \Google\Cloud\Dlp\V2\InspectJobConfig $var + * @return $this + */ + public function setJobConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectJobConfig::class); + $this->job_config = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(RequestedOptions::class, \Google\Cloud\Dlp\V2\InspectDataSourceDetails_RequestedOptions::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/Result.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/Result.php new file mode 100644 index 000000000000..45e94c9da3c8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/Result.php @@ -0,0 +1,224 @@ +google.privacy.dlp.v2.InspectDataSourceDetails.Result + */ +class Result extends \Google\Protobuf\Internal\Message +{ + /** + * Total size in bytes that were processed. + * + * Generated from protobuf field int64 processed_bytes = 1; + */ + protected $processed_bytes = 0; + /** + * Estimate of the number of bytes to process. + * + * Generated from protobuf field int64 total_estimated_bytes = 2; + */ + protected $total_estimated_bytes = 0; + /** + * Statistics of how many instances of each info type were found during + * inspect job. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeStats info_type_stats = 3; + */ + private $info_type_stats; + /** + * Number of rows scanned after sampling and time filtering (applicable for + * row based stores such as BigQuery). + * + * Generated from protobuf field int64 num_rows_processed = 5; + */ + protected $num_rows_processed = 0; + /** + * Statistics related to the processing of hybrid inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridInspectStatistics hybrid_stats = 7; + */ + protected $hybrid_stats = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $processed_bytes + * Total size in bytes that were processed. + * @type int|string $total_estimated_bytes + * Estimate of the number of bytes to process. + * @type array<\Google\Cloud\Dlp\V2\InfoTypeStats>|\Google\Protobuf\Internal\RepeatedField $info_type_stats + * Statistics of how many instances of each info type were found during + * inspect job. + * @type int|string $num_rows_processed + * Number of rows scanned after sampling and time filtering (applicable for + * row based stores such as BigQuery). + * @type \Google\Cloud\Dlp\V2\HybridInspectStatistics $hybrid_stats + * Statistics related to the processing of hybrid inspect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Total size in bytes that were processed. + * + * Generated from protobuf field int64 processed_bytes = 1; + * @return int|string + */ + public function getProcessedBytes() + { + return $this->processed_bytes; + } + + /** + * Total size in bytes that were processed. + * + * Generated from protobuf field int64 processed_bytes = 1; + * @param int|string $var + * @return $this + */ + public function setProcessedBytes($var) + { + GPBUtil::checkInt64($var); + $this->processed_bytes = $var; + + return $this; + } + + /** + * Estimate of the number of bytes to process. + * + * Generated from protobuf field int64 total_estimated_bytes = 2; + * @return int|string + */ + public function getTotalEstimatedBytes() + { + return $this->total_estimated_bytes; + } + + /** + * Estimate of the number of bytes to process. + * + * Generated from protobuf field int64 total_estimated_bytes = 2; + * @param int|string $var + * @return $this + */ + public function setTotalEstimatedBytes($var) + { + GPBUtil::checkInt64($var); + $this->total_estimated_bytes = $var; + + return $this; + } + + /** + * Statistics of how many instances of each info type were found during + * inspect job. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeStats info_type_stats = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getInfoTypeStats() + { + return $this->info_type_stats; + } + + /** + * Statistics of how many instances of each info type were found during + * inspect job. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeStats info_type_stats = 3; + * @param array<\Google\Cloud\Dlp\V2\InfoTypeStats>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setInfoTypeStats($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoTypeStats::class); + $this->info_type_stats = $arr; + + return $this; + } + + /** + * Number of rows scanned after sampling and time filtering (applicable for + * row based stores such as BigQuery). + * + * Generated from protobuf field int64 num_rows_processed = 5; + * @return int|string + */ + public function getNumRowsProcessed() + { + return $this->num_rows_processed; + } + + /** + * Number of rows scanned after sampling and time filtering (applicable for + * row based stores such as BigQuery). + * + * Generated from protobuf field int64 num_rows_processed = 5; + * @param int|string $var + * @return $this + */ + public function setNumRowsProcessed($var) + { + GPBUtil::checkInt64($var); + $this->num_rows_processed = $var; + + return $this; + } + + /** + * Statistics related to the processing of hybrid inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridInspectStatistics hybrid_stats = 7; + * @return \Google\Cloud\Dlp\V2\HybridInspectStatistics|null + */ + public function getHybridStats() + { + return $this->hybrid_stats; + } + + public function hasHybridStats() + { + return isset($this->hybrid_stats); + } + + public function clearHybridStats() + { + unset($this->hybrid_stats); + } + + /** + * Statistics related to the processing of hybrid inspect. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridInspectStatistics hybrid_stats = 7; + * @param \Google\Cloud\Dlp\V2\HybridInspectStatistics $var + * @return $this + */ + public function setHybridStats($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\HybridInspectStatistics::class); + $this->hybrid_stats = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Result::class, \Google\Cloud\Dlp\V2\InspectDataSourceDetails_Result::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectJobConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectJobConfig.php new file mode 100644 index 000000000000..3163d015f708 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectJobConfig.php @@ -0,0 +1,197 @@ +google.privacy.dlp.v2.InspectJobConfig + */ +class InspectJobConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The data to scan. + * + * Generated from protobuf field .google.privacy.dlp.v2.StorageConfig storage_config = 1; + */ + protected $storage_config = null; + /** + * How and what to scan for. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; + */ + protected $inspect_config = null; + /** + * If provided, will be used as the default for all values in InspectConfig. + * `inspect_config` will be merged into the values persisted as part of the + * template. + * + * Generated from protobuf field string inspect_template_name = 3; + */ + protected $inspect_template_name = ''; + /** + * Actions to execute at the completion of the job. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Action actions = 4; + */ + private $actions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\StorageConfig $storage_config + * The data to scan. + * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config + * How and what to scan for. + * @type string $inspect_template_name + * If provided, will be used as the default for all values in InspectConfig. + * `inspect_config` will be merged into the values persisted as part of the + * template. + * @type array<\Google\Cloud\Dlp\V2\Action>|\Google\Protobuf\Internal\RepeatedField $actions + * Actions to execute at the completion of the job. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The data to scan. + * + * Generated from protobuf field .google.privacy.dlp.v2.StorageConfig storage_config = 1; + * @return \Google\Cloud\Dlp\V2\StorageConfig|null + */ + public function getStorageConfig() + { + return $this->storage_config; + } + + public function hasStorageConfig() + { + return isset($this->storage_config); + } + + public function clearStorageConfig() + { + unset($this->storage_config); + } + + /** + * The data to scan. + * + * Generated from protobuf field .google.privacy.dlp.v2.StorageConfig storage_config = 1; + * @param \Google\Cloud\Dlp\V2\StorageConfig $var + * @return $this + */ + public function setStorageConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StorageConfig::class); + $this->storage_config = $var; + + return $this; + } + + /** + * How and what to scan for. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; + * @return \Google\Cloud\Dlp\V2\InspectConfig|null + */ + public function getInspectConfig() + { + return $this->inspect_config; + } + + public function hasInspectConfig() + { + return isset($this->inspect_config); + } + + public function clearInspectConfig() + { + unset($this->inspect_config); + } + + /** + * How and what to scan for. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; + * @param \Google\Cloud\Dlp\V2\InspectConfig $var + * @return $this + */ + public function setInspectConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); + $this->inspect_config = $var; + + return $this; + } + + /** + * If provided, will be used as the default for all values in InspectConfig. + * `inspect_config` will be merged into the values persisted as part of the + * template. + * + * Generated from protobuf field string inspect_template_name = 3; + * @return string + */ + public function getInspectTemplateName() + { + return $this->inspect_template_name; + } + + /** + * If provided, will be used as the default for all values in InspectConfig. + * `inspect_config` will be merged into the values persisted as part of the + * template. + * + * Generated from protobuf field string inspect_template_name = 3; + * @param string $var + * @return $this + */ + public function setInspectTemplateName($var) + { + GPBUtil::checkString($var, True); + $this->inspect_template_name = $var; + + return $this; + } + + /** + * Actions to execute at the completion of the job. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Action actions = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getActions() + { + return $this->actions; + } + + /** + * Actions to execute at the completion of the job. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Action actions = 4; + * @param array<\Google\Cloud\Dlp\V2\Action>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setActions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Action::class); + $this->actions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectResult.php new file mode 100644 index 000000000000..b929d0e4e696 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectResult.php @@ -0,0 +1,121 @@ +google.privacy.dlp.v2.InspectResult + */ +class InspectResult extends \Google\Protobuf\Internal\Message +{ + /** + * List of findings for an item. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Finding findings = 1; + */ + private $findings; + /** + * If true, then this item might have more findings than were returned, + * and the findings returned are an arbitrary subset of all findings. + * The findings list might be truncated because the input items were too + * large, or because the server reached the maximum amount of resources + * allowed for a single API call. For best results, divide the input into + * smaller batches. + * + * Generated from protobuf field bool findings_truncated = 2; + */ + protected $findings_truncated = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\Finding>|\Google\Protobuf\Internal\RepeatedField $findings + * List of findings for an item. + * @type bool $findings_truncated + * If true, then this item might have more findings than were returned, + * and the findings returned are an arbitrary subset of all findings. + * The findings list might be truncated because the input items were too + * large, or because the server reached the maximum amount of resources + * allowed for a single API call. For best results, divide the input into + * smaller batches. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of findings for an item. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Finding findings = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFindings() + { + return $this->findings; + } + + /** + * List of findings for an item. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Finding findings = 1; + * @param array<\Google\Cloud\Dlp\V2\Finding>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFindings($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Finding::class); + $this->findings = $arr; + + return $this; + } + + /** + * If true, then this item might have more findings than were returned, + * and the findings returned are an arbitrary subset of all findings. + * The findings list might be truncated because the input items were too + * large, or because the server reached the maximum amount of resources + * allowed for a single API call. For best results, divide the input into + * smaller batches. + * + * Generated from protobuf field bool findings_truncated = 2; + * @return bool + */ + public function getFindingsTruncated() + { + return $this->findings_truncated; + } + + /** + * If true, then this item might have more findings than were returned, + * and the findings returned are an arbitrary subset of all findings. + * The findings list might be truncated because the input items were too + * large, or because the server reached the maximum amount of resources + * allowed for a single API call. For best results, divide the input into + * smaller batches. + * + * Generated from protobuf field bool findings_truncated = 2; + * @param bool $var + * @return $this + */ + public function setFindingsTruncated($var) + { + GPBUtil::checkBool($var); + $this->findings_truncated = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectTemplate.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectTemplate.php new file mode 100644 index 000000000000..9dec2b293b5f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectTemplate.php @@ -0,0 +1,283 @@ +google.privacy.dlp.v2.InspectTemplate + */ +class InspectTemplate extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The template name. + * The template will have one of the following formats: + * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR + * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`; + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Display name (max 256 chars). + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + /** + * Short description (max 256 chars). + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * Output only. The creation timestamp of an inspectTemplate. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The last update timestamp of an inspectTemplate. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * The core content of the template. Configuration of the scanning process. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 6; + */ + protected $inspect_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The template name. + * The template will have one of the following formats: + * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR + * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`; + * @type string $display_name + * Display name (max 256 chars). + * @type string $description + * Short description (max 256 chars). + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The creation timestamp of an inspectTemplate. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The last update timestamp of an inspectTemplate. + * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config + * The core content of the template. Configuration of the scanning process. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The template name. + * The template will have one of the following formats: + * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR + * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`; + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. The template name. + * The template will have one of the following formats: + * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR + * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`; + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Display name (max 256 chars). + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Display name (max 256 chars). + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * Short description (max 256 chars). + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Short description (max 256 chars). + * + * 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; + } + + /** + * Output only. The creation timestamp of an inspectTemplate. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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 creation timestamp of an inspectTemplate. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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 last update timestamp of an inspectTemplate. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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 last update timestamp of an inspectTemplate. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * The core content of the template. Configuration of the scanning process. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 6; + * @return \Google\Cloud\Dlp\V2\InspectConfig|null + */ + public function getInspectConfig() + { + return $this->inspect_config; + } + + public function hasInspectConfig() + { + return isset($this->inspect_config); + } + + public function clearInspectConfig() + { + unset($this->inspect_config); + } + + /** + * The core content of the template. Configuration of the scanning process. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 6; + * @param \Google\Cloud\Dlp\V2\InspectConfig $var + * @return $this + */ + public function setInspectConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); + $this->inspect_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRule.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRule.php new file mode 100644 index 000000000000..a1854d0497c6 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRule.php @@ -0,0 +1,109 @@ +google.privacy.dlp.v2.InspectionRule + */ +class InspectionRule extends \Google\Protobuf\Internal\Message +{ + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule $hotword_rule + * Hotword-based detection rule. + * @type \Google\Cloud\Dlp\V2\ExclusionRule $exclusion_rule + * Exclusion rule. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Hotword-based detection rule. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.HotwordRule hotword_rule = 1; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule|null + */ + public function getHotwordRule() + { + return $this->readOneof(1); + } + + public function hasHotwordRule() + { + return $this->hasOneof(1); + } + + /** + * Hotword-based detection rule. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.HotwordRule hotword_rule = 1; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule $var + * @return $this + */ + public function setHotwordRule($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Exclusion rule. + * + * Generated from protobuf field .google.privacy.dlp.v2.ExclusionRule exclusion_rule = 2; + * @return \Google\Cloud\Dlp\V2\ExclusionRule|null + */ + public function getExclusionRule() + { + return $this->readOneof(2); + } + + public function hasExclusionRule() + { + return $this->hasOneof(2); + } + + /** + * Exclusion rule. + * + * Generated from protobuf field .google.privacy.dlp.v2.ExclusionRule exclusion_rule = 2; + * @param \Google\Cloud\Dlp\V2\ExclusionRule $var + * @return $this + */ + public function setExclusionRule($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ExclusionRule::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRuleSet.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRuleSet.php new file mode 100644 index 000000000000..5ee0f98dd54b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRuleSet.php @@ -0,0 +1,102 @@ +google.privacy.dlp.v2.InspectionRuleSet + */ +class InspectionRuleSet extends \Google\Protobuf\Internal\Message +{ + /** + * List of infoTypes this rule set is applied to. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; + */ + private $info_types; + /** + * Set of rules to be applied to infoTypes. The rules are applied in order. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectionRule rules = 2; + */ + private $rules; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $info_types + * List of infoTypes this rule set is applied to. + * @type array<\Google\Cloud\Dlp\V2\InspectionRule>|\Google\Protobuf\Internal\RepeatedField $rules + * Set of rules to be applied to infoTypes. The rules are applied in order. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of infoTypes this rule set is applied to. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getInfoTypes() + { + return $this->info_types; + } + + /** + * List of infoTypes this rule set is applied to. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; + * @param array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setInfoTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_types = $arr; + + return $this; + } + + /** + * Set of rules to be applied to infoTypes. The rules are applied in order. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectionRule rules = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRules() + { + return $this->rules; + } + + /** + * Set of rules to be applied to infoTypes. The rules are applied in order. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectionRule rules = 2; + * @param array<\Google\Cloud\Dlp\V2\InspectionRule>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRules($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InspectionRule::class); + $this->rules = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger.php new file mode 100644 index 000000000000..d09ba0071108 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger.php @@ -0,0 +1,442 @@ +google.privacy.dlp.v2.JobTrigger + */ +class JobTrigger extends \Google\Protobuf\Internal\Message +{ + /** + * Unique resource name for the triggeredJob, assigned by the service when the + * triggeredJob is created, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Display name (max 100 chars) + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + /** + * User provided description (max 256 chars) + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * A list of triggers which will be OR'ed together. Only one in the list + * needs to trigger for a job to be started. The list may contain only + * a single Schedule trigger and must have at least one object. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.JobTrigger.Trigger triggers = 5; + */ + private $triggers; + /** + * Output only. A stream of errors encountered when the trigger was activated. + * Repeated errors may result in the JobTrigger automatically being paused. + * Will return the last 100 errors. Whenever the JobTrigger is modified + * this list will be cleared. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $errors; + /** + * Output only. The creation timestamp of a triggeredJob. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The last update timestamp of a triggeredJob. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. The timestamp of the last time this trigger executed. + * + * Generated from protobuf field .google.protobuf.Timestamp last_run_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $last_run_time = null; + /** + * Required. A status for this trigger. + * + * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger.Status status = 10 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $status = 0; + protected $job; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Unique resource name for the triggeredJob, assigned by the service when the + * triggeredJob is created, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * @type string $display_name + * Display name (max 100 chars) + * @type string $description + * User provided description (max 256 chars) + * @type \Google\Cloud\Dlp\V2\InspectJobConfig $inspect_job + * For inspect jobs, a snapshot of the configuration. + * @type array<\Google\Cloud\Dlp\V2\JobTrigger\Trigger>|\Google\Protobuf\Internal\RepeatedField $triggers + * A list of triggers which will be OR'ed together. Only one in the list + * needs to trigger for a job to be started. The list may contain only + * a single Schedule trigger and must have at least one object. + * @type array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $errors + * Output only. A stream of errors encountered when the trigger was activated. + * Repeated errors may result in the JobTrigger automatically being paused. + * Will return the last 100 errors. Whenever the JobTrigger is modified + * this list will be cleared. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The creation timestamp of a triggeredJob. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The last update timestamp of a triggeredJob. + * @type \Google\Protobuf\Timestamp $last_run_time + * Output only. The timestamp of the last time this trigger executed. + * @type int $status + * Required. A status for this trigger. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Unique resource name for the triggeredJob, assigned by the service when the + * triggeredJob is created, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Unique resource name for the triggeredJob, assigned by the service when the + * triggeredJob is created, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * 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; + } + + /** + * Display name (max 100 chars) + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Display name (max 100 chars) + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * User provided description (max 256 chars) + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * User provided description (max 256 chars) + * + * 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; + } + + /** + * For inspect jobs, a snapshot of the configuration. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig inspect_job = 4; + * @return \Google\Cloud\Dlp\V2\InspectJobConfig|null + */ + public function getInspectJob() + { + return $this->readOneof(4); + } + + public function hasInspectJob() + { + return $this->hasOneof(4); + } + + /** + * For inspect jobs, a snapshot of the configuration. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig inspect_job = 4; + * @param \Google\Cloud\Dlp\V2\InspectJobConfig $var + * @return $this + */ + public function setInspectJob($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectJobConfig::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * A list of triggers which will be OR'ed together. Only one in the list + * needs to trigger for a job to be started. The list may contain only + * a single Schedule trigger and must have at least one object. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.JobTrigger.Trigger triggers = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTriggers() + { + return $this->triggers; + } + + /** + * A list of triggers which will be OR'ed together. Only one in the list + * needs to trigger for a job to be started. The list may contain only + * a single Schedule trigger and must have at least one object. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.JobTrigger.Trigger triggers = 5; + * @param array<\Google\Cloud\Dlp\V2\JobTrigger\Trigger>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTriggers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\JobTrigger\Trigger::class); + $this->triggers = $arr; + + return $this; + } + + /** + * Output only. A stream of errors encountered when the trigger was activated. + * Repeated errors may result in the JobTrigger automatically being paused. + * Will return the last 100 errors. Whenever the JobTrigger is modified + * this list will be cleared. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getErrors() + { + return $this->errors; + } + + /** + * Output only. A stream of errors encountered when the trigger was activated. + * Repeated errors may result in the JobTrigger automatically being paused. + * Will return the last 100 errors. Whenever the JobTrigger is modified + * this list will be cleared. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setErrors($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Error::class); + $this->errors = $arr; + + return $this; + } + + /** + * Output only. The creation timestamp of a triggeredJob. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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 creation timestamp of a triggeredJob. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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 last update timestamp of a triggeredJob. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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 last update timestamp of a triggeredJob. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Output only. The timestamp of the last time this trigger executed. + * + * Generated from protobuf field .google.protobuf.Timestamp last_run_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getLastRunTime() + { + return $this->last_run_time; + } + + public function hasLastRunTime() + { + return isset($this->last_run_time); + } + + public function clearLastRunTime() + { + unset($this->last_run_time); + } + + /** + * Output only. The timestamp of the last time this trigger executed. + * + * Generated from protobuf field .google.protobuf.Timestamp last_run_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setLastRunTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->last_run_time = $var; + + return $this; + } + + /** + * Required. A status for this trigger. + * + * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger.Status status = 10 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getStatus() + { + return $this->status; + } + + /** + * Required. A status for this trigger. + * + * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger.Status status = 10 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setStatus($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\JobTrigger\Status::class); + $this->status = $var; + + return $this; + } + + /** + * @return string + */ + public function getJob() + { + return $this->whichOneof("job"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Status.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Status.php new file mode 100644 index 000000000000..aa040ce1b3a4 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Status.php @@ -0,0 +1,74 @@ +google.privacy.dlp.v2.JobTrigger.Status + */ +class Status +{ + /** + * Unused. + * + * Generated from protobuf enum STATUS_UNSPECIFIED = 0; + */ + const STATUS_UNSPECIFIED = 0; + /** + * Trigger is healthy. + * + * Generated from protobuf enum HEALTHY = 1; + */ + const HEALTHY = 1; + /** + * Trigger is temporarily paused. + * + * Generated from protobuf enum PAUSED = 2; + */ + const PAUSED = 2; + /** + * Trigger is cancelled and can not be resumed. + * + * Generated from protobuf enum CANCELLED = 3; + */ + const CANCELLED = 3; + + private static $valueToName = [ + self::STATUS_UNSPECIFIED => 'STATUS_UNSPECIFIED', + self::HEALTHY => 'HEALTHY', + self::PAUSED => 'PAUSED', + self::CANCELLED => 'CANCELLED', + ]; + + 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(Status::class, \Google\Cloud\Dlp\V2\JobTrigger_Status::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Trigger.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Trigger.php new file mode 100644 index 000000000000..fc12ffebbe29 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Trigger.php @@ -0,0 +1,111 @@ +google.privacy.dlp.v2.JobTrigger.Trigger + */ +class Trigger extends \Google\Protobuf\Internal\Message +{ + protected $trigger; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\Schedule $schedule + * Create a job on a repeating basis based on the elapse of time. + * @type \Google\Cloud\Dlp\V2\Manual $manual + * For use with hybrid jobs. Jobs must be manually created and finished. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Create a job on a repeating basis based on the elapse of time. + * + * Generated from protobuf field .google.privacy.dlp.v2.Schedule schedule = 1; + * @return \Google\Cloud\Dlp\V2\Schedule|null + */ + public function getSchedule() + { + return $this->readOneof(1); + } + + public function hasSchedule() + { + return $this->hasOneof(1); + } + + /** + * Create a job on a repeating basis based on the elapse of time. + * + * Generated from protobuf field .google.privacy.dlp.v2.Schedule schedule = 1; + * @param \Google\Cloud\Dlp\V2\Schedule $var + * @return $this + */ + public function setSchedule($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Schedule::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * For use with hybrid jobs. Jobs must be manually created and finished. + * + * Generated from protobuf field .google.privacy.dlp.v2.Manual manual = 2; + * @return \Google\Cloud\Dlp\V2\Manual|null + */ + public function getManual() + { + return $this->readOneof(2); + } + + public function hasManual() + { + return $this->hasOneof(2); + } + + /** + * For use with hybrid jobs. Jobs must be manually created and finished. + * + * Generated from protobuf field .google.privacy.dlp.v2.Manual manual = 2; + * @param \Google\Cloud\Dlp\V2\Manual $var + * @return $this + */ + public function setManual($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Manual::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getTrigger() + { + return $this->whichOneof("trigger"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Trigger::class, \Google\Cloud\Dlp\V2\JobTrigger_Trigger::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key.php new file mode 100644 index 000000000000..e21d17e612db --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key.php @@ -0,0 +1,150 @@ +google.privacy.dlp.v2.Key + */ +class Key extends \Google\Protobuf\Internal\Message +{ + /** + * Entities are partitioned into subsets, currently identified by a project + * ID and namespace ID. + * Queries are scoped to a single partition. + * + * Generated from protobuf field .google.privacy.dlp.v2.PartitionId partition_id = 1; + */ + protected $partition_id = null; + /** + * The entity path. + * An entity path consists of one or more elements composed of a kind and a + * string or numerical identifier, which identify entities. The first + * element identifies a _root entity_, the second element identifies + * a _child_ of the root entity, the third element identifies a child of the + * second entity, and so forth. The entities identified by all prefixes of + * the path are called the element's _ancestors_. + * A path can never be empty, and a path can have at most 100 elements. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Key.PathElement path = 2; + */ + private $path; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\PartitionId $partition_id + * Entities are partitioned into subsets, currently identified by a project + * ID and namespace ID. + * Queries are scoped to a single partition. + * @type array<\Google\Cloud\Dlp\V2\Key\PathElement>|\Google\Protobuf\Internal\RepeatedField $path + * The entity path. + * An entity path consists of one or more elements composed of a kind and a + * string or numerical identifier, which identify entities. The first + * element identifies a _root entity_, the second element identifies + * a _child_ of the root entity, the third element identifies a child of the + * second entity, and so forth. The entities identified by all prefixes of + * the path are called the element's _ancestors_. + * A path can never be empty, and a path can have at most 100 elements. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Entities are partitioned into subsets, currently identified by a project + * ID and namespace ID. + * Queries are scoped to a single partition. + * + * Generated from protobuf field .google.privacy.dlp.v2.PartitionId partition_id = 1; + * @return \Google\Cloud\Dlp\V2\PartitionId|null + */ + public function getPartitionId() + { + return $this->partition_id; + } + + public function hasPartitionId() + { + return isset($this->partition_id); + } + + public function clearPartitionId() + { + unset($this->partition_id); + } + + /** + * Entities are partitioned into subsets, currently identified by a project + * ID and namespace ID. + * Queries are scoped to a single partition. + * + * Generated from protobuf field .google.privacy.dlp.v2.PartitionId partition_id = 1; + * @param \Google\Cloud\Dlp\V2\PartitionId $var + * @return $this + */ + public function setPartitionId($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PartitionId::class); + $this->partition_id = $var; + + return $this; + } + + /** + * The entity path. + * An entity path consists of one or more elements composed of a kind and a + * string or numerical identifier, which identify entities. The first + * element identifies a _root entity_, the second element identifies + * a _child_ of the root entity, the third element identifies a child of the + * second entity, and so forth. The entities identified by all prefixes of + * the path are called the element's _ancestors_. + * A path can never be empty, and a path can have at most 100 elements. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Key.PathElement path = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPath() + { + return $this->path; + } + + /** + * The entity path. + * An entity path consists of one or more elements composed of a kind and a + * string or numerical identifier, which identify entities. The first + * element identifies a _root entity_, the second element identifies + * a _child_ of the root entity, the third element identifies a child of the + * second entity, and so forth. The entities identified by all prefixes of + * the path are called the element's _ancestors_. + * A path can never be empty, and a path can have at most 100 elements. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Key.PathElement path = 2; + * @param array<\Google\Cloud\Dlp\V2\Key\PathElement>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPath($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Key\PathElement::class); + $this->path = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key/PathElement.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key/PathElement.php new file mode 100644 index 000000000000..6850456e3a22 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key/PathElement.php @@ -0,0 +1,174 @@ +google.privacy.dlp.v2.Key.PathElement + */ +class PathElement extends \Google\Protobuf\Internal\Message +{ + /** + * The kind of the entity. + * A kind matching regex `__.*__` is reserved/read-only. + * A kind must not contain more than 1500 bytes when UTF-8 encoded. + * Cannot be `""`. + * + * Generated from protobuf field string kind = 1; + */ + protected $kind = ''; + protected $id_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $kind + * The kind of the entity. + * A kind matching regex `__.*__` is reserved/read-only. + * A kind must not contain more than 1500 bytes when UTF-8 encoded. + * Cannot be `""`. + * @type int|string $id + * The auto-allocated ID of the entity. + * Never equal to zero. Values less than zero are discouraged and may not + * be supported in the future. + * @type string $name + * The name of the entity. + * A name matching regex `__.*__` is reserved/read-only. + * A name must not be more than 1500 bytes when UTF-8 encoded. + * Cannot be `""`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * The kind of the entity. + * A kind matching regex `__.*__` is reserved/read-only. + * A kind must not contain more than 1500 bytes when UTF-8 encoded. + * Cannot be `""`. + * + * Generated from protobuf field string kind = 1; + * @return string + */ + public function getKind() + { + return $this->kind; + } + + /** + * The kind of the entity. + * A kind matching regex `__.*__` is reserved/read-only. + * A kind must not contain more than 1500 bytes when UTF-8 encoded. + * Cannot be `""`. + * + * Generated from protobuf field string kind = 1; + * @param string $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkString($var, True); + $this->kind = $var; + + return $this; + } + + /** + * The auto-allocated ID of the entity. + * Never equal to zero. Values less than zero are discouraged and may not + * be supported in the future. + * + * Generated from protobuf field int64 id = 2; + * @return int|string + */ + public function getId() + { + return $this->readOneof(2); + } + + public function hasId() + { + return $this->hasOneof(2); + } + + /** + * The auto-allocated ID of the entity. + * Never equal to zero. Values less than zero are discouraged and may not + * be supported in the future. + * + * Generated from protobuf field int64 id = 2; + * @param int|string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkInt64($var); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The name of the entity. + * A name matching regex `__.*__` is reserved/read-only. + * A name must not be more than 1500 bytes when UTF-8 encoded. + * Cannot be `""`. + * + * Generated from protobuf field string name = 3; + * @return string + */ + public function getName() + { + return $this->readOneof(3); + } + + public function hasName() + { + return $this->hasOneof(3); + } + + /** + * The name of the entity. + * A name matching regex `__.*__` is reserved/read-only. + * A name must not be more than 1500 bytes when UTF-8 encoded. + * Cannot be `""`. + * + * Generated from protobuf field string name = 3; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getIdType() + { + return $this->whichOneof("id_type"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PathElement::class, \Google\Cloud\Dlp\V2\Key_PathElement::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KindExpression.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KindExpression.php new file mode 100644 index 000000000000..76d319fa474f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KindExpression.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.KindExpression + */ +class KindExpression extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the kind. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the kind. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * The name of the kind. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the kind. + * + * 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; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KmsWrappedCryptoKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KmsWrappedCryptoKey.php new file mode 100644 index 000000000000..19894467aa2e --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KmsWrappedCryptoKey.php @@ -0,0 +1,109 @@ +google.privacy.dlp.v2.KmsWrappedCryptoKey + */ +class KmsWrappedCryptoKey extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The wrapped data crypto key. + * + * Generated from protobuf field bytes wrapped_key = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $wrapped_key = ''; + /** + * Required. The resource name of the KMS CryptoKey to use for unwrapping. + * + * Generated from protobuf field string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $crypto_key_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $wrapped_key + * Required. The wrapped data crypto key. + * @type string $crypto_key_name + * Required. The resource name of the KMS CryptoKey to use for unwrapping. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. The wrapped data crypto key. + * + * Generated from protobuf field bytes wrapped_key = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getWrappedKey() + { + return $this->wrapped_key; + } + + /** + * Required. The wrapped data crypto key. + * + * Generated from protobuf field bytes wrapped_key = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setWrappedKey($var) + { + GPBUtil::checkString($var, False); + $this->wrapped_key = $var; + + return $this; + } + + /** + * Required. The resource name of the KMS CryptoKey to use for unwrapping. + * + * Generated from protobuf field string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getCryptoKeyName() + { + return $this->crypto_key_name; + } + + /** + * Required. The resource name of the KMS CryptoKey to use for unwrapping. + * + * Generated from protobuf field string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setCryptoKeyName($var) + { + GPBUtil::checkString($var, True); + $this->crypto_key_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryConfig.php new file mode 100644 index 000000000000..01eb8bd279ee --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryConfig.php @@ -0,0 +1,169 @@ +google.privacy.dlp.v2.LargeCustomDictionaryConfig + */ +class LargeCustomDictionaryConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Location to store dictionary artifacts in Cloud Storage. These files + * will only be accessible by project owners and the DLP API. If any of these + * artifacts are modified, the dictionary is considered invalid and can no + * longer be used. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStoragePath output_path = 1; + */ + protected $output_path = null; + protected $source; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\CloudStoragePath $output_path + * Location to store dictionary artifacts in Cloud Storage. These files + * will only be accessible by project owners and the DLP API. If any of these + * artifacts are modified, the dictionary is considered invalid and can no + * longer be used. + * @type \Google\Cloud\Dlp\V2\CloudStorageFileSet $cloud_storage_file_set + * Set of files containing newline-delimited lists of dictionary phrases. + * @type \Google\Cloud\Dlp\V2\BigQueryField $big_query_field + * Field in a BigQuery table where each cell represents a dictionary phrase. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Location to store dictionary artifacts in Cloud Storage. These files + * will only be accessible by project owners and the DLP API. If any of these + * artifacts are modified, the dictionary is considered invalid and can no + * longer be used. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStoragePath output_path = 1; + * @return \Google\Cloud\Dlp\V2\CloudStoragePath|null + */ + public function getOutputPath() + { + return $this->output_path; + } + + public function hasOutputPath() + { + return isset($this->output_path); + } + + public function clearOutputPath() + { + unset($this->output_path); + } + + /** + * Location to store dictionary artifacts in Cloud Storage. These files + * will only be accessible by project owners and the DLP API. If any of these + * artifacts are modified, the dictionary is considered invalid and can no + * longer be used. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStoragePath output_path = 1; + * @param \Google\Cloud\Dlp\V2\CloudStoragePath $var + * @return $this + */ + public function setOutputPath($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudStoragePath::class); + $this->output_path = $var; + + return $this; + } + + /** + * Set of files containing newline-delimited lists of dictionary phrases. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageFileSet cloud_storage_file_set = 2; + * @return \Google\Cloud\Dlp\V2\CloudStorageFileSet|null + */ + public function getCloudStorageFileSet() + { + return $this->readOneof(2); + } + + public function hasCloudStorageFileSet() + { + return $this->hasOneof(2); + } + + /** + * Set of files containing newline-delimited lists of dictionary phrases. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageFileSet cloud_storage_file_set = 2; + * @param \Google\Cloud\Dlp\V2\CloudStorageFileSet $var + * @return $this + */ + public function setCloudStorageFileSet($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudStorageFileSet::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Field in a BigQuery table where each cell represents a dictionary phrase. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryField big_query_field = 3; + * @return \Google\Cloud\Dlp\V2\BigQueryField|null + */ + public function getBigQueryField() + { + return $this->readOneof(3); + } + + public function hasBigQueryField() + { + return $this->hasOneof(3); + } + + /** + * Field in a BigQuery table where each cell represents a dictionary phrase. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryField big_query_field = 3; + * @param \Google\Cloud\Dlp\V2\BigQueryField $var + * @return $this + */ + public function setBigQueryField($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryField::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getSource() + { + return $this->whichOneof("source"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryStats.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryStats.php new file mode 100644 index 000000000000..3e6a9284724e --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryStats.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.LargeCustomDictionaryStats + */ +class LargeCustomDictionaryStats extends \Google\Protobuf\Internal\Message +{ + /** + * Approximate number of distinct phrases in the dictionary. + * + * Generated from protobuf field int64 approx_num_phrases = 1; + */ + protected $approx_num_phrases = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $approx_num_phrases + * Approximate number of distinct phrases in the dictionary. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Approximate number of distinct phrases in the dictionary. + * + * Generated from protobuf field int64 approx_num_phrases = 1; + * @return int|string + */ + public function getApproxNumPhrases() + { + return $this->approx_num_phrases; + } + + /** + * Approximate number of distinct phrases in the dictionary. + * + * Generated from protobuf field int64 approx_num_phrases = 1; + * @param int|string $var + * @return $this + */ + public function setApproxNumPhrases($var) + { + GPBUtil::checkInt64($var); + $this->approx_num_phrases = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Likelihood.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Likelihood.php new file mode 100644 index 000000000000..bcc9e96e6120 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Likelihood.php @@ -0,0 +1,93 @@ +google.privacy.dlp.v2.Likelihood + */ +class Likelihood +{ + /** + * Default value; same as POSSIBLE. + * + * Generated from protobuf enum LIKELIHOOD_UNSPECIFIED = 0; + */ + const LIKELIHOOD_UNSPECIFIED = 0; + /** + * Highest chance of a false positive. + * + * Generated from protobuf enum VERY_UNLIKELY = 1; + */ + const VERY_UNLIKELY = 1; + /** + * High chance of a false positive. + * + * Generated from protobuf enum UNLIKELY = 2; + */ + const UNLIKELY = 2; + /** + * Some matching signals. The default value. + * + * Generated from protobuf enum POSSIBLE = 3; + */ + const POSSIBLE = 3; + /** + * Low chance of a false positive. + * + * Generated from protobuf enum LIKELY = 4; + */ + const LIKELY = 4; + /** + * Confidence level is high. Lowest chance of a false positive. + * + * Generated from protobuf enum VERY_LIKELY = 5; + */ + const VERY_LIKELY = 5; + + private static $valueToName = [ + self::LIKELIHOOD_UNSPECIFIED => 'LIKELIHOOD_UNSPECIFIED', + self::VERY_UNLIKELY => 'VERY_UNLIKELY', + self::UNLIKELY => 'UNLIKELY', + self::POSSIBLE => 'POSSIBLE', + self::LIKELY => 'LIKELY', + self::VERY_LIKELY => 'VERY_LIKELY', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesRequest.php new file mode 100644 index 000000000000..363b066d006f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesRequest.php @@ -0,0 +1,387 @@ +google.privacy.dlp.v2.ListColumnDataProfilesRequest + */ +class ListColumnDataProfilesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the organization or project, for + * example `organizations/433245324/locations/europe` or + * `projects/project-id/locations/asia`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Page token to continue retrieval. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * Size of the page. This value can be limited by the server. If zero, server + * returns a page of max size 100. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + /** + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * Examples: + * * `project_id asc` + * * `table_id` + * * `sensitivity_level desc` + * Supported fields are: + * - `project_id`: The Google Cloud project ID. + * - `dataset_id`: The ID of a BigQuery dataset. + * - `table_id`: The ID of a BigQuery table. + * - `sensitivity_level`: How sensitive the data in a column is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * + * Generated from protobuf field string order_by = 4; + */ + protected $order_by = ''; + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `table_data_profile_name` - The name of the related table data + * profile. + * - `project_id` - The Google Cloud project ID. (REQUIRED) + * - `dataset_id` - The BigQuery dataset ID. (REQUIRED) + * - `table_id` - The BigQuery table ID. (REQUIRED) + * - `field_id` - The ID of the BigQuery field. + * - `info_type` - The infotype detected in the resource. + * - `sensitivity_level` - HIGH|MEDIUM|LOW + * - `data_risk_level`: How much risk is associated with this data. + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` for project_id, dataset_id, and table_id. Other + * filters also support `!=`. + * Examples: + * * project_id = 12345 AND status_code = 1 + * * project_id = 12345 AND sensitivity_level = HIGH + * * project_id = 12345 AND info_type = STREET_ADDRESS + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 5; + */ + protected $filter = ''; + + /** + * @param string $parent Required. Resource name of the organization or project, for + * example `organizations/433245324/locations/europe` or + * `projects/project-id/locations/asia`. Please see + * {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\ListColumnDataProfilesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the organization or project, for + * example `organizations/433245324/locations/europe` or + * `projects/project-id/locations/asia`. + * @type string $page_token + * Page token to continue retrieval. + * @type int $page_size + * Size of the page. This value can be limited by the server. If zero, server + * returns a page of max size 100. + * @type string $order_by + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * Examples: + * * `project_id asc` + * * `table_id` + * * `sensitivity_level desc` + * Supported fields are: + * - `project_id`: The Google Cloud project ID. + * - `dataset_id`: The ID of a BigQuery dataset. + * - `table_id`: The ID of a BigQuery table. + * - `sensitivity_level`: How sensitive the data in a column is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * @type string $filter + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `table_data_profile_name` - The name of the related table data + * profile. + * - `project_id` - The Google Cloud project ID. (REQUIRED) + * - `dataset_id` - The BigQuery dataset ID. (REQUIRED) + * - `table_id` - The BigQuery table ID. (REQUIRED) + * - `field_id` - The ID of the BigQuery field. + * - `info_type` - The infotype detected in the resource. + * - `sensitivity_level` - HIGH|MEDIUM|LOW + * - `data_risk_level`: How much risk is associated with this data. + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` for project_id, dataset_id, and table_id. Other + * filters also support `!=`. + * Examples: + * * project_id = 12345 AND status_code = 1 + * * project_id = 12345 AND sensitivity_level = HIGH + * * project_id = 12345 AND info_type = STREET_ADDRESS + * The length of this field should be no more than 500 characters. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the organization or project, for + * example `organizations/433245324/locations/europe` or + * `projects/project-id/locations/asia`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the organization or project, for + * example `organizations/433245324/locations/europe` or + * `projects/project-id/locations/asia`. + * + * 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; + } + + /** + * Page token to continue retrieval. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Page token to continue retrieval. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * Size of the page. This value can be limited by the server. If zero, server + * returns a page of max size 100. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Size of the page. This value can be limited by the server. If zero, server + * returns a page of max size 100. + * + * 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; + } + + /** + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * Examples: + * * `project_id asc` + * * `table_id` + * * `sensitivity_level desc` + * Supported fields are: + * - `project_id`: The Google Cloud project ID. + * - `dataset_id`: The ID of a BigQuery dataset. + * - `table_id`: The ID of a BigQuery table. + * - `sensitivity_level`: How sensitive the data in a column is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * + * Generated from protobuf field string order_by = 4; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * Examples: + * * `project_id asc` + * * `table_id` + * * `sensitivity_level desc` + * Supported fields are: + * - `project_id`: The Google Cloud project ID. + * - `dataset_id`: The ID of a BigQuery dataset. + * - `table_id`: The ID of a BigQuery table. + * - `sensitivity_level`: How sensitive the data in a column is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * + * Generated from protobuf field string order_by = 4; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `table_data_profile_name` - The name of the related table data + * profile. + * - `project_id` - The Google Cloud project ID. (REQUIRED) + * - `dataset_id` - The BigQuery dataset ID. (REQUIRED) + * - `table_id` - The BigQuery table ID. (REQUIRED) + * - `field_id` - The ID of the BigQuery field. + * - `info_type` - The infotype detected in the resource. + * - `sensitivity_level` - HIGH|MEDIUM|LOW + * - `data_risk_level`: How much risk is associated with this data. + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` for project_id, dataset_id, and table_id. Other + * filters also support `!=`. + * Examples: + * * project_id = 12345 AND status_code = 1 + * * project_id = 12345 AND sensitivity_level = HIGH + * * project_id = 12345 AND info_type = STREET_ADDRESS + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 5; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `table_data_profile_name` - The name of the related table data + * profile. + * - `project_id` - The Google Cloud project ID. (REQUIRED) + * - `dataset_id` - The BigQuery dataset ID. (REQUIRED) + * - `table_id` - The BigQuery table ID. (REQUIRED) + * - `field_id` - The ID of the BigQuery field. + * - `info_type` - The infotype detected in the resource. + * - `sensitivity_level` - HIGH|MEDIUM|LOW + * - `data_risk_level`: How much risk is associated with this data. + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` for project_id, dataset_id, and table_id. Other + * filters also support `!=`. + * Examples: + * * project_id = 12345 AND status_code = 1 + * * project_id = 12345 AND sensitivity_level = HIGH + * * project_id = 12345 AND info_type = STREET_ADDRESS + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 5; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesResponse.php new file mode 100644 index 000000000000..81fea408c64d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesResponse.php @@ -0,0 +1,101 @@ +google.privacy.dlp.v2.ListColumnDataProfilesResponse + */ +class ListColumnDataProfilesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * List of data profiles. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ColumnDataProfile column_data_profiles = 1; + */ + private $column_data_profiles; + /** + * The next page token. + * + * 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<\Google\Cloud\Dlp\V2\ColumnDataProfile>|\Google\Protobuf\Internal\RepeatedField $column_data_profiles + * List of data profiles. + * @type string $next_page_token + * The next page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of data profiles. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ColumnDataProfile column_data_profiles = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getColumnDataProfiles() + { + return $this->column_data_profiles; + } + + /** + * List of data profiles. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ColumnDataProfile column_data_profiles = 1; + * @param array<\Google\Cloud\Dlp\V2\ColumnDataProfile>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setColumnDataProfiles($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ColumnDataProfile::class); + $this->column_data_profiles = $arr; + + return $this; + } + + /** + * The next page token. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * The next page token. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsRequest.php new file mode 100644 index 000000000000..98a09d1acfe9 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsRequest.php @@ -0,0 +1,192 @@ +google.privacy.dlp.v2.ListConnectionsRequest + */ +class ListConnectionsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent name, for example: + * `projects/project-id/locations/global`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. Number of results per page, max 1000. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. Page token from a previous page to return the next set of + * results. If set, all other request fields must match the original request. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + /** + * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $filter = ''; + + /** + * @param string $parent Required. Parent name, for example: + * `projects/project-id/locations/global`. Please see + * {@see DlpServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\ListConnectionsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent name, for example: + * `projects/project-id/locations/global`. + * @type int $page_size + * Optional. Number of results per page, max 1000. + * @type string $page_token + * Optional. Page token from a previous page to return the next set of + * results. If set, all other request fields must match the original request. + * @type string $filter + * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent name, for example: + * `projects/project-id/locations/global`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent name, for example: + * `projects/project-id/locations/global`. + * + * 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; + } + + /** + * Optional. Number of results per page, max 1000. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Optional. Number of results per page, max 1000. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * Optional. Page token from a previous page to return the next set of + * results. If set, all other request fields must match the original request. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. Page token from a previous page to return the next set of + * results. If set, all other request fields must match the original request. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsResponse.php new file mode 100644 index 000000000000..a16148048980 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsResponse.php @@ -0,0 +1,105 @@ +google.privacy.dlp.v2.ListConnectionsResponse + */ +class ListConnectionsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * List of connections. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Connection connections = 1; + */ + private $connections; + /** + * Token to retrieve the next page of results. An empty value means there are + * 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<\Google\Cloud\Dlp\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $connections + * List of connections. + * @type string $next_page_token + * Token to retrieve the next page of results. An empty value means there are + * no more results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of connections. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Connection connections = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getConnections() + { + return $this->connections; + } + + /** + * List of connections. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Connection connections = 1; + * @param array<\Google\Cloud\Dlp\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setConnections($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Connection::class); + $this->connections = $arr; + + return $this; + } + + /** + * Token to retrieve the next page of results. An empty value means there are + * no more results. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results. An empty value means there are + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesRequest.php new file mode 100644 index 000000000000..c2bb760c2421 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesRequest.php @@ -0,0 +1,340 @@ +google.privacy.dlp.v2.ListDeidentifyTemplatesRequest + */ +class ListDeidentifyTemplatesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Page token to continue retrieval. Comes from the previous call + * to `ListDeidentifyTemplates`. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * Size of the page. This value can be limited by the server. If zero server + * returns a page of max size 100. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + /** + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the template was created. + * - `update_time`: corresponds to the time the template was last updated. + * - `name`: corresponds to the template's name. + * - `display_name`: corresponds to the template's display name. + * + * Generated from protobuf field string order_by = 4; + */ + protected $order_by = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + */ + protected $location_id = ''; + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\ListDeidentifyTemplatesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type string $page_token + * Page token to continue retrieval. Comes from the previous call + * to `ListDeidentifyTemplates`. + * @type int $page_size + * Size of the page. This value can be limited by the server. If zero server + * returns a page of max size 100. + * @type string $order_by + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the template was created. + * - `update_time`: corresponds to the time the template was last updated. + * - `name`: corresponds to the template's name. + * - `display_name`: corresponds to the template's display name. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * 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; + } + + /** + * Page token to continue retrieval. Comes from the previous call + * to `ListDeidentifyTemplates`. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Page token to continue retrieval. Comes from the previous call + * to `ListDeidentifyTemplates`. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * Size of the page. This value can be limited by the server. If zero server + * returns a page of max size 100. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Size of the page. This value can be limited by the server. If zero server + * returns a page of max size 100. + * + * 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; + } + + /** + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the template was created. + * - `update_time`: corresponds to the time the template was last updated. + * - `name`: corresponds to the template's name. + * - `display_name`: corresponds to the template's display name. + * + * Generated from protobuf field string order_by = 4; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the template was created. + * - `update_time`: corresponds to the time the template was last updated. + * - `name`: corresponds to the template's name. + * - `display_name`: corresponds to the template's display name. + * + * Generated from protobuf field string order_by = 4; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesResponse.php new file mode 100644 index 000000000000..078648be7417 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesResponse.php @@ -0,0 +1,109 @@ +google.privacy.dlp.v2.ListDeidentifyTemplatesResponse + */ +class ListDeidentifyTemplatesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * List of deidentify templates, up to page_size in + * ListDeidentifyTemplatesRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DeidentifyTemplate deidentify_templates = 1; + */ + private $deidentify_templates; + /** + * If the next page is available then the next page token to be used in the + * following ListDeidentifyTemplates request. + * + * 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<\Google\Cloud\Dlp\V2\DeidentifyTemplate>|\Google\Protobuf\Internal\RepeatedField $deidentify_templates + * List of deidentify templates, up to page_size in + * ListDeidentifyTemplatesRequest. + * @type string $next_page_token + * If the next page is available then the next page token to be used in the + * following ListDeidentifyTemplates request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of deidentify templates, up to page_size in + * ListDeidentifyTemplatesRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DeidentifyTemplate deidentify_templates = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDeidentifyTemplates() + { + return $this->deidentify_templates; + } + + /** + * List of deidentify templates, up to page_size in + * ListDeidentifyTemplatesRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DeidentifyTemplate deidentify_templates = 1; + * @param array<\Google\Cloud\Dlp\V2\DeidentifyTemplate>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDeidentifyTemplates($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DeidentifyTemplate::class); + $this->deidentify_templates = $arr; + + return $this; + } + + /** + * If the next page is available then the next page token to be used in the + * following ListDeidentifyTemplates request. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * If the next page is available then the next page token to be used in the + * following ListDeidentifyTemplates request. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsRequest.php new file mode 100644 index 000000000000..fad47e3fe97a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsRequest.php @@ -0,0 +1,256 @@ +google.privacy.dlp.v2.ListDiscoveryConfigsRequest + */ +class ListDiscoveryConfigsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value is as follows: + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Page token to continue retrieval. Comes from the previous call + * to ListDiscoveryConfigs. `order_by` field must not + * change for subsequent calls. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * Size of the page. This value can be limited by a server. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + /** + * Comma separated list of config fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `last_run_time`: corresponds to the last time the DiscoveryConfig ran. + * - `name`: corresponds to the DiscoveryConfig's name. + * - `status`: corresponds to DiscoveryConfig's status. + * + * Generated from protobuf field string order_by = 4; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value is as follows: + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\ListDiscoveryConfigsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value is as follows: + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type string $page_token + * Page token to continue retrieval. Comes from the previous call + * to ListDiscoveryConfigs. `order_by` field must not + * change for subsequent calls. + * @type int $page_size + * Size of the page. This value can be limited by a server. + * @type string $order_by + * Comma separated list of config fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `last_run_time`: corresponds to the last time the DiscoveryConfig ran. + * - `name`: corresponds to the DiscoveryConfig's name. + * - `status`: corresponds to DiscoveryConfig's status. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value is as follows: + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value is as follows: + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * 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; + } + + /** + * Page token to continue retrieval. Comes from the previous call + * to ListDiscoveryConfigs. `order_by` field must not + * change for subsequent calls. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Page token to continue retrieval. Comes from the previous call + * to ListDiscoveryConfigs. `order_by` field must not + * change for subsequent calls. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * Size of the page. This value can be limited by a server. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Size of the page. This value can be limited by a server. + * + * 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; + } + + /** + * Comma separated list of config fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `last_run_time`: corresponds to the last time the DiscoveryConfig ran. + * - `name`: corresponds to the DiscoveryConfig's name. + * - `status`: corresponds to DiscoveryConfig's status. + * + * Generated from protobuf field string order_by = 4; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Comma separated list of config fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `last_run_time`: corresponds to the last time the DiscoveryConfig ran. + * - `name`: corresponds to the DiscoveryConfig's name. + * - `status`: corresponds to DiscoveryConfig's status. + * + * Generated from protobuf field string order_by = 4; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsResponse.php new file mode 100644 index 000000000000..118594acf0b4 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsResponse.php @@ -0,0 +1,105 @@ +google.privacy.dlp.v2.ListDiscoveryConfigsResponse + */ +class ListDiscoveryConfigsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * List of configs, up to page_size in ListDiscoveryConfigsRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryConfig discovery_configs = 1; + */ + private $discovery_configs; + /** + * If the next page is available then this value is the next page token to be + * used in the following ListDiscoveryConfigs request. + * + * 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<\Google\Cloud\Dlp\V2\DiscoveryConfig>|\Google\Protobuf\Internal\RepeatedField $discovery_configs + * List of configs, up to page_size in ListDiscoveryConfigsRequest. + * @type string $next_page_token + * If the next page is available then this value is the next page token to be + * used in the following ListDiscoveryConfigs request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of configs, up to page_size in ListDiscoveryConfigsRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryConfig discovery_configs = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDiscoveryConfigs() + { + return $this->discovery_configs; + } + + /** + * List of configs, up to page_size in ListDiscoveryConfigsRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryConfig discovery_configs = 1; + * @param array<\Google\Cloud\Dlp\V2\DiscoveryConfig>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDiscoveryConfigs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DiscoveryConfig::class); + $this->discovery_configs = $arr; + + return $this; + } + + /** + * If the next page is available then this value is the next page token to be + * used in the following ListDiscoveryConfigs request. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * If the next page is available then this value is the next page token to be + * used in the following ListDiscoveryConfigs request. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsRequest.php new file mode 100644 index 000000000000..1bc0db8d5e19 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsRequest.php @@ -0,0 +1,468 @@ +google.privacy.dlp.v2.ListDlpJobsRequest + */ +class ListDlpJobsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values for inspect jobs: + * - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED + * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY + * - `trigger_name` - The name of the trigger that created the job. + * - 'end_time` - Corresponds to the time the job finished. + * - 'start_time` - Corresponds to the time the job finished. + * * Supported fields for risk analysis jobs: + * - `state` - RUNNING|CANCELED|FINISHED|FAILED + * - 'end_time` - Corresponds to the time the job finished. + * - 'start_time` - Corresponds to the time the job finished. + * * The operator must be `=` or `!=`. + * Examples: + * * inspected_storage = cloud_storage AND state = done + * * inspected_storage = cloud_storage OR inspected_storage = bigquery + * * inspected_storage = cloud_storage AND (state = done OR state = canceled) + * * end_time > \"2017-12-12T00:00:00+00:00\" + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 1; + */ + protected $filter = ''; + /** + * The standard list page size. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * The standard list page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * The type of job. Defaults to `DlpJobType.INSPECT` + * + * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 5; + */ + protected $type = 0; + /** + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc, end_time asc, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the job was created. + * - `end_time`: corresponds to the time the job ended. + * - `name`: corresponds to the job's name. + * - `state`: corresponds to `state` + * + * Generated from protobuf field string order_by = 6; + */ + protected $order_by = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 7; + */ + protected $location_id = ''; + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::projectName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\ListDlpJobsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type string $filter + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values for inspect jobs: + * - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED + * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY + * - `trigger_name` - The name of the trigger that created the job. + * - 'end_time` - Corresponds to the time the job finished. + * - 'start_time` - Corresponds to the time the job finished. + * * Supported fields for risk analysis jobs: + * - `state` - RUNNING|CANCELED|FINISHED|FAILED + * - 'end_time` - Corresponds to the time the job finished. + * - 'start_time` - Corresponds to the time the job finished. + * * The operator must be `=` or `!=`. + * Examples: + * * inspected_storage = cloud_storage AND state = done + * * inspected_storage = cloud_storage OR inspected_storage = bigquery + * * inspected_storage = cloud_storage AND (state = done OR state = canceled) + * * end_time > \"2017-12-12T00:00:00+00:00\" + * The length of this field should be no more than 500 characters. + * @type int $page_size + * The standard list page size. + * @type string $page_token + * The standard list page token. + * @type int $type + * The type of job. Defaults to `DlpJobType.INSPECT` + * @type string $order_by + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc, end_time asc, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the job was created. + * - `end_time`: corresponds to the time the job ended. + * - `name`: corresponds to the job's name. + * - `state`: corresponds to `state` + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 4 [(.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; + } + + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values for inspect jobs: + * - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED + * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY + * - `trigger_name` - The name of the trigger that created the job. + * - 'end_time` - Corresponds to the time the job finished. + * - 'start_time` - Corresponds to the time the job finished. + * * Supported fields for risk analysis jobs: + * - `state` - RUNNING|CANCELED|FINISHED|FAILED + * - 'end_time` - Corresponds to the time the job finished. + * - 'start_time` - Corresponds to the time the job finished. + * * The operator must be `=` or `!=`. + * Examples: + * * inspected_storage = cloud_storage AND state = done + * * inspected_storage = cloud_storage OR inspected_storage = bigquery + * * inspected_storage = cloud_storage AND (state = done OR state = canceled) + * * end_time > \"2017-12-12T00:00:00+00:00\" + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 1; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values for inspect jobs: + * - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED + * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY + * - `trigger_name` - The name of the trigger that created the job. + * - 'end_time` - Corresponds to the time the job finished. + * - 'start_time` - Corresponds to the time the job finished. + * * Supported fields for risk analysis jobs: + * - `state` - RUNNING|CANCELED|FINISHED|FAILED + * - 'end_time` - Corresponds to the time the job finished. + * - 'start_time` - Corresponds to the time the job finished. + * * The operator must be `=` or `!=`. + * Examples: + * * inspected_storage = cloud_storage AND state = done + * * inspected_storage = cloud_storage OR inspected_storage = bigquery + * * inspected_storage = cloud_storage AND (state = done OR state = canceled) + * * end_time > \"2017-12-12T00:00:00+00:00\" + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 1; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * The standard list page size. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The standard list page size. + * + * Generated from protobuf field int32 page_size = 2; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * The standard list page token. + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The standard list page token. + * + * Generated from protobuf field string page_token = 3; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The type of job. Defaults to `DlpJobType.INSPECT` + * + * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 5; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * The type of job. Defaults to `DlpJobType.INSPECT` + * + * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 5; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DlpJobType::class); + $this->type = $var; + + return $this; + } + + /** + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc, end_time asc, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the job was created. + * - `end_time`: corresponds to the time the job ended. + * - `name`: corresponds to the job's name. + * - `state`: corresponds to `state` + * + * Generated from protobuf field string order_by = 6; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc, end_time asc, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the job was created. + * - `end_time`: corresponds to the time the job ended. + * - `name`: corresponds to the job's name. + * - `state`: corresponds to `state` + * + * Generated from protobuf field string order_by = 6; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 7; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 7; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsResponse.php new file mode 100644 index 000000000000..62d9df6c8efb --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsResponse.php @@ -0,0 +1,101 @@ +google.privacy.dlp.v2.ListDlpJobsResponse + */ +class ListDlpJobsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of DlpJobs that matches the specified filter in the request. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DlpJob jobs = 1; + */ + private $jobs; + /** + * The standard List next-page token. + * + * 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<\Google\Cloud\Dlp\V2\DlpJob>|\Google\Protobuf\Internal\RepeatedField $jobs + * A list of DlpJobs that matches the specified filter in the request. + * @type string $next_page_token + * The standard List next-page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A list of DlpJobs that matches the specified filter in the request. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DlpJob jobs = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getJobs() + { + return $this->jobs; + } + + /** + * A list of DlpJobs that matches the specified filter in the request. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.DlpJob jobs = 1; + * @param array<\Google\Cloud\Dlp\V2\DlpJob>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setJobs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DlpJob::class); + $this->jobs = $arr; + + return $this; + } + + /** + * The standard List next-page token. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * The standard List next-page token. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesRequest.php new file mode 100644 index 000000000000..c9217ebba228 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesRequest.php @@ -0,0 +1,206 @@ +google.privacy.dlp.v2.ListInfoTypesRequest + */ +class ListInfoTypesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * The parent resource name. + * The format of this value is as follows: + * locations/LOCATION_ID + * + * Generated from protobuf field string parent = 4; + */ + protected $parent = ''; + /** + * BCP-47 language code for localized infoType friendly + * names. If omitted, or if localized strings are not available, + * en-US strings will be returned. + * + * Generated from protobuf field string language_code = 1; + */ + protected $language_code = ''; + /** + * filter to only return infoTypes supported by certain parts of the + * API. Defaults to supported_by=INSPECT. + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 3; + */ + protected $location_id = ''; + + /** + * @param string $parent The parent resource name. + * + * The format of this value is as follows: + * + * locations/LOCATION_ID + * + * @return \Google\Cloud\Dlp\V2\ListInfoTypesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * The parent resource name. + * The format of this value is as follows: + * locations/LOCATION_ID + * @type string $language_code + * BCP-47 language code for localized infoType friendly + * names. If omitted, or if localized strings are not available, + * en-US strings will be returned. + * @type string $filter + * filter to only return infoTypes supported by certain parts of the + * API. Defaults to supported_by=INSPECT. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The parent resource name. + * The format of this value is as follows: + * locations/LOCATION_ID + * + * Generated from protobuf field string parent = 4; + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The parent resource name. + * The format of this value is as follows: + * locations/LOCATION_ID + * + * Generated from protobuf field string parent = 4; + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * BCP-47 language code for localized infoType friendly + * names. If omitted, or if localized strings are not available, + * en-US strings will be returned. + * + * Generated from protobuf field string language_code = 1; + * @return string + */ + public function getLanguageCode() + { + return $this->language_code; + } + + /** + * BCP-47 language code for localized infoType friendly + * names. If omitted, or if localized strings are not available, + * en-US strings will be returned. + * + * Generated from protobuf field string language_code = 1; + * @param string $var + * @return $this + */ + public function setLanguageCode($var) + { + GPBUtil::checkString($var, True); + $this->language_code = $var; + + return $this; + } + + /** + * filter to only return infoTypes supported by certain parts of the + * API. Defaults to supported_by=INSPECT. + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * filter to only return infoTypes supported by certain parts of the + * API. Defaults to supported_by=INSPECT. + * + * 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; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 3; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 3; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesResponse.php new file mode 100644 index 000000000000..38951fc4c7e2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesResponse.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.ListInfoTypesResponse + */ +class ListInfoTypesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Set of sensitive infoTypes. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeDescription info_types = 1; + */ + private $info_types; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\InfoTypeDescription>|\Google\Protobuf\Internal\RepeatedField $info_types + * Set of sensitive infoTypes. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Set of sensitive infoTypes. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeDescription info_types = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getInfoTypes() + { + return $this->info_types; + } + + /** + * Set of sensitive infoTypes. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeDescription info_types = 1; + * @param array<\Google\Cloud\Dlp\V2\InfoTypeDescription>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setInfoTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoTypeDescription::class); + $this->info_types = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesRequest.php new file mode 100644 index 000000000000..c53d0ee6d0df --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesRequest.php @@ -0,0 +1,340 @@ +google.privacy.dlp.v2.ListInspectTemplatesRequest + */ +class ListInspectTemplatesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Page token to continue retrieval. Comes from the previous call + * to `ListInspectTemplates`. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * Size of the page. This value can be limited by the server. If zero server + * returns a page of max size 100. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + /** + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the template was created. + * - `update_time`: corresponds to the time the template was last updated. + * - `name`: corresponds to the template's name. + * - `display_name`: corresponds to the template's display name. + * + * Generated from protobuf field string order_by = 4; + */ + protected $order_by = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + */ + protected $location_id = ''; + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\ListInspectTemplatesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type string $page_token + * Page token to continue retrieval. Comes from the previous call + * to `ListInspectTemplates`. + * @type int $page_size + * Size of the page. This value can be limited by the server. If zero server + * returns a page of max size 100. + * @type string $order_by + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the template was created. + * - `update_time`: corresponds to the time the template was last updated. + * - `name`: corresponds to the template's name. + * - `display_name`: corresponds to the template's display name. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * 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; + } + + /** + * Page token to continue retrieval. Comes from the previous call + * to `ListInspectTemplates`. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Page token to continue retrieval. Comes from the previous call + * to `ListInspectTemplates`. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * Size of the page. This value can be limited by the server. If zero server + * returns a page of max size 100. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Size of the page. This value can be limited by the server. If zero server + * returns a page of max size 100. + * + * 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; + } + + /** + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the template was created. + * - `update_time`: corresponds to the time the template was last updated. + * - `name`: corresponds to the template's name. + * - `display_name`: corresponds to the template's display name. + * + * Generated from protobuf field string order_by = 4; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the template was created. + * - `update_time`: corresponds to the time the template was last updated. + * - `name`: corresponds to the template's name. + * - `display_name`: corresponds to the template's display name. + * + * Generated from protobuf field string order_by = 4; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesResponse.php new file mode 100644 index 000000000000..8d00e0dab910 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesResponse.php @@ -0,0 +1,105 @@ +google.privacy.dlp.v2.ListInspectTemplatesResponse + */ +class ListInspectTemplatesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * List of inspectTemplates, up to page_size in ListInspectTemplatesRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectTemplate inspect_templates = 1; + */ + private $inspect_templates; + /** + * If the next page is available then the next page token to be used in the + * following ListInspectTemplates request. + * + * 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<\Google\Cloud\Dlp\V2\InspectTemplate>|\Google\Protobuf\Internal\RepeatedField $inspect_templates + * List of inspectTemplates, up to page_size in ListInspectTemplatesRequest. + * @type string $next_page_token + * If the next page is available then the next page token to be used in the + * following ListInspectTemplates request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of inspectTemplates, up to page_size in ListInspectTemplatesRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectTemplate inspect_templates = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getInspectTemplates() + { + return $this->inspect_templates; + } + + /** + * List of inspectTemplates, up to page_size in ListInspectTemplatesRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectTemplate inspect_templates = 1; + * @param array<\Google\Cloud\Dlp\V2\InspectTemplate>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setInspectTemplates($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InspectTemplate::class); + $this->inspect_templates = $arr; + + return $this; + } + + /** + * If the next page is available then the next page token to be used in the + * following ListInspectTemplates request. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * If the next page is available then the next page token to be used in the + * following ListInspectTemplates request. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersRequest.php new file mode 100644 index 000000000000..3279052b9af6 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersRequest.php @@ -0,0 +1,468 @@ +google.privacy.dlp.v2.ListJobTriggersRequest + */ +class ListJobTriggersRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Page token to continue retrieval. Comes from the previous call + * to ListJobTriggers. `order_by` field must not + * change for subsequent calls. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * Size of the page. This value can be limited by a server. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + /** + * Comma separated list of triggeredJob fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the JobTrigger was created. + * - `update_time`: corresponds to the time the JobTrigger was last updated. + * - `last_run_time`: corresponds to the last time the JobTrigger ran. + * - `name`: corresponds to the JobTrigger's name. + * - `display_name`: corresponds to the JobTrigger's display name. + * - `status`: corresponds to JobTrigger's status. + * + * Generated from protobuf field string order_by = 4; + */ + protected $order_by = ''; + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values for inspect triggers: + * - `status` - HEALTHY|PAUSED|CANCELLED + * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY + * - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by + * quotation marks. Nanoseconds are ignored. + * - 'error_count' - Number of errors that have occurred while running. + * * The operator must be `=` or `!=` for status and inspected_storage. + * Examples: + * * inspected_storage = cloud_storage AND status = HEALTHY + * * inspected_storage = cloud_storage OR inspected_storage = bigquery + * * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) + * * last_run_time > \"2017-12-12T00:00:00+00:00\" + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 5; + */ + protected $filter = ''; + /** + * The type of jobs. Will use `DlpJobType.INSPECT` if not set. + * + * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 6; + */ + protected $type = 0; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 7; + */ + protected $location_id = ''; + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::projectName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\ListJobTriggersRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type string $page_token + * Page token to continue retrieval. Comes from the previous call + * to ListJobTriggers. `order_by` field must not + * change for subsequent calls. + * @type int $page_size + * Size of the page. This value can be limited by a server. + * @type string $order_by + * Comma separated list of triggeredJob fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the JobTrigger was created. + * - `update_time`: corresponds to the time the JobTrigger was last updated. + * - `last_run_time`: corresponds to the last time the JobTrigger ran. + * - `name`: corresponds to the JobTrigger's name. + * - `display_name`: corresponds to the JobTrigger's display name. + * - `status`: corresponds to JobTrigger's status. + * @type string $filter + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values for inspect triggers: + * - `status` - HEALTHY|PAUSED|CANCELLED + * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY + * - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by + * quotation marks. Nanoseconds are ignored. + * - 'error_count' - Number of errors that have occurred while running. + * * The operator must be `=` or `!=` for status and inspected_storage. + * Examples: + * * inspected_storage = cloud_storage AND status = HEALTHY + * * inspected_storage = cloud_storage OR inspected_storage = bigquery + * * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) + * * last_run_time > \"2017-12-12T00:00:00+00:00\" + * The length of this field should be no more than 500 characters. + * @type int $type + * The type of jobs. Will use `DlpJobType.INSPECT` if not set. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * 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; + } + + /** + * Page token to continue retrieval. Comes from the previous call + * to ListJobTriggers. `order_by` field must not + * change for subsequent calls. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Page token to continue retrieval. Comes from the previous call + * to ListJobTriggers. `order_by` field must not + * change for subsequent calls. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * Size of the page. This value can be limited by a server. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Size of the page. This value can be limited by a server. + * + * 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; + } + + /** + * Comma separated list of triggeredJob fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the JobTrigger was created. + * - `update_time`: corresponds to the time the JobTrigger was last updated. + * - `last_run_time`: corresponds to the last time the JobTrigger ran. + * - `name`: corresponds to the JobTrigger's name. + * - `display_name`: corresponds to the JobTrigger's display name. + * - `status`: corresponds to JobTrigger's status. + * + * Generated from protobuf field string order_by = 4; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Comma separated list of triggeredJob fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc,update_time, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the JobTrigger was created. + * - `update_time`: corresponds to the time the JobTrigger was last updated. + * - `last_run_time`: corresponds to the last time the JobTrigger ran. + * - `name`: corresponds to the JobTrigger's name. + * - `display_name`: corresponds to the JobTrigger's display name. + * - `status`: corresponds to JobTrigger's status. + * + * Generated from protobuf field string order_by = 4; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values for inspect triggers: + * - `status` - HEALTHY|PAUSED|CANCELLED + * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY + * - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by + * quotation marks. Nanoseconds are ignored. + * - 'error_count' - Number of errors that have occurred while running. + * * The operator must be `=` or `!=` for status and inspected_storage. + * Examples: + * * inspected_storage = cloud_storage AND status = HEALTHY + * * inspected_storage = cloud_storage OR inspected_storage = bigquery + * * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) + * * last_run_time > \"2017-12-12T00:00:00+00:00\" + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 5; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values for inspect triggers: + * - `status` - HEALTHY|PAUSED|CANCELLED + * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY + * - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by + * quotation marks. Nanoseconds are ignored. + * - 'error_count' - Number of errors that have occurred while running. + * * The operator must be `=` or `!=` for status and inspected_storage. + * Examples: + * * inspected_storage = cloud_storage AND status = HEALTHY + * * inspected_storage = cloud_storage OR inspected_storage = bigquery + * * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) + * * last_run_time > \"2017-12-12T00:00:00+00:00\" + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 5; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * The type of jobs. Will use `DlpJobType.INSPECT` if not set. + * + * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 6; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * The type of jobs. Will use `DlpJobType.INSPECT` if not set. + * + * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 6; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DlpJobType::class); + $this->type = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 7; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 7; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersResponse.php new file mode 100644 index 000000000000..a271b151b1f8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersResponse.php @@ -0,0 +1,105 @@ +google.privacy.dlp.v2.ListJobTriggersResponse + */ +class ListJobTriggersResponse extends \Google\Protobuf\Internal\Message +{ + /** + * List of triggeredJobs, up to page_size in ListJobTriggersRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.JobTrigger job_triggers = 1; + */ + private $job_triggers; + /** + * If the next page is available then this value is the next page token to be + * used in the following ListJobTriggers request. + * + * 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<\Google\Cloud\Dlp\V2\JobTrigger>|\Google\Protobuf\Internal\RepeatedField $job_triggers + * List of triggeredJobs, up to page_size in ListJobTriggersRequest. + * @type string $next_page_token + * If the next page is available then this value is the next page token to be + * used in the following ListJobTriggers request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of triggeredJobs, up to page_size in ListJobTriggersRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.JobTrigger job_triggers = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getJobTriggers() + { + return $this->job_triggers; + } + + /** + * List of triggeredJobs, up to page_size in ListJobTriggersRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.JobTrigger job_triggers = 1; + * @param array<\Google\Cloud\Dlp\V2\JobTrigger>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setJobTriggers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\JobTrigger::class); + $this->job_triggers = $arr; + + return $this; + } + + /** + * If the next page is available then this value is the next page token to be + * used in the following ListJobTriggers request. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * If the next page is available then this value is the next page token to be + * used in the following ListJobTriggers request. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesRequest.php new file mode 100644 index 000000000000..4b3a69cee79c --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesRequest.php @@ -0,0 +1,329 @@ +google.privacy.dlp.v2.ListProjectDataProfilesRequest + */ +class ListProjectDataProfilesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. organizations/{org_id}/locations/{loc_id} + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Page token to continue retrieval. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * Size of the page. This value can be limited by the server. If zero, server + * returns a page of max size 100. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + /** + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * Examples: + * * `project_id` + * * `sensitivity_level desc` + * Supported fields are: + * - `project_id`: Google Cloud project ID + * - `sensitivity_level`: How sensitive the data in a project is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * + * Generated from protobuf field string order_by = 4; + */ + protected $order_by = ''; + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `sensitivity_level` - HIGH|MODERATE|LOW + * - `data_risk_level` - HIGH|MODERATE|LOW + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` or `!=`. + * Examples: + * * `project_id = 12345 AND status_code = 1` + * * `project_id = 12345 AND sensitivity_level = HIGH` + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 5; + */ + protected $filter = ''; + + /** + * @param string $parent Required. organizations/{org_id}/locations/{loc_id} + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\ListProjectDataProfilesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. organizations/{org_id}/locations/{loc_id} + * @type string $page_token + * Page token to continue retrieval. + * @type int $page_size + * Size of the page. This value can be limited by the server. If zero, server + * returns a page of max size 100. + * @type string $order_by + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * Examples: + * * `project_id` + * * `sensitivity_level desc` + * Supported fields are: + * - `project_id`: Google Cloud project ID + * - `sensitivity_level`: How sensitive the data in a project is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * @type string $filter + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `sensitivity_level` - HIGH|MODERATE|LOW + * - `data_risk_level` - HIGH|MODERATE|LOW + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` or `!=`. + * Examples: + * * `project_id = 12345 AND status_code = 1` + * * `project_id = 12345 AND sensitivity_level = HIGH` + * The length of this field should be no more than 500 characters. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. organizations/{org_id}/locations/{loc_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; + } + + /** + * Required. organizations/{org_id}/locations/{loc_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; + } + + /** + * Page token to continue retrieval. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Page token to continue retrieval. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * Size of the page. This value can be limited by the server. If zero, server + * returns a page of max size 100. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Size of the page. This value can be limited by the server. If zero, server + * returns a page of max size 100. + * + * 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; + } + + /** + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * Examples: + * * `project_id` + * * `sensitivity_level desc` + * Supported fields are: + * - `project_id`: Google Cloud project ID + * - `sensitivity_level`: How sensitive the data in a project is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * + * Generated from protobuf field string order_by = 4; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * Examples: + * * `project_id` + * * `sensitivity_level desc` + * Supported fields are: + * - `project_id`: Google Cloud project ID + * - `sensitivity_level`: How sensitive the data in a project is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * + * Generated from protobuf field string order_by = 4; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `sensitivity_level` - HIGH|MODERATE|LOW + * - `data_risk_level` - HIGH|MODERATE|LOW + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` or `!=`. + * Examples: + * * `project_id = 12345 AND status_code = 1` + * * `project_id = 12345 AND sensitivity_level = HIGH` + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 5; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `sensitivity_level` - HIGH|MODERATE|LOW + * - `data_risk_level` - HIGH|MODERATE|LOW + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` or `!=`. + * Examples: + * * `project_id = 12345 AND status_code = 1` + * * `project_id = 12345 AND sensitivity_level = HIGH` + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 5; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesResponse.php new file mode 100644 index 000000000000..3a2e2dab2e96 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesResponse.php @@ -0,0 +1,101 @@ +google.privacy.dlp.v2.ListProjectDataProfilesResponse + */ +class ListProjectDataProfilesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * List of data profiles. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ProjectDataProfile project_data_profiles = 1; + */ + private $project_data_profiles; + /** + * The next page token. + * + * 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<\Google\Cloud\Dlp\V2\ProjectDataProfile>|\Google\Protobuf\Internal\RepeatedField $project_data_profiles + * List of data profiles. + * @type string $next_page_token + * The next page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of data profiles. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ProjectDataProfile project_data_profiles = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getProjectDataProfiles() + { + return $this->project_data_profiles; + } + + /** + * List of data profiles. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ProjectDataProfile project_data_profiles = 1; + * @param array<\Google\Cloud\Dlp\V2\ProjectDataProfile>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setProjectDataProfiles($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ProjectDataProfile::class); + $this->project_data_profiles = $arr; + + return $this; + } + + /** + * The next page token. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * The next page token. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesRequest.php new file mode 100644 index 000000000000..81069a255cae --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesRequest.php @@ -0,0 +1,324 @@ +google.privacy.dlp.v2.ListStoredInfoTypesRequest + */ +class ListStoredInfoTypesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Page token to continue retrieval. Comes from the previous call + * to `ListStoredInfoTypes`. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * Size of the page. This value can be limited by the server. If zero server + * returns a page of max size 100. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + /** + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc, display_name, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the most recent version of the + * resource was created. + * - `state`: corresponds to the state of the resource. + * - `name`: corresponds to resource name. + * - `display_name`: corresponds to info type's display name. + * + * Generated from protobuf field string order_by = 4; + */ + protected $order_by = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + */ + protected $location_id = ''; + + /** + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\ListStoredInfoTypesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type string $page_token + * Page token to continue retrieval. Comes from the previous call + * to `ListStoredInfoTypes`. + * @type int $page_size + * Size of the page. This value can be limited by the server. If zero server + * returns a page of max size 100. + * @type string $order_by + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc, display_name, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the most recent version of the + * resource was created. + * - `state`: corresponds to the state of the resource. + * - `name`: corresponds to resource name. + * - `display_name`: corresponds to info type's display name. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * 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; + } + + /** + * Page token to continue retrieval. Comes from the previous call + * to `ListStoredInfoTypes`. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Page token to continue retrieval. Comes from the previous call + * to `ListStoredInfoTypes`. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * Size of the page. This value can be limited by the server. If zero server + * returns a page of max size 100. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Size of the page. This value can be limited by the server. If zero server + * returns a page of max size 100. + * + * 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; + } + + /** + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc, display_name, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the most recent version of the + * resource was created. + * - `state`: corresponds to the state of the resource. + * - `name`: corresponds to resource name. + * - `display_name`: corresponds to info type's display name. + * + * Generated from protobuf field string order_by = 4; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * Example: `name asc, display_name, create_time desc` + * Supported fields are: + * - `create_time`: corresponds to the time the most recent version of the + * resource was created. + * - `state`: corresponds to the state of the resource. + * - `name`: corresponds to resource name. + * - `display_name`: corresponds to info type's display name. + * + * Generated from protobuf field string order_by = 4; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 5; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesResponse.php new file mode 100644 index 000000000000..83a7019de840 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesResponse.php @@ -0,0 +1,105 @@ +google.privacy.dlp.v2.ListStoredInfoTypesResponse + */ +class ListStoredInfoTypesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * List of storedInfoTypes, up to page_size in ListStoredInfoTypesRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.StoredInfoType stored_info_types = 1; + */ + private $stored_info_types; + /** + * If the next page is available then the next page token to be used + * in the following ListStoredInfoTypes request. + * + * 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<\Google\Cloud\Dlp\V2\StoredInfoType>|\Google\Protobuf\Internal\RepeatedField $stored_info_types + * List of storedInfoTypes, up to page_size in ListStoredInfoTypesRequest. + * @type string $next_page_token + * If the next page is available then the next page token to be used + * in the following ListStoredInfoTypes request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of storedInfoTypes, up to page_size in ListStoredInfoTypesRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.StoredInfoType stored_info_types = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getStoredInfoTypes() + { + return $this->stored_info_types; + } + + /** + * List of storedInfoTypes, up to page_size in ListStoredInfoTypesRequest. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.StoredInfoType stored_info_types = 1; + * @param array<\Google\Cloud\Dlp\V2\StoredInfoType>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setStoredInfoTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\StoredInfoType::class); + $this->stored_info_types = $arr; + + return $this; + } + + /** + * If the next page is available then the next page token to be used + * in the following ListStoredInfoTypes request. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * If the next page is available then the next page token to be used + * in the following ListStoredInfoTypes request. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesRequest.php new file mode 100644 index 000000000000..1083018845d2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesRequest.php @@ -0,0 +1,383 @@ +google.privacy.dlp.v2.ListTableDataProfilesRequest + */ +class ListTableDataProfilesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the organization or project, for + * example `organizations/433245324/locations/europe` or + * `projects/project-id/locations/asia`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Page token to continue retrieval. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * Size of the page. This value can be limited by the server. If zero, server + * returns a page of max size 100. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + /** + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * Examples: + * * `project_id asc` + * * `table_id` + * * `sensitivity_level desc` + * Supported fields are: + * - `project_id`: The Google Cloud project ID. + * - `dataset_id`: The ID of a BigQuery dataset. + * - `table_id`: The ID of a BigQuery table. + * - `sensitivity_level`: How sensitive the data in a table is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * - `last_modified`: The last time the resource was modified. + * - `resource_visibility`: Visibility restriction for this resource. + * - `row_count`: Number of rows in this resource. + * + * Generated from protobuf field string order_by = 4; + */ + protected $order_by = ''; + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `project_id` - The Google Cloud project ID. + * - `dataset_id` - The BigQuery dataset ID. + * - `table_id` - The ID of the BigQuery table. + * - `sensitivity_level` - HIGH|MODERATE|LOW + * - `data_risk_level` - HIGH|MODERATE|LOW + * - `resource_visibility`: PUBLIC|RESTRICTED + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` or `!=`. + * Examples: + * * `project_id = 12345 AND status_code = 1` + * * `project_id = 12345 AND sensitivity_level = HIGH` + * * `project_id = 12345 AND resource_visibility = PUBLIC` + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 5; + */ + protected $filter = ''; + + /** + * @param string $parent Required. Resource name of the organization or project, for + * example `organizations/433245324/locations/europe` or + * `projects/project-id/locations/asia`. Please see + * {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\ListTableDataProfilesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the organization or project, for + * example `organizations/433245324/locations/europe` or + * `projects/project-id/locations/asia`. + * @type string $page_token + * Page token to continue retrieval. + * @type int $page_size + * Size of the page. This value can be limited by the server. If zero, server + * returns a page of max size 100. + * @type string $order_by + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * Examples: + * * `project_id asc` + * * `table_id` + * * `sensitivity_level desc` + * Supported fields are: + * - `project_id`: The Google Cloud project ID. + * - `dataset_id`: The ID of a BigQuery dataset. + * - `table_id`: The ID of a BigQuery table. + * - `sensitivity_level`: How sensitive the data in a table is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * - `last_modified`: The last time the resource was modified. + * - `resource_visibility`: Visibility restriction for this resource. + * - `row_count`: Number of rows in this resource. + * @type string $filter + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `project_id` - The Google Cloud project ID. + * - `dataset_id` - The BigQuery dataset ID. + * - `table_id` - The ID of the BigQuery table. + * - `sensitivity_level` - HIGH|MODERATE|LOW + * - `data_risk_level` - HIGH|MODERATE|LOW + * - `resource_visibility`: PUBLIC|RESTRICTED + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` or `!=`. + * Examples: + * * `project_id = 12345 AND status_code = 1` + * * `project_id = 12345 AND sensitivity_level = HIGH` + * * `project_id = 12345 AND resource_visibility = PUBLIC` + * The length of this field should be no more than 500 characters. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the organization or project, for + * example `organizations/433245324/locations/europe` or + * `projects/project-id/locations/asia`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the organization or project, for + * example `organizations/433245324/locations/europe` or + * `projects/project-id/locations/asia`. + * + * 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; + } + + /** + * Page token to continue retrieval. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Page token to continue retrieval. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * Size of the page. This value can be limited by the server. If zero, server + * returns a page of max size 100. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Size of the page. This value can be limited by the server. If zero, server + * returns a page of max size 100. + * + * 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; + } + + /** + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * Examples: + * * `project_id asc` + * * `table_id` + * * `sensitivity_level desc` + * Supported fields are: + * - `project_id`: The Google Cloud project ID. + * - `dataset_id`: The ID of a BigQuery dataset. + * - `table_id`: The ID of a BigQuery table. + * - `sensitivity_level`: How sensitive the data in a table is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * - `last_modified`: The last time the resource was modified. + * - `resource_visibility`: Visibility restriction for this resource. + * - `row_count`: Number of rows in this resource. + * + * Generated from protobuf field string order_by = 4; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * Examples: + * * `project_id asc` + * * `table_id` + * * `sensitivity_level desc` + * Supported fields are: + * - `project_id`: The Google Cloud project ID. + * - `dataset_id`: The ID of a BigQuery dataset. + * - `table_id`: The ID of a BigQuery table. + * - `sensitivity_level`: How sensitive the data in a table is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * - `last_modified`: The last time the resource was modified. + * - `resource_visibility`: Visibility restriction for this resource. + * - `row_count`: Number of rows in this resource. + * + * Generated from protobuf field string order_by = 4; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `project_id` - The Google Cloud project ID. + * - `dataset_id` - The BigQuery dataset ID. + * - `table_id` - The ID of the BigQuery table. + * - `sensitivity_level` - HIGH|MODERATE|LOW + * - `data_risk_level` - HIGH|MODERATE|LOW + * - `resource_visibility`: PUBLIC|RESTRICTED + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` or `!=`. + * Examples: + * * `project_id = 12345 AND status_code = 1` + * * `project_id = 12345 AND sensitivity_level = HIGH` + * * `project_id = 12345 AND resource_visibility = PUBLIC` + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 5; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Allows filtering. + * Supported syntax: + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `project_id` - The Google Cloud project ID. + * - `dataset_id` - The BigQuery dataset ID. + * - `table_id` - The ID of the BigQuery table. + * - `sensitivity_level` - HIGH|MODERATE|LOW + * - `data_risk_level` - HIGH|MODERATE|LOW + * - `resource_visibility`: PUBLIC|RESTRICTED + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` or `!=`. + * Examples: + * * `project_id = 12345 AND status_code = 1` + * * `project_id = 12345 AND sensitivity_level = HIGH` + * * `project_id = 12345 AND resource_visibility = PUBLIC` + * The length of this field should be no more than 500 characters. + * + * Generated from protobuf field string filter = 5; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesResponse.php new file mode 100644 index 000000000000..a6b2694c12a0 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesResponse.php @@ -0,0 +1,101 @@ +google.privacy.dlp.v2.ListTableDataProfilesResponse + */ +class ListTableDataProfilesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * List of data profiles. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.TableDataProfile table_data_profiles = 1; + */ + private $table_data_profiles; + /** + * The next page token. + * + * 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<\Google\Cloud\Dlp\V2\TableDataProfile>|\Google\Protobuf\Internal\RepeatedField $table_data_profiles + * List of data profiles. + * @type string $next_page_token + * The next page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of data profiles. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.TableDataProfile table_data_profiles = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTableDataProfiles() + { + return $this->table_data_profiles; + } + + /** + * List of data profiles. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.TableDataProfile table_data_profiles = 1; + * @param array<\Google\Cloud\Dlp\V2\TableDataProfile>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTableDataProfiles($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\TableDataProfile::class); + $this->table_data_profiles = $arr; + + return $this; + } + + /** + * The next page token. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * The next page token. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Location.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Location.php new file mode 100644 index 000000000000..c67c38368c6d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Location.php @@ -0,0 +1,227 @@ +google.privacy.dlp.v2.Location + */ +class Location extends \Google\Protobuf\Internal\Message +{ + /** + * Zero-based byte offsets delimiting the finding. + * These are relative to the finding's containing element. + * Note that when the content is not textual, this references + * the UTF-8 encoded textual representation of the content. + * Omitted if content is an image. + * + * Generated from protobuf field .google.privacy.dlp.v2.Range byte_range = 1; + */ + protected $byte_range = null; + /** + * Unicode character offsets delimiting the finding. + * These are relative to the finding's containing element. + * Provided when the content is text. + * + * Generated from protobuf field .google.privacy.dlp.v2.Range codepoint_range = 2; + */ + protected $codepoint_range = null; + /** + * List of nested objects pointing to the precise location of the finding + * within the file or record. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ContentLocation content_locations = 7; + */ + private $content_locations; + /** + * Information about the container where this finding occurred, if available. + * + * Generated from protobuf field .google.privacy.dlp.v2.Container container = 8; + */ + protected $container = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\Range $byte_range + * Zero-based byte offsets delimiting the finding. + * These are relative to the finding's containing element. + * Note that when the content is not textual, this references + * the UTF-8 encoded textual representation of the content. + * Omitted if content is an image. + * @type \Google\Cloud\Dlp\V2\Range $codepoint_range + * Unicode character offsets delimiting the finding. + * These are relative to the finding's containing element. + * Provided when the content is text. + * @type array<\Google\Cloud\Dlp\V2\ContentLocation>|\Google\Protobuf\Internal\RepeatedField $content_locations + * List of nested objects pointing to the precise location of the finding + * within the file or record. + * @type \Google\Cloud\Dlp\V2\Container $container + * Information about the container where this finding occurred, if available. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Zero-based byte offsets delimiting the finding. + * These are relative to the finding's containing element. + * Note that when the content is not textual, this references + * the UTF-8 encoded textual representation of the content. + * Omitted if content is an image. + * + * Generated from protobuf field .google.privacy.dlp.v2.Range byte_range = 1; + * @return \Google\Cloud\Dlp\V2\Range|null + */ + public function getByteRange() + { + return $this->byte_range; + } + + public function hasByteRange() + { + return isset($this->byte_range); + } + + public function clearByteRange() + { + unset($this->byte_range); + } + + /** + * Zero-based byte offsets delimiting the finding. + * These are relative to the finding's containing element. + * Note that when the content is not textual, this references + * the UTF-8 encoded textual representation of the content. + * Omitted if content is an image. + * + * Generated from protobuf field .google.privacy.dlp.v2.Range byte_range = 1; + * @param \Google\Cloud\Dlp\V2\Range $var + * @return $this + */ + public function setByteRange($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Range::class); + $this->byte_range = $var; + + return $this; + } + + /** + * Unicode character offsets delimiting the finding. + * These are relative to the finding's containing element. + * Provided when the content is text. + * + * Generated from protobuf field .google.privacy.dlp.v2.Range codepoint_range = 2; + * @return \Google\Cloud\Dlp\V2\Range|null + */ + public function getCodepointRange() + { + return $this->codepoint_range; + } + + public function hasCodepointRange() + { + return isset($this->codepoint_range); + } + + public function clearCodepointRange() + { + unset($this->codepoint_range); + } + + /** + * Unicode character offsets delimiting the finding. + * These are relative to the finding's containing element. + * Provided when the content is text. + * + * Generated from protobuf field .google.privacy.dlp.v2.Range codepoint_range = 2; + * @param \Google\Cloud\Dlp\V2\Range $var + * @return $this + */ + public function setCodepointRange($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Range::class); + $this->codepoint_range = $var; + + return $this; + } + + /** + * List of nested objects pointing to the precise location of the finding + * within the file or record. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ContentLocation content_locations = 7; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getContentLocations() + { + return $this->content_locations; + } + + /** + * List of nested objects pointing to the precise location of the finding + * within the file or record. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.ContentLocation content_locations = 7; + * @param array<\Google\Cloud\Dlp\V2\ContentLocation>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setContentLocations($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ContentLocation::class); + $this->content_locations = $arr; + + return $this; + } + + /** + * Information about the container where this finding occurred, if available. + * + * Generated from protobuf field .google.privacy.dlp.v2.Container container = 8; + * @return \Google\Cloud\Dlp\V2\Container|null + */ + public function getContainer() + { + return $this->container; + } + + public function hasContainer() + { + return isset($this->container); + } + + public function clearContainer() + { + unset($this->container); + } + + /** + * Information about the container where this finding occurred, if available. + * + * Generated from protobuf field .google.privacy.dlp.v2.Container container = 8; + * @param \Google\Cloud\Dlp\V2\Container $var + * @return $this + */ + public function setContainer($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Container::class); + $this->container = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Manual.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Manual.php new file mode 100644 index 000000000000..dbc05788c5db --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Manual.php @@ -0,0 +1,34 @@ +google.privacy.dlp.v2.Manual + */ +class Manual extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MatchingType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MatchingType.php new file mode 100644 index 000000000000..5d456a0dc111 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MatchingType.php @@ -0,0 +1,79 @@ +google.privacy.dlp.v2.MatchingType + */ +class MatchingType +{ + /** + * Invalid. + * + * Generated from protobuf enum MATCHING_TYPE_UNSPECIFIED = 0; + */ + const MATCHING_TYPE_UNSPECIFIED = 0; + /** + * Full match. + * - Dictionary: join of Dictionary results matched complete finding quote + * - Regex: all regex matches fill a finding quote start to end + * - Exclude info type: completely inside affecting info types findings + * + * Generated from protobuf enum MATCHING_TYPE_FULL_MATCH = 1; + */ + const MATCHING_TYPE_FULL_MATCH = 1; + /** + * Partial match. + * - Dictionary: at least one of the tokens in the finding matches + * - Regex: substring of the finding matches + * - Exclude info type: intersects with affecting info types findings + * + * Generated from protobuf enum MATCHING_TYPE_PARTIAL_MATCH = 2; + */ + const MATCHING_TYPE_PARTIAL_MATCH = 2; + /** + * Inverse match. + * - Dictionary: no tokens in the finding match the dictionary + * - Regex: finding doesn't match the regex + * - Exclude info type: no intersection with affecting info types findings + * + * Generated from protobuf enum MATCHING_TYPE_INVERSE_MATCH = 3; + */ + const MATCHING_TYPE_INVERSE_MATCH = 3; + + private static $valueToName = [ + self::MATCHING_TYPE_UNSPECIFIED => 'MATCHING_TYPE_UNSPECIFIED', + self::MATCHING_TYPE_FULL_MATCH => 'MATCHING_TYPE_FULL_MATCH', + self::MATCHING_TYPE_PARTIAL_MATCH => 'MATCHING_TYPE_PARTIAL_MATCH', + self::MATCHING_TYPE_INVERSE_MATCH => 'MATCHING_TYPE_INVERSE_MATCH', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataLocation.php new file mode 100644 index 000000000000..ff36bc6835ea --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataLocation.php @@ -0,0 +1,109 @@ +google.privacy.dlp.v2.MetadataLocation + */ +class MetadataLocation extends \Google\Protobuf\Internal\Message +{ + /** + * Type of metadata containing the finding. + * + * Generated from protobuf field .google.privacy.dlp.v2.MetadataType type = 1; + */ + protected $type = 0; + protected $label; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $type + * Type of metadata containing the finding. + * @type \Google\Cloud\Dlp\V2\StorageMetadataLabel $storage_label + * Storage metadata. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Type of metadata containing the finding. + * + * Generated from protobuf field .google.privacy.dlp.v2.MetadataType type = 1; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * Type of metadata containing the finding. + * + * Generated from protobuf field .google.privacy.dlp.v2.MetadataType type = 1; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\MetadataType::class); + $this->type = $var; + + return $this; + } + + /** + * Storage metadata. + * + * Generated from protobuf field .google.privacy.dlp.v2.StorageMetadataLabel storage_label = 3; + * @return \Google\Cloud\Dlp\V2\StorageMetadataLabel|null + */ + public function getStorageLabel() + { + return $this->readOneof(3); + } + + public function hasStorageLabel() + { + return $this->hasOneof(3); + } + + /** + * Storage metadata. + * + * Generated from protobuf field .google.privacy.dlp.v2.StorageMetadataLabel storage_label = 3; + * @param \Google\Cloud\Dlp\V2\StorageMetadataLabel $var + * @return $this + */ + public function setStorageLabel($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StorageMetadataLabel::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getLabel() + { + return $this->whichOneof("label"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataType.php new file mode 100644 index 000000000000..e99808ba042e --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataType.php @@ -0,0 +1,54 @@ +google.privacy.dlp.v2.MetadataType + */ +class MetadataType +{ + /** + * Unused + * + * Generated from protobuf enum METADATATYPE_UNSPECIFIED = 0; + */ + const METADATATYPE_UNSPECIFIED = 0; + /** + * General file metadata provided by Cloud Storage. + * + * Generated from protobuf enum STORAGE_METADATA = 2; + */ + const STORAGE_METADATA = 2; + + private static $valueToName = [ + self::METADATATYPE_UNSPECIFIED => 'METADATATYPE_UNSPECIFIED', + self::STORAGE_METADATA => 'STORAGE_METADATA', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/NullPercentageLevel.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/NullPercentageLevel.php new file mode 100644 index 000000000000..bcd45432e06a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/NullPercentageLevel.php @@ -0,0 +1,76 @@ +google.privacy.dlp.v2.NullPercentageLevel + */ +class NullPercentageLevel +{ + /** + * Unused. + * + * Generated from protobuf enum NULL_PERCENTAGE_LEVEL_UNSPECIFIED = 0; + */ + const NULL_PERCENTAGE_LEVEL_UNSPECIFIED = 0; + /** + * Very few null entries. + * + * Generated from protobuf enum NULL_PERCENTAGE_VERY_LOW = 1; + */ + const NULL_PERCENTAGE_VERY_LOW = 1; + /** + * Some null entries. + * + * Generated from protobuf enum NULL_PERCENTAGE_LOW = 2; + */ + const NULL_PERCENTAGE_LOW = 2; + /** + * A few null entries. + * + * Generated from protobuf enum NULL_PERCENTAGE_MEDIUM = 3; + */ + const NULL_PERCENTAGE_MEDIUM = 3; + /** + * A lot of null entries. + * + * Generated from protobuf enum NULL_PERCENTAGE_HIGH = 4; + */ + const NULL_PERCENTAGE_HIGH = 4; + + private static $valueToName = [ + self::NULL_PERCENTAGE_LEVEL_UNSPECIFIED => 'NULL_PERCENTAGE_LEVEL_UNSPECIFIED', + self::NULL_PERCENTAGE_VERY_LOW => 'NULL_PERCENTAGE_VERY_LOW', + self::NULL_PERCENTAGE_LOW => 'NULL_PERCENTAGE_LOW', + self::NULL_PERCENTAGE_MEDIUM => 'NULL_PERCENTAGE_MEDIUM', + self::NULL_PERCENTAGE_HIGH => 'NULL_PERCENTAGE_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); + } +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OtherInfoTypeSummary.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OtherInfoTypeSummary.php new file mode 100644 index 000000000000..ea7528a8112b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OtherInfoTypeSummary.php @@ -0,0 +1,153 @@ +google.privacy.dlp.v2.OtherInfoTypeSummary + */ +class OtherInfoTypeSummary extends \Google\Protobuf\Internal\Message +{ + /** + * The other infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + */ + protected $info_type = null; + /** + * Approximate percentage of non-null rows that contained data detected by + * this infotype. + * + * Generated from protobuf field int32 estimated_prevalence = 2; + */ + protected $estimated_prevalence = 0; + /** + * Whether this infoType was excluded from sensitivity and risk analysis due + * to factors such as low prevalence (subject to change). + * + * Generated from protobuf field bool excluded_from_analysis = 3; + */ + protected $excluded_from_analysis = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InfoType $info_type + * The other infoType. + * @type int $estimated_prevalence + * Approximate percentage of non-null rows that contained data detected by + * this infotype. + * @type bool $excluded_from_analysis + * Whether this infoType was excluded from sensitivity and risk analysis due + * to factors such as low prevalence (subject to change). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The other infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getInfoType() + { + return $this->info_type; + } + + public function hasInfoType() + { + return isset($this->info_type); + } + + public function clearInfoType() + { + unset($this->info_type); + } + + /** + * The other infoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_type = $var; + + return $this; + } + + /** + * Approximate percentage of non-null rows that contained data detected by + * this infotype. + * + * Generated from protobuf field int32 estimated_prevalence = 2; + * @return int + */ + public function getEstimatedPrevalence() + { + return $this->estimated_prevalence; + } + + /** + * Approximate percentage of non-null rows that contained data detected by + * this infotype. + * + * Generated from protobuf field int32 estimated_prevalence = 2; + * @param int $var + * @return $this + */ + public function setEstimatedPrevalence($var) + { + GPBUtil::checkInt32($var); + $this->estimated_prevalence = $var; + + return $this; + } + + /** + * Whether this infoType was excluded from sensitivity and risk analysis due + * to factors such as low prevalence (subject to change). + * + * Generated from protobuf field bool excluded_from_analysis = 3; + * @return bool + */ + public function getExcludedFromAnalysis() + { + return $this->excluded_from_analysis; + } + + /** + * Whether this infoType was excluded from sensitivity and risk analysis due + * to factors such as low prevalence (subject to change). + * + * Generated from protobuf field bool excluded_from_analysis = 3; + * @param bool $var + * @return $this + */ + public function setExcludedFromAnalysis($var) + { + GPBUtil::checkBool($var); + $this->excluded_from_analysis = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig.php new file mode 100644 index 000000000000..cd7b054981d8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig.php @@ -0,0 +1,174 @@ +google.privacy.dlp.v2.OutputStorageConfig + */ +class OutputStorageConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Schema used for writing the findings for Inspect jobs. This field is only + * used for Inspect and must be unspecified for Risk jobs. Columns are derived + * from the `Finding` object. If appending to an existing table, any columns + * from the predefined schema that are missing will be added. No columns in + * the existing table will be deleted. + * If unspecified, then all available columns will be used for a new table or + * an (existing) table with no schema, and no changes will be made to an + * existing table that has a schema. + * Only for use with external storage. + * + * Generated from protobuf field .google.privacy.dlp.v2.OutputStorageConfig.OutputSchema output_schema = 3; + */ + protected $output_schema = 0; + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\BigQueryTable $table + * Store findings in an existing table or a new table in an existing + * dataset. If table_id is not set a new one will be generated + * for you with the following format: + * dlp_googleapis_yyyy_mm_dd_[dlp_job_id]. Pacific time zone will be used + * for generating the date details. + * For Inspect, each column in an existing output table must have the same + * name, type, and mode of a field in the `Finding` object. + * For Risk, an existing output table should be the output of a previous + * Risk analysis job run on the same source table, with the same privacy + * metric and quasi-identifiers. Risk jobs that analyze the same table but + * compute a different privacy metric, or use different sets of + * quasi-identifiers, cannot store their results in the same table. + * @type int $output_schema + * Schema used for writing the findings for Inspect jobs. This field is only + * used for Inspect and must be unspecified for Risk jobs. Columns are derived + * from the `Finding` object. If appending to an existing table, any columns + * from the predefined schema that are missing will be added. No columns in + * the existing table will be deleted. + * If unspecified, then all available columns will be used for a new table or + * an (existing) table with no schema, and no changes will be made to an + * existing table that has a schema. + * Only for use with external storage. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Store findings in an existing table or a new table in an existing + * dataset. If table_id is not set a new one will be generated + * for you with the following format: + * dlp_googleapis_yyyy_mm_dd_[dlp_job_id]. Pacific time zone will be used + * for generating the date details. + * For Inspect, each column in an existing output table must have the same + * name, type, and mode of a field in the `Finding` object. + * For Risk, an existing output table should be the output of a previous + * Risk analysis job run on the same source table, with the same privacy + * metric and quasi-identifiers. Risk jobs that analyze the same table but + * compute a different privacy metric, or use different sets of + * quasi-identifiers, cannot store their results in the same table. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; + * @return \Google\Cloud\Dlp\V2\BigQueryTable|null + */ + public function getTable() + { + return $this->readOneof(1); + } + + public function hasTable() + { + return $this->hasOneof(1); + } + + /** + * Store findings in an existing table or a new table in an existing + * dataset. If table_id is not set a new one will be generated + * for you with the following format: + * dlp_googleapis_yyyy_mm_dd_[dlp_job_id]. Pacific time zone will be used + * for generating the date details. + * For Inspect, each column in an existing output table must have the same + * name, type, and mode of a field in the `Finding` object. + * For Risk, an existing output table should be the output of a previous + * Risk analysis job run on the same source table, with the same privacy + * metric and quasi-identifiers. Risk jobs that analyze the same table but + * compute a different privacy metric, or use different sets of + * quasi-identifiers, cannot store their results in the same table. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; + * @param \Google\Cloud\Dlp\V2\BigQueryTable $var + * @return $this + */ + public function setTable($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Schema used for writing the findings for Inspect jobs. This field is only + * used for Inspect and must be unspecified for Risk jobs. Columns are derived + * from the `Finding` object. If appending to an existing table, any columns + * from the predefined schema that are missing will be added. No columns in + * the existing table will be deleted. + * If unspecified, then all available columns will be used for a new table or + * an (existing) table with no schema, and no changes will be made to an + * existing table that has a schema. + * Only for use with external storage. + * + * Generated from protobuf field .google.privacy.dlp.v2.OutputStorageConfig.OutputSchema output_schema = 3; + * @return int + */ + public function getOutputSchema() + { + return $this->output_schema; + } + + /** + * Schema used for writing the findings for Inspect jobs. This field is only + * used for Inspect and must be unspecified for Risk jobs. Columns are derived + * from the `Finding` object. If appending to an existing table, any columns + * from the predefined schema that are missing will be added. No columns in + * the existing table will be deleted. + * If unspecified, then all available columns will be used for a new table or + * an (existing) table with no schema, and no changes will be made to an + * existing table that has a schema. + * Only for use with external storage. + * + * Generated from protobuf field .google.privacy.dlp.v2.OutputStorageConfig.OutputSchema output_schema = 3; + * @param int $var + * @return $this + */ + public function setOutputSchema($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\OutputStorageConfig\OutputSchema::class); + $this->output_schema = $var; + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig/OutputSchema.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig/OutputSchema.php new file mode 100644 index 000000000000..561e97f7d483 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig/OutputSchema.php @@ -0,0 +1,87 @@ +google.privacy.dlp.v2.OutputStorageConfig.OutputSchema + */ +class OutputSchema +{ + /** + * Unused. + * + * Generated from protobuf enum OUTPUT_SCHEMA_UNSPECIFIED = 0; + */ + const OUTPUT_SCHEMA_UNSPECIFIED = 0; + /** + * Basic schema including only `info_type`, `quote`, `certainty`, and + * `timestamp`. + * + * Generated from protobuf enum BASIC_COLUMNS = 1; + */ + const BASIC_COLUMNS = 1; + /** + * Schema tailored to findings from scanning Cloud Storage. + * + * Generated from protobuf enum GCS_COLUMNS = 2; + */ + const GCS_COLUMNS = 2; + /** + * Schema tailored to findings from scanning Google Datastore. + * + * Generated from protobuf enum DATASTORE_COLUMNS = 3; + */ + const DATASTORE_COLUMNS = 3; + /** + * Schema tailored to findings from scanning Google BigQuery. + * + * Generated from protobuf enum BIG_QUERY_COLUMNS = 4; + */ + const BIG_QUERY_COLUMNS = 4; + /** + * Schema containing all columns. + * + * Generated from protobuf enum ALL_COLUMNS = 5; + */ + const ALL_COLUMNS = 5; + + private static $valueToName = [ + self::OUTPUT_SCHEMA_UNSPECIFIED => 'OUTPUT_SCHEMA_UNSPECIFIED', + self::BASIC_COLUMNS => 'BASIC_COLUMNS', + self::GCS_COLUMNS => 'GCS_COLUMNS', + self::DATASTORE_COLUMNS => 'DATASTORE_COLUMNS', + self::BIG_QUERY_COLUMNS => 'BIG_QUERY_COLUMNS', + self::ALL_COLUMNS => 'ALL_COLUMNS', + ]; + + 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(OutputSchema::class, \Google\Cloud\Dlp\V2\OutputStorageConfig_OutputSchema::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PartitionId.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PartitionId.php new file mode 100644 index 000000000000..1f8527860eb1 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PartitionId.php @@ -0,0 +1,105 @@ +google.privacy.dlp.v2.PartitionId + */ +class PartitionId extends \Google\Protobuf\Internal\Message +{ + /** + * The ID of the project to which the entities belong. + * + * Generated from protobuf field string project_id = 2; + */ + protected $project_id = ''; + /** + * If not empty, the ID of the namespace to which the entities belong. + * + * Generated from protobuf field string namespace_id = 4; + */ + protected $namespace_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $project_id + * The ID of the project to which the entities belong. + * @type string $namespace_id + * If not empty, the ID of the namespace to which the entities belong. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * The ID of the project to which the entities belong. + * + * Generated from protobuf field string project_id = 2; + * @return string + */ + public function getProjectId() + { + return $this->project_id; + } + + /** + * The ID of the project to which the entities belong. + * + * 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; + } + + /** + * If not empty, the ID of the namespace to which the entities belong. + * + * Generated from protobuf field string namespace_id = 4; + * @return string + */ + public function getNamespaceId() + { + return $this->namespace_id; + } + + /** + * If not empty, the ID of the namespace to which the entities belong. + * + * Generated from protobuf field string namespace_id = 4; + * @param string $var + * @return $this + */ + public function setNamespaceId($var) + { + GPBUtil::checkString($var, True); + $this->namespace_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrimitiveTransformation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrimitiveTransformation.php new file mode 100644 index 000000000000..3e157d333e06 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrimitiveTransformation.php @@ -0,0 +1,438 @@ +google.privacy.dlp.v2.PrimitiveTransformation + */ +class PrimitiveTransformation extends \Google\Protobuf\Internal\Message +{ + protected $transformation; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\ReplaceValueConfig $replace_config + * Replace with a specified value. + * @type \Google\Cloud\Dlp\V2\RedactConfig $redact_config + * Redact + * @type \Google\Cloud\Dlp\V2\CharacterMaskConfig $character_mask_config + * Mask + * @type \Google\Cloud\Dlp\V2\CryptoReplaceFfxFpeConfig $crypto_replace_ffx_fpe_config + * Ffx-Fpe + * @type \Google\Cloud\Dlp\V2\FixedSizeBucketingConfig $fixed_size_bucketing_config + * Fixed size bucketing + * @type \Google\Cloud\Dlp\V2\BucketingConfig $bucketing_config + * Bucketing + * @type \Google\Cloud\Dlp\V2\ReplaceWithInfoTypeConfig $replace_with_info_type_config + * Replace with infotype + * @type \Google\Cloud\Dlp\V2\TimePartConfig $time_part_config + * Time extraction + * @type \Google\Cloud\Dlp\V2\CryptoHashConfig $crypto_hash_config + * Crypto + * @type \Google\Cloud\Dlp\V2\DateShiftConfig $date_shift_config + * Date Shift + * @type \Google\Cloud\Dlp\V2\CryptoDeterministicConfig $crypto_deterministic_config + * Deterministic Crypto + * @type \Google\Cloud\Dlp\V2\ReplaceDictionaryConfig $replace_dictionary_config + * Replace with a value randomly drawn (with replacement) from a dictionary. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Replace with a specified value. + * + * Generated from protobuf field .google.privacy.dlp.v2.ReplaceValueConfig replace_config = 1; + * @return \Google\Cloud\Dlp\V2\ReplaceValueConfig|null + */ + public function getReplaceConfig() + { + return $this->readOneof(1); + } + + public function hasReplaceConfig() + { + return $this->hasOneof(1); + } + + /** + * Replace with a specified value. + * + * Generated from protobuf field .google.privacy.dlp.v2.ReplaceValueConfig replace_config = 1; + * @param \Google\Cloud\Dlp\V2\ReplaceValueConfig $var + * @return $this + */ + public function setReplaceConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ReplaceValueConfig::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Redact + * + * Generated from protobuf field .google.privacy.dlp.v2.RedactConfig redact_config = 2; + * @return \Google\Cloud\Dlp\V2\RedactConfig|null + */ + public function getRedactConfig() + { + return $this->readOneof(2); + } + + public function hasRedactConfig() + { + return $this->hasOneof(2); + } + + /** + * Redact + * + * Generated from protobuf field .google.privacy.dlp.v2.RedactConfig redact_config = 2; + * @param \Google\Cloud\Dlp\V2\RedactConfig $var + * @return $this + */ + public function setRedactConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RedactConfig::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Mask + * + * Generated from protobuf field .google.privacy.dlp.v2.CharacterMaskConfig character_mask_config = 3; + * @return \Google\Cloud\Dlp\V2\CharacterMaskConfig|null + */ + public function getCharacterMaskConfig() + { + return $this->readOneof(3); + } + + public function hasCharacterMaskConfig() + { + return $this->hasOneof(3); + } + + /** + * Mask + * + * Generated from protobuf field .google.privacy.dlp.v2.CharacterMaskConfig character_mask_config = 3; + * @param \Google\Cloud\Dlp\V2\CharacterMaskConfig $var + * @return $this + */ + public function setCharacterMaskConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CharacterMaskConfig::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Ffx-Fpe + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; + * @return \Google\Cloud\Dlp\V2\CryptoReplaceFfxFpeConfig|null + */ + public function getCryptoReplaceFfxFpeConfig() + { + return $this->readOneof(4); + } + + public function hasCryptoReplaceFfxFpeConfig() + { + return $this->hasOneof(4); + } + + /** + * Ffx-Fpe + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; + * @param \Google\Cloud\Dlp\V2\CryptoReplaceFfxFpeConfig $var + * @return $this + */ + public function setCryptoReplaceFfxFpeConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoReplaceFfxFpeConfig::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Fixed size bucketing + * + * Generated from protobuf field .google.privacy.dlp.v2.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; + * @return \Google\Cloud\Dlp\V2\FixedSizeBucketingConfig|null + */ + public function getFixedSizeBucketingConfig() + { + return $this->readOneof(5); + } + + public function hasFixedSizeBucketingConfig() + { + return $this->hasOneof(5); + } + + /** + * Fixed size bucketing + * + * Generated from protobuf field .google.privacy.dlp.v2.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; + * @param \Google\Cloud\Dlp\V2\FixedSizeBucketingConfig $var + * @return $this + */ + public function setFixedSizeBucketingConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FixedSizeBucketingConfig::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * Bucketing + * + * Generated from protobuf field .google.privacy.dlp.v2.BucketingConfig bucketing_config = 6; + * @return \Google\Cloud\Dlp\V2\BucketingConfig|null + */ + public function getBucketingConfig() + { + return $this->readOneof(6); + } + + public function hasBucketingConfig() + { + return $this->hasOneof(6); + } + + /** + * Bucketing + * + * Generated from protobuf field .google.privacy.dlp.v2.BucketingConfig bucketing_config = 6; + * @param \Google\Cloud\Dlp\V2\BucketingConfig $var + * @return $this + */ + public function setBucketingConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BucketingConfig::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * Replace with infotype + * + * Generated from protobuf field .google.privacy.dlp.v2.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; + * @return \Google\Cloud\Dlp\V2\ReplaceWithInfoTypeConfig|null + */ + public function getReplaceWithInfoTypeConfig() + { + return $this->readOneof(7); + } + + public function hasReplaceWithInfoTypeConfig() + { + return $this->hasOneof(7); + } + + /** + * Replace with infotype + * + * Generated from protobuf field .google.privacy.dlp.v2.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; + * @param \Google\Cloud\Dlp\V2\ReplaceWithInfoTypeConfig $var + * @return $this + */ + public function setReplaceWithInfoTypeConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ReplaceWithInfoTypeConfig::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * Time extraction + * + * Generated from protobuf field .google.privacy.dlp.v2.TimePartConfig time_part_config = 8; + * @return \Google\Cloud\Dlp\V2\TimePartConfig|null + */ + public function getTimePartConfig() + { + return $this->readOneof(8); + } + + public function hasTimePartConfig() + { + return $this->hasOneof(8); + } + + /** + * Time extraction + * + * Generated from protobuf field .google.privacy.dlp.v2.TimePartConfig time_part_config = 8; + * @param \Google\Cloud\Dlp\V2\TimePartConfig $var + * @return $this + */ + public function setTimePartConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TimePartConfig::class); + $this->writeOneof(8, $var); + + return $this; + } + + /** + * Crypto + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoHashConfig crypto_hash_config = 9; + * @return \Google\Cloud\Dlp\V2\CryptoHashConfig|null + */ + public function getCryptoHashConfig() + { + return $this->readOneof(9); + } + + public function hasCryptoHashConfig() + { + return $this->hasOneof(9); + } + + /** + * Crypto + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoHashConfig crypto_hash_config = 9; + * @param \Google\Cloud\Dlp\V2\CryptoHashConfig $var + * @return $this + */ + public function setCryptoHashConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoHashConfig::class); + $this->writeOneof(9, $var); + + return $this; + } + + /** + * Date Shift + * + * Generated from protobuf field .google.privacy.dlp.v2.DateShiftConfig date_shift_config = 11; + * @return \Google\Cloud\Dlp\V2\DateShiftConfig|null + */ + public function getDateShiftConfig() + { + return $this->readOneof(11); + } + + public function hasDateShiftConfig() + { + return $this->hasOneof(11); + } + + /** + * Date Shift + * + * Generated from protobuf field .google.privacy.dlp.v2.DateShiftConfig date_shift_config = 11; + * @param \Google\Cloud\Dlp\V2\DateShiftConfig $var + * @return $this + */ + public function setDateShiftConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DateShiftConfig::class); + $this->writeOneof(11, $var); + + return $this; + } + + /** + * Deterministic Crypto + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoDeterministicConfig crypto_deterministic_config = 12; + * @return \Google\Cloud\Dlp\V2\CryptoDeterministicConfig|null + */ + public function getCryptoDeterministicConfig() + { + return $this->readOneof(12); + } + + public function hasCryptoDeterministicConfig() + { + return $this->hasOneof(12); + } + + /** + * Deterministic Crypto + * + * Generated from protobuf field .google.privacy.dlp.v2.CryptoDeterministicConfig crypto_deterministic_config = 12; + * @param \Google\Cloud\Dlp\V2\CryptoDeterministicConfig $var + * @return $this + */ + public function setCryptoDeterministicConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoDeterministicConfig::class); + $this->writeOneof(12, $var); + + return $this; + } + + /** + * Replace with a value randomly drawn (with replacement) from a dictionary. + * + * Generated from protobuf field .google.privacy.dlp.v2.ReplaceDictionaryConfig replace_dictionary_config = 13; + * @return \Google\Cloud\Dlp\V2\ReplaceDictionaryConfig|null + */ + public function getReplaceDictionaryConfig() + { + return $this->readOneof(13); + } + + public function hasReplaceDictionaryConfig() + { + return $this->hasOneof(13); + } + + /** + * Replace with a value randomly drawn (with replacement) from a dictionary. + * + * Generated from protobuf field .google.privacy.dlp.v2.ReplaceDictionaryConfig replace_dictionary_config = 13; + * @param \Google\Cloud\Dlp\V2\ReplaceDictionaryConfig $var + * @return $this + */ + public function setReplaceDictionaryConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ReplaceDictionaryConfig::class); + $this->writeOneof(13, $var); + + return $this; + } + + /** + * @return string + */ + public function getTransformation() + { + return $this->whichOneof("transformation"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric.php new file mode 100644 index 000000000000..8b9475f69955 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric.php @@ -0,0 +1,240 @@ +google.privacy.dlp.v2.PrivacyMetric + */ +class PrivacyMetric extends \Google\Protobuf\Internal\Message +{ + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\PrivacyMetric\NumericalStatsConfig $numerical_stats_config + * Numerical stats + * @type \Google\Cloud\Dlp\V2\PrivacyMetric\CategoricalStatsConfig $categorical_stats_config + * Categorical stats + * @type \Google\Cloud\Dlp\V2\PrivacyMetric\KAnonymityConfig $k_anonymity_config + * K-anonymity + * @type \Google\Cloud\Dlp\V2\PrivacyMetric\LDiversityConfig $l_diversity_config + * l-diversity + * @type \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig $k_map_estimation_config + * k-map + * @type \Google\Cloud\Dlp\V2\PrivacyMetric\DeltaPresenceEstimationConfig $delta_presence_estimation_config + * delta-presence + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Numerical stats + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; + * @return \Google\Cloud\Dlp\V2\PrivacyMetric\NumericalStatsConfig|null + */ + public function getNumericalStatsConfig() + { + return $this->readOneof(1); + } + + public function hasNumericalStatsConfig() + { + return $this->hasOneof(1); + } + + /** + * Numerical stats + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; + * @param \Google\Cloud\Dlp\V2\PrivacyMetric\NumericalStatsConfig $var + * @return $this + */ + public function setNumericalStatsConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric\NumericalStatsConfig::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Categorical stats + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; + * @return \Google\Cloud\Dlp\V2\PrivacyMetric\CategoricalStatsConfig|null + */ + public function getCategoricalStatsConfig() + { + return $this->readOneof(2); + } + + public function hasCategoricalStatsConfig() + { + return $this->hasOneof(2); + } + + /** + * Categorical stats + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; + * @param \Google\Cloud\Dlp\V2\PrivacyMetric\CategoricalStatsConfig $var + * @return $this + */ + public function setCategoricalStatsConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric\CategoricalStatsConfig::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * K-anonymity + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; + * @return \Google\Cloud\Dlp\V2\PrivacyMetric\KAnonymityConfig|null + */ + public function getKAnonymityConfig() + { + return $this->readOneof(3); + } + + public function hasKAnonymityConfig() + { + return $this->hasOneof(3); + } + + /** + * K-anonymity + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; + * @param \Google\Cloud\Dlp\V2\PrivacyMetric\KAnonymityConfig $var + * @return $this + */ + public function setKAnonymityConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric\KAnonymityConfig::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * l-diversity + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.LDiversityConfig l_diversity_config = 4; + * @return \Google\Cloud\Dlp\V2\PrivacyMetric\LDiversityConfig|null + */ + public function getLDiversityConfig() + { + return $this->readOneof(4); + } + + public function hasLDiversityConfig() + { + return $this->hasOneof(4); + } + + /** + * l-diversity + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.LDiversityConfig l_diversity_config = 4; + * @param \Google\Cloud\Dlp\V2\PrivacyMetric\LDiversityConfig $var + * @return $this + */ + public function setLDiversityConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric\LDiversityConfig::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * k-map + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig k_map_estimation_config = 5; + * @return \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig|null + */ + public function getKMapEstimationConfig() + { + return $this->readOneof(5); + } + + public function hasKMapEstimationConfig() + { + return $this->hasOneof(5); + } + + /** + * k-map + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig k_map_estimation_config = 5; + * @param \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig $var + * @return $this + */ + public function setKMapEstimationConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * delta-presence + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.DeltaPresenceEstimationConfig delta_presence_estimation_config = 6; + * @return \Google\Cloud\Dlp\V2\PrivacyMetric\DeltaPresenceEstimationConfig|null + */ + public function getDeltaPresenceEstimationConfig() + { + return $this->readOneof(6); + } + + public function hasDeltaPresenceEstimationConfig() + { + return $this->hasOneof(6); + } + + /** + * delta-presence + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.DeltaPresenceEstimationConfig delta_presence_estimation_config = 6; + * @param \Google\Cloud\Dlp\V2\PrivacyMetric\DeltaPresenceEstimationConfig $var + * @return $this + */ + public function setDeltaPresenceEstimationConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric\DeltaPresenceEstimationConfig::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/CategoricalStatsConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/CategoricalStatsConfig.php new file mode 100644 index 000000000000..d00835a5269d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/CategoricalStatsConfig.php @@ -0,0 +1,93 @@ +google.privacy.dlp.v2.PrivacyMetric.CategoricalStatsConfig + */ +class CategoricalStatsConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Field to compute categorical stats on. All column types are + * supported except for arrays and structs. However, it may be more + * informative to use NumericalStats when the field type is supported, + * depending on the data. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + */ + protected $field = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\FieldId $field + * Field to compute categorical stats on. All column types are + * supported except for arrays and structs. However, it may be more + * informative to use NumericalStats when the field type is supported, + * depending on the data. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Field to compute categorical stats on. All column types are + * supported except for arrays and structs. However, it may be more + * informative to use NumericalStats when the field type is supported, + * depending on the data. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getField() + { + return $this->field; + } + + public function hasField() + { + return isset($this->field); + } + + public function clearField() + { + unset($this->field); + } + + /** + * Field to compute categorical stats on. All column types are + * supported except for arrays and structs. However, it may be more + * informative to use NumericalStats when the field type is supported, + * depending on the data. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setField($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->field = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(CategoricalStatsConfig::class, \Google\Cloud\Dlp\V2\PrivacyMetric_CategoricalStatsConfig::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/DeltaPresenceEstimationConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/DeltaPresenceEstimationConfig.php new file mode 100644 index 000000000000..101c63e5430c --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/DeltaPresenceEstimationConfig.php @@ -0,0 +1,161 @@ +google.privacy.dlp.v2.PrivacyMetric.DeltaPresenceEstimationConfig + */ +class DeltaPresenceEstimationConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Fields considered to be quasi-identifiers. No two fields can + * have the same tag. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.QuasiId quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + private $quasi_ids; + /** + * ISO 3166-1 alpha-2 region code to use in the statistical modeling. + * Set if no column is tagged with a region-specific InfoType (like + * US_ZIP_5) or a region code. + * + * Generated from protobuf field string region_code = 2; + */ + protected $region_code = ''; + /** + * Several auxiliary tables can be used in the analysis. Each custom_tag + * used to tag a quasi-identifiers field must appear in exactly one + * field of one auxiliary table. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.StatisticalTable auxiliary_tables = 3; + */ + private $auxiliary_tables; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\QuasiId>|\Google\Protobuf\Internal\RepeatedField $quasi_ids + * Required. Fields considered to be quasi-identifiers. No two fields can + * have the same tag. + * @type string $region_code + * ISO 3166-1 alpha-2 region code to use in the statistical modeling. + * Set if no column is tagged with a region-specific InfoType (like + * US_ZIP_5) or a region code. + * @type array<\Google\Cloud\Dlp\V2\StatisticalTable>|\Google\Protobuf\Internal\RepeatedField $auxiliary_tables + * Several auxiliary tables can be used in the analysis. Each custom_tag + * used to tag a quasi-identifiers field must appear in exactly one + * field of one auxiliary table. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Fields considered to be quasi-identifiers. No two fields can + * have the same tag. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.QuasiId quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getQuasiIds() + { + return $this->quasi_ids; + } + + /** + * Required. Fields considered to be quasi-identifiers. No two fields can + * have the same tag. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.QuasiId quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param array<\Google\Cloud\Dlp\V2\QuasiId>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setQuasiIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\QuasiId::class); + $this->quasi_ids = $arr; + + return $this; + } + + /** + * ISO 3166-1 alpha-2 region code to use in the statistical modeling. + * Set if no column is tagged with a region-specific InfoType (like + * US_ZIP_5) or a region code. + * + * Generated from protobuf field string region_code = 2; + * @return string + */ + public function getRegionCode() + { + return $this->region_code; + } + + /** + * ISO 3166-1 alpha-2 region code to use in the statistical modeling. + * Set if no column is tagged with a region-specific InfoType (like + * US_ZIP_5) or a region code. + * + * Generated from protobuf field string region_code = 2; + * @param string $var + * @return $this + */ + public function setRegionCode($var) + { + GPBUtil::checkString($var, True); + $this->region_code = $var; + + return $this; + } + + /** + * Several auxiliary tables can be used in the analysis. Each custom_tag + * used to tag a quasi-identifiers field must appear in exactly one + * field of one auxiliary table. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.StatisticalTable auxiliary_tables = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAuxiliaryTables() + { + return $this->auxiliary_tables; + } + + /** + * Several auxiliary tables can be used in the analysis. Each custom_tag + * used to tag a quasi-identifiers field must appear in exactly one + * field of one auxiliary table. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.StatisticalTable auxiliary_tables = 3; + * @param array<\Google\Cloud\Dlp\V2\StatisticalTable>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAuxiliaryTables($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\StatisticalTable::class); + $this->auxiliary_tables = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(DeltaPresenceEstimationConfig::class, \Google\Cloud\Dlp\V2\PrivacyMetric_DeltaPresenceEstimationConfig::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KAnonymityConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KAnonymityConfig.php new file mode 100644 index 000000000000..0628b25d574a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KAnonymityConfig.php @@ -0,0 +1,162 @@ +google.privacy.dlp.v2.PrivacyMetric.KAnonymityConfig + */ +class KAnonymityConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Set of fields to compute k-anonymity over. When multiple fields are + * specified, they are considered a single composite key. Structs and + * repeated data types are not supported; however, nested fields are + * supported so long as they are not structs themselves or nested within + * a repeated field. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId quasi_ids = 1; + */ + private $quasi_ids; + /** + * Message indicating that multiple rows might be associated to a + * single individual. If the same entity_id is associated to multiple + * quasi-identifier tuples over distinct rows, we consider the entire + * collection of tuples as the composite quasi-identifier. This collection + * is a multiset: the order in which the different tuples appear in the + * dataset is ignored, but their frequency is taken into account. + * Important note: a maximum of 1000 rows can be associated to a single + * entity ID. If more rows are associated with the same entity ID, some + * might be ignored. + * + * Generated from protobuf field .google.privacy.dlp.v2.EntityId entity_id = 2; + */ + protected $entity_id = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $quasi_ids + * Set of fields to compute k-anonymity over. When multiple fields are + * specified, they are considered a single composite key. Structs and + * repeated data types are not supported; however, nested fields are + * supported so long as they are not structs themselves or nested within + * a repeated field. + * @type \Google\Cloud\Dlp\V2\EntityId $entity_id + * Message indicating that multiple rows might be associated to a + * single individual. If the same entity_id is associated to multiple + * quasi-identifier tuples over distinct rows, we consider the entire + * collection of tuples as the composite quasi-identifier. This collection + * is a multiset: the order in which the different tuples appear in the + * dataset is ignored, but their frequency is taken into account. + * Important note: a maximum of 1000 rows can be associated to a single + * entity ID. If more rows are associated with the same entity ID, some + * might be ignored. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Set of fields to compute k-anonymity over. When multiple fields are + * specified, they are considered a single composite key. Structs and + * repeated data types are not supported; however, nested fields are + * supported so long as they are not structs themselves or nested within + * a repeated field. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId quasi_ids = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getQuasiIds() + { + return $this->quasi_ids; + } + + /** + * Set of fields to compute k-anonymity over. When multiple fields are + * specified, they are considered a single composite key. Structs and + * repeated data types are not supported; however, nested fields are + * supported so long as they are not structs themselves or nested within + * a repeated field. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId quasi_ids = 1; + * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setQuasiIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); + $this->quasi_ids = $arr; + + return $this; + } + + /** + * Message indicating that multiple rows might be associated to a + * single individual. If the same entity_id is associated to multiple + * quasi-identifier tuples over distinct rows, we consider the entire + * collection of tuples as the composite quasi-identifier. This collection + * is a multiset: the order in which the different tuples appear in the + * dataset is ignored, but their frequency is taken into account. + * Important note: a maximum of 1000 rows can be associated to a single + * entity ID. If more rows are associated with the same entity ID, some + * might be ignored. + * + * Generated from protobuf field .google.privacy.dlp.v2.EntityId entity_id = 2; + * @return \Google\Cloud\Dlp\V2\EntityId|null + */ + public function getEntityId() + { + return $this->entity_id; + } + + public function hasEntityId() + { + return isset($this->entity_id); + } + + public function clearEntityId() + { + unset($this->entity_id); + } + + /** + * Message indicating that multiple rows might be associated to a + * single individual. If the same entity_id is associated to multiple + * quasi-identifier tuples over distinct rows, we consider the entire + * collection of tuples as the composite quasi-identifier. This collection + * is a multiset: the order in which the different tuples appear in the + * dataset is ignored, but their frequency is taken into account. + * Important note: a maximum of 1000 rows can be associated to a single + * entity ID. If more rows are associated with the same entity ID, some + * might be ignored. + * + * Generated from protobuf field .google.privacy.dlp.v2.EntityId entity_id = 2; + * @param \Google\Cloud\Dlp\V2\EntityId $var + * @return $this + */ + public function setEntityId($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\EntityId::class); + $this->entity_id = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(KAnonymityConfig::class, \Google\Cloud\Dlp\V2\PrivacyMetric_KAnonymityConfig::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig.php new file mode 100644 index 000000000000..036f106c6a86 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig.php @@ -0,0 +1,163 @@ +google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig + */ +class KMapEstimationConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Fields considered to be quasi-identifiers. No two columns can + * have the same tag. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.TaggedField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + private $quasi_ids; + /** + * ISO 3166-1 alpha-2 region code to use in the statistical modeling. + * Set if no column is tagged with a region-specific InfoType (like + * US_ZIP_5) or a region code. + * + * Generated from protobuf field string region_code = 2; + */ + protected $region_code = ''; + /** + * Several auxiliary tables can be used in the analysis. Each custom_tag + * used to tag a quasi-identifiers column must appear in exactly one column + * of one auxiliary table. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable auxiliary_tables = 3; + */ + private $auxiliary_tables; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\TaggedField>|\Google\Protobuf\Internal\RepeatedField $quasi_ids + * Required. Fields considered to be quasi-identifiers. No two columns can + * have the same tag. + * @type string $region_code + * ISO 3166-1 alpha-2 region code to use in the statistical modeling. + * Set if no column is tagged with a region-specific InfoType (like + * US_ZIP_5) or a region code. + * @type array<\Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\AuxiliaryTable>|\Google\Protobuf\Internal\RepeatedField $auxiliary_tables + * Several auxiliary tables can be used in the analysis. Each custom_tag + * used to tag a quasi-identifiers column must appear in exactly one column + * of one auxiliary table. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Fields considered to be quasi-identifiers. No two columns can + * have the same tag. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.TaggedField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getQuasiIds() + { + return $this->quasi_ids; + } + + /** + * Required. Fields considered to be quasi-identifiers. No two columns can + * have the same tag. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.TaggedField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param array<\Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\TaggedField>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setQuasiIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\TaggedField::class); + $this->quasi_ids = $arr; + + return $this; + } + + /** + * ISO 3166-1 alpha-2 region code to use in the statistical modeling. + * Set if no column is tagged with a region-specific InfoType (like + * US_ZIP_5) or a region code. + * + * Generated from protobuf field string region_code = 2; + * @return string + */ + public function getRegionCode() + { + return $this->region_code; + } + + /** + * ISO 3166-1 alpha-2 region code to use in the statistical modeling. + * Set if no column is tagged with a region-specific InfoType (like + * US_ZIP_5) or a region code. + * + * Generated from protobuf field string region_code = 2; + * @param string $var + * @return $this + */ + public function setRegionCode($var) + { + GPBUtil::checkString($var, True); + $this->region_code = $var; + + return $this; + } + + /** + * Several auxiliary tables can be used in the analysis. Each custom_tag + * used to tag a quasi-identifiers column must appear in exactly one column + * of one auxiliary table. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable auxiliary_tables = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAuxiliaryTables() + { + return $this->auxiliary_tables; + } + + /** + * Several auxiliary tables can be used in the analysis. Each custom_tag + * used to tag a quasi-identifiers column must appear in exactly one column + * of one auxiliary table. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable auxiliary_tables = 3; + * @param array<\Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\AuxiliaryTable>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAuxiliaryTables($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\AuxiliaryTable::class); + $this->auxiliary_tables = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(KMapEstimationConfig::class, \Google\Cloud\Dlp\V2\PrivacyMetric_KMapEstimationConfig::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable.php new file mode 100644 index 000000000000..339b644973ef --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable.php @@ -0,0 +1,168 @@ +google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable + */ +class AuxiliaryTable extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Auxiliary table location. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $table = null; + /** + * Required. Quasi-identifier columns. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable.QuasiIdField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + private $quasi_ids; + /** + * Required. The relative frequency column must contain a floating-point + * number between 0 and 1 (inclusive). Null values are assumed to be zero. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId relative_frequency = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $relative_frequency = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\BigQueryTable $table + * Required. Auxiliary table location. + * @type array<\Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\AuxiliaryTable\QuasiIdField>|\Google\Protobuf\Internal\RepeatedField $quasi_ids + * Required. Quasi-identifier columns. + * @type \Google\Cloud\Dlp\V2\FieldId $relative_frequency + * Required. The relative frequency column must contain a floating-point + * number between 0 and 1 (inclusive). Null values are assumed to be zero. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Auxiliary table location. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\BigQueryTable|null + */ + public function getTable() + { + return $this->table; + } + + public function hasTable() + { + return isset($this->table); + } + + public function clearTable() + { + unset($this->table); + } + + /** + * Required. Auxiliary table location. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\BigQueryTable $var + * @return $this + */ + public function setTable($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); + $this->table = $var; + + return $this; + } + + /** + * Required. Quasi-identifier columns. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable.QuasiIdField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getQuasiIds() + { + return $this->quasi_ids; + } + + /** + * Required. Quasi-identifier columns. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable.QuasiIdField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param array<\Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\AuxiliaryTable\QuasiIdField>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setQuasiIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\AuxiliaryTable\QuasiIdField::class); + $this->quasi_ids = $arr; + + return $this; + } + + /** + * Required. The relative frequency column must contain a floating-point + * number between 0 and 1 (inclusive). Null values are assumed to be zero. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId relative_frequency = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getRelativeFrequency() + { + return $this->relative_frequency; + } + + public function hasRelativeFrequency() + { + return isset($this->relative_frequency); + } + + public function clearRelativeFrequency() + { + unset($this->relative_frequency); + } + + /** + * Required. The relative frequency column must contain a floating-point + * number between 0 and 1 (inclusive). Null values are assumed to be zero. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId relative_frequency = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setRelativeFrequency($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->relative_frequency = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AuxiliaryTable::class, \Google\Cloud\Dlp\V2\PrivacyMetric_KMapEstimationConfig_AuxiliaryTable::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable/QuasiIdField.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable/QuasiIdField.php new file mode 100644 index 000000000000..b82e7afcb51f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable/QuasiIdField.php @@ -0,0 +1,115 @@ +google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable.QuasiIdField + */ +class QuasiIdField extends \Google\Protobuf\Internal\Message +{ + /** + * Identifies the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + */ + protected $field = null; + /** + * A auxiliary field. + * + * Generated from protobuf field string custom_tag = 2; + */ + protected $custom_tag = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\FieldId $field + * Identifies the column. + * @type string $custom_tag + * A auxiliary field. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Identifies the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getField() + { + return $this->field; + } + + public function hasField() + { + return isset($this->field); + } + + public function clearField() + { + unset($this->field); + } + + /** + * Identifies the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setField($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->field = $var; + + return $this; + } + + /** + * A auxiliary field. + * + * Generated from protobuf field string custom_tag = 2; + * @return string + */ + public function getCustomTag() + { + return $this->custom_tag; + } + + /** + * A auxiliary field. + * + * Generated from protobuf field string custom_tag = 2; + * @param string $var + * @return $this + */ + public function setCustomTag($var) + { + GPBUtil::checkString($var, True); + $this->custom_tag = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(QuasiIdField::class, \Google\Cloud\Dlp\V2\PrivacyMetric_KMapEstimationConfig_AuxiliaryTable_QuasiIdField::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/TaggedField.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/TaggedField.php new file mode 100644 index 000000000000..8de01c61e6ae --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/TaggedField.php @@ -0,0 +1,209 @@ +google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.TaggedField + */ +class TaggedField extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Identifies the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $field = null; + protected $tag; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\FieldId $field + * Required. Identifies the column. + * @type \Google\Cloud\Dlp\V2\InfoType $info_type + * A column can be tagged with a InfoType to use the relevant public + * dataset as a statistical model of population, if available. We + * currently support US ZIP codes, region codes, ages and genders. + * To programmatically obtain the list of supported InfoTypes, use + * ListInfoTypes with the supported_by=RISK_ANALYSIS filter. + * @type string $custom_tag + * A column can be tagged with a custom tag. In this case, the user must + * indicate an auxiliary table that contains statistical information on + * the possible values of this column (below). + * @type \Google\Protobuf\GPBEmpty $inferred + * If no semantic tag is indicated, we infer the statistical model from + * the distribution of values in the input data + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Identifies the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getField() + { + return $this->field; + } + + public function hasField() + { + return isset($this->field); + } + + public function clearField() + { + unset($this->field); + } + + /** + * Required. Identifies the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setField($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->field = $var; + + return $this; + } + + /** + * A column can be tagged with a InfoType to use the relevant public + * dataset as a statistical model of population, if available. We + * currently support US ZIP codes, region codes, ages and genders. + * To programmatically obtain the list of supported InfoTypes, use + * ListInfoTypes with the supported_by=RISK_ANALYSIS filter. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getInfoType() + { + return $this->readOneof(2); + } + + public function hasInfoType() + { + return $this->hasOneof(2); + } + + /** + * A column can be tagged with a InfoType to use the relevant public + * dataset as a statistical model of population, if available. We + * currently support US ZIP codes, region codes, ages and genders. + * To programmatically obtain the list of supported InfoTypes, use + * ListInfoTypes with the supported_by=RISK_ANALYSIS filter. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * A column can be tagged with a custom tag. In this case, the user must + * indicate an auxiliary table that contains statistical information on + * the possible values of this column (below). + * + * Generated from protobuf field string custom_tag = 3; + * @return string + */ + public function getCustomTag() + { + return $this->readOneof(3); + } + + public function hasCustomTag() + { + return $this->hasOneof(3); + } + + /** + * A column can be tagged with a custom tag. In this case, the user must + * indicate an auxiliary table that contains statistical information on + * the possible values of this column (below). + * + * Generated from protobuf field string custom_tag = 3; + * @param string $var + * @return $this + */ + public function setCustomTag($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * If no semantic tag is indicated, we infer the statistical model from + * the distribution of values in the input data + * + * Generated from protobuf field .google.protobuf.Empty inferred = 4; + * @return \Google\Protobuf\GPBEmpty|null + */ + public function getInferred() + { + return $this->readOneof(4); + } + + public function hasInferred() + { + return $this->hasOneof(4); + } + + /** + * If no semantic tag is indicated, we infer the statistical model from + * the distribution of values in the input data + * + * Generated from protobuf field .google.protobuf.Empty inferred = 4; + * @param \Google\Protobuf\GPBEmpty $var + * @return $this + */ + public function setInferred($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\GPBEmpty::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getTag() + { + return $this->whichOneof("tag"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(TaggedField::class, \Google\Cloud\Dlp\V2\PrivacyMetric_KMapEstimationConfig_TaggedField::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/LDiversityConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/LDiversityConfig.php new file mode 100644 index 000000000000..f75061de054d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/LDiversityConfig.php @@ -0,0 +1,122 @@ +google.privacy.dlp.v2.PrivacyMetric.LDiversityConfig + */ +class LDiversityConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Set of quasi-identifiers indicating how equivalence classes are + * defined for the l-diversity computation. When multiple fields are + * specified, they are considered a single composite key. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId quasi_ids = 1; + */ + private $quasi_ids; + /** + * Sensitive field for computing the l-value. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId sensitive_attribute = 2; + */ + protected $sensitive_attribute = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $quasi_ids + * Set of quasi-identifiers indicating how equivalence classes are + * defined for the l-diversity computation. When multiple fields are + * specified, they are considered a single composite key. + * @type \Google\Cloud\Dlp\V2\FieldId $sensitive_attribute + * Sensitive field for computing the l-value. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Set of quasi-identifiers indicating how equivalence classes are + * defined for the l-diversity computation. When multiple fields are + * specified, they are considered a single composite key. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId quasi_ids = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getQuasiIds() + { + return $this->quasi_ids; + } + + /** + * Set of quasi-identifiers indicating how equivalence classes are + * defined for the l-diversity computation. When multiple fields are + * specified, they are considered a single composite key. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId quasi_ids = 1; + * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setQuasiIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); + $this->quasi_ids = $arr; + + return $this; + } + + /** + * Sensitive field for computing the l-value. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId sensitive_attribute = 2; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getSensitiveAttribute() + { + return $this->sensitive_attribute; + } + + public function hasSensitiveAttribute() + { + return isset($this->sensitive_attribute); + } + + public function clearSensitiveAttribute() + { + unset($this->sensitive_attribute); + } + + /** + * Sensitive field for computing the l-value. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId sensitive_attribute = 2; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setSensitiveAttribute($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->sensitive_attribute = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(LDiversityConfig::class, \Google\Cloud\Dlp\V2\PrivacyMetric_LDiversityConfig::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/NumericalStatsConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/NumericalStatsConfig.php new file mode 100644 index 000000000000..95efdae391d6 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/NumericalStatsConfig.php @@ -0,0 +1,85 @@ +google.privacy.dlp.v2.PrivacyMetric.NumericalStatsConfig + */ +class NumericalStatsConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Field to compute numerical stats on. Supported types are + * integer, float, date, datetime, timestamp, time. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + */ + protected $field = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\FieldId $field + * Field to compute numerical stats on. Supported types are + * integer, float, date, datetime, timestamp, time. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Field to compute numerical stats on. Supported types are + * integer, float, date, datetime, timestamp, time. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getField() + { + return $this->field; + } + + public function hasField() + { + return isset($this->field); + } + + public function clearField() + { + unset($this->field); + } + + /** + * Field to compute numerical stats on. Supported types are + * integer, float, date, datetime, timestamp, time. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setField($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->field = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(NumericalStatsConfig::class, \Google\Cloud\Dlp\V2\PrivacyMetric_NumericalStatsConfig::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProfileStatus.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProfileStatus.php new file mode 100644 index 000000000000..efc705b0d043 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProfileStatus.php @@ -0,0 +1,125 @@ +google.privacy.dlp.v2.ProfileStatus + */ +class ProfileStatus extends \Google\Protobuf\Internal\Message +{ + /** + * Profiling status code and optional message. The `status.code` value is 0 + * (default value) for OK. + * + * Generated from protobuf field .google.rpc.Status status = 1; + */ + protected $status = null; + /** + * Time when the profile generation status was updated + * + * Generated from protobuf field .google.protobuf.Timestamp timestamp = 3; + */ + protected $timestamp = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Rpc\Status $status + * Profiling status code and optional message. The `status.code` value is 0 + * (default value) for OK. + * @type \Google\Protobuf\Timestamp $timestamp + * Time when the profile generation status was updated + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Profiling status code and optional message. The `status.code` value is 0 + * (default value) for OK. + * + * Generated from protobuf field .google.rpc.Status status = 1; + * @return \Google\Rpc\Status|null + */ + public function getStatus() + { + return $this->status; + } + + public function hasStatus() + { + return isset($this->status); + } + + public function clearStatus() + { + unset($this->status); + } + + /** + * Profiling status code and optional message. The `status.code` value is 0 + * (default value) for OK. + * + * Generated from protobuf field .google.rpc.Status status = 1; + * @param \Google\Rpc\Status $var + * @return $this + */ + public function setStatus($var) + { + GPBUtil::checkMessage($var, \Google\Rpc\Status::class); + $this->status = $var; + + return $this; + } + + /** + * Time when the profile generation status was updated + * + * Generated from protobuf field .google.protobuf.Timestamp timestamp = 3; + * @return \Google\Protobuf\Timestamp|null + */ + public function getTimestamp() + { + return $this->timestamp; + } + + public function hasTimestamp() + { + return isset($this->timestamp); + } + + public function clearTimestamp() + { + unset($this->timestamp); + } + + /** + * Time when the profile generation status was updated + * + * Generated from protobuf field .google.protobuf.Timestamp timestamp = 3; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setTimestamp($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->timestamp = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProjectDataProfile.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProjectDataProfile.php new file mode 100644 index 000000000000..9af8b6c77824 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProjectDataProfile.php @@ -0,0 +1,278 @@ +google.privacy.dlp.v2.ProjectDataProfile + */ +class ProjectDataProfile extends \Google\Protobuf\Internal\Message +{ + /** + * The resource name of the profile. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Project ID that was profiled. + * + * Generated from protobuf field string project_id = 2; + */ + protected $project_id = ''; + /** + * The last time the profile was generated. + * + * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 3; + */ + protected $profile_last_generated = null; + /** + * The sensitivity score of this project. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 4; + */ + protected $sensitivity_score = null; + /** + * The data risk level of this project. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 5; + */ + protected $data_risk_level = null; + /** + * Success or error status of the last attempt to profile the project. + * + * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 7; + */ + protected $profile_status = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The resource name of the profile. + * @type string $project_id + * Project ID that was profiled. + * @type \Google\Protobuf\Timestamp $profile_last_generated + * The last time the profile was generated. + * @type \Google\Cloud\Dlp\V2\SensitivityScore $sensitivity_score + * The sensitivity score of this project. + * @type \Google\Cloud\Dlp\V2\DataRiskLevel $data_risk_level + * The data risk level of this project. + * @type \Google\Cloud\Dlp\V2\ProfileStatus $profile_status + * Success or error status of the last attempt to profile the project. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The resource name of the profile. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The resource name of the profile. + * + * 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; + } + + /** + * Project ID that was profiled. + * + * Generated from protobuf field string project_id = 2; + * @return string + */ + public function getProjectId() + { + return $this->project_id; + } + + /** + * Project ID that was profiled. + * + * 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; + } + + /** + * The last time the profile was generated. + * + * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 3; + * @return \Google\Protobuf\Timestamp|null + */ + public function getProfileLastGenerated() + { + return $this->profile_last_generated; + } + + public function hasProfileLastGenerated() + { + return isset($this->profile_last_generated); + } + + public function clearProfileLastGenerated() + { + unset($this->profile_last_generated); + } + + /** + * The last time the profile was generated. + * + * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 3; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setProfileLastGenerated($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->profile_last_generated = $var; + + return $this; + } + + /** + * The sensitivity score of this project. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 4; + * @return \Google\Cloud\Dlp\V2\SensitivityScore|null + */ + public function getSensitivityScore() + { + return $this->sensitivity_score; + } + + public function hasSensitivityScore() + { + return isset($this->sensitivity_score); + } + + public function clearSensitivityScore() + { + unset($this->sensitivity_score); + } + + /** + * The sensitivity score of this project. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 4; + * @param \Google\Cloud\Dlp\V2\SensitivityScore $var + * @return $this + */ + public function setSensitivityScore($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SensitivityScore::class); + $this->sensitivity_score = $var; + + return $this; + } + + /** + * The data risk level of this project. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 5; + * @return \Google\Cloud\Dlp\V2\DataRiskLevel|null + */ + public function getDataRiskLevel() + { + return $this->data_risk_level; + } + + public function hasDataRiskLevel() + { + return isset($this->data_risk_level); + } + + public function clearDataRiskLevel() + { + unset($this->data_risk_level); + } + + /** + * The data risk level of this project. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 5; + * @param \Google\Cloud\Dlp\V2\DataRiskLevel $var + * @return $this + */ + public function setDataRiskLevel($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataRiskLevel::class); + $this->data_risk_level = $var; + + return $this; + } + + /** + * Success or error status of the last attempt to profile the project. + * + * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 7; + * @return \Google\Cloud\Dlp\V2\ProfileStatus|null + */ + public function getProfileStatus() + { + return $this->profile_status; + } + + public function hasProfileStatus() + { + return isset($this->profile_status); + } + + public function clearProfileStatus() + { + unset($this->profile_status); + } + + /** + * Success or error status of the last attempt to profile the project. + * + * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 7; + * @param \Google\Cloud\Dlp\V2\ProfileStatus $var + * @return $this + */ + public function setProfileStatus($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ProfileStatus::class); + $this->profile_status = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuasiId.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuasiId.php new file mode 100644 index 000000000000..032c8e8a2cde --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuasiId.php @@ -0,0 +1,206 @@ +google.privacy.dlp.v2.QuasiId + */ +class QuasiId extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Identifies the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $field = null; + protected $tag; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\FieldId $field + * Required. Identifies the column. + * @type \Google\Cloud\Dlp\V2\InfoType $info_type + * A column can be tagged with a InfoType to use the relevant public + * dataset as a statistical model of population, if available. We + * currently support US ZIP codes, region codes, ages and genders. + * To programmatically obtain the list of supported InfoTypes, use + * ListInfoTypes with the supported_by=RISK_ANALYSIS filter. + * @type string $custom_tag + * A column can be tagged with a custom tag. In this case, the user must + * indicate an auxiliary table that contains statistical information on + * the possible values of this column (below). + * @type \Google\Protobuf\GPBEmpty $inferred + * If no semantic tag is indicated, we infer the statistical model from + * the distribution of values in the input data + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Identifies the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getField() + { + return $this->field; + } + + public function hasField() + { + return isset($this->field); + } + + public function clearField() + { + unset($this->field); + } + + /** + * Required. Identifies the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setField($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->field = $var; + + return $this; + } + + /** + * A column can be tagged with a InfoType to use the relevant public + * dataset as a statistical model of population, if available. We + * currently support US ZIP codes, region codes, ages and genders. + * To programmatically obtain the list of supported InfoTypes, use + * ListInfoTypes with the supported_by=RISK_ANALYSIS filter. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getInfoType() + { + return $this->readOneof(2); + } + + public function hasInfoType() + { + return $this->hasOneof(2); + } + + /** + * A column can be tagged with a InfoType to use the relevant public + * dataset as a statistical model of population, if available. We + * currently support US ZIP codes, region codes, ages and genders. + * To programmatically obtain the list of supported InfoTypes, use + * ListInfoTypes with the supported_by=RISK_ANALYSIS filter. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * A column can be tagged with a custom tag. In this case, the user must + * indicate an auxiliary table that contains statistical information on + * the possible values of this column (below). + * + * Generated from protobuf field string custom_tag = 3; + * @return string + */ + public function getCustomTag() + { + return $this->readOneof(3); + } + + public function hasCustomTag() + { + return $this->hasOneof(3); + } + + /** + * A column can be tagged with a custom tag. In this case, the user must + * indicate an auxiliary table that contains statistical information on + * the possible values of this column (below). + * + * Generated from protobuf field string custom_tag = 3; + * @param string $var + * @return $this + */ + public function setCustomTag($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * If no semantic tag is indicated, we infer the statistical model from + * the distribution of values in the input data + * + * Generated from protobuf field .google.protobuf.Empty inferred = 4; + * @return \Google\Protobuf\GPBEmpty|null + */ + public function getInferred() + { + return $this->readOneof(4); + } + + public function hasInferred() + { + return $this->hasOneof(4); + } + + /** + * If no semantic tag is indicated, we infer the statistical model from + * the distribution of values in the input data + * + * Generated from protobuf field .google.protobuf.Empty inferred = 4; + * @param \Google\Protobuf\GPBEmpty $var + * @return $this + */ + public function setInferred($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\GPBEmpty::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getTag() + { + return $this->whichOneof("tag"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuoteInfo.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuoteInfo.php new file mode 100644 index 000000000000..f33288a3dbcc --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuoteInfo.php @@ -0,0 +1,75 @@ +google.privacy.dlp.v2.QuoteInfo + */ +class QuoteInfo extends \Google\Protobuf\Internal\Message +{ + protected $parsed_quote; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DateTime $date_time + * The date time indicated by the quote. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The date time indicated by the quote. + * + * Generated from protobuf field .google.privacy.dlp.v2.DateTime date_time = 2; + * @return \Google\Cloud\Dlp\V2\DateTime|null + */ + public function getDateTime() + { + return $this->readOneof(2); + } + + public function hasDateTime() + { + return $this->hasOneof(2); + } + + /** + * The date time indicated by the quote. + * + * Generated from protobuf field .google.privacy.dlp.v2.DateTime date_time = 2; + * @param \Google\Cloud\Dlp\V2\DateTime $var + * @return $this + */ + public function setDateTime($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DateTime::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getParsedQuote() + { + return $this->whichOneof("parsed_quote"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Range.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Range.php new file mode 100644 index 000000000000..c7f695bcb24f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Range.php @@ -0,0 +1,101 @@ +google.privacy.dlp.v2.Range + */ +class Range extends \Google\Protobuf\Internal\Message +{ + /** + * Index of the first character of the range (inclusive). + * + * Generated from protobuf field int64 start = 1; + */ + protected $start = 0; + /** + * Index of the last character of the range (exclusive). + * + * Generated from protobuf field int64 end = 2; + */ + protected $end = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $start + * Index of the first character of the range (inclusive). + * @type int|string $end + * Index of the last character of the range (exclusive). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Index of the first character of the range (inclusive). + * + * Generated from protobuf field int64 start = 1; + * @return int|string + */ + public function getStart() + { + return $this->start; + } + + /** + * Index of the first character of the range (inclusive). + * + * Generated from protobuf field int64 start = 1; + * @param int|string $var + * @return $this + */ + public function setStart($var) + { + GPBUtil::checkInt64($var); + $this->start = $var; + + return $this; + } + + /** + * Index of the last character of the range (exclusive). + * + * Generated from protobuf field int64 end = 2; + * @return int|string + */ + public function getEnd() + { + return $this->end; + } + + /** + * Index of the last character of the range (exclusive). + * + * Generated from protobuf field int64 end = 2; + * @param int|string $var + * @return $this + */ + public function setEnd($var) + { + GPBUtil::checkInt64($var); + $this->end = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition.php new file mode 100644 index 000000000000..8d4ffb088b55 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition.php @@ -0,0 +1,78 @@ +google.privacy.dlp.v2.RecordCondition + */ +class RecordCondition extends \Google\Protobuf\Internal\Message +{ + /** + * An expression. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Expressions expressions = 3; + */ + protected $expressions = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\RecordCondition\Expressions $expressions + * An expression. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * An expression. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Expressions expressions = 3; + * @return \Google\Cloud\Dlp\V2\RecordCondition\Expressions|null + */ + public function getExpressions() + { + return $this->expressions; + } + + public function hasExpressions() + { + return isset($this->expressions); + } + + public function clearExpressions() + { + unset($this->expressions); + } + + /** + * An expression. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Expressions expressions = 3; + * @param \Google\Cloud\Dlp\V2\RecordCondition\Expressions $var + * @return $this + */ + public function setExpressions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordCondition\Expressions::class); + $this->expressions = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Condition.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Condition.php new file mode 100644 index 000000000000..b1f05c356b4e --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Condition.php @@ -0,0 +1,174 @@ +google.privacy.dlp.v2.RecordCondition.Condition + */ +class Condition extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Field within the record this condition is evaluated against. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $field = null; + /** + * Required. Operator used to compare the field or infoType to the value. + * + * Generated from protobuf field .google.privacy.dlp.v2.RelationalOperator operator = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $operator = 0; + /** + * Value to compare against. [Mandatory, except for `EXISTS` tests.] + * + * Generated from protobuf field .google.privacy.dlp.v2.Value value = 4; + */ + protected $value = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\FieldId $field + * Required. Field within the record this condition is evaluated against. + * @type int $operator + * Required. Operator used to compare the field or infoType to the value. + * @type \Google\Cloud\Dlp\V2\Value $value + * Value to compare against. [Mandatory, except for `EXISTS` tests.] + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Field within the record this condition is evaluated against. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getField() + { + return $this->field; + } + + public function hasField() + { + return isset($this->field); + } + + public function clearField() + { + unset($this->field); + } + + /** + * Required. Field within the record this condition is evaluated against. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setField($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->field = $var; + + return $this; + } + + /** + * Required. Operator used to compare the field or infoType to the value. + * + * Generated from protobuf field .google.privacy.dlp.v2.RelationalOperator operator = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getOperator() + { + return $this->operator; + } + + /** + * Required. Operator used to compare the field or infoType to the value. + * + * Generated from protobuf field .google.privacy.dlp.v2.RelationalOperator operator = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setOperator($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\RelationalOperator::class); + $this->operator = $var; + + return $this; + } + + /** + * Value to compare against. [Mandatory, except for `EXISTS` tests.] + * + * Generated from protobuf field .google.privacy.dlp.v2.Value value = 4; + * @return \Google\Cloud\Dlp\V2\Value|null + */ + public function getValue() + { + return $this->value; + } + + public function hasValue() + { + return isset($this->value); + } + + public function clearValue() + { + unset($this->value); + } + + /** + * Value to compare against. [Mandatory, except for `EXISTS` tests.] + * + * Generated from protobuf field .google.privacy.dlp.v2.Value value = 4; + * @param \Google\Cloud\Dlp\V2\Value $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); + $this->value = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Condition::class, \Google\Cloud\Dlp\V2\RecordCondition_Condition::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Conditions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Conditions.php new file mode 100644 index 000000000000..29e0ab591806 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Conditions.php @@ -0,0 +1,70 @@ +google.privacy.dlp.v2.RecordCondition.Conditions + */ +class Conditions extends \Google\Protobuf\Internal\Message +{ + /** + * A collection of conditions. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.RecordCondition.Condition conditions = 1; + */ + private $conditions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\RecordCondition\Condition>|\Google\Protobuf\Internal\RepeatedField $conditions + * A collection of conditions. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A collection of conditions. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.RecordCondition.Condition conditions = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getConditions() + { + return $this->conditions; + } + + /** + * A collection of conditions. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.RecordCondition.Condition conditions = 1; + * @param array<\Google\Cloud\Dlp\V2\RecordCondition\Condition>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setConditions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\RecordCondition\Condition::class); + $this->conditions = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Conditions::class, \Google\Cloud\Dlp\V2\RecordCondition_Conditions::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions.php new file mode 100644 index 000000000000..eccccbd1959e --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions.php @@ -0,0 +1,116 @@ +google.privacy.dlp.v2.RecordCondition.Expressions + */ +class Expressions extends \Google\Protobuf\Internal\Message +{ + /** + * The operator to apply to the result of conditions. Default and currently + * only supported value is `AND`. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Expressions.LogicalOperator logical_operator = 1; + */ + protected $logical_operator = 0; + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $logical_operator + * The operator to apply to the result of conditions. Default and currently + * only supported value is `AND`. + * @type \Google\Cloud\Dlp\V2\RecordCondition\Conditions $conditions + * Conditions to apply to the expression. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The operator to apply to the result of conditions. Default and currently + * only supported value is `AND`. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Expressions.LogicalOperator logical_operator = 1; + * @return int + */ + public function getLogicalOperator() + { + return $this->logical_operator; + } + + /** + * The operator to apply to the result of conditions. Default and currently + * only supported value is `AND`. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Expressions.LogicalOperator logical_operator = 1; + * @param int $var + * @return $this + */ + public function setLogicalOperator($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\RecordCondition\Expressions\LogicalOperator::class); + $this->logical_operator = $var; + + return $this; + } + + /** + * Conditions to apply to the expression. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Conditions conditions = 3; + * @return \Google\Cloud\Dlp\V2\RecordCondition\Conditions|null + */ + public function getConditions() + { + return $this->readOneof(3); + } + + public function hasConditions() + { + return $this->hasOneof(3); + } + + /** + * Conditions to apply to the expression. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Conditions conditions = 3; + * @param \Google\Cloud\Dlp\V2\RecordCondition\Conditions $var + * @return $this + */ + public function setConditions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordCondition\Conditions::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Expressions::class, \Google\Cloud\Dlp\V2\RecordCondition_Expressions::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions/LogicalOperator.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions/LogicalOperator.php new file mode 100644 index 000000000000..aeb6e0286883 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions/LogicalOperator.php @@ -0,0 +1,61 @@ +google.privacy.dlp.v2.RecordCondition.Expressions.LogicalOperator + */ +class LogicalOperator +{ + /** + * Unused + * + * Generated from protobuf enum LOGICAL_OPERATOR_UNSPECIFIED = 0; + */ + const LOGICAL_OPERATOR_UNSPECIFIED = 0; + /** + * Conditional AND + * + * Generated from protobuf enum AND = 1; + */ + const PBAND = 1; + + private static $valueToName = [ + self::LOGICAL_OPERATOR_UNSPECIFIED => 'LOGICAL_OPERATOR_UNSPECIFIED', + self::PBAND => 'AND', + ]; + + 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)) { + $pbconst = __CLASS__. '::PB' . strtoupper($name); + if (!defined($pbconst)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($pbconst); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(LogicalOperator::class, \Google\Cloud\Dlp\V2\RecordCondition_Expressions_LogicalOperator::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordKey.php new file mode 100644 index 000000000000..12d649962d53 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordKey.php @@ -0,0 +1,146 @@ +google.privacy.dlp.v2.RecordKey + */ +class RecordKey extends \Google\Protobuf\Internal\Message +{ + /** + * Values of identifying columns in the given row. Order of values matches + * the order of `identifying_fields` specified in the scanning request. + * + * Generated from protobuf field repeated string id_values = 5; + */ + private $id_values; + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DatastoreKey $datastore_key + * BigQuery key + * @type \Google\Cloud\Dlp\V2\BigQueryKey $big_query_key + * Datastore key + * @type array|\Google\Protobuf\Internal\RepeatedField $id_values + * Values of identifying columns in the given row. Order of values matches + * the order of `identifying_fields` specified in the scanning request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * BigQuery key + * + * Generated from protobuf field .google.privacy.dlp.v2.DatastoreKey datastore_key = 2; + * @return \Google\Cloud\Dlp\V2\DatastoreKey|null + */ + public function getDatastoreKey() + { + return $this->readOneof(2); + } + + public function hasDatastoreKey() + { + return $this->hasOneof(2); + } + + /** + * BigQuery key + * + * Generated from protobuf field .google.privacy.dlp.v2.DatastoreKey datastore_key = 2; + * @param \Google\Cloud\Dlp\V2\DatastoreKey $var + * @return $this + */ + public function setDatastoreKey($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DatastoreKey::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Datastore key + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryKey big_query_key = 3; + * @return \Google\Cloud\Dlp\V2\BigQueryKey|null + */ + public function getBigQueryKey() + { + return $this->readOneof(3); + } + + public function hasBigQueryKey() + { + return $this->hasOneof(3); + } + + /** + * Datastore key + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryKey big_query_key = 3; + * @param \Google\Cloud\Dlp\V2\BigQueryKey $var + * @return $this + */ + public function setBigQueryKey($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryKey::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Values of identifying columns in the given row. Order of values matches + * the order of `identifying_fields` specified in the scanning request. + * + * Generated from protobuf field repeated string id_values = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getIdValues() + { + return $this->id_values; + } + + /** + * Values of identifying columns in the given row. Order of values matches + * the order of `identifying_fields` specified in the scanning request. + * + * Generated from protobuf field repeated string id_values = 5; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setIdValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->id_values = $arr; + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordLocation.php new file mode 100644 index 000000000000..08d3831c17e8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordLocation.php @@ -0,0 +1,165 @@ +google.privacy.dlp.v2.RecordLocation + */ +class RecordLocation extends \Google\Protobuf\Internal\Message +{ + /** + * Key of the finding. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordKey record_key = 1; + */ + protected $record_key = null; + /** + * Field id of the field containing the finding. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field_id = 2; + */ + protected $field_id = null; + /** + * Location within a `ContentItem.Table`. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableLocation table_location = 3; + */ + protected $table_location = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\RecordKey $record_key + * Key of the finding. + * @type \Google\Cloud\Dlp\V2\FieldId $field_id + * Field id of the field containing the finding. + * @type \Google\Cloud\Dlp\V2\TableLocation $table_location + * Location within a `ContentItem.Table`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Key of the finding. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordKey record_key = 1; + * @return \Google\Cloud\Dlp\V2\RecordKey|null + */ + public function getRecordKey() + { + return $this->record_key; + } + + public function hasRecordKey() + { + return isset($this->record_key); + } + + public function clearRecordKey() + { + unset($this->record_key); + } + + /** + * Key of the finding. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordKey record_key = 1; + * @param \Google\Cloud\Dlp\V2\RecordKey $var + * @return $this + */ + public function setRecordKey($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordKey::class); + $this->record_key = $var; + + return $this; + } + + /** + * Field id of the field containing the finding. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field_id = 2; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getFieldId() + { + return $this->field_id; + } + + public function hasFieldId() + { + return isset($this->field_id); + } + + public function clearFieldId() + { + unset($this->field_id); + } + + /** + * Field id of the field containing the finding. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field_id = 2; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setFieldId($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->field_id = $var; + + return $this; + } + + /** + * Location within a `ContentItem.Table`. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableLocation table_location = 3; + * @return \Google\Cloud\Dlp\V2\TableLocation|null + */ + public function getTableLocation() + { + return $this->table_location; + } + + public function hasTableLocation() + { + return isset($this->table_location); + } + + public function clearTableLocation() + { + unset($this->table_location); + } + + /** + * Location within a `ContentItem.Table`. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableLocation table_location = 3; + * @param \Google\Cloud\Dlp\V2\TableLocation $var + * @return $this + */ + public function setTableLocation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableLocation::class); + $this->table_location = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordSuppression.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordSuppression.php new file mode 100644 index 000000000000..3a6d09b1bbce --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordSuppression.php @@ -0,0 +1,82 @@ +google.privacy.dlp.v2.RecordSuppression + */ +class RecordSuppression extends \Google\Protobuf\Internal\Message +{ + /** + * A condition that when it evaluates to true will result in the record being + * evaluated to be suppressed from the transformed content. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition condition = 1; + */ + protected $condition = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\RecordCondition $condition + * A condition that when it evaluates to true will result in the record being + * evaluated to be suppressed from the transformed content. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A condition that when it evaluates to true will result in the record being + * evaluated to be suppressed from the transformed content. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition condition = 1; + * @return \Google\Cloud\Dlp\V2\RecordCondition|null + */ + public function getCondition() + { + return $this->condition; + } + + public function hasCondition() + { + return isset($this->condition); + } + + public function clearCondition() + { + unset($this->condition); + } + + /** + * A condition that when it evaluates to true will result in the record being + * evaluated to be suppressed from the transformed content. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition condition = 1; + * @param \Google\Cloud\Dlp\V2\RecordCondition $var + * @return $this + */ + public function setCondition($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordCondition::class); + $this->condition = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformation.php new file mode 100644 index 000000000000..e802da478496 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformation.php @@ -0,0 +1,155 @@ +google.privacy.dlp.v2.RecordTransformation + */ +class RecordTransformation extends \Google\Protobuf\Internal\Message +{ + /** + * For record transformations, provide a field. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field_id = 1; + */ + protected $field_id = null; + /** + * Findings container modification timestamp, if applicable. + * + * Generated from protobuf field .google.protobuf.Timestamp container_timestamp = 2; + */ + protected $container_timestamp = null; + /** + * Container version, if available ("generation" for Cloud Storage). + * + * Generated from protobuf field string container_version = 3; + */ + protected $container_version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\FieldId $field_id + * For record transformations, provide a field. + * @type \Google\Protobuf\Timestamp $container_timestamp + * Findings container modification timestamp, if applicable. + * @type string $container_version + * Container version, if available ("generation" for Cloud Storage). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * For record transformations, provide a field. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field_id = 1; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getFieldId() + { + return $this->field_id; + } + + public function hasFieldId() + { + return isset($this->field_id); + } + + public function clearFieldId() + { + unset($this->field_id); + } + + /** + * For record transformations, provide a field. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field_id = 1; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setFieldId($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->field_id = $var; + + return $this; + } + + /** + * Findings container modification timestamp, if applicable. + * + * Generated from protobuf field .google.protobuf.Timestamp container_timestamp = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getContainerTimestamp() + { + return $this->container_timestamp; + } + + public function hasContainerTimestamp() + { + return isset($this->container_timestamp); + } + + public function clearContainerTimestamp() + { + unset($this->container_timestamp); + } + + /** + * Findings container modification timestamp, if applicable. + * + * Generated from protobuf field .google.protobuf.Timestamp container_timestamp = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setContainerTimestamp($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->container_timestamp = $var; + + return $this; + } + + /** + * Container version, if available ("generation" for Cloud Storage). + * + * Generated from protobuf field string container_version = 3; + * @return string + */ + public function getContainerVersion() + { + return $this->container_version; + } + + /** + * Container version, if available ("generation" for Cloud Storage). + * + * Generated from protobuf field string container_version = 3; + * @param string $var + * @return $this + */ + public function setContainerVersion($var) + { + GPBUtil::checkString($var, True); + $this->container_version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformations.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformations.php new file mode 100644 index 000000000000..33498ce84dd7 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformations.php @@ -0,0 +1,106 @@ +google.privacy.dlp.v2.RecordTransformations + */ +class RecordTransformations extends \Google\Protobuf\Internal\Message +{ + /** + * Transform the record by applying various field transformations. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldTransformation field_transformations = 1; + */ + private $field_transformations; + /** + * Configuration defining which records get suppressed entirely. Records that + * match any suppression rule are omitted from the output. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.RecordSuppression record_suppressions = 2; + */ + private $record_suppressions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\FieldTransformation>|\Google\Protobuf\Internal\RepeatedField $field_transformations + * Transform the record by applying various field transformations. + * @type array<\Google\Cloud\Dlp\V2\RecordSuppression>|\Google\Protobuf\Internal\RepeatedField $record_suppressions + * Configuration defining which records get suppressed entirely. Records that + * match any suppression rule are omitted from the output. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Transform the record by applying various field transformations. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldTransformation field_transformations = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFieldTransformations() + { + return $this->field_transformations; + } + + /** + * Transform the record by applying various field transformations. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldTransformation field_transformations = 1; + * @param array<\Google\Cloud\Dlp\V2\FieldTransformation>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFieldTransformations($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldTransformation::class); + $this->field_transformations = $arr; + + return $this; + } + + /** + * Configuration defining which records get suppressed entirely. Records that + * match any suppression rule are omitted from the output. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.RecordSuppression record_suppressions = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRecordSuppressions() + { + return $this->record_suppressions; + } + + /** + * Configuration defining which records get suppressed entirely. Records that + * match any suppression rule are omitted from the output. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.RecordSuppression record_suppressions = 2; + * @param array<\Google\Cloud\Dlp\V2\RecordSuppression>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRecordSuppressions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\RecordSuppression::class); + $this->record_suppressions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactConfig.php new file mode 100644 index 000000000000..79729a849f20 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactConfig.php @@ -0,0 +1,35 @@ +google.privacy.dlp.v2.RedactConfig + */ +class RedactConfig extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest.php new file mode 100644 index 000000000000..1175ce0477ac --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest.php @@ -0,0 +1,306 @@ +google.privacy.dlp.v2.RedactImageRequest + */ +class RedactImageRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 8; + */ + protected $location_id = ''; + /** + * Configuration for the inspector. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; + */ + protected $inspect_config = null; + /** + * The configuration for specifying what content to redact from images. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5; + */ + private $image_redaction_configs; + /** + * Whether the response should include findings along with the redacted + * image. + * + * Generated from protobuf field bool include_findings = 6; + */ + protected $include_findings = false; + /** + * The content must be PNG, JPEG, SVG or BMP. + * + * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem byte_item = 7; + */ + protected $byte_item = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type string $location_id + * Deprecated. This field has no effect. + * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config + * Configuration for the inspector. + * @type array<\Google\Cloud\Dlp\V2\RedactImageRequest\ImageRedactionConfig>|\Google\Protobuf\Internal\RepeatedField $image_redaction_configs + * The configuration for specifying what content to redact from images. + * @type bool $include_findings + * Whether the response should include findings along with the redacted + * image. + * @type \Google\Cloud\Dlp\V2\ByteContentItem $byte_item + * The content must be PNG, JPEG, SVG or BMP. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 8; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 8; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + + /** + * Configuration for the inspector. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; + * @return \Google\Cloud\Dlp\V2\InspectConfig|null + */ + public function getInspectConfig() + { + return $this->inspect_config; + } + + public function hasInspectConfig() + { + return isset($this->inspect_config); + } + + public function clearInspectConfig() + { + unset($this->inspect_config); + } + + /** + * Configuration for the inspector. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; + * @param \Google\Cloud\Dlp\V2\InspectConfig $var + * @return $this + */ + public function setInspectConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); + $this->inspect_config = $var; + + return $this; + } + + /** + * The configuration for specifying what content to redact from images. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getImageRedactionConfigs() + { + return $this->image_redaction_configs; + } + + /** + * The configuration for specifying what content to redact from images. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5; + * @param array<\Google\Cloud\Dlp\V2\RedactImageRequest\ImageRedactionConfig>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setImageRedactionConfigs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\RedactImageRequest\ImageRedactionConfig::class); + $this->image_redaction_configs = $arr; + + return $this; + } + + /** + * Whether the response should include findings along with the redacted + * image. + * + * Generated from protobuf field bool include_findings = 6; + * @return bool + */ + public function getIncludeFindings() + { + return $this->include_findings; + } + + /** + * Whether the response should include findings along with the redacted + * image. + * + * Generated from protobuf field bool include_findings = 6; + * @param bool $var + * @return $this + */ + public function setIncludeFindings($var) + { + GPBUtil::checkBool($var); + $this->include_findings = $var; + + return $this; + } + + /** + * The content must be PNG, JPEG, SVG or BMP. + * + * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem byte_item = 7; + * @return \Google\Cloud\Dlp\V2\ByteContentItem|null + */ + public function getByteItem() + { + return $this->byte_item; + } + + public function hasByteItem() + { + return isset($this->byte_item); + } + + public function clearByteItem() + { + unset($this->byte_item); + } + + /** + * The content must be PNG, JPEG, SVG or BMP. + * + * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem byte_item = 7; + * @param \Google\Cloud\Dlp\V2\ByteContentItem $var + * @return $this + */ + public function setByteItem($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ByteContentItem::class); + $this->byte_item = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest/ImageRedactionConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest/ImageRedactionConfig.php new file mode 100644 index 000000000000..d5ba6d7c75f3 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest/ImageRedactionConfig.php @@ -0,0 +1,171 @@ +google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig + */ +class ImageRedactionConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The color to use when redacting content from an image. If not specified, + * the default is black. + * + * Generated from protobuf field .google.privacy.dlp.v2.Color redaction_color = 3; + */ + protected $redaction_color = null; + protected $target; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InfoType $info_type + * Only one per info_type should be provided per request. If not + * specified, and redact_all_text is false, the DLP API will redact all + * text that it matches against all info_types that are found, but not + * specified in another ImageRedactionConfig. + * @type bool $redact_all_text + * If true, all text found in the image, regardless whether it matches an + * info_type, is redacted. Only one should be provided. + * @type \Google\Cloud\Dlp\V2\Color $redaction_color + * The color to use when redacting content from an image. If not specified, + * the default is black. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Only one per info_type should be provided per request. If not + * specified, and redact_all_text is false, the DLP API will redact all + * text that it matches against all info_types that are found, but not + * specified in another ImageRedactionConfig. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getInfoType() + { + return $this->readOneof(1); + } + + public function hasInfoType() + { + return $this->hasOneof(1); + } + + /** + * Only one per info_type should be provided per request. If not + * specified, and redact_all_text is false, the DLP API will redact all + * text that it matches against all info_types that are found, but not + * specified in another ImageRedactionConfig. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * If true, all text found in the image, regardless whether it matches an + * info_type, is redacted. Only one should be provided. + * + * Generated from protobuf field bool redact_all_text = 2; + * @return bool + */ + public function getRedactAllText() + { + return $this->readOneof(2); + } + + public function hasRedactAllText() + { + return $this->hasOneof(2); + } + + /** + * If true, all text found in the image, regardless whether it matches an + * info_type, is redacted. Only one should be provided. + * + * Generated from protobuf field bool redact_all_text = 2; + * @param bool $var + * @return $this + */ + public function setRedactAllText($var) + { + GPBUtil::checkBool($var); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The color to use when redacting content from an image. If not specified, + * the default is black. + * + * Generated from protobuf field .google.privacy.dlp.v2.Color redaction_color = 3; + * @return \Google\Cloud\Dlp\V2\Color|null + */ + public function getRedactionColor() + { + return $this->redaction_color; + } + + public function hasRedactionColor() + { + return isset($this->redaction_color); + } + + public function clearRedactionColor() + { + unset($this->redaction_color); + } + + /** + * The color to use when redacting content from an image. If not specified, + * the default is black. + * + * Generated from protobuf field .google.privacy.dlp.v2.Color redaction_color = 3; + * @param \Google\Cloud\Dlp\V2\Color $var + * @return $this + */ + public function setRedactionColor($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Color::class); + $this->redaction_color = $var; + + return $this; + } + + /** + * @return string + */ + public function getTarget() + { + return $this->whichOneof("target"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ImageRedactionConfig::class, \Google\Cloud\Dlp\V2\RedactImageRequest_ImageRedactionConfig::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageResponse.php new file mode 100644 index 000000000000..2f749551986a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageResponse.php @@ -0,0 +1,153 @@ +google.privacy.dlp.v2.RedactImageResponse + */ +class RedactImageResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The redacted image. The type will be the same as the original image. + * + * Generated from protobuf field bytes redacted_image = 1; + */ + protected $redacted_image = ''; + /** + * If an image was being inspected and the InspectConfig's include_quote was + * set to true, then this field will include all text, if any, that was found + * in the image. + * + * Generated from protobuf field string extracted_text = 2; + */ + protected $extracted_text = ''; + /** + * The findings. Populated when include_findings in the request is true. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectResult inspect_result = 3; + */ + protected $inspect_result = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $redacted_image + * The redacted image. The type will be the same as the original image. + * @type string $extracted_text + * If an image was being inspected and the InspectConfig's include_quote was + * set to true, then this field will include all text, if any, that was found + * in the image. + * @type \Google\Cloud\Dlp\V2\InspectResult $inspect_result + * The findings. Populated when include_findings in the request is true. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The redacted image. The type will be the same as the original image. + * + * Generated from protobuf field bytes redacted_image = 1; + * @return string + */ + public function getRedactedImage() + { + return $this->redacted_image; + } + + /** + * The redacted image. The type will be the same as the original image. + * + * Generated from protobuf field bytes redacted_image = 1; + * @param string $var + * @return $this + */ + public function setRedactedImage($var) + { + GPBUtil::checkString($var, False); + $this->redacted_image = $var; + + return $this; + } + + /** + * If an image was being inspected and the InspectConfig's include_quote was + * set to true, then this field will include all text, if any, that was found + * in the image. + * + * Generated from protobuf field string extracted_text = 2; + * @return string + */ + public function getExtractedText() + { + return $this->extracted_text; + } + + /** + * If an image was being inspected and the InspectConfig's include_quote was + * set to true, then this field will include all text, if any, that was found + * in the image. + * + * Generated from protobuf field string extracted_text = 2; + * @param string $var + * @return $this + */ + public function setExtractedText($var) + { + GPBUtil::checkString($var, True); + $this->extracted_text = $var; + + return $this; + } + + /** + * The findings. Populated when include_findings in the request is true. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectResult inspect_result = 3; + * @return \Google\Cloud\Dlp\V2\InspectResult|null + */ + public function getInspectResult() + { + return $this->inspect_result; + } + + public function hasInspectResult() + { + return isset($this->inspect_result); + } + + public function clearInspectResult() + { + unset($this->inspect_result); + } + + /** + * The findings. Populated when include_findings in the request is true. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectResult inspect_result = 3; + * @param \Google\Cloud\Dlp\V2\InspectResult $var + * @return $this + */ + public function setInspectResult($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectResult::class); + $this->inspect_result = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentRequest.php new file mode 100644 index 000000000000..f87523fc482e --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentRequest.php @@ -0,0 +1,417 @@ +google.privacy.dlp.v2.ReidentifyContentRequest + */ +class ReidentifyContentRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Configuration for the re-identification of the content item. + * This field shares the same proto message type that is used for + * de-identification, however its usage here is for the reversal of the + * previous de-identification. Re-identification is performed by examining + * the transformations used to de-identify the items and executing the + * reverse. This requires that only reversible transformations + * be provided here. The reversible transformations are: + * - `CryptoDeterministicConfig` + * - `CryptoReplaceFfxFpeConfig` + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig reidentify_config = 2; + */ + protected $reidentify_config = null; + /** + * Configuration for the inspector. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 3; + */ + protected $inspect_config = null; + /** + * The item to re-identify. Will be treated as text. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 4; + */ + protected $item = null; + /** + * Template to use. Any configuration directly specified in + * `inspect_config` will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * + * Generated from protobuf field string inspect_template_name = 5; + */ + protected $inspect_template_name = ''; + /** + * Template to use. References an instance of `DeidentifyTemplate`. + * Any configuration directly specified in `reidentify_config` or + * `inspect_config` will override those set in the template. The + * `DeidentifyTemplate` used must include only reversible transformations. + * Singular fields that are set in this request will replace their + * corresponding fields in the template. Repeated fields are appended. + * Singular sub-messages and groups are recursively merged. + * + * Generated from protobuf field string reidentify_template_name = 6; + */ + protected $reidentify_template_name = ''; + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 7; + */ + protected $location_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * @type \Google\Cloud\Dlp\V2\DeidentifyConfig $reidentify_config + * Configuration for the re-identification of the content item. + * This field shares the same proto message type that is used for + * de-identification, however its usage here is for the reversal of the + * previous de-identification. Re-identification is performed by examining + * the transformations used to de-identify the items and executing the + * reverse. This requires that only reversible transformations + * be provided here. The reversible transformations are: + * - `CryptoDeterministicConfig` + * - `CryptoReplaceFfxFpeConfig` + * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config + * Configuration for the inspector. + * @type \Google\Cloud\Dlp\V2\ContentItem $item + * The item to re-identify. Will be treated as text. + * @type string $inspect_template_name + * Template to use. Any configuration directly specified in + * `inspect_config` will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * @type string $reidentify_template_name + * Template to use. References an instance of `DeidentifyTemplate`. + * Any configuration directly specified in `reidentify_config` or + * `inspect_config` will override those set in the template. The + * `DeidentifyTemplate` used must include only reversible transformations. + * Singular fields that are set in this request will replace their + * corresponding fields in the template. Repeated fields are appended. + * Singular sub-messages and groups are recursively merged. + * @type string $location_id + * Deprecated. This field has no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent resource name. + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * parent=projects/example-project/locations/europe-west3 + * + * 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; + } + + /** + * Configuration for the re-identification of the content item. + * This field shares the same proto message type that is used for + * de-identification, however its usage here is for the reversal of the + * previous de-identification. Re-identification is performed by examining + * the transformations used to de-identify the items and executing the + * reverse. This requires that only reversible transformations + * be provided here. The reversible transformations are: + * - `CryptoDeterministicConfig` + * - `CryptoReplaceFfxFpeConfig` + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig reidentify_config = 2; + * @return \Google\Cloud\Dlp\V2\DeidentifyConfig|null + */ + public function getReidentifyConfig() + { + return $this->reidentify_config; + } + + public function hasReidentifyConfig() + { + return isset($this->reidentify_config); + } + + public function clearReidentifyConfig() + { + unset($this->reidentify_config); + } + + /** + * Configuration for the re-identification of the content item. + * This field shares the same proto message type that is used for + * de-identification, however its usage here is for the reversal of the + * previous de-identification. Re-identification is performed by examining + * the transformations used to de-identify the items and executing the + * reverse. This requires that only reversible transformations + * be provided here. The reversible transformations are: + * - `CryptoDeterministicConfig` + * - `CryptoReplaceFfxFpeConfig` + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig reidentify_config = 2; + * @param \Google\Cloud\Dlp\V2\DeidentifyConfig $var + * @return $this + */ + public function setReidentifyConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyConfig::class); + $this->reidentify_config = $var; + + return $this; + } + + /** + * Configuration for the inspector. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 3; + * @return \Google\Cloud\Dlp\V2\InspectConfig|null + */ + public function getInspectConfig() + { + return $this->inspect_config; + } + + public function hasInspectConfig() + { + return isset($this->inspect_config); + } + + public function clearInspectConfig() + { + unset($this->inspect_config); + } + + /** + * Configuration for the inspector. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 3; + * @param \Google\Cloud\Dlp\V2\InspectConfig $var + * @return $this + */ + public function setInspectConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); + $this->inspect_config = $var; + + return $this; + } + + /** + * The item to re-identify. Will be treated as text. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 4; + * @return \Google\Cloud\Dlp\V2\ContentItem|null + */ + public function getItem() + { + return $this->item; + } + + public function hasItem() + { + return isset($this->item); + } + + public function clearItem() + { + unset($this->item); + } + + /** + * The item to re-identify. Will be treated as text. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 4; + * @param \Google\Cloud\Dlp\V2\ContentItem $var + * @return $this + */ + public function setItem($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ContentItem::class); + $this->item = $var; + + return $this; + } + + /** + * Template to use. Any configuration directly specified in + * `inspect_config` will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * + * Generated from protobuf field string inspect_template_name = 5; + * @return string + */ + public function getInspectTemplateName() + { + return $this->inspect_template_name; + } + + /** + * Template to use. Any configuration directly specified in + * `inspect_config` will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * + * Generated from protobuf field string inspect_template_name = 5; + * @param string $var + * @return $this + */ + public function setInspectTemplateName($var) + { + GPBUtil::checkString($var, True); + $this->inspect_template_name = $var; + + return $this; + } + + /** + * Template to use. References an instance of `DeidentifyTemplate`. + * Any configuration directly specified in `reidentify_config` or + * `inspect_config` will override those set in the template. The + * `DeidentifyTemplate` used must include only reversible transformations. + * Singular fields that are set in this request will replace their + * corresponding fields in the template. Repeated fields are appended. + * Singular sub-messages and groups are recursively merged. + * + * Generated from protobuf field string reidentify_template_name = 6; + * @return string + */ + public function getReidentifyTemplateName() + { + return $this->reidentify_template_name; + } + + /** + * Template to use. References an instance of `DeidentifyTemplate`. + * Any configuration directly specified in `reidentify_config` or + * `inspect_config` will override those set in the template. The + * `DeidentifyTemplate` used must include only reversible transformations. + * Singular fields that are set in this request will replace their + * corresponding fields in the template. Repeated fields are appended. + * Singular sub-messages and groups are recursively merged. + * + * Generated from protobuf field string reidentify_template_name = 6; + * @param string $var + * @return $this + */ + public function setReidentifyTemplateName($var) + { + GPBUtil::checkString($var, True); + $this->reidentify_template_name = $var; + + return $this; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 7; + * @return string + */ + public function getLocationId() + { + return $this->location_id; + } + + /** + * Deprecated. This field has no effect. + * + * Generated from protobuf field string location_id = 7; + * @param string $var + * @return $this + */ + public function setLocationId($var) + { + GPBUtil::checkString($var, True); + $this->location_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentResponse.php new file mode 100644 index 000000000000..645c5eb06117 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentResponse.php @@ -0,0 +1,121 @@ +google.privacy.dlp.v2.ReidentifyContentResponse + */ +class ReidentifyContentResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The re-identified item. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; + */ + protected $item = null; + /** + * An overview of the changes that were made to the `item`. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationOverview overview = 2; + */ + protected $overview = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\ContentItem $item + * The re-identified item. + * @type \Google\Cloud\Dlp\V2\TransformationOverview $overview + * An overview of the changes that were made to the `item`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The re-identified item. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; + * @return \Google\Cloud\Dlp\V2\ContentItem|null + */ + public function getItem() + { + return $this->item; + } + + public function hasItem() + { + return isset($this->item); + } + + public function clearItem() + { + unset($this->item); + } + + /** + * The re-identified item. + * + * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; + * @param \Google\Cloud\Dlp\V2\ContentItem $var + * @return $this + */ + public function setItem($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ContentItem::class); + $this->item = $var; + + return $this; + } + + /** + * An overview of the changes that were made to the `item`. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationOverview overview = 2; + * @return \Google\Cloud\Dlp\V2\TransformationOverview|null + */ + public function getOverview() + { + return $this->overview; + } + + public function hasOverview() + { + return isset($this->overview); + } + + public function clearOverview() + { + unset($this->overview); + } + + /** + * An overview of the changes that were made to the `item`. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationOverview overview = 2; + * @param \Google\Cloud\Dlp\V2\TransformationOverview $var + * @return $this + */ + public function setOverview($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationOverview::class); + $this->overview = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RelationalOperator.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RelationalOperator.php new file mode 100644 index 000000000000..6ed71c1ce458 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RelationalOperator.php @@ -0,0 +1,96 @@ +google.privacy.dlp.v2.RelationalOperator + */ +class RelationalOperator +{ + /** + * Unused + * + * Generated from protobuf enum RELATIONAL_OPERATOR_UNSPECIFIED = 0; + */ + const RELATIONAL_OPERATOR_UNSPECIFIED = 0; + /** + * Equal. Attempts to match even with incompatible types. + * + * Generated from protobuf enum EQUAL_TO = 1; + */ + const EQUAL_TO = 1; + /** + * Not equal to. Attempts to match even with incompatible types. + * + * Generated from protobuf enum NOT_EQUAL_TO = 2; + */ + const NOT_EQUAL_TO = 2; + /** + * Greater than. + * + * Generated from protobuf enum GREATER_THAN = 3; + */ + const GREATER_THAN = 3; + /** + * Less than. + * + * Generated from protobuf enum LESS_THAN = 4; + */ + const LESS_THAN = 4; + /** + * Greater than or equals. + * + * Generated from protobuf enum GREATER_THAN_OR_EQUALS = 5; + */ + const GREATER_THAN_OR_EQUALS = 5; + /** + * Less than or equals. + * + * Generated from protobuf enum LESS_THAN_OR_EQUALS = 6; + */ + const LESS_THAN_OR_EQUALS = 6; + /** + * Exists + * + * Generated from protobuf enum EXISTS = 7; + */ + const EXISTS = 7; + + private static $valueToName = [ + self::RELATIONAL_OPERATOR_UNSPECIFIED => 'RELATIONAL_OPERATOR_UNSPECIFIED', + self::EQUAL_TO => 'EQUAL_TO', + self::NOT_EQUAL_TO => 'NOT_EQUAL_TO', + self::GREATER_THAN => 'GREATER_THAN', + self::LESS_THAN => 'LESS_THAN', + self::GREATER_THAN_OR_EQUALS => 'GREATER_THAN_OR_EQUALS', + self::LESS_THAN_OR_EQUALS => 'LESS_THAN_OR_EQUALS', + self::EXISTS => 'EXISTS', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceDictionaryConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceDictionaryConfig.php new file mode 100644 index 000000000000..334777891ff9 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceDictionaryConfig.php @@ -0,0 +1,81 @@ +google.privacy.dlp.v2.ReplaceDictionaryConfig + */ +class ReplaceDictionaryConfig extends \Google\Protobuf\Internal\Message +{ + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList $word_list + * A list of words to select from for random replacement. The + * [limits](https://cloud.google.com/sensitive-data-protection/limits) page + * contains details about the size limits of dictionaries. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A list of words to select from for random replacement. The + * [limits](https://cloud.google.com/sensitive-data-protection/limits) page + * contains details about the size limits of dictionaries. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary.WordList word_list = 1; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList|null + */ + public function getWordList() + { + return $this->readOneof(1); + } + + public function hasWordList() + { + return $this->hasOneof(1); + } + + /** + * A list of words to select from for random replacement. The + * [limits](https://cloud.google.com/sensitive-data-protection/limits) page + * contains details about the size limits of dictionaries. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary.WordList word_list = 1; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList $var + * @return $this + */ + public function setWordList($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceValueConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceValueConfig.php new file mode 100644 index 000000000000..6b6b0f7a06d1 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceValueConfig.php @@ -0,0 +1,77 @@ +google.privacy.dlp.v2.ReplaceValueConfig + */ +class ReplaceValueConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Value to replace it with. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value new_value = 1; + */ + protected $new_value = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\Value $new_value + * Value to replace it with. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Value to replace it with. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value new_value = 1; + * @return \Google\Cloud\Dlp\V2\Value|null + */ + public function getNewValue() + { + return $this->new_value; + } + + public function hasNewValue() + { + return isset($this->new_value); + } + + public function clearNewValue() + { + unset($this->new_value); + } + + /** + * Value to replace it with. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value new_value = 1; + * @param \Google\Cloud\Dlp\V2\Value $var + * @return $this + */ + public function setNewValue($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); + $this->new_value = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceWithInfoTypeConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceWithInfoTypeConfig.php new file mode 100644 index 000000000000..5896285166fe --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceWithInfoTypeConfig.php @@ -0,0 +1,33 @@ +google.privacy.dlp.v2.ReplaceWithInfoTypeConfig + */ +class ReplaceWithInfoTypeConfig extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ResourceVisibility.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ResourceVisibility.php new file mode 100644 index 000000000000..091e4e5299f2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ResourceVisibility.php @@ -0,0 +1,71 @@ +google.privacy.dlp.v2.ResourceVisibility + */ +class ResourceVisibility +{ + /** + * Unused. + * + * Generated from protobuf enum RESOURCE_VISIBILITY_UNSPECIFIED = 0; + */ + const RESOURCE_VISIBILITY_UNSPECIFIED = 0; + /** + * Visible to any user. + * + * Generated from protobuf enum RESOURCE_VISIBILITY_PUBLIC = 10; + */ + const RESOURCE_VISIBILITY_PUBLIC = 10; + /** + * May contain public items. + * For example, if a Cloud Storage bucket has uniform bucket level access + * disabled, some objects inside it may be public. + * + * Generated from protobuf enum RESOURCE_VISIBILITY_INCONCLUSIVE = 15; + */ + const RESOURCE_VISIBILITY_INCONCLUSIVE = 15; + /** + * Visible only to specific users. + * + * Generated from protobuf enum RESOURCE_VISIBILITY_RESTRICTED = 20; + */ + const RESOURCE_VISIBILITY_RESTRICTED = 20; + + private static $valueToName = [ + self::RESOURCE_VISIBILITY_UNSPECIFIED => 'RESOURCE_VISIBILITY_UNSPECIFIED', + self::RESOURCE_VISIBILITY_PUBLIC => 'RESOURCE_VISIBILITY_PUBLIC', + self::RESOURCE_VISIBILITY_INCONCLUSIVE => 'RESOURCE_VISIBILITY_INCONCLUSIVE', + self::RESOURCE_VISIBILITY_RESTRICTED => 'RESOURCE_VISIBILITY_RESTRICTED', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RiskAnalysisJobConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RiskAnalysisJobConfig.php new file mode 100644 index 000000000000..d188958519c0 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RiskAnalysisJobConfig.php @@ -0,0 +1,161 @@ +google.privacy.dlp.v2.RiskAnalysisJobConfig + */ +class RiskAnalysisJobConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Privacy metric to compute. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric privacy_metric = 1; + */ + protected $privacy_metric = null; + /** + * Input dataset to compute metrics over. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable source_table = 2; + */ + protected $source_table = null; + /** + * Actions to execute at the completion of the job. Are executed in the order + * provided. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Action actions = 3; + */ + private $actions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\PrivacyMetric $privacy_metric + * Privacy metric to compute. + * @type \Google\Cloud\Dlp\V2\BigQueryTable $source_table + * Input dataset to compute metrics over. + * @type array<\Google\Cloud\Dlp\V2\Action>|\Google\Protobuf\Internal\RepeatedField $actions + * Actions to execute at the completion of the job. Are executed in the order + * provided. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Privacy metric to compute. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric privacy_metric = 1; + * @return \Google\Cloud\Dlp\V2\PrivacyMetric|null + */ + public function getPrivacyMetric() + { + return $this->privacy_metric; + } + + public function hasPrivacyMetric() + { + return isset($this->privacy_metric); + } + + public function clearPrivacyMetric() + { + unset($this->privacy_metric); + } + + /** + * Privacy metric to compute. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric privacy_metric = 1; + * @param \Google\Cloud\Dlp\V2\PrivacyMetric $var + * @return $this + */ + public function setPrivacyMetric($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric::class); + $this->privacy_metric = $var; + + return $this; + } + + /** + * Input dataset to compute metrics over. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable source_table = 2; + * @return \Google\Cloud\Dlp\V2\BigQueryTable|null + */ + public function getSourceTable() + { + return $this->source_table; + } + + public function hasSourceTable() + { + return isset($this->source_table); + } + + public function clearSourceTable() + { + unset($this->source_table); + } + + /** + * Input dataset to compute metrics over. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable source_table = 2; + * @param \Google\Cloud\Dlp\V2\BigQueryTable $var + * @return $this + */ + public function setSourceTable($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); + $this->source_table = $var; + + return $this; + } + + /** + * Actions to execute at the completion of the job. Are executed in the order + * provided. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Action actions = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getActions() + { + return $this->actions; + } + + /** + * Actions to execute at the completion of the job. Are executed in the order + * provided. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Action actions = 3; + * @param array<\Google\Cloud\Dlp\V2\Action>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setActions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Action::class); + $this->actions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Schedule.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Schedule.php new file mode 100644 index 000000000000..f7fe89d24dac --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Schedule.php @@ -0,0 +1,90 @@ +google.privacy.dlp.v2.Schedule + */ +class Schedule extends \Google\Protobuf\Internal\Message +{ + protected $option; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Protobuf\Duration $recurrence_period_duration + * With this option a job is started on a regular periodic basis. For + * example: every day (86400 seconds). + * A scheduled start time will be skipped if the previous + * execution has not ended when its scheduled time occurs. + * This value must be set to a time duration greater than or equal + * to 1 day and can be no longer than 60 days. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * With this option a job is started on a regular periodic basis. For + * example: every day (86400 seconds). + * A scheduled start time will be skipped if the previous + * execution has not ended when its scheduled time occurs. + * This value must be set to a time duration greater than or equal + * to 1 day and can be no longer than 60 days. + * + * Generated from protobuf field .google.protobuf.Duration recurrence_period_duration = 1; + * @return \Google\Protobuf\Duration|null + */ + public function getRecurrencePeriodDuration() + { + return $this->readOneof(1); + } + + public function hasRecurrencePeriodDuration() + { + return $this->hasOneof(1); + } + + /** + * With this option a job is started on a regular periodic basis. For + * example: every day (86400 seconds). + * A scheduled start time will be skipped if the previous + * execution has not ended when its scheduled time occurs. + * This value must be set to a time duration greater than or equal + * to 1 day and can be no longer than 60 days. + * + * Generated from protobuf field .google.protobuf.Duration recurrence_period_duration = 1; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setRecurrencePeriodDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getOption() + { + return $this->whichOneof("option"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsRequest.php new file mode 100644 index 000000000000..e7293ed166f1 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsRequest.php @@ -0,0 +1,192 @@ +google.privacy.dlp.v2.SearchConnectionsRequest + */ +class SearchConnectionsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent name, typically an organization, without location. + * For example: `organizations/12345678`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. Number of results per page, max 1000. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. Page token from a previous page to return the next set of + * results. If set, all other request fields must match the original request. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + /** + * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $filter = ''; + + /** + * @param string $parent Required. Parent name, typically an organization, without location. + * For example: `organizations/12345678`. Please see + * {@see DlpServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\SearchConnectionsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Parent name, typically an organization, without location. + * For example: `organizations/12345678`. + * @type int $page_size + * Optional. Number of results per page, max 1000. + * @type string $page_token + * Optional. Page token from a previous page to return the next set of + * results. If set, all other request fields must match the original request. + * @type string $filter + * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent name, typically an organization, without location. + * For example: `organizations/12345678`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent name, typically an organization, without location. + * For example: `organizations/12345678`. + * + * 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; + } + + /** + * Optional. Number of results per page, max 1000. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Optional. Number of results per page, max 1000. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * Optional. Page token from a previous page to return the next set of + * results. If set, all other request fields must match the original request. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. Page token from a previous page to return the next set of + * results. If set, all other request fields must match the original request. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsResponse.php new file mode 100644 index 000000000000..291026d1abed --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsResponse.php @@ -0,0 +1,113 @@ +google.privacy.dlp.v2.SearchConnectionsResponse + */ +class SearchConnectionsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * List of connections that match the search query. Note that only a subset + * of the fields will be populated, and only "name" is guaranteed to be set. + * For full details of a Connection, call GetConnection with the name. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Connection connections = 1; + */ + private $connections; + /** + * Token to retrieve the next page of results. An empty value means there are + * 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<\Google\Cloud\Dlp\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $connections + * List of connections that match the search query. Note that only a subset + * of the fields will be populated, and only "name" is guaranteed to be set. + * For full details of a Connection, call GetConnection with the name. + * @type string $next_page_token + * Token to retrieve the next page of results. An empty value means there are + * no more results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * List of connections that match the search query. Note that only a subset + * of the fields will be populated, and only "name" is guaranteed to be set. + * For full details of a Connection, call GetConnection with the name. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Connection connections = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getConnections() + { + return $this->connections; + } + + /** + * List of connections that match the search query. Note that only a subset + * of the fields will be populated, and only "name" is guaranteed to be set. + * For full details of a Connection, call GetConnection with the name. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Connection connections = 1; + * @param array<\Google\Cloud\Dlp\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setConnections($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Connection::class); + $this->connections = $arr; + + return $this; + } + + /** + * Token to retrieve the next page of results. An empty value means there are + * no more results. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results. An empty value means there are + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretManagerCredential.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretManagerCredential.php new file mode 100644 index 000000000000..280526b8b2ab --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretManagerCredential.php @@ -0,0 +1,108 @@ +google.privacy.dlp.v2.SecretManagerCredential + */ +class SecretManagerCredential extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The username. + * + * Generated from protobuf field string username = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $username = ''; + /** + * Required. The name of the Secret Manager resource that stores the password, + * in the form `projects/project-id/secrets/secret-name/versions/version`. + * + * Generated from protobuf field string password_secret_version_name = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $password_secret_version_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $username + * Required. The username. + * @type string $password_secret_version_name + * Required. The name of the Secret Manager resource that stores the password, + * in the form `projects/project-id/secrets/secret-name/versions/version`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. The username. + * + * Generated from protobuf field string username = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getUsername() + { + return $this->username; + } + + /** + * Required. The username. + * + * Generated from protobuf field string username = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setUsername($var) + { + GPBUtil::checkString($var, True); + $this->username = $var; + + return $this; + } + + /** + * Required. The name of the Secret Manager resource that stores the password, + * in the form `projects/project-id/secrets/secret-name/versions/version`. + * + * Generated from protobuf field string password_secret_version_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getPasswordSecretVersionName() + { + return $this->password_secret_version_name; + } + + /** + * Required. The name of the Secret Manager resource that stores the password, + * in the form `projects/project-id/secrets/secret-name/versions/version`. + * + * Generated from protobuf field string password_secret_version_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setPasswordSecretVersionName($var) + { + GPBUtil::checkString($var, True); + $this->password_secret_version_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretsDiscoveryTarget.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretsDiscoveryTarget.php new file mode 100644 index 000000000000..1e5a804a0f78 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretsDiscoveryTarget.php @@ -0,0 +1,41 @@ +google.privacy.dlp.v2.SecretsDiscoveryTarget + */ +class SecretsDiscoveryTarget extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore.php new file mode 100644 index 000000000000..90daf36c4bf9 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore.php @@ -0,0 +1,68 @@ +google.privacy.dlp.v2.SensitivityScore + */ +class SensitivityScore extends \Google\Protobuf\Internal\Message +{ + /** + * The sensitivity score applied to the resource. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore.SensitivityScoreLevel score = 1; + */ + protected $score = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $score + * The sensitivity score applied to the resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * The sensitivity score applied to the resource. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore.SensitivityScoreLevel score = 1; + * @return int + */ + public function getScore() + { + return $this->score; + } + + /** + * The sensitivity score applied to the resource. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore.SensitivityScoreLevel score = 1; + * @param int $var + * @return $this + */ + public function setScore($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\SensitivityScore\SensitivityScoreLevel::class); + $this->score = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore/SensitivityScoreLevel.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore/SensitivityScoreLevel.php new file mode 100644 index 000000000000..dd35a70fb36d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore/SensitivityScoreLevel.php @@ -0,0 +1,78 @@ +google.privacy.dlp.v2.SensitivityScore.SensitivityScoreLevel + */ +class SensitivityScoreLevel +{ + /** + * Unused. + * + * Generated from protobuf enum SENSITIVITY_SCORE_UNSPECIFIED = 0; + */ + const SENSITIVITY_SCORE_UNSPECIFIED = 0; + /** + * No sensitive information detected. The resource isn't publicly + * accessible. + * + * Generated from protobuf enum SENSITIVITY_LOW = 10; + */ + const SENSITIVITY_LOW = 10; + /** + * Medium risk. Contains personally identifiable information (PII), + * potentially sensitive data, or fields with free-text data that are at a + * higher risk of having intermittent sensitive data. Consider limiting + * access. + * + * Generated from protobuf enum SENSITIVITY_MODERATE = 20; + */ + const SENSITIVITY_MODERATE = 20; + /** + * High risk. Sensitive personally identifiable information (SPII) can be + * present. Exfiltration of data can lead to user data loss. + * Re-identification of users might be possible. Consider limiting usage and + * or removing SPII. + * + * Generated from protobuf enum SENSITIVITY_HIGH = 30; + */ + const SENSITIVITY_HIGH = 30; + + private static $valueToName = [ + self::SENSITIVITY_SCORE_UNSPECIFIED => 'SENSITIVITY_SCORE_UNSPECIFIED', + self::SENSITIVITY_LOW => 'SENSITIVITY_LOW', + self::SENSITIVITY_MODERATE => 'SENSITIVITY_MODERATE', + self::SENSITIVITY_HIGH => 'SENSITIVITY_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(SensitivityScoreLevel::class, \Google\Cloud\Dlp\V2\SensitivityScore_SensitivityScoreLevel::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable.php new file mode 100644 index 000000000000..533649a094e9 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable.php @@ -0,0 +1,165 @@ +google.privacy.dlp.v2.StatisticalTable + */ +class StatisticalTable extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Auxiliary table location. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $table = null; + /** + * Required. Quasi-identifier columns. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.StatisticalTable.QuasiIdentifierField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + private $quasi_ids; + /** + * Required. The relative frequency column must contain a floating-point + * number between 0 and 1 (inclusive). Null values are assumed to be zero. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId relative_frequency = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $relative_frequency = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\BigQueryTable $table + * Required. Auxiliary table location. + * @type array<\Google\Cloud\Dlp\V2\StatisticalTable\QuasiIdentifierField>|\Google\Protobuf\Internal\RepeatedField $quasi_ids + * Required. Quasi-identifier columns. + * @type \Google\Cloud\Dlp\V2\FieldId $relative_frequency + * Required. The relative frequency column must contain a floating-point + * number between 0 and 1 (inclusive). Null values are assumed to be zero. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Auxiliary table location. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\BigQueryTable|null + */ + public function getTable() + { + return $this->table; + } + + public function hasTable() + { + return isset($this->table); + } + + public function clearTable() + { + unset($this->table); + } + + /** + * Required. Auxiliary table location. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\BigQueryTable $var + * @return $this + */ + public function setTable($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); + $this->table = $var; + + return $this; + } + + /** + * Required. Quasi-identifier columns. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.StatisticalTable.QuasiIdentifierField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getQuasiIds() + { + return $this->quasi_ids; + } + + /** + * Required. Quasi-identifier columns. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.StatisticalTable.QuasiIdentifierField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param array<\Google\Cloud\Dlp\V2\StatisticalTable\QuasiIdentifierField>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setQuasiIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\StatisticalTable\QuasiIdentifierField::class); + $this->quasi_ids = $arr; + + return $this; + } + + /** + * Required. The relative frequency column must contain a floating-point + * number between 0 and 1 (inclusive). Null values are assumed to be zero. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId relative_frequency = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getRelativeFrequency() + { + return $this->relative_frequency; + } + + public function hasRelativeFrequency() + { + return isset($this->relative_frequency); + } + + public function clearRelativeFrequency() + { + unset($this->relative_frequency); + } + + /** + * Required. The relative frequency column must contain a floating-point + * number between 0 and 1 (inclusive). Null values are assumed to be zero. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId relative_frequency = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setRelativeFrequency($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->relative_frequency = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable/QuasiIdentifierField.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable/QuasiIdentifierField.php new file mode 100644 index 000000000000..eac02a9161ed --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable/QuasiIdentifierField.php @@ -0,0 +1,123 @@ +google.privacy.dlp.v2.StatisticalTable.QuasiIdentifierField + */ +class QuasiIdentifierField extends \Google\Protobuf\Internal\Message +{ + /** + * Identifies the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + */ + protected $field = null; + /** + * A column can be tagged with a custom tag. In this case, the user must + * indicate an auxiliary table that contains statistical information on + * the possible values of this column (below). + * + * Generated from protobuf field string custom_tag = 2; + */ + protected $custom_tag = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\FieldId $field + * Identifies the column. + * @type string $custom_tag + * A column can be tagged with a custom tag. In this case, the user must + * indicate an auxiliary table that contains statistical information on + * the possible values of this column (below). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Identifies the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getField() + { + return $this->field; + } + + public function hasField() + { + return isset($this->field); + } + + public function clearField() + { + unset($this->field); + } + + /** + * Identifies the column. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setField($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->field = $var; + + return $this; + } + + /** + * A column can be tagged with a custom tag. In this case, the user must + * indicate an auxiliary table that contains statistical information on + * the possible values of this column (below). + * + * Generated from protobuf field string custom_tag = 2; + * @return string + */ + public function getCustomTag() + { + return $this->custom_tag; + } + + /** + * A column can be tagged with a custom tag. In this case, the user must + * indicate an auxiliary table that contains statistical information on + * the possible values of this column (below). + * + * Generated from protobuf field string custom_tag = 2; + * @param string $var + * @return $this + */ + public function setCustomTag($var) + { + GPBUtil::checkString($var, True); + $this->custom_tag = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(QuasiIdentifierField::class, \Google\Cloud\Dlp\V2\StatisticalTable_QuasiIdentifierField::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig.php new file mode 100644 index 000000000000..630d3b44dda2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig.php @@ -0,0 +1,218 @@ +google.privacy.dlp.v2.StorageConfig + */ +class StorageConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Configuration of the timespan of the items to include in scanning. + * + * Generated from protobuf field .google.privacy.dlp.v2.StorageConfig.TimespanConfig timespan_config = 6; + */ + protected $timespan_config = null; + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\DatastoreOptions $datastore_options + * Google Cloud Datastore options. + * @type \Google\Cloud\Dlp\V2\CloudStorageOptions $cloud_storage_options + * Cloud Storage options. + * @type \Google\Cloud\Dlp\V2\BigQueryOptions $big_query_options + * BigQuery options. + * @type \Google\Cloud\Dlp\V2\HybridOptions $hybrid_options + * Hybrid inspection options. + * @type \Google\Cloud\Dlp\V2\StorageConfig\TimespanConfig $timespan_config + * Configuration of the timespan of the items to include in scanning. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Google Cloud Datastore options. + * + * Generated from protobuf field .google.privacy.dlp.v2.DatastoreOptions datastore_options = 2; + * @return \Google\Cloud\Dlp\V2\DatastoreOptions|null + */ + public function getDatastoreOptions() + { + return $this->readOneof(2); + } + + public function hasDatastoreOptions() + { + return $this->hasOneof(2); + } + + /** + * Google Cloud Datastore options. + * + * Generated from protobuf field .google.privacy.dlp.v2.DatastoreOptions datastore_options = 2; + * @param \Google\Cloud\Dlp\V2\DatastoreOptions $var + * @return $this + */ + public function setDatastoreOptions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DatastoreOptions::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Cloud Storage options. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions cloud_storage_options = 3; + * @return \Google\Cloud\Dlp\V2\CloudStorageOptions|null + */ + public function getCloudStorageOptions() + { + return $this->readOneof(3); + } + + public function hasCloudStorageOptions() + { + return $this->hasOneof(3); + } + + /** + * Cloud Storage options. + * + * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions cloud_storage_options = 3; + * @param \Google\Cloud\Dlp\V2\CloudStorageOptions $var + * @return $this + */ + public function setCloudStorageOptions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudStorageOptions::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * BigQuery options. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryOptions big_query_options = 4; + * @return \Google\Cloud\Dlp\V2\BigQueryOptions|null + */ + public function getBigQueryOptions() + { + return $this->readOneof(4); + } + + public function hasBigQueryOptions() + { + return $this->hasOneof(4); + } + + /** + * BigQuery options. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryOptions big_query_options = 4; + * @param \Google\Cloud\Dlp\V2\BigQueryOptions $var + * @return $this + */ + public function setBigQueryOptions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryOptions::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Hybrid inspection options. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridOptions hybrid_options = 9; + * @return \Google\Cloud\Dlp\V2\HybridOptions|null + */ + public function getHybridOptions() + { + return $this->readOneof(9); + } + + public function hasHybridOptions() + { + return $this->hasOneof(9); + } + + /** + * Hybrid inspection options. + * + * Generated from protobuf field .google.privacy.dlp.v2.HybridOptions hybrid_options = 9; + * @param \Google\Cloud\Dlp\V2\HybridOptions $var + * @return $this + */ + public function setHybridOptions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\HybridOptions::class); + $this->writeOneof(9, $var); + + return $this; + } + + /** + * Configuration of the timespan of the items to include in scanning. + * + * Generated from protobuf field .google.privacy.dlp.v2.StorageConfig.TimespanConfig timespan_config = 6; + * @return \Google\Cloud\Dlp\V2\StorageConfig\TimespanConfig|null + */ + public function getTimespanConfig() + { + return $this->timespan_config; + } + + public function hasTimespanConfig() + { + return isset($this->timespan_config); + } + + public function clearTimespanConfig() + { + unset($this->timespan_config); + } + + /** + * Configuration of the timespan of the items to include in scanning. + * + * Generated from protobuf field .google.privacy.dlp.v2.StorageConfig.TimespanConfig timespan_config = 6; + * @param \Google\Cloud\Dlp\V2\StorageConfig\TimespanConfig $var + * @return $this + */ + public function setTimespanConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StorageConfig\TimespanConfig::class); + $this->timespan_config = $var; + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig/TimespanConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig/TimespanConfig.php new file mode 100644 index 000000000000..102874db60d0 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig/TimespanConfig.php @@ -0,0 +1,367 @@ +google.privacy.dlp.v2.StorageConfig.TimespanConfig + */ +class TimespanConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Exclude files, tables, or rows older than this value. + * If not set, no lower time limit is applied. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 1; + */ + protected $start_time = null; + /** + * Exclude files, tables, or rows newer than this value. + * If not set, no upper time limit is applied. + * + * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; + */ + protected $end_time = null; + /** + * Specification of the field containing the timestamp of scanned items. + * Used for data sources like Datastore and BigQuery. + * For BigQuery + * If this value is not specified and the table was modified between the + * given start and end times, the entire table will be scanned. If this + * value is specified, then rows are filtered based on the given start and + * end times. Rows with a `NULL` value in the provided BigQuery column are + * skipped. + * Valid data types of the provided BigQuery column are: `INTEGER`, `DATE`, + * `TIMESTAMP`, and `DATETIME`. + * If your BigQuery table is [partitioned at ingestion + * time](https://cloud.google.com/bigquery/docs/partitioned-tables#ingestion_time), + * you can use any of the following pseudo-columns as your timestamp field. + * When used with Cloud DLP, these pseudo-column names are case sensitive. + *
    + *
  • _PARTITIONTIME
  • + *
  • _PARTITIONDATE
  • + *
  • _PARTITION_LOAD_TIME
  • + *
+ * For Datastore + * If this value is specified, then entities are filtered based on the given + * start and end times. If an entity does not contain the provided timestamp + * property or contains empty or invalid values, then it is included. + * Valid data types of the provided timestamp property are: `TIMESTAMP`. + * See the + * [known + * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-timespan) + * related to this operation. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId timestamp_field = 3; + */ + protected $timestamp_field = null; + /** + * When the job is started by a JobTrigger we will automatically figure out + * a valid start_time to avoid scanning files that have not been modified + * since the last time the JobTrigger executed. This will be based on the + * time of the execution of the last run of the JobTrigger or the timespan + * end_time used in the last run of the JobTrigger. + * **For BigQuery** + * Inspect jobs triggered by automatic population will scan data that is at + * least three hours old when the job starts. This is because streaming + * buffer rows are not read during inspection and reading up to the current + * timestamp will result in skipped rows. + * See the [known + * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#recently-streamed-data) + * related to this operation. + * + * Generated from protobuf field bool enable_auto_population_of_timespan_config = 4; + */ + protected $enable_auto_population_of_timespan_config = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Protobuf\Timestamp $start_time + * Exclude files, tables, or rows older than this value. + * If not set, no lower time limit is applied. + * @type \Google\Protobuf\Timestamp $end_time + * Exclude files, tables, or rows newer than this value. + * If not set, no upper time limit is applied. + * @type \Google\Cloud\Dlp\V2\FieldId $timestamp_field + * Specification of the field containing the timestamp of scanned items. + * Used for data sources like Datastore and BigQuery. + * For BigQuery + * If this value is not specified and the table was modified between the + * given start and end times, the entire table will be scanned. If this + * value is specified, then rows are filtered based on the given start and + * end times. Rows with a `NULL` value in the provided BigQuery column are + * skipped. + * Valid data types of the provided BigQuery column are: `INTEGER`, `DATE`, + * `TIMESTAMP`, and `DATETIME`. + * If your BigQuery table is [partitioned at ingestion + * time](https://cloud.google.com/bigquery/docs/partitioned-tables#ingestion_time), + * you can use any of the following pseudo-columns as your timestamp field. + * When used with Cloud DLP, these pseudo-column names are case sensitive. + *
    + *
  • _PARTITIONTIME
  • + *
  • _PARTITIONDATE
  • + *
  • _PARTITION_LOAD_TIME
  • + *
+ * For Datastore + * If this value is specified, then entities are filtered based on the given + * start and end times. If an entity does not contain the provided timestamp + * property or contains empty or invalid values, then it is included. + * Valid data types of the provided timestamp property are: `TIMESTAMP`. + * See the + * [known + * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-timespan) + * related to this operation. + * @type bool $enable_auto_population_of_timespan_config + * When the job is started by a JobTrigger we will automatically figure out + * a valid start_time to avoid scanning files that have not been modified + * since the last time the JobTrigger executed. This will be based on the + * time of the execution of the last run of the JobTrigger or the timespan + * end_time used in the last run of the JobTrigger. + * **For BigQuery** + * Inspect jobs triggered by automatic population will scan data that is at + * least three hours old when the job starts. This is because streaming + * buffer rows are not read during inspection and reading up to the current + * timestamp will result in skipped rows. + * See the [known + * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#recently-streamed-data) + * related to this operation. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Exclude files, tables, or rows older than this value. + * If not set, no lower time limit is applied. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 1; + * @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); + } + + /** + * Exclude files, tables, or rows older than this value. + * If not set, no lower time limit is applied. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 1; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setStartTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->start_time = $var; + + return $this; + } + + /** + * Exclude files, tables, or rows newer than this value. + * If not set, no upper time limit is applied. + * + * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; + * @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); + } + + /** + * Exclude files, tables, or rows newer than this value. + * If not set, no upper time limit is applied. + * + * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setEndTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->end_time = $var; + + return $this; + } + + /** + * Specification of the field containing the timestamp of scanned items. + * Used for data sources like Datastore and BigQuery. + * For BigQuery + * If this value is not specified and the table was modified between the + * given start and end times, the entire table will be scanned. If this + * value is specified, then rows are filtered based on the given start and + * end times. Rows with a `NULL` value in the provided BigQuery column are + * skipped. + * Valid data types of the provided BigQuery column are: `INTEGER`, `DATE`, + * `TIMESTAMP`, and `DATETIME`. + * If your BigQuery table is [partitioned at ingestion + * time](https://cloud.google.com/bigquery/docs/partitioned-tables#ingestion_time), + * you can use any of the following pseudo-columns as your timestamp field. + * When used with Cloud DLP, these pseudo-column names are case sensitive. + *
    + *
  • _PARTITIONTIME
  • + *
  • _PARTITIONDATE
  • + *
  • _PARTITION_LOAD_TIME
  • + *
+ * For Datastore + * If this value is specified, then entities are filtered based on the given + * start and end times. If an entity does not contain the provided timestamp + * property or contains empty or invalid values, then it is included. + * Valid data types of the provided timestamp property are: `TIMESTAMP`. + * See the + * [known + * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-timespan) + * related to this operation. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId timestamp_field = 3; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getTimestampField() + { + return $this->timestamp_field; + } + + public function hasTimestampField() + { + return isset($this->timestamp_field); + } + + public function clearTimestampField() + { + unset($this->timestamp_field); + } + + /** + * Specification of the field containing the timestamp of scanned items. + * Used for data sources like Datastore and BigQuery. + * For BigQuery + * If this value is not specified and the table was modified between the + * given start and end times, the entire table will be scanned. If this + * value is specified, then rows are filtered based on the given start and + * end times. Rows with a `NULL` value in the provided BigQuery column are + * skipped. + * Valid data types of the provided BigQuery column are: `INTEGER`, `DATE`, + * `TIMESTAMP`, and `DATETIME`. + * If your BigQuery table is [partitioned at ingestion + * time](https://cloud.google.com/bigquery/docs/partitioned-tables#ingestion_time), + * you can use any of the following pseudo-columns as your timestamp field. + * When used with Cloud DLP, these pseudo-column names are case sensitive. + *
    + *
  • _PARTITIONTIME
  • + *
  • _PARTITIONDATE
  • + *
  • _PARTITION_LOAD_TIME
  • + *
+ * For Datastore + * If this value is specified, then entities are filtered based on the given + * start and end times. If an entity does not contain the provided timestamp + * property or contains empty or invalid values, then it is included. + * Valid data types of the provided timestamp property are: `TIMESTAMP`. + * See the + * [known + * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-timespan) + * related to this operation. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId timestamp_field = 3; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setTimestampField($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->timestamp_field = $var; + + return $this; + } + + /** + * When the job is started by a JobTrigger we will automatically figure out + * a valid start_time to avoid scanning files that have not been modified + * since the last time the JobTrigger executed. This will be based on the + * time of the execution of the last run of the JobTrigger or the timespan + * end_time used in the last run of the JobTrigger. + * **For BigQuery** + * Inspect jobs triggered by automatic population will scan data that is at + * least three hours old when the job starts. This is because streaming + * buffer rows are not read during inspection and reading up to the current + * timestamp will result in skipped rows. + * See the [known + * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#recently-streamed-data) + * related to this operation. + * + * Generated from protobuf field bool enable_auto_population_of_timespan_config = 4; + * @return bool + */ + public function getEnableAutoPopulationOfTimespanConfig() + { + return $this->enable_auto_population_of_timespan_config; + } + + /** + * When the job is started by a JobTrigger we will automatically figure out + * a valid start_time to avoid scanning files that have not been modified + * since the last time the JobTrigger executed. This will be based on the + * time of the execution of the last run of the JobTrigger or the timespan + * end_time used in the last run of the JobTrigger. + * **For BigQuery** + * Inspect jobs triggered by automatic population will scan data that is at + * least three hours old when the job starts. This is because streaming + * buffer rows are not read during inspection and reading up to the current + * timestamp will result in skipped rows. + * See the [known + * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#recently-streamed-data) + * related to this operation. + * + * Generated from protobuf field bool enable_auto_population_of_timespan_config = 4; + * @param bool $var + * @return $this + */ + public function setEnableAutoPopulationOfTimespanConfig($var) + { + GPBUtil::checkBool($var); + $this->enable_auto_population_of_timespan_config = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(TimespanConfig::class, \Google\Cloud\Dlp\V2\StorageConfig_TimespanConfig::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageMetadataLabel.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageMetadataLabel.php new file mode 100644 index 000000000000..e982b805e95c --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageMetadataLabel.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.StorageMetadataLabel + */ +class StorageMetadataLabel extends \Google\Protobuf\Internal\Message +{ + /** + * Label name. + * + * Generated from protobuf field string key = 1; + */ + protected $key = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $key + * Label name. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Label name. + * + * Generated from protobuf field string key = 1; + * @return string + */ + public function getKey() + { + return $this->key; + } + + /** + * Label name. + * + * Generated from protobuf field string key = 1; + * @param string $var + * @return $this + */ + public function setKey($var) + { + GPBUtil::checkString($var, True); + $this->key = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoType.php new file mode 100644 index 000000000000..156e6335b473 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoType.php @@ -0,0 +1,150 @@ +google.privacy.dlp.v2.StoredInfoType + */ +class StoredInfoType extends \Google\Protobuf\Internal\Message +{ + /** + * Resource name. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Current version of the stored info type. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeVersion current_version = 2; + */ + protected $current_version = null; + /** + * Pending versions of the stored info type. Empty if no versions are + * pending. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.StoredInfoTypeVersion pending_versions = 3; + */ + private $pending_versions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Resource name. + * @type \Google\Cloud\Dlp\V2\StoredInfoTypeVersion $current_version + * Current version of the stored info type. + * @type array<\Google\Cloud\Dlp\V2\StoredInfoTypeVersion>|\Google\Protobuf\Internal\RepeatedField $pending_versions + * Pending versions of the stored info type. Empty if no versions are + * pending. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Resource name. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Resource 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; + } + + /** + * Current version of the stored info type. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeVersion current_version = 2; + * @return \Google\Cloud\Dlp\V2\StoredInfoTypeVersion|null + */ + public function getCurrentVersion() + { + return $this->current_version; + } + + public function hasCurrentVersion() + { + return isset($this->current_version); + } + + public function clearCurrentVersion() + { + unset($this->current_version); + } + + /** + * Current version of the stored info type. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeVersion current_version = 2; + * @param \Google\Cloud\Dlp\V2\StoredInfoTypeVersion $var + * @return $this + */ + public function setCurrentVersion($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StoredInfoTypeVersion::class); + $this->current_version = $var; + + return $this; + } + + /** + * Pending versions of the stored info type. Empty if no versions are + * pending. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.StoredInfoTypeVersion pending_versions = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPendingVersions() + { + return $this->pending_versions; + } + + /** + * Pending versions of the stored info type. Empty if no versions are + * pending. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.StoredInfoTypeVersion pending_versions = 3; + * @param array<\Google\Cloud\Dlp\V2\StoredInfoTypeVersion>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPendingVersions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\StoredInfoTypeVersion::class); + $this->pending_versions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeConfig.php new file mode 100644 index 000000000000..ac6a4b96e563 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeConfig.php @@ -0,0 +1,211 @@ +google.privacy.dlp.v2.StoredInfoTypeConfig + */ +class StoredInfoTypeConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Display name of the StoredInfoType (max 256 characters). + * + * Generated from protobuf field string display_name = 1; + */ + protected $display_name = ''; + /** + * Description of the StoredInfoType (max 256 characters). + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $display_name + * Display name of the StoredInfoType (max 256 characters). + * @type string $description + * Description of the StoredInfoType (max 256 characters). + * @type \Google\Cloud\Dlp\V2\LargeCustomDictionaryConfig $large_custom_dictionary + * StoredInfoType where findings are defined by a dictionary of phrases. + * @type \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary $dictionary + * Store dictionary-based CustomInfoType. + * @type \Google\Cloud\Dlp\V2\CustomInfoType\Regex $regex + * Store regular expression-based StoredInfoType. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Display name of the StoredInfoType (max 256 characters). + * + * Generated from protobuf field string display_name = 1; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Display name of the StoredInfoType (max 256 characters). + * + * Generated from protobuf field string display_name = 1; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * Description of the StoredInfoType (max 256 characters). + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Description of the StoredInfoType (max 256 characters). + * + * 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; + } + + /** + * StoredInfoType where findings are defined by a dictionary of phrases. + * + * Generated from protobuf field .google.privacy.dlp.v2.LargeCustomDictionaryConfig large_custom_dictionary = 3; + * @return \Google\Cloud\Dlp\V2\LargeCustomDictionaryConfig|null + */ + public function getLargeCustomDictionary() + { + return $this->readOneof(3); + } + + public function hasLargeCustomDictionary() + { + return $this->hasOneof(3); + } + + /** + * StoredInfoType where findings are defined by a dictionary of phrases. + * + * Generated from protobuf field .google.privacy.dlp.v2.LargeCustomDictionaryConfig large_custom_dictionary = 3; + * @param \Google\Cloud\Dlp\V2\LargeCustomDictionaryConfig $var + * @return $this + */ + public function setLargeCustomDictionary($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\LargeCustomDictionaryConfig::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Store dictionary-based CustomInfoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary dictionary = 4; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary|null + */ + public function getDictionary() + { + return $this->readOneof(4); + } + + public function hasDictionary() + { + return $this->hasOneof(4); + } + + /** + * Store dictionary-based CustomInfoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary dictionary = 4; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary $var + * @return $this + */ + public function setDictionary($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Store regular expression-based StoredInfoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex regex = 5; + * @return \Google\Cloud\Dlp\V2\CustomInfoType\Regex|null + */ + public function getRegex() + { + return $this->readOneof(5); + } + + public function hasRegex() + { + return $this->hasOneof(5); + } + + /** + * Store regular expression-based StoredInfoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex regex = 5; + * @param \Google\Cloud\Dlp\V2\CustomInfoType\Regex $var + * @return $this + */ + public function setRegex($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Regex::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeState.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeState.php new file mode 100644 index 000000000000..8b2ebfc111d0 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeState.php @@ -0,0 +1,78 @@ +google.privacy.dlp.v2.StoredInfoTypeState + */ +class StoredInfoTypeState +{ + /** + * Unused + * + * Generated from protobuf enum STORED_INFO_TYPE_STATE_UNSPECIFIED = 0; + */ + const STORED_INFO_TYPE_STATE_UNSPECIFIED = 0; + /** + * StoredInfoType version is being created. + * + * Generated from protobuf enum PENDING = 1; + */ + const PENDING = 1; + /** + * StoredInfoType version is ready for use. + * + * Generated from protobuf enum READY = 2; + */ + const READY = 2; + /** + * StoredInfoType creation failed. All relevant error messages are returned in + * the `StoredInfoTypeVersion` message. + * + * Generated from protobuf enum FAILED = 3; + */ + const FAILED = 3; + /** + * StoredInfoType is no longer valid because artifacts stored in + * user-controlled storage were modified. To fix an invalid StoredInfoType, + * use the `UpdateStoredInfoType` method to create a new version. + * + * Generated from protobuf enum INVALID = 4; + */ + const INVALID = 4; + + private static $valueToName = [ + self::STORED_INFO_TYPE_STATE_UNSPECIFIED => 'STORED_INFO_TYPE_STATE_UNSPECIFIED', + self::PENDING => 'PENDING', + self::READY => 'READY', + self::FAILED => 'FAILED', + self::INVALID => 'INVALID', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeStats.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeStats.php new file mode 100644 index 000000000000..b6c9b0b25919 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeStats.php @@ -0,0 +1,75 @@ +google.privacy.dlp.v2.StoredInfoTypeStats + */ +class StoredInfoTypeStats extends \Google\Protobuf\Internal\Message +{ + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\LargeCustomDictionaryStats $large_custom_dictionary + * StoredInfoType where findings are defined by a dictionary of phrases. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * StoredInfoType where findings are defined by a dictionary of phrases. + * + * Generated from protobuf field .google.privacy.dlp.v2.LargeCustomDictionaryStats large_custom_dictionary = 1; + * @return \Google\Cloud\Dlp\V2\LargeCustomDictionaryStats|null + */ + public function getLargeCustomDictionary() + { + return $this->readOneof(1); + } + + public function hasLargeCustomDictionary() + { + return $this->hasOneof(1); + } + + /** + * StoredInfoType where findings are defined by a dictionary of phrases. + * + * Generated from protobuf field .google.privacy.dlp.v2.LargeCustomDictionaryStats large_custom_dictionary = 1; + * @param \Google\Cloud\Dlp\V2\LargeCustomDictionaryStats $var + * @return $this + */ + public function setLargeCustomDictionary($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\LargeCustomDictionaryStats::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeVersion.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeVersion.php new file mode 100644 index 000000000000..a9ad81826cb3 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeVersion.php @@ -0,0 +1,282 @@ +google.privacy.dlp.v2.StoredInfoTypeVersion + */ +class StoredInfoTypeVersion extends \Google\Protobuf\Internal\Message +{ + /** + * StoredInfoType configuration. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 1; + */ + protected $config = null; + /** + * Create timestamp of the version. Read-only, determined by the system + * when the version is created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; + */ + protected $create_time = null; + /** + * Stored info type version state. Read-only, updated by the system + * during dictionary creation. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeState state = 3; + */ + protected $state = 0; + /** + * Errors that occurred when creating this storedInfoType version, or + * anomalies detected in the storedInfoType data that render it unusable. Only + * the five most recent errors will be displayed, with the most recent error + * appearing first. + * For example, some of the data for stored custom dictionaries is put in + * the user's Cloud Storage bucket, and if this data is modified or + * deleted by the user or another system, the dictionary becomes invalid. + * If any errors occur, fix the problem indicated by the error message and + * use the UpdateStoredInfoType API method to create another version of the + * storedInfoType to continue using it, reusing the same `config` if it was + * not the source of the error. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 4; + */ + private $errors; + /** + * Statistics about this storedInfoType version. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeStats stats = 5; + */ + protected $stats = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config + * StoredInfoType configuration. + * @type \Google\Protobuf\Timestamp $create_time + * Create timestamp of the version. Read-only, determined by the system + * when the version is created. + * @type int $state + * Stored info type version state. Read-only, updated by the system + * during dictionary creation. + * @type array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $errors + * Errors that occurred when creating this storedInfoType version, or + * anomalies detected in the storedInfoType data that render it unusable. Only + * the five most recent errors will be displayed, with the most recent error + * appearing first. + * For example, some of the data for stored custom dictionaries is put in + * the user's Cloud Storage bucket, and if this data is modified or + * deleted by the user or another system, the dictionary becomes invalid. + * If any errors occur, fix the problem indicated by the error message and + * use the UpdateStoredInfoType API method to create another version of the + * storedInfoType to continue using it, reusing the same `config` if it was + * not the source of the error. + * @type \Google\Cloud\Dlp\V2\StoredInfoTypeStats $stats + * Statistics about this storedInfoType version. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * StoredInfoType configuration. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 1; + * @return \Google\Cloud\Dlp\V2\StoredInfoTypeConfig|null + */ + public function getConfig() + { + return $this->config; + } + + public function hasConfig() + { + return isset($this->config); + } + + public function clearConfig() + { + unset($this->config); + } + + /** + * StoredInfoType configuration. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 1; + * @param \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $var + * @return $this + */ + public function setConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StoredInfoTypeConfig::class); + $this->config = $var; + + return $this; + } + + /** + * Create timestamp of the version. Read-only, determined by the system + * when the version is created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; + * @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); + } + + /** + * Create timestamp of the version. Read-only, determined by the system + * when the version is created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * Stored info type version state. Read-only, updated by the system + * during dictionary creation. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeState state = 3; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Stored info type version state. Read-only, updated by the system + * during dictionary creation. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeState state = 3; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\StoredInfoTypeState::class); + $this->state = $var; + + return $this; + } + + /** + * Errors that occurred when creating this storedInfoType version, or + * anomalies detected in the storedInfoType data that render it unusable. Only + * the five most recent errors will be displayed, with the most recent error + * appearing first. + * For example, some of the data for stored custom dictionaries is put in + * the user's Cloud Storage bucket, and if this data is modified or + * deleted by the user or another system, the dictionary becomes invalid. + * If any errors occur, fix the problem indicated by the error message and + * use the UpdateStoredInfoType API method to create another version of the + * storedInfoType to continue using it, reusing the same `config` if it was + * not the source of the error. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getErrors() + { + return $this->errors; + } + + /** + * Errors that occurred when creating this storedInfoType version, or + * anomalies detected in the storedInfoType data that render it unusable. Only + * the five most recent errors will be displayed, with the most recent error + * appearing first. + * For example, some of the data for stored custom dictionaries is put in + * the user's Cloud Storage bucket, and if this data is modified or + * deleted by the user or another system, the dictionary becomes invalid. + * If any errors occur, fix the problem indicated by the error message and + * use the UpdateStoredInfoType API method to create another version of the + * storedInfoType to continue using it, reusing the same `config` if it was + * not the source of the error. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 4; + * @param array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setErrors($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Error::class); + $this->errors = $arr; + + return $this; + } + + /** + * Statistics about this storedInfoType version. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeStats stats = 5; + * @return \Google\Cloud\Dlp\V2\StoredInfoTypeStats|null + */ + public function getStats() + { + return $this->stats; + } + + public function hasStats() + { + return isset($this->stats); + } + + public function clearStats() + { + unset($this->stats); + } + + /** + * Statistics about this storedInfoType version. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeStats stats = 5; + * @param \Google\Cloud\Dlp\V2\StoredInfoTypeStats $var + * @return $this + */ + public function setStats($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StoredInfoTypeStats::class); + $this->stats = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredType.php new file mode 100644 index 000000000000..e240578bf676 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredType.php @@ -0,0 +1,123 @@ +google.privacy.dlp.v2.StoredType + */ +class StoredType extends \Google\Protobuf\Internal\Message +{ + /** + * Resource name of the requested `StoredInfoType`, for example + * `organizations/433245324/storedInfoTypes/432452342` or + * `projects/project-id/storedInfoTypes/432452342`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Timestamp indicating when the version of the `StoredInfoType` used for + * inspection was created. Output-only field, populated by the system. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; + */ + protected $create_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Resource name of the requested `StoredInfoType`, for example + * `organizations/433245324/storedInfoTypes/432452342` or + * `projects/project-id/storedInfoTypes/432452342`. + * @type \Google\Protobuf\Timestamp $create_time + * Timestamp indicating when the version of the `StoredInfoType` used for + * inspection was created. Output-only field, populated by the system. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Resource name of the requested `StoredInfoType`, for example + * `organizations/433245324/storedInfoTypes/432452342` or + * `projects/project-id/storedInfoTypes/432452342`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Resource name of the requested `StoredInfoType`, for example + * `organizations/433245324/storedInfoTypes/432452342` or + * `projects/project-id/storedInfoTypes/432452342`. + * + * 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; + } + + /** + * Timestamp indicating when the version of the `StoredInfoType` used for + * inspection was created. Output-only field, populated by the system. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; + * @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); + } + + /** + * Timestamp indicating when the version of the `StoredInfoType` used for + * inspection was created. Output-only field, populated by the system. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table.php new file mode 100644 index 000000000000..3fda5434774a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table.php @@ -0,0 +1,103 @@ +google.privacy.dlp.v2.Table + */ +class Table extends \Google\Protobuf\Internal\Message +{ + /** + * Headers of the table. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId headers = 1; + */ + private $headers; + /** + * Rows of the table. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Table.Row rows = 2; + */ + private $rows; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $headers + * Headers of the table. + * @type array<\Google\Cloud\Dlp\V2\Table\Row>|\Google\Protobuf\Internal\RepeatedField $rows + * Rows of the table. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Headers of the table. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId headers = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getHeaders() + { + return $this->headers; + } + + /** + * Headers of the table. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId headers = 1; + * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); + $this->headers = $arr; + + return $this; + } + + /** + * Rows of the table. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Table.Row rows = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRows() + { + return $this->rows; + } + + /** + * Rows of the table. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Table.Row rows = 2; + * @param array<\Google\Cloud\Dlp\V2\Table\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRows($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Table\Row::class); + $this->rows = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table/Row.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table/Row.php new file mode 100644 index 000000000000..18ab4403ca50 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table/Row.php @@ -0,0 +1,70 @@ +google.privacy.dlp.v2.Table.Row + */ +class Row extends \Google\Protobuf\Internal\Message +{ + /** + * Individual cells. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value values = 1; + */ + private $values; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $values + * Individual cells. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Individual cells. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value values = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getValues() + { + return $this->values; + } + + /** + * Individual cells. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.Value values = 1; + * @param array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Value::class); + $this->values = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Row::class, \Google\Cloud\Dlp\V2\Table_Row::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile.php new file mode 100644 index 000000000000..d923b7458aba --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile.php @@ -0,0 +1,1027 @@ +google.privacy.dlp.v2.TableDataProfile + */ +class TableDataProfile extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the profile. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The resource type that was profiled. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataSourceType data_source_type = 36; + */ + protected $data_source_type = null; + /** + * The resource name to the project data profile for this table. + * + * Generated from protobuf field string project_data_profile = 2; + */ + protected $project_data_profile = ''; + /** + * The Google Cloud project ID that owns the resource. + * + * Generated from protobuf field string dataset_project_id = 24; + */ + protected $dataset_project_id = ''; + /** + * If supported, the location where the dataset's data is stored. + * See https://cloud.google.com/bigquery/docs/locations for supported + * locations. + * + * Generated from protobuf field string dataset_location = 29; + */ + protected $dataset_location = ''; + /** + * If the resource is BigQuery, the dataset ID. + * + * Generated from protobuf field string dataset_id = 25; + */ + protected $dataset_id = ''; + /** + * If the resource is BigQuery, the BigQuery table ID. + * + * Generated from protobuf field string table_id = 26; + */ + protected $table_id = ''; + /** + * The resource name of the resource profiled. + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string full_resource = 3; + */ + protected $full_resource = ''; + /** + * Success or error status from the most recent profile generation attempt. + * May be empty if the profile is still being generated. + * + * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 21; + */ + protected $profile_status = null; + /** + * State of a profile. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile.State state = 22; + */ + protected $state = 0; + /** + * The sensitivity score of this table. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 5; + */ + protected $sensitivity_score = null; + /** + * The data risk level of this table. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 6; + */ + protected $data_risk_level = null; + /** + * The infoTypes predicted from this table's data. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeSummary predicted_info_types = 27; + */ + private $predicted_info_types; + /** + * Other infoTypes found in this table's data. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.OtherInfoTypeSummary other_info_types = 28; + */ + private $other_info_types; + /** + * The snapshot of the configurations used to generate the profile. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileConfigSnapshot config_snapshot = 7; + */ + protected $config_snapshot = null; + /** + * The time when this table was last modified + * + * Generated from protobuf field .google.protobuf.Timestamp last_modified_time = 8; + */ + protected $last_modified_time = null; + /** + * Optional. The time when this table expires. + * + * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 9; + */ + protected $expiration_time = null; + /** + * The number of columns profiled in the table. + * + * Generated from protobuf field int64 scanned_column_count = 10; + */ + protected $scanned_column_count = 0; + /** + * The number of columns skipped in the table because of an error. + * + * Generated from protobuf field int64 failed_column_count = 11; + */ + protected $failed_column_count = 0; + /** + * The size of the table when the profile was generated. + * + * Generated from protobuf field int64 table_size_bytes = 12; + */ + protected $table_size_bytes = 0; + /** + * Number of rows in the table when the profile was generated. + * This will not be populated for BigLake tables. + * + * Generated from protobuf field int64 row_count = 13; + */ + protected $row_count = 0; + /** + * How the table is encrypted. + * + * Generated from protobuf field .google.privacy.dlp.v2.EncryptionStatus encryption_status = 14; + */ + protected $encryption_status = 0; + /** + * How broadly a resource has been shared. + * + * Generated from protobuf field .google.privacy.dlp.v2.ResourceVisibility resource_visibility = 15; + */ + protected $resource_visibility = 0; + /** + * The last time the profile was generated. + * + * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 16; + */ + protected $profile_last_generated = null; + /** + * The labels applied to the resource at the time the profile was generated. + * + * Generated from protobuf field map resource_labels = 17; + */ + private $resource_labels; + /** + * The time at which the table was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 23; + */ + protected $create_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the profile. + * @type \Google\Cloud\Dlp\V2\DataSourceType $data_source_type + * The resource type that was profiled. + * @type string $project_data_profile + * The resource name to the project data profile for this table. + * @type string $dataset_project_id + * The Google Cloud project ID that owns the resource. + * @type string $dataset_location + * If supported, the location where the dataset's data is stored. + * See https://cloud.google.com/bigquery/docs/locations for supported + * locations. + * @type string $dataset_id + * If the resource is BigQuery, the dataset ID. + * @type string $table_id + * If the resource is BigQuery, the BigQuery table ID. + * @type string $full_resource + * The resource name of the resource profiled. + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type \Google\Cloud\Dlp\V2\ProfileStatus $profile_status + * Success or error status from the most recent profile generation attempt. + * May be empty if the profile is still being generated. + * @type int $state + * State of a profile. + * @type \Google\Cloud\Dlp\V2\SensitivityScore $sensitivity_score + * The sensitivity score of this table. + * @type \Google\Cloud\Dlp\V2\DataRiskLevel $data_risk_level + * The data risk level of this table. + * @type array<\Google\Cloud\Dlp\V2\InfoTypeSummary>|\Google\Protobuf\Internal\RepeatedField $predicted_info_types + * The infoTypes predicted from this table's data. + * @type array<\Google\Cloud\Dlp\V2\OtherInfoTypeSummary>|\Google\Protobuf\Internal\RepeatedField $other_info_types + * Other infoTypes found in this table's data. + * @type \Google\Cloud\Dlp\V2\DataProfileConfigSnapshot $config_snapshot + * The snapshot of the configurations used to generate the profile. + * @type \Google\Protobuf\Timestamp $last_modified_time + * The time when this table was last modified + * @type \Google\Protobuf\Timestamp $expiration_time + * Optional. The time when this table expires. + * @type int|string $scanned_column_count + * The number of columns profiled in the table. + * @type int|string $failed_column_count + * The number of columns skipped in the table because of an error. + * @type int|string $table_size_bytes + * The size of the table when the profile was generated. + * @type int|string $row_count + * Number of rows in the table when the profile was generated. + * This will not be populated for BigLake tables. + * @type int $encryption_status + * How the table is encrypted. + * @type int $resource_visibility + * How broadly a resource has been shared. + * @type \Google\Protobuf\Timestamp $profile_last_generated + * The last time the profile was generated. + * @type array|\Google\Protobuf\Internal\MapField $resource_labels + * The labels applied to the resource at the time the profile was generated. + * @type \Google\Protobuf\Timestamp $create_time + * The time at which the table was created. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The name of the profile. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the profile. + * + * 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; + } + + /** + * The resource type that was profiled. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataSourceType data_source_type = 36; + * @return \Google\Cloud\Dlp\V2\DataSourceType|null + */ + public function getDataSourceType() + { + return $this->data_source_type; + } + + public function hasDataSourceType() + { + return isset($this->data_source_type); + } + + public function clearDataSourceType() + { + unset($this->data_source_type); + } + + /** + * The resource type that was profiled. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataSourceType data_source_type = 36; + * @param \Google\Cloud\Dlp\V2\DataSourceType $var + * @return $this + */ + public function setDataSourceType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataSourceType::class); + $this->data_source_type = $var; + + return $this; + } + + /** + * The resource name to the project data profile for this table. + * + * Generated from protobuf field string project_data_profile = 2; + * @return string + */ + public function getProjectDataProfile() + { + return $this->project_data_profile; + } + + /** + * The resource name to the project data profile for this table. + * + * Generated from protobuf field string project_data_profile = 2; + * @param string $var + * @return $this + */ + public function setProjectDataProfile($var) + { + GPBUtil::checkString($var, True); + $this->project_data_profile = $var; + + return $this; + } + + /** + * The Google Cloud project ID that owns the resource. + * + * Generated from protobuf field string dataset_project_id = 24; + * @return string + */ + public function getDatasetProjectId() + { + return $this->dataset_project_id; + } + + /** + * The Google Cloud project ID that owns the resource. + * + * Generated from protobuf field string dataset_project_id = 24; + * @param string $var + * @return $this + */ + public function setDatasetProjectId($var) + { + GPBUtil::checkString($var, True); + $this->dataset_project_id = $var; + + return $this; + } + + /** + * If supported, the location where the dataset's data is stored. + * See https://cloud.google.com/bigquery/docs/locations for supported + * locations. + * + * Generated from protobuf field string dataset_location = 29; + * @return string + */ + public function getDatasetLocation() + { + return $this->dataset_location; + } + + /** + * If supported, the location where the dataset's data is stored. + * See https://cloud.google.com/bigquery/docs/locations for supported + * locations. + * + * Generated from protobuf field string dataset_location = 29; + * @param string $var + * @return $this + */ + public function setDatasetLocation($var) + { + GPBUtil::checkString($var, True); + $this->dataset_location = $var; + + return $this; + } + + /** + * If the resource is BigQuery, the dataset ID. + * + * Generated from protobuf field string dataset_id = 25; + * @return string + */ + public function getDatasetId() + { + return $this->dataset_id; + } + + /** + * If the resource is BigQuery, the dataset ID. + * + * Generated from protobuf field string dataset_id = 25; + * @param string $var + * @return $this + */ + public function setDatasetId($var) + { + GPBUtil::checkString($var, True); + $this->dataset_id = $var; + + return $this; + } + + /** + * If the resource is BigQuery, the BigQuery table ID. + * + * Generated from protobuf field string table_id = 26; + * @return string + */ + public function getTableId() + { + return $this->table_id; + } + + /** + * If the resource is BigQuery, the BigQuery table ID. + * + * Generated from protobuf field string table_id = 26; + * @param string $var + * @return $this + */ + public function setTableId($var) + { + GPBUtil::checkString($var, True); + $this->table_id = $var; + + return $this; + } + + /** + * The resource name of the resource profiled. + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string full_resource = 3; + * @return string + */ + public function getFullResource() + { + return $this->full_resource; + } + + /** + * The resource name of the resource profiled. + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string full_resource = 3; + * @param string $var + * @return $this + */ + public function setFullResource($var) + { + GPBUtil::checkString($var, True); + $this->full_resource = $var; + + return $this; + } + + /** + * Success or error status from the most recent profile generation attempt. + * May be empty if the profile is still being generated. + * + * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 21; + * @return \Google\Cloud\Dlp\V2\ProfileStatus|null + */ + public function getProfileStatus() + { + return $this->profile_status; + } + + public function hasProfileStatus() + { + return isset($this->profile_status); + } + + public function clearProfileStatus() + { + unset($this->profile_status); + } + + /** + * Success or error status from the most recent profile generation attempt. + * May be empty if the profile is still being generated. + * + * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 21; + * @param \Google\Cloud\Dlp\V2\ProfileStatus $var + * @return $this + */ + public function setProfileStatus($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ProfileStatus::class); + $this->profile_status = $var; + + return $this; + } + + /** + * State of a profile. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile.State state = 22; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * State of a profile. + * + * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile.State state = 22; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\TableDataProfile\State::class); + $this->state = $var; + + return $this; + } + + /** + * The sensitivity score of this table. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 5; + * @return \Google\Cloud\Dlp\V2\SensitivityScore|null + */ + public function getSensitivityScore() + { + return $this->sensitivity_score; + } + + public function hasSensitivityScore() + { + return isset($this->sensitivity_score); + } + + public function clearSensitivityScore() + { + unset($this->sensitivity_score); + } + + /** + * The sensitivity score of this table. + * + * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 5; + * @param \Google\Cloud\Dlp\V2\SensitivityScore $var + * @return $this + */ + public function setSensitivityScore($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SensitivityScore::class); + $this->sensitivity_score = $var; + + return $this; + } + + /** + * The data risk level of this table. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 6; + * @return \Google\Cloud\Dlp\V2\DataRiskLevel|null + */ + public function getDataRiskLevel() + { + return $this->data_risk_level; + } + + public function hasDataRiskLevel() + { + return isset($this->data_risk_level); + } + + public function clearDataRiskLevel() + { + unset($this->data_risk_level); + } + + /** + * The data risk level of this table. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 6; + * @param \Google\Cloud\Dlp\V2\DataRiskLevel $var + * @return $this + */ + public function setDataRiskLevel($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataRiskLevel::class); + $this->data_risk_level = $var; + + return $this; + } + + /** + * The infoTypes predicted from this table's data. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeSummary predicted_info_types = 27; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPredictedInfoTypes() + { + return $this->predicted_info_types; + } + + /** + * The infoTypes predicted from this table's data. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeSummary predicted_info_types = 27; + * @param array<\Google\Cloud\Dlp\V2\InfoTypeSummary>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPredictedInfoTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoTypeSummary::class); + $this->predicted_info_types = $arr; + + return $this; + } + + /** + * Other infoTypes found in this table's data. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.OtherInfoTypeSummary other_info_types = 28; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOtherInfoTypes() + { + return $this->other_info_types; + } + + /** + * Other infoTypes found in this table's data. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.OtherInfoTypeSummary other_info_types = 28; + * @param array<\Google\Cloud\Dlp\V2\OtherInfoTypeSummary>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOtherInfoTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\OtherInfoTypeSummary::class); + $this->other_info_types = $arr; + + return $this; + } + + /** + * The snapshot of the configurations used to generate the profile. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileConfigSnapshot config_snapshot = 7; + * @return \Google\Cloud\Dlp\V2\DataProfileConfigSnapshot|null + */ + public function getConfigSnapshot() + { + return $this->config_snapshot; + } + + public function hasConfigSnapshot() + { + return isset($this->config_snapshot); + } + + public function clearConfigSnapshot() + { + unset($this->config_snapshot); + } + + /** + * The snapshot of the configurations used to generate the profile. + * + * Generated from protobuf field .google.privacy.dlp.v2.DataProfileConfigSnapshot config_snapshot = 7; + * @param \Google\Cloud\Dlp\V2\DataProfileConfigSnapshot $var + * @return $this + */ + public function setConfigSnapshot($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfileConfigSnapshot::class); + $this->config_snapshot = $var; + + return $this; + } + + /** + * The time when this table was last modified + * + * Generated from protobuf field .google.protobuf.Timestamp last_modified_time = 8; + * @return \Google\Protobuf\Timestamp|null + */ + public function getLastModifiedTime() + { + return $this->last_modified_time; + } + + public function hasLastModifiedTime() + { + return isset($this->last_modified_time); + } + + public function clearLastModifiedTime() + { + unset($this->last_modified_time); + } + + /** + * The time when this table was last modified + * + * Generated from protobuf field .google.protobuf.Timestamp last_modified_time = 8; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setLastModifiedTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->last_modified_time = $var; + + return $this; + } + + /** + * Optional. The time when this table expires. + * + * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 9; + * @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); + } + + /** + * Optional. The time when this table expires. + * + * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 9; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setExpirationTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->expiration_time = $var; + + return $this; + } + + /** + * The number of columns profiled in the table. + * + * Generated from protobuf field int64 scanned_column_count = 10; + * @return int|string + */ + public function getScannedColumnCount() + { + return $this->scanned_column_count; + } + + /** + * The number of columns profiled in the table. + * + * Generated from protobuf field int64 scanned_column_count = 10; + * @param int|string $var + * @return $this + */ + public function setScannedColumnCount($var) + { + GPBUtil::checkInt64($var); + $this->scanned_column_count = $var; + + return $this; + } + + /** + * The number of columns skipped in the table because of an error. + * + * Generated from protobuf field int64 failed_column_count = 11; + * @return int|string + */ + public function getFailedColumnCount() + { + return $this->failed_column_count; + } + + /** + * The number of columns skipped in the table because of an error. + * + * Generated from protobuf field int64 failed_column_count = 11; + * @param int|string $var + * @return $this + */ + public function setFailedColumnCount($var) + { + GPBUtil::checkInt64($var); + $this->failed_column_count = $var; + + return $this; + } + + /** + * The size of the table when the profile was generated. + * + * Generated from protobuf field int64 table_size_bytes = 12; + * @return int|string + */ + public function getTableSizeBytes() + { + return $this->table_size_bytes; + } + + /** + * The size of the table when the profile was generated. + * + * Generated from protobuf field int64 table_size_bytes = 12; + * @param int|string $var + * @return $this + */ + public function setTableSizeBytes($var) + { + GPBUtil::checkInt64($var); + $this->table_size_bytes = $var; + + return $this; + } + + /** + * Number of rows in the table when the profile was generated. + * This will not be populated for BigLake tables. + * + * Generated from protobuf field int64 row_count = 13; + * @return int|string + */ + public function getRowCount() + { + return $this->row_count; + } + + /** + * Number of rows in the table when the profile was generated. + * This will not be populated for BigLake tables. + * + * Generated from protobuf field int64 row_count = 13; + * @param int|string $var + * @return $this + */ + public function setRowCount($var) + { + GPBUtil::checkInt64($var); + $this->row_count = $var; + + return $this; + } + + /** + * How the table is encrypted. + * + * Generated from protobuf field .google.privacy.dlp.v2.EncryptionStatus encryption_status = 14; + * @return int + */ + public function getEncryptionStatus() + { + return $this->encryption_status; + } + + /** + * How the table is encrypted. + * + * Generated from protobuf field .google.privacy.dlp.v2.EncryptionStatus encryption_status = 14; + * @param int $var + * @return $this + */ + public function setEncryptionStatus($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\EncryptionStatus::class); + $this->encryption_status = $var; + + return $this; + } + + /** + * How broadly a resource has been shared. + * + * Generated from protobuf field .google.privacy.dlp.v2.ResourceVisibility resource_visibility = 15; + * @return int + */ + public function getResourceVisibility() + { + return $this->resource_visibility; + } + + /** + * How broadly a resource has been shared. + * + * Generated from protobuf field .google.privacy.dlp.v2.ResourceVisibility resource_visibility = 15; + * @param int $var + * @return $this + */ + public function setResourceVisibility($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\ResourceVisibility::class); + $this->resource_visibility = $var; + + return $this; + } + + /** + * The last time the profile was generated. + * + * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 16; + * @return \Google\Protobuf\Timestamp|null + */ + public function getProfileLastGenerated() + { + return $this->profile_last_generated; + } + + public function hasProfileLastGenerated() + { + return isset($this->profile_last_generated); + } + + public function clearProfileLastGenerated() + { + unset($this->profile_last_generated); + } + + /** + * The last time the profile was generated. + * + * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 16; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setProfileLastGenerated($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->profile_last_generated = $var; + + return $this; + } + + /** + * The labels applied to the resource at the time the profile was generated. + * + * Generated from protobuf field map resource_labels = 17; + * @return \Google\Protobuf\Internal\MapField + */ + public function getResourceLabels() + { + return $this->resource_labels; + } + + /** + * The labels applied to the resource at the time the profile was generated. + * + * Generated from protobuf field map resource_labels = 17; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setResourceLabels($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->resource_labels = $arr; + + return $this; + } + + /** + * The time at which the table was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 23; + * @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); + } + + /** + * The time at which the table was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 23; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile/State.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile/State.php new file mode 100644 index 000000000000..c28719cfb2e3 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile/State.php @@ -0,0 +1,67 @@ +google.privacy.dlp.v2.TableDataProfile.State + */ +class State +{ + /** + * Unused. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The profile is currently running. Once a profile has finished it will + * transition to DONE. + * + * Generated from protobuf enum RUNNING = 1; + */ + const RUNNING = 1; + /** + * The profile is no longer generating. + * If profile_status.status.code is 0, the profile succeeded, otherwise, it + * failed. + * + * Generated from protobuf enum DONE = 2; + */ + const DONE = 2; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::RUNNING => 'RUNNING', + self::DONE => 'DONE', + ]; + + 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, \Google\Cloud\Dlp\V2\TableDataProfile_State::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableLocation.php new file mode 100644 index 000000000000..16a8dbadb8fb --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableLocation.php @@ -0,0 +1,87 @@ +google.privacy.dlp.v2.TableLocation + */ +class TableLocation extends \Google\Protobuf\Internal\Message +{ + /** + * The zero-based index of the row where the finding is located. Only + * populated for resources that have a natural ordering, not BigQuery. In + * BigQuery, to identify the row a finding came from, populate + * BigQueryOptions.identifying_fields with your primary key column names and + * when you store the findings the value of those columns will be stored + * inside of Finding. + * + * Generated from protobuf field int64 row_index = 1; + */ + protected $row_index = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $row_index + * The zero-based index of the row where the finding is located. Only + * populated for resources that have a natural ordering, not BigQuery. In + * BigQuery, to identify the row a finding came from, populate + * BigQueryOptions.identifying_fields with your primary key column names and + * when you store the findings the value of those columns will be stored + * inside of Finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The zero-based index of the row where the finding is located. Only + * populated for resources that have a natural ordering, not BigQuery. In + * BigQuery, to identify the row a finding came from, populate + * BigQueryOptions.identifying_fields with your primary key column names and + * when you store the findings the value of those columns will be stored + * inside of Finding. + * + * Generated from protobuf field int64 row_index = 1; + * @return int|string + */ + public function getRowIndex() + { + return $this->row_index; + } + + /** + * The zero-based index of the row where the finding is located. Only + * populated for resources that have a natural ordering, not BigQuery. In + * BigQuery, to identify the row a finding came from, populate + * BigQueryOptions.identifying_fields with your primary key column names and + * when you store the findings the value of those columns will be stored + * inside of Finding. + * + * Generated from protobuf field int64 row_index = 1; + * @param int|string $var + * @return $this + */ + public function setRowIndex($var) + { + GPBUtil::checkInt64($var); + $this->row_index = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableOptions.php new file mode 100644 index 000000000000..46fbb8dc8f82 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableOptions.php @@ -0,0 +1,79 @@ +google.privacy.dlp.v2.TableOptions + */ +class TableOptions extends \Google\Protobuf\Internal\Message +{ + /** + * The columns that are the primary keys for table objects included in + * ContentItem. A copy of this cell's value will stored alongside alongside + * each finding so that the finding can be traced to the specific row it came + * from. No more than 3 may be provided. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId identifying_fields = 1; + */ + private $identifying_fields; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $identifying_fields + * The columns that are the primary keys for table objects included in + * ContentItem. A copy of this cell's value will stored alongside alongside + * each finding so that the finding can be traced to the specific row it came + * from. No more than 3 may be provided. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * The columns that are the primary keys for table objects included in + * ContentItem. A copy of this cell's value will stored alongside alongside + * each finding so that the finding can be traced to the specific row it came + * from. No more than 3 may be provided. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId identifying_fields = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getIdentifyingFields() + { + return $this->identifying_fields; + } + + /** + * The columns that are the primary keys for table objects included in + * ContentItem. A copy of this cell's value will stored alongside alongside + * each finding so that the finding can be traced to the specific row it came + * from. No more than 3 may be provided. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId identifying_fields = 1; + * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setIdentifyingFields($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); + $this->identifying_fields = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableReference.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableReference.php new file mode 100644 index 000000000000..d66eac073739 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableReference.php @@ -0,0 +1,102 @@ +google.privacy.dlp.v2.TableReference + */ +class TableReference extends \Google\Protobuf\Internal\Message +{ + /** + * Dataset ID of the table. + * + * Generated from protobuf field string dataset_id = 1; + */ + protected $dataset_id = ''; + /** + * Name of the table. + * + * Generated from protobuf field string table_id = 2; + */ + protected $table_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $dataset_id + * Dataset ID of the table. + * @type string $table_id + * Name of the table. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); + parent::__construct($data); + } + + /** + * Dataset ID of the table. + * + * Generated from protobuf field string dataset_id = 1; + * @return string + */ + public function getDatasetId() + { + return $this->dataset_id; + } + + /** + * Dataset ID of the table. + * + * Generated from protobuf field string dataset_id = 1; + * @param string $var + * @return $this + */ + public function setDatasetId($var) + { + GPBUtil::checkString($var, True); + $this->dataset_id = $var; + + return $this; + } + + /** + * Name of the table. + * + * Generated from protobuf field string table_id = 2; + * @return string + */ + public function getTableId() + { + return $this->table_id; + } + + /** + * Name of the table. + * + * Generated from protobuf field string table_id = 2; + * @param string $var + * @return $this + */ + public function setTableId($var) + { + GPBUtil::checkString($var, True); + $this->table_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig.php new file mode 100644 index 000000000000..56ef5ac5f19b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig.php @@ -0,0 +1,68 @@ +google.privacy.dlp.v2.TimePartConfig + */ +class TimePartConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The part of the time to keep. + * + * Generated from protobuf field .google.privacy.dlp.v2.TimePartConfig.TimePart part_to_extract = 1; + */ + protected $part_to_extract = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $part_to_extract + * The part of the time to keep. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The part of the time to keep. + * + * Generated from protobuf field .google.privacy.dlp.v2.TimePartConfig.TimePart part_to_extract = 1; + * @return int + */ + public function getPartToExtract() + { + return $this->part_to_extract; + } + + /** + * The part of the time to keep. + * + * Generated from protobuf field .google.privacy.dlp.v2.TimePartConfig.TimePart part_to_extract = 1; + * @param int $var + * @return $this + */ + public function setPartToExtract($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\TimePartConfig\TimePart::class); + $this->part_to_extract = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig/TimePart.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig/TimePart.php new file mode 100644 index 000000000000..a1b53ed057fc --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig/TimePart.php @@ -0,0 +1,92 @@ +google.privacy.dlp.v2.TimePartConfig.TimePart + */ +class TimePart +{ + /** + * Unused + * + * Generated from protobuf enum TIME_PART_UNSPECIFIED = 0; + */ + const TIME_PART_UNSPECIFIED = 0; + /** + * [0-9999] + * + * Generated from protobuf enum YEAR = 1; + */ + const YEAR = 1; + /** + * [1-12] + * + * Generated from protobuf enum MONTH = 2; + */ + const MONTH = 2; + /** + * [1-31] + * + * Generated from protobuf enum DAY_OF_MONTH = 3; + */ + const DAY_OF_MONTH = 3; + /** + * [1-7] + * + * Generated from protobuf enum DAY_OF_WEEK = 4; + */ + const DAY_OF_WEEK = 4; + /** + * [1-53] + * + * Generated from protobuf enum WEEK_OF_YEAR = 5; + */ + const WEEK_OF_YEAR = 5; + /** + * [0-23] + * + * Generated from protobuf enum HOUR_OF_DAY = 6; + */ + const HOUR_OF_DAY = 6; + + private static $valueToName = [ + self::TIME_PART_UNSPECIFIED => 'TIME_PART_UNSPECIFIED', + self::YEAR => 'YEAR', + self::MONTH => 'MONTH', + self::DAY_OF_MONTH => 'DAY_OF_MONTH', + self::DAY_OF_WEEK => 'DAY_OF_WEEK', + self::WEEK_OF_YEAR => 'WEEK_OF_YEAR', + self::HOUR_OF_DAY => 'HOUR_OF_DAY', + ]; + + 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(TimePart::class, \Google\Cloud\Dlp\V2\TimePartConfig_TimePart::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationConfig.php new file mode 100644 index 000000000000..ba44342662ed --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationConfig.php @@ -0,0 +1,193 @@ +google.privacy.dlp.v2.TransformationConfig + */ +class TransformationConfig extends \Google\Protobuf\Internal\Message +{ + /** + * De-identify template. + * If this template is specified, it will serve as the default de-identify + * template. This template cannot contain `record_transformations` since it + * can be used for unstructured content such as free-form text files. If this + * template is not set, a default `ReplaceWithInfoTypeConfig` will be used to + * de-identify unstructured content. + * + * Generated from protobuf field string deidentify_template = 1; + */ + protected $deidentify_template = ''; + /** + * Structured de-identify template. + * If this template is specified, it will serve as the de-identify template + * for structured content such as delimited files and tables. If this template + * is not set but the `deidentify_template` is set, then `deidentify_template` + * will also apply to the structured content. If neither template is set, a + * default `ReplaceWithInfoTypeConfig` will be used to de-identify structured + * content. + * + * Generated from protobuf field string structured_deidentify_template = 2; + */ + protected $structured_deidentify_template = ''; + /** + * Image redact template. + * If this template is specified, it will serve as the de-identify template + * for images. If this template is not set, all findings in the image will be + * redacted with a black box. + * + * Generated from protobuf field string image_redact_template = 4; + */ + protected $image_redact_template = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $deidentify_template + * De-identify template. + * If this template is specified, it will serve as the default de-identify + * template. This template cannot contain `record_transformations` since it + * can be used for unstructured content such as free-form text files. If this + * template is not set, a default `ReplaceWithInfoTypeConfig` will be used to + * de-identify unstructured content. + * @type string $structured_deidentify_template + * Structured de-identify template. + * If this template is specified, it will serve as the de-identify template + * for structured content such as delimited files and tables. If this template + * is not set but the `deidentify_template` is set, then `deidentify_template` + * will also apply to the structured content. If neither template is set, a + * default `ReplaceWithInfoTypeConfig` will be used to de-identify structured + * content. + * @type string $image_redact_template + * Image redact template. + * If this template is specified, it will serve as the de-identify template + * for images. If this template is not set, all findings in the image will be + * redacted with a black box. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * De-identify template. + * If this template is specified, it will serve as the default de-identify + * template. This template cannot contain `record_transformations` since it + * can be used for unstructured content such as free-form text files. If this + * template is not set, a default `ReplaceWithInfoTypeConfig` will be used to + * de-identify unstructured content. + * + * Generated from protobuf field string deidentify_template = 1; + * @return string + */ + public function getDeidentifyTemplate() + { + return $this->deidentify_template; + } + + /** + * De-identify template. + * If this template is specified, it will serve as the default de-identify + * template. This template cannot contain `record_transformations` since it + * can be used for unstructured content such as free-form text files. If this + * template is not set, a default `ReplaceWithInfoTypeConfig` will be used to + * de-identify unstructured content. + * + * Generated from protobuf field string deidentify_template = 1; + * @param string $var + * @return $this + */ + public function setDeidentifyTemplate($var) + { + GPBUtil::checkString($var, True); + $this->deidentify_template = $var; + + return $this; + } + + /** + * Structured de-identify template. + * If this template is specified, it will serve as the de-identify template + * for structured content such as delimited files and tables. If this template + * is not set but the `deidentify_template` is set, then `deidentify_template` + * will also apply to the structured content. If neither template is set, a + * default `ReplaceWithInfoTypeConfig` will be used to de-identify structured + * content. + * + * Generated from protobuf field string structured_deidentify_template = 2; + * @return string + */ + public function getStructuredDeidentifyTemplate() + { + return $this->structured_deidentify_template; + } + + /** + * Structured de-identify template. + * If this template is specified, it will serve as the de-identify template + * for structured content such as delimited files and tables. If this template + * is not set but the `deidentify_template` is set, then `deidentify_template` + * will also apply to the structured content. If neither template is set, a + * default `ReplaceWithInfoTypeConfig` will be used to de-identify structured + * content. + * + * Generated from protobuf field string structured_deidentify_template = 2; + * @param string $var + * @return $this + */ + public function setStructuredDeidentifyTemplate($var) + { + GPBUtil::checkString($var, True); + $this->structured_deidentify_template = $var; + + return $this; + } + + /** + * Image redact template. + * If this template is specified, it will serve as the de-identify template + * for images. If this template is not set, all findings in the image will be + * redacted with a black box. + * + * Generated from protobuf field string image_redact_template = 4; + * @return string + */ + public function getImageRedactTemplate() + { + return $this->image_redact_template; + } + + /** + * Image redact template. + * If this template is specified, it will serve as the de-identify template + * for images. If this template is not set, all findings in the image will be + * redacted with a black box. + * + * Generated from protobuf field string image_redact_template = 4; + * @param string $var + * @return $this + */ + public function setImageRedactTemplate($var) + { + GPBUtil::checkString($var, True); + $this->image_redact_template = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationContainerType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationContainerType.php new file mode 100644 index 000000000000..2030c3527e9f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationContainerType.php @@ -0,0 +1,68 @@ +google.privacy.dlp.v2.TransformationContainerType + */ +class TransformationContainerType +{ + /** + * Unused. + * + * Generated from protobuf enum TRANSFORM_UNKNOWN_CONTAINER = 0; + */ + const TRANSFORM_UNKNOWN_CONTAINER = 0; + /** + * Body of a file. + * + * Generated from protobuf enum TRANSFORM_BODY = 1; + */ + const TRANSFORM_BODY = 1; + /** + * Metadata for a file. + * + * Generated from protobuf enum TRANSFORM_METADATA = 2; + */ + const TRANSFORM_METADATA = 2; + /** + * A table. + * + * Generated from protobuf enum TRANSFORM_TABLE = 3; + */ + const TRANSFORM_TABLE = 3; + + private static $valueToName = [ + self::TRANSFORM_UNKNOWN_CONTAINER => 'TRANSFORM_UNKNOWN_CONTAINER', + self::TRANSFORM_BODY => 'TRANSFORM_BODY', + self::TRANSFORM_METADATA => 'TRANSFORM_METADATA', + self::TRANSFORM_TABLE => 'TRANSFORM_TABLE', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDescription.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDescription.php new file mode 100644 index 000000000000..1f75fa66768f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDescription.php @@ -0,0 +1,224 @@ +google.privacy.dlp.v2.TransformationDescription + */ +class TransformationDescription extends \Google\Protobuf\Internal\Message +{ + /** + * The transformation type. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationType type = 1; + */ + protected $type = 0; + /** + * A description of the transformation. This is empty for a + * RECORD_SUPPRESSION, or is the output of calling toString() on the + * `PrimitiveTransformation` protocol buffer message for any other type of + * transformation. + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + /** + * A human-readable string representation of the `RecordCondition` + * corresponding to this transformation. Set if a `RecordCondition` was used + * to determine whether or not to apply this transformation. + * Examples: + * * (age_field > 85) + * * (age_field <= 18) + * * (zip_field exists) + * * (zip_field == 01234) && (city_field != "Springville") + * * (zip_field == 01234) && (age_field <= 18) && (city_field exists) + * + * Generated from protobuf field string condition = 3; + */ + protected $condition = ''; + /** + * Set if the transformation was limited to a specific `InfoType`. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 4; + */ + protected $info_type = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $type + * The transformation type. + * @type string $description + * A description of the transformation. This is empty for a + * RECORD_SUPPRESSION, or is the output of calling toString() on the + * `PrimitiveTransformation` protocol buffer message for any other type of + * transformation. + * @type string $condition + * A human-readable string representation of the `RecordCondition` + * corresponding to this transformation. Set if a `RecordCondition` was used + * to determine whether or not to apply this transformation. + * Examples: + * * (age_field > 85) + * * (age_field <= 18) + * * (zip_field exists) + * * (zip_field == 01234) && (city_field != "Springville") + * * (zip_field == 01234) && (age_field <= 18) && (city_field exists) + * @type \Google\Cloud\Dlp\V2\InfoType $info_type + * Set if the transformation was limited to a specific `InfoType`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The transformation type. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationType type = 1; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * The transformation type. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationType type = 1; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\TransformationType::class); + $this->type = $var; + + return $this; + } + + /** + * A description of the transformation. This is empty for a + * RECORD_SUPPRESSION, or is the output of calling toString() on the + * `PrimitiveTransformation` protocol buffer message for any other type of + * transformation. + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * A description of the transformation. This is empty for a + * RECORD_SUPPRESSION, or is the output of calling toString() on the + * `PrimitiveTransformation` protocol buffer message for any other type of + * transformation. + * + * 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; + } + + /** + * A human-readable string representation of the `RecordCondition` + * corresponding to this transformation. Set if a `RecordCondition` was used + * to determine whether or not to apply this transformation. + * Examples: + * * (age_field > 85) + * * (age_field <= 18) + * * (zip_field exists) + * * (zip_field == 01234) && (city_field != "Springville") + * * (zip_field == 01234) && (age_field <= 18) && (city_field exists) + * + * Generated from protobuf field string condition = 3; + * @return string + */ + public function getCondition() + { + return $this->condition; + } + + /** + * A human-readable string representation of the `RecordCondition` + * corresponding to this transformation. Set if a `RecordCondition` was used + * to determine whether or not to apply this transformation. + * Examples: + * * (age_field > 85) + * * (age_field <= 18) + * * (zip_field exists) + * * (zip_field == 01234) && (city_field != "Springville") + * * (zip_field == 01234) && (age_field <= 18) && (city_field exists) + * + * Generated from protobuf field string condition = 3; + * @param string $var + * @return $this + */ + public function setCondition($var) + { + GPBUtil::checkString($var, True); + $this->condition = $var; + + return $this; + } + + /** + * Set if the transformation was limited to a specific `InfoType`. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 4; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getInfoType() + { + return $this->info_type; + } + + public function hasInfoType() + { + return isset($this->info_type); + } + + public function clearInfoType() + { + unset($this->info_type); + } + + /** + * Set if the transformation was limited to a specific `InfoType`. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 4; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetails.php new file mode 100644 index 000000000000..4dd1b7730d8a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetails.php @@ -0,0 +1,296 @@ +google.privacy.dlp.v2.TransformationDetails + */ +class TransformationDetails extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the job that completed the transformation. + * + * Generated from protobuf field string resource_name = 1; + */ + protected $resource_name = ''; + /** + * The top level name of the container where the transformation is located + * (this will be the source file name or table name). + * + * Generated from protobuf field string container_name = 2; + */ + protected $container_name = ''; + /** + * Description of transformation. This would only contain more than one + * element if there were multiple matching transformations and which one to + * apply was ambiguous. Not set for states that contain no transformation, + * currently only state that contains no transformation is + * TransformationResultStateType.METADATA_UNRETRIEVABLE. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationDescription transformation = 3; + */ + private $transformation; + /** + * Status of the transformation, if transformation was not successful, this + * will specify what caused it to fail, otherwise it will show that the + * transformation was successful. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationResultStatus status_details = 4; + */ + protected $status_details = null; + /** + * The number of bytes that were transformed. If transformation was + * unsuccessful or did not take place because there was no content to + * transform, this will be zero. + * + * Generated from protobuf field int64 transformed_bytes = 5; + */ + protected $transformed_bytes = 0; + /** + * The precise location of the transformed content in the original container. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationLocation transformation_location = 6; + */ + protected $transformation_location = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $resource_name + * The name of the job that completed the transformation. + * @type string $container_name + * The top level name of the container where the transformation is located + * (this will be the source file name or table name). + * @type array<\Google\Cloud\Dlp\V2\TransformationDescription>|\Google\Protobuf\Internal\RepeatedField $transformation + * Description of transformation. This would only contain more than one + * element if there were multiple matching transformations and which one to + * apply was ambiguous. Not set for states that contain no transformation, + * currently only state that contains no transformation is + * TransformationResultStateType.METADATA_UNRETRIEVABLE. + * @type \Google\Cloud\Dlp\V2\TransformationResultStatus $status_details + * Status of the transformation, if transformation was not successful, this + * will specify what caused it to fail, otherwise it will show that the + * transformation was successful. + * @type int|string $transformed_bytes + * The number of bytes that were transformed. If transformation was + * unsuccessful or did not take place because there was no content to + * transform, this will be zero. + * @type \Google\Cloud\Dlp\V2\TransformationLocation $transformation_location + * The precise location of the transformed content in the original container. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The name of the job that completed the transformation. + * + * Generated from protobuf field string resource_name = 1; + * @return string + */ + public function getResourceName() + { + return $this->resource_name; + } + + /** + * The name of the job that completed the transformation. + * + * Generated from protobuf field string resource_name = 1; + * @param string $var + * @return $this + */ + public function setResourceName($var) + { + GPBUtil::checkString($var, True); + $this->resource_name = $var; + + return $this; + } + + /** + * The top level name of the container where the transformation is located + * (this will be the source file name or table name). + * + * Generated from protobuf field string container_name = 2; + * @return string + */ + public function getContainerName() + { + return $this->container_name; + } + + /** + * The top level name of the container where the transformation is located + * (this will be the source file name or table name). + * + * Generated from protobuf field string container_name = 2; + * @param string $var + * @return $this + */ + public function setContainerName($var) + { + GPBUtil::checkString($var, True); + $this->container_name = $var; + + return $this; + } + + /** + * Description of transformation. This would only contain more than one + * element if there were multiple matching transformations and which one to + * apply was ambiguous. Not set for states that contain no transformation, + * currently only state that contains no transformation is + * TransformationResultStateType.METADATA_UNRETRIEVABLE. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationDescription transformation = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTransformation() + { + return $this->transformation; + } + + /** + * Description of transformation. This would only contain more than one + * element if there were multiple matching transformations and which one to + * apply was ambiguous. Not set for states that contain no transformation, + * currently only state that contains no transformation is + * TransformationResultStateType.METADATA_UNRETRIEVABLE. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationDescription transformation = 3; + * @param array<\Google\Cloud\Dlp\V2\TransformationDescription>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTransformation($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\TransformationDescription::class); + $this->transformation = $arr; + + return $this; + } + + /** + * Status of the transformation, if transformation was not successful, this + * will specify what caused it to fail, otherwise it will show that the + * transformation was successful. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationResultStatus status_details = 4; + * @return \Google\Cloud\Dlp\V2\TransformationResultStatus|null + */ + public function getStatusDetails() + { + return $this->status_details; + } + + public function hasStatusDetails() + { + return isset($this->status_details); + } + + public function clearStatusDetails() + { + unset($this->status_details); + } + + /** + * Status of the transformation, if transformation was not successful, this + * will specify what caused it to fail, otherwise it will show that the + * transformation was successful. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationResultStatus status_details = 4; + * @param \Google\Cloud\Dlp\V2\TransformationResultStatus $var + * @return $this + */ + public function setStatusDetails($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationResultStatus::class); + $this->status_details = $var; + + return $this; + } + + /** + * The number of bytes that were transformed. If transformation was + * unsuccessful or did not take place because there was no content to + * transform, this will be zero. + * + * Generated from protobuf field int64 transformed_bytes = 5; + * @return int|string + */ + public function getTransformedBytes() + { + return $this->transformed_bytes; + } + + /** + * The number of bytes that were transformed. If transformation was + * unsuccessful or did not take place because there was no content to + * transform, this will be zero. + * + * Generated from protobuf field int64 transformed_bytes = 5; + * @param int|string $var + * @return $this + */ + public function setTransformedBytes($var) + { + GPBUtil::checkInt64($var); + $this->transformed_bytes = $var; + + return $this; + } + + /** + * The precise location of the transformed content in the original container. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationLocation transformation_location = 6; + * @return \Google\Cloud\Dlp\V2\TransformationLocation|null + */ + public function getTransformationLocation() + { + return $this->transformation_location; + } + + public function hasTransformationLocation() + { + return isset($this->transformation_location); + } + + public function clearTransformationLocation() + { + unset($this->transformation_location); + } + + /** + * The precise location of the transformed content in the original container. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationLocation transformation_location = 6; + * @param \Google\Cloud\Dlp\V2\TransformationLocation $var + * @return $this + */ + public function setTransformationLocation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationLocation::class); + $this->transformation_location = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetailsStorageConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetailsStorageConfig.php new file mode 100644 index 000000000000..24bf69f6a45b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetailsStorageConfig.php @@ -0,0 +1,90 @@ +google.privacy.dlp.v2.TransformationDetailsStorageConfig + */ +class TransformationDetailsStorageConfig extends \Google\Protobuf\Internal\Message +{ + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\BigQueryTable $table + * The BigQuery table in which to store the output. This may be an existing + * table or in a new table in an existing dataset. + * If table_id is not set a new one will be generated for you with the + * following format: + * dlp_googleapis_transformation_details_yyyy_mm_dd_[dlp_job_id]. Pacific + * time zone will be used for generating the date details. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * The BigQuery table in which to store the output. This may be an existing + * table or in a new table in an existing dataset. + * If table_id is not set a new one will be generated for you with the + * following format: + * dlp_googleapis_transformation_details_yyyy_mm_dd_[dlp_job_id]. Pacific + * time zone will be used for generating the date details. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; + * @return \Google\Cloud\Dlp\V2\BigQueryTable|null + */ + public function getTable() + { + return $this->readOneof(1); + } + + public function hasTable() + { + return $this->hasOneof(1); + } + + /** + * The BigQuery table in which to store the output. This may be an existing + * table or in a new table in an existing dataset. + * If table_id is not set a new one will be generated for you with the + * following format: + * dlp_googleapis_transformation_details_yyyy_mm_dd_[dlp_job_id]. Pacific + * time zone will be used for generating the date details. + * + * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; + * @param \Google\Cloud\Dlp\V2\BigQueryTable $var + * @return $this + */ + public function setTable($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling.php new file mode 100644 index 000000000000..59e5328ad8ef --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling.php @@ -0,0 +1,115 @@ +google.privacy.dlp.v2.TransformationErrorHandling + */ +class TransformationErrorHandling extends \Google\Protobuf\Internal\Message +{ + protected $mode; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\TransformationErrorHandling\ThrowError $throw_error + * Throw an error + * @type \Google\Cloud\Dlp\V2\TransformationErrorHandling\LeaveUntransformed $leave_untransformed + * Ignore errors + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Throw an error + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling.ThrowError throw_error = 1; + * @return \Google\Cloud\Dlp\V2\TransformationErrorHandling\ThrowError|null + */ + public function getThrowError() + { + return $this->readOneof(1); + } + + public function hasThrowError() + { + return $this->hasOneof(1); + } + + /** + * Throw an error + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling.ThrowError throw_error = 1; + * @param \Google\Cloud\Dlp\V2\TransformationErrorHandling\ThrowError $var + * @return $this + */ + public function setThrowError($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationErrorHandling\ThrowError::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Ignore errors + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling.LeaveUntransformed leave_untransformed = 2; + * @return \Google\Cloud\Dlp\V2\TransformationErrorHandling\LeaveUntransformed|null + */ + public function getLeaveUntransformed() + { + return $this->readOneof(2); + } + + public function hasLeaveUntransformed() + { + return $this->hasOneof(2); + } + + /** + * Ignore errors + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling.LeaveUntransformed leave_untransformed = 2; + * @param \Google\Cloud\Dlp\V2\TransformationErrorHandling\LeaveUntransformed $var + * @return $this + */ + public function setLeaveUntransformed($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationErrorHandling\LeaveUntransformed::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getMode() + { + return $this->whichOneof("mode"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/LeaveUntransformed.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/LeaveUntransformed.php new file mode 100644 index 000000000000..6bae015ce978 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/LeaveUntransformed.php @@ -0,0 +1,39 @@ +google.privacy.dlp.v2.TransformationErrorHandling.LeaveUntransformed + */ +class LeaveUntransformed extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(LeaveUntransformed::class, \Google\Cloud\Dlp\V2\TransformationErrorHandling_LeaveUntransformed::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/ThrowError.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/ThrowError.php new file mode 100644 index 000000000000..7333a88ddd7e --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/ThrowError.php @@ -0,0 +1,36 @@ +google.privacy.dlp.v2.TransformationErrorHandling.ThrowError + */ +class ThrowError extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ThrowError::class, \Google\Cloud\Dlp\V2\TransformationErrorHandling_ThrowError::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationLocation.php new file mode 100644 index 000000000000..458b4a9e22ad --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationLocation.php @@ -0,0 +1,158 @@ +google.privacy.dlp.v2.TransformationLocation + */ +class TransformationLocation extends \Google\Protobuf\Internal\Message +{ + /** + * Information about the functionality of the container where this finding + * occurred, if available. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationContainerType container_type = 3; + */ + protected $container_type = 0; + protected $location_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $finding_id + * For infotype transformations, link to the corresponding findings ID so + * that location information does not need to be duplicated. Each findings + * ID correlates to an entry in the findings output table, this table only + * gets created when users specify to save findings (add the save findings + * action to the request). + * @type \Google\Cloud\Dlp\V2\RecordTransformation $record_transformation + * For record transformations, provide a field and container information. + * @type int $container_type + * Information about the functionality of the container where this finding + * occurred, if available. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * For infotype transformations, link to the corresponding findings ID so + * that location information does not need to be duplicated. Each findings + * ID correlates to an entry in the findings output table, this table only + * gets created when users specify to save findings (add the save findings + * action to the request). + * + * Generated from protobuf field string finding_id = 1; + * @return string + */ + public function getFindingId() + { + return $this->readOneof(1); + } + + public function hasFindingId() + { + return $this->hasOneof(1); + } + + /** + * For infotype transformations, link to the corresponding findings ID so + * that location information does not need to be duplicated. Each findings + * ID correlates to an entry in the findings output table, this table only + * gets created when users specify to save findings (add the save findings + * action to the request). + * + * Generated from protobuf field string finding_id = 1; + * @param string $var + * @return $this + */ + public function setFindingId($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * For record transformations, provide a field and container information. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordTransformation record_transformation = 2; + * @return \Google\Cloud\Dlp\V2\RecordTransformation|null + */ + public function getRecordTransformation() + { + return $this->readOneof(2); + } + + public function hasRecordTransformation() + { + return $this->hasOneof(2); + } + + /** + * For record transformations, provide a field and container information. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordTransformation record_transformation = 2; + * @param \Google\Cloud\Dlp\V2\RecordTransformation $var + * @return $this + */ + public function setRecordTransformation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordTransformation::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Information about the functionality of the container where this finding + * occurred, if available. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationContainerType container_type = 3; + * @return int + */ + public function getContainerType() + { + return $this->container_type; + } + + /** + * Information about the functionality of the container where this finding + * occurred, if available. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationContainerType container_type = 3; + * @param int $var + * @return $this + */ + public function setContainerType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\TransformationContainerType::class); + $this->container_type = $var; + + return $this; + } + + /** + * @return string + */ + public function getLocationType() + { + return $this->whichOneof("location_type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationOverview.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationOverview.php new file mode 100644 index 000000000000..74a2de1d0589 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationOverview.php @@ -0,0 +1,101 @@ +google.privacy.dlp.v2.TransformationOverview + */ +class TransformationOverview extends \Google\Protobuf\Internal\Message +{ + /** + * Total size in bytes that were transformed in some way. + * + * Generated from protobuf field int64 transformed_bytes = 2; + */ + protected $transformed_bytes = 0; + /** + * Transformations applied to the dataset. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationSummary transformation_summaries = 3; + */ + private $transformation_summaries; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $transformed_bytes + * Total size in bytes that were transformed in some way. + * @type array<\Google\Cloud\Dlp\V2\TransformationSummary>|\Google\Protobuf\Internal\RepeatedField $transformation_summaries + * Transformations applied to the dataset. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Total size in bytes that were transformed in some way. + * + * Generated from protobuf field int64 transformed_bytes = 2; + * @return int|string + */ + public function getTransformedBytes() + { + return $this->transformed_bytes; + } + + /** + * Total size in bytes that were transformed in some way. + * + * Generated from protobuf field int64 transformed_bytes = 2; + * @param int|string $var + * @return $this + */ + public function setTransformedBytes($var) + { + GPBUtil::checkInt64($var); + $this->transformed_bytes = $var; + + return $this; + } + + /** + * Transformations applied to the dataset. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationSummary transformation_summaries = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTransformationSummaries() + { + return $this->transformation_summaries; + } + + /** + * Transformations applied to the dataset. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationSummary transformation_summaries = 3; + * @param array<\Google\Cloud\Dlp\V2\TransformationSummary>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTransformationSummaries($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\TransformationSummary::class); + $this->transformation_summaries = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatus.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatus.php new file mode 100644 index 000000000000..28eb9e5aa675 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatus.php @@ -0,0 +1,115 @@ +google.privacy.dlp.v2.TransformationResultStatus + */ +class TransformationResultStatus extends \Google\Protobuf\Internal\Message +{ + /** + * Transformation result status type, this will be either SUCCESS, or it will + * be the reason for why the transformation was not completely successful. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationResultStatusType result_status_type = 1; + */ + protected $result_status_type = 0; + /** + * Detailed error codes and messages + * + * Generated from protobuf field .google.rpc.Status details = 2; + */ + protected $details = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $result_status_type + * Transformation result status type, this will be either SUCCESS, or it will + * be the reason for why the transformation was not completely successful. + * @type \Google\Rpc\Status $details + * Detailed error codes and messages + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Transformation result status type, this will be either SUCCESS, or it will + * be the reason for why the transformation was not completely successful. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationResultStatusType result_status_type = 1; + * @return int + */ + public function getResultStatusType() + { + return $this->result_status_type; + } + + /** + * Transformation result status type, this will be either SUCCESS, or it will + * be the reason for why the transformation was not completely successful. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationResultStatusType result_status_type = 1; + * @param int $var + * @return $this + */ + public function setResultStatusType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\TransformationResultStatusType::class); + $this->result_status_type = $var; + + return $this; + } + + /** + * Detailed error codes and messages + * + * Generated from protobuf field .google.rpc.Status details = 2; + * @return \Google\Rpc\Status|null + */ + public function getDetails() + { + return $this->details; + } + + public function hasDetails() + { + return isset($this->details); + } + + public function clearDetails() + { + unset($this->details); + } + + /** + * Detailed error codes and messages + * + * Generated from protobuf field .google.rpc.Status details = 2; + * @param \Google\Rpc\Status $var + * @return $this + */ + public function setDetails($var) + { + GPBUtil::checkMessage($var, \Google\Rpc\Status::class); + $this->details = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatusType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatusType.php new file mode 100644 index 000000000000..a308e60c8154 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatusType.php @@ -0,0 +1,82 @@ +google.privacy.dlp.v2.TransformationResultStatusType + */ +class TransformationResultStatusType +{ + /** + * Unused. + * + * Generated from protobuf enum STATE_TYPE_UNSPECIFIED = 0; + */ + const STATE_TYPE_UNSPECIFIED = 0; + /** + * This will be set when a finding could not be transformed (i.e. outside user + * set bucket range). + * + * Generated from protobuf enum INVALID_TRANSFORM = 1; + */ + const INVALID_TRANSFORM = 1; + /** + * This will be set when a BigQuery transformation was successful but could + * not be stored back in BigQuery because the transformed row exceeds + * BigQuery's max row size. + * + * Generated from protobuf enum BIGQUERY_MAX_ROW_SIZE_EXCEEDED = 2; + */ + const BIGQUERY_MAX_ROW_SIZE_EXCEEDED = 2; + /** + * This will be set when there is a finding in the custom metadata of a file, + * but at the write time of the transformed file, this key / value pair is + * unretrievable. + * + * Generated from protobuf enum METADATA_UNRETRIEVABLE = 3; + */ + const METADATA_UNRETRIEVABLE = 3; + /** + * This will be set when the transformation and storing of it is successful. + * + * Generated from protobuf enum SUCCESS = 4; + */ + const SUCCESS = 4; + + private static $valueToName = [ + self::STATE_TYPE_UNSPECIFIED => 'STATE_TYPE_UNSPECIFIED', + self::INVALID_TRANSFORM => 'INVALID_TRANSFORM', + self::BIGQUERY_MAX_ROW_SIZE_EXCEEDED => 'BIGQUERY_MAX_ROW_SIZE_EXCEEDED', + self::METADATA_UNRETRIEVABLE => 'METADATA_UNRETRIEVABLE', + self::SUCCESS => 'SUCCESS', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary.php new file mode 100644 index 000000000000..04cfa3e5e049 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary.php @@ -0,0 +1,321 @@ +google.privacy.dlp.v2.TransformationSummary + */ +class TransformationSummary extends \Google\Protobuf\Internal\Message +{ + /** + * Set if the transformation was limited to a specific InfoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + */ + protected $info_type = null; + /** + * Set if the transformation was limited to a specific FieldId. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 2; + */ + protected $field = null; + /** + * The specific transformation these stats apply to. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation transformation = 3; + */ + protected $transformation = null; + /** + * The field transformation that was applied. + * If multiple field transformations are requested for a single field, + * this list will contain all of them; otherwise, only one is supplied. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldTransformation field_transformations = 5; + */ + private $field_transformations; + /** + * The specific suppression option these stats apply to. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordSuppression record_suppress = 6; + */ + protected $record_suppress = null; + /** + * Collection of all transformations that took place or had an error. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationSummary.SummaryResult results = 4; + */ + private $results; + /** + * Total size in bytes that were transformed in some way. + * + * Generated from protobuf field int64 transformed_bytes = 7; + */ + protected $transformed_bytes = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\InfoType $info_type + * Set if the transformation was limited to a specific InfoType. + * @type \Google\Cloud\Dlp\V2\FieldId $field + * Set if the transformation was limited to a specific FieldId. + * @type \Google\Cloud\Dlp\V2\PrimitiveTransformation $transformation + * The specific transformation these stats apply to. + * @type array<\Google\Cloud\Dlp\V2\FieldTransformation>|\Google\Protobuf\Internal\RepeatedField $field_transformations + * The field transformation that was applied. + * If multiple field transformations are requested for a single field, + * this list will contain all of them; otherwise, only one is supplied. + * @type \Google\Cloud\Dlp\V2\RecordSuppression $record_suppress + * The specific suppression option these stats apply to. + * @type array<\Google\Cloud\Dlp\V2\TransformationSummary\SummaryResult>|\Google\Protobuf\Internal\RepeatedField $results + * Collection of all transformations that took place or had an error. + * @type int|string $transformed_bytes + * Total size in bytes that were transformed in some way. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Set if the transformation was limited to a specific InfoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @return \Google\Cloud\Dlp\V2\InfoType|null + */ + public function getInfoType() + { + return $this->info_type; + } + + public function hasInfoType() + { + return isset($this->info_type); + } + + public function clearInfoType() + { + unset($this->info_type); + } + + /** + * Set if the transformation was limited to a specific InfoType. + * + * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; + * @param \Google\Cloud\Dlp\V2\InfoType $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); + $this->info_type = $var; + + return $this; + } + + /** + * Set if the transformation was limited to a specific FieldId. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 2; + * @return \Google\Cloud\Dlp\V2\FieldId|null + */ + public function getField() + { + return $this->field; + } + + public function hasField() + { + return isset($this->field); + } + + public function clearField() + { + unset($this->field); + } + + /** + * Set if the transformation was limited to a specific FieldId. + * + * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 2; + * @param \Google\Cloud\Dlp\V2\FieldId $var + * @return $this + */ + public function setField($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); + $this->field = $var; + + return $this; + } + + /** + * The specific transformation these stats apply to. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation transformation = 3; + * @return \Google\Cloud\Dlp\V2\PrimitiveTransformation|null + */ + public function getTransformation() + { + return $this->transformation; + } + + public function hasTransformation() + { + return isset($this->transformation); + } + + public function clearTransformation() + { + unset($this->transformation); + } + + /** + * The specific transformation these stats apply to. + * + * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation transformation = 3; + * @param \Google\Cloud\Dlp\V2\PrimitiveTransformation $var + * @return $this + */ + public function setTransformation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrimitiveTransformation::class); + $this->transformation = $var; + + return $this; + } + + /** + * The field transformation that was applied. + * If multiple field transformations are requested for a single field, + * this list will contain all of them; otherwise, only one is supplied. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldTransformation field_transformations = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFieldTransformations() + { + return $this->field_transformations; + } + + /** + * The field transformation that was applied. + * If multiple field transformations are requested for a single field, + * this list will contain all of them; otherwise, only one is supplied. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldTransformation field_transformations = 5; + * @param array<\Google\Cloud\Dlp\V2\FieldTransformation>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFieldTransformations($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldTransformation::class); + $this->field_transformations = $arr; + + return $this; + } + + /** + * The specific suppression option these stats apply to. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordSuppression record_suppress = 6; + * @return \Google\Cloud\Dlp\V2\RecordSuppression|null + */ + public function getRecordSuppress() + { + return $this->record_suppress; + } + + public function hasRecordSuppress() + { + return isset($this->record_suppress); + } + + public function clearRecordSuppress() + { + unset($this->record_suppress); + } + + /** + * The specific suppression option these stats apply to. + * + * Generated from protobuf field .google.privacy.dlp.v2.RecordSuppression record_suppress = 6; + * @param \Google\Cloud\Dlp\V2\RecordSuppression $var + * @return $this + */ + public function setRecordSuppress($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordSuppression::class); + $this->record_suppress = $var; + + return $this; + } + + /** + * Collection of all transformations that took place or had an error. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationSummary.SummaryResult results = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getResults() + { + return $this->results; + } + + /** + * Collection of all transformations that took place or had an error. + * + * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationSummary.SummaryResult results = 4; + * @param array<\Google\Cloud\Dlp\V2\TransformationSummary\SummaryResult>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\TransformationSummary\SummaryResult::class); + $this->results = $arr; + + return $this; + } + + /** + * Total size in bytes that were transformed in some way. + * + * Generated from protobuf field int64 transformed_bytes = 7; + * @return int|string + */ + public function getTransformedBytes() + { + return $this->transformed_bytes; + } + + /** + * Total size in bytes that were transformed in some way. + * + * Generated from protobuf field int64 transformed_bytes = 7; + * @param int|string $var + * @return $this + */ + public function setTransformedBytes($var) + { + GPBUtil::checkInt64($var); + $this->transformed_bytes = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/SummaryResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/SummaryResult.php new file mode 100644 index 000000000000..fc99bcd54c85 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/SummaryResult.php @@ -0,0 +1,143 @@ +google.privacy.dlp.v2.TransformationSummary.SummaryResult + */ +class SummaryResult extends \Google\Protobuf\Internal\Message +{ + /** + * Number of transformations counted by this result. + * + * Generated from protobuf field int64 count = 1; + */ + protected $count = 0; + /** + * Outcome of the transformation. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationSummary.TransformationResultCode code = 2; + */ + protected $code = 0; + /** + * A place for warnings or errors to show up if a transformation didn't + * work as expected. + * + * Generated from protobuf field string details = 3; + */ + protected $details = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $count + * Number of transformations counted by this result. + * @type int $code + * Outcome of the transformation. + * @type string $details + * A place for warnings or errors to show up if a transformation didn't + * work as expected. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Number of transformations counted by this result. + * + * Generated from protobuf field int64 count = 1; + * @return int|string + */ + public function getCount() + { + return $this->count; + } + + /** + * Number of transformations counted by this result. + * + * Generated from protobuf field int64 count = 1; + * @param int|string $var + * @return $this + */ + public function setCount($var) + { + GPBUtil::checkInt64($var); + $this->count = $var; + + return $this; + } + + /** + * Outcome of the transformation. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationSummary.TransformationResultCode code = 2; + * @return int + */ + public function getCode() + { + return $this->code; + } + + /** + * Outcome of the transformation. + * + * Generated from protobuf field .google.privacy.dlp.v2.TransformationSummary.TransformationResultCode code = 2; + * @param int $var + * @return $this + */ + public function setCode($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\TransformationSummary\TransformationResultCode::class); + $this->code = $var; + + return $this; + } + + /** + * A place for warnings or errors to show up if a transformation didn't + * work as expected. + * + * Generated from protobuf field string details = 3; + * @return string + */ + public function getDetails() + { + return $this->details; + } + + /** + * A place for warnings or errors to show up if a transformation didn't + * work as expected. + * + * Generated from protobuf field string details = 3; + * @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(SummaryResult::class, \Google\Cloud\Dlp\V2\TransformationSummary_SummaryResult::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/TransformationResultCode.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/TransformationResultCode.php new file mode 100644 index 000000000000..e2f82e986ca2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/TransformationResultCode.php @@ -0,0 +1,64 @@ +google.privacy.dlp.v2.TransformationSummary.TransformationResultCode + */ +class TransformationResultCode +{ + /** + * Unused + * + * Generated from protobuf enum TRANSFORMATION_RESULT_CODE_UNSPECIFIED = 0; + */ + const TRANSFORMATION_RESULT_CODE_UNSPECIFIED = 0; + /** + * Transformation completed without an error. + * + * Generated from protobuf enum SUCCESS = 1; + */ + const SUCCESS = 1; + /** + * Transformation had an error. + * + * Generated from protobuf enum ERROR = 2; + */ + const ERROR = 2; + + private static $valueToName = [ + self::TRANSFORMATION_RESULT_CODE_UNSPECIFIED => 'TRANSFORMATION_RESULT_CODE_UNSPECIFIED', + self::SUCCESS => 'SUCCESS', + self::ERROR => 'ERROR', + ]; + + 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(TransformationResultCode::class, \Google\Cloud\Dlp\V2\TransformationSummary_TransformationResultCode::class); + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationType.php new file mode 100644 index 000000000000..0bff43bdcf5e --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationType.php @@ -0,0 +1,147 @@ +google.privacy.dlp.v2.TransformationType + */ +class TransformationType +{ + /** + * Unused + * + * Generated from protobuf enum TRANSFORMATION_TYPE_UNSPECIFIED = 0; + */ + const TRANSFORMATION_TYPE_UNSPECIFIED = 0; + /** + * Record suppression + * + * Generated from protobuf enum RECORD_SUPPRESSION = 1; + */ + const RECORD_SUPPRESSION = 1; + /** + * Replace value + * + * Generated from protobuf enum REPLACE_VALUE = 2; + */ + const REPLACE_VALUE = 2; + /** + * Replace value using a dictionary. + * + * Generated from protobuf enum REPLACE_DICTIONARY = 15; + */ + const REPLACE_DICTIONARY = 15; + /** + * Redact + * + * Generated from protobuf enum REDACT = 3; + */ + const REDACT = 3; + /** + * Character mask + * + * Generated from protobuf enum CHARACTER_MASK = 4; + */ + const CHARACTER_MASK = 4; + /** + * FFX-FPE + * + * Generated from protobuf enum CRYPTO_REPLACE_FFX_FPE = 5; + */ + const CRYPTO_REPLACE_FFX_FPE = 5; + /** + * Fixed size bucketing + * + * Generated from protobuf enum FIXED_SIZE_BUCKETING = 6; + */ + const FIXED_SIZE_BUCKETING = 6; + /** + * Bucketing + * + * Generated from protobuf enum BUCKETING = 7; + */ + const BUCKETING = 7; + /** + * Replace with info type + * + * Generated from protobuf enum REPLACE_WITH_INFO_TYPE = 8; + */ + const REPLACE_WITH_INFO_TYPE = 8; + /** + * Time part + * + * Generated from protobuf enum TIME_PART = 9; + */ + const TIME_PART = 9; + /** + * Crypto hash + * + * Generated from protobuf enum CRYPTO_HASH = 10; + */ + const CRYPTO_HASH = 10; + /** + * Date shift + * + * Generated from protobuf enum DATE_SHIFT = 12; + */ + const DATE_SHIFT = 12; + /** + * Deterministic crypto + * + * Generated from protobuf enum CRYPTO_DETERMINISTIC_CONFIG = 13; + */ + const CRYPTO_DETERMINISTIC_CONFIG = 13; + /** + * Redact image + * + * Generated from protobuf enum REDACT_IMAGE = 14; + */ + const REDACT_IMAGE = 14; + + private static $valueToName = [ + self::TRANSFORMATION_TYPE_UNSPECIFIED => 'TRANSFORMATION_TYPE_UNSPECIFIED', + self::RECORD_SUPPRESSION => 'RECORD_SUPPRESSION', + self::REPLACE_VALUE => 'REPLACE_VALUE', + self::REPLACE_DICTIONARY => 'REPLACE_DICTIONARY', + self::REDACT => 'REDACT', + self::CHARACTER_MASK => 'CHARACTER_MASK', + self::CRYPTO_REPLACE_FFX_FPE => 'CRYPTO_REPLACE_FFX_FPE', + self::FIXED_SIZE_BUCKETING => 'FIXED_SIZE_BUCKETING', + self::BUCKETING => 'BUCKETING', + self::REPLACE_WITH_INFO_TYPE => 'REPLACE_WITH_INFO_TYPE', + self::TIME_PART => 'TIME_PART', + self::CRYPTO_HASH => 'CRYPTO_HASH', + self::DATE_SHIFT => 'DATE_SHIFT', + self::CRYPTO_DETERMINISTIC_CONFIG => 'CRYPTO_DETERMINISTIC_CONFIG', + self::REDACT_IMAGE => 'REDACT_IMAGE', + ]; + + 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransientCryptoKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransientCryptoKey.php new file mode 100644 index 000000000000..d489aa9fe140 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransientCryptoKey.php @@ -0,0 +1,88 @@ +google.privacy.dlp.v2.TransientCryptoKey + */ +class TransientCryptoKey extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the key. + * This is an arbitrary string used to differentiate different keys. + * A unique key is generated per name: two separate `TransientCryptoKey` + * protos share the same generated key if their names are the same. + * When the data crypto key is generated, this name is not used in any way + * (repeating the api call will result in a different key being generated). + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the key. + * This is an arbitrary string used to differentiate different keys. + * A unique key is generated per name: two separate `TransientCryptoKey` + * protos share the same generated key if their names are the same. + * When the data crypto key is generated, this name is not used in any way + * (repeating the api call will result in a different key being generated). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the key. + * This is an arbitrary string used to differentiate different keys. + * A unique key is generated per name: two separate `TransientCryptoKey` + * protos share the same generated key if their names are the same. + * When the data crypto key is generated, this name is not used in any way + * (repeating the api call will result in a different key being generated). + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the key. + * This is an arbitrary string used to differentiate different keys. + * A unique key is generated per name: two separate `TransientCryptoKey` + * protos share the same generated key if their names are the same. + * When the data crypto key is generated, this name is not used in any way + * (repeating the api call will result in a different key being generated). + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UniquenessScoreLevel.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UniquenessScoreLevel.php new file mode 100644 index 000000000000..32a233f41645 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UniquenessScoreLevel.php @@ -0,0 +1,72 @@ +google.privacy.dlp.v2.UniquenessScoreLevel + */ +class UniquenessScoreLevel +{ + /** + * Some columns do not have estimated uniqueness. Possible reasons include + * having too few values. + * + * Generated from protobuf enum UNIQUENESS_SCORE_LEVEL_UNSPECIFIED = 0; + */ + const UNIQUENESS_SCORE_LEVEL_UNSPECIFIED = 0; + /** + * Low uniqueness, possibly a boolean, enum or similiarly typed column. + * + * Generated from protobuf enum UNIQUENESS_SCORE_LOW = 1; + */ + const UNIQUENESS_SCORE_LOW = 1; + /** + * Medium uniqueness. + * + * Generated from protobuf enum UNIQUENESS_SCORE_MEDIUM = 2; + */ + const UNIQUENESS_SCORE_MEDIUM = 2; + /** + * High uniqueness, possibly a column of free text or unique identifiers. + * + * Generated from protobuf enum UNIQUENESS_SCORE_HIGH = 3; + */ + const UNIQUENESS_SCORE_HIGH = 3; + + private static $valueToName = [ + self::UNIQUENESS_SCORE_LEVEL_UNSPECIFIED => 'UNIQUENESS_SCORE_LEVEL_UNSPECIFIED', + self::UNIQUENESS_SCORE_LOW => 'UNIQUENESS_SCORE_LOW', + self::UNIQUENESS_SCORE_MEDIUM => 'UNIQUENESS_SCORE_MEDIUM', + self::UNIQUENESS_SCORE_HIGH => 'UNIQUENESS_SCORE_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); + } +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UnwrappedCryptoKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UnwrappedCryptoKey.php new file mode 100644 index 000000000000..5fc83b85b802 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UnwrappedCryptoKey.php @@ -0,0 +1,68 @@ +google.privacy.dlp.v2.UnwrappedCryptoKey + */ +class UnwrappedCryptoKey extends \Google\Protobuf\Internal\Message +{ + /** + * Required. A 128/192/256 bit key. + * + * Generated from protobuf field bytes key = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $key = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $key + * Required. A 128/192/256 bit key. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. A 128/192/256 bit key. + * + * Generated from protobuf field bytes key = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getKey() + { + return $this->key; + } + + /** + * Required. A 128/192/256 bit key. + * + * Generated from protobuf field bytes key = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setKey($var) + { + GPBUtil::checkString($var, False); + $this->key = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateConnectionRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateConnectionRequest.php new file mode 100644 index 000000000000..71462dea509e --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateConnectionRequest.php @@ -0,0 +1,174 @@ +google.privacy.dlp.v2.UpdateConnectionRequest + */ +class UpdateConnectionRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Required. The connection with new values for the relevant fields. + * + * Generated from protobuf field .google.privacy.dlp.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $connection = null; + /** + * Optional. Mask to control which fields get updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $update_mask = null; + + /** + * @param string $name Required. Resource name in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. Please see + * {@see DlpServiceClient::connectionName()} for help formatting this field. + * + * @return \Google\Cloud\Dlp\V2\UpdateConnectionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * @type \Google\Cloud\Dlp\V2\Connection $connection + * Required. The connection with new values for the relevant fields. + * @type \Google\Protobuf\FieldMask $update_mask + * Optional. Mask to control which fields get updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * + * 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; + } + + /** + * Required. The connection with new values for the relevant fields. + * + * Generated from protobuf field .google.privacy.dlp.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\Connection|null + */ + public function getConnection() + { + return $this->connection; + } + + public function hasConnection() + { + return isset($this->connection); + } + + public function clearConnection() + { + unset($this->connection); + } + + /** + * Required. The connection with new values for the relevant fields. + * + * Generated from protobuf field .google.privacy.dlp.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\Connection $var + * @return $this + */ + public function setConnection($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Connection::class); + $this->connection = $var; + + return $this; + } + + /** + * Optional. Mask to control which fields get updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @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); + } + + /** + * Optional. Mask to control which fields get updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDeidentifyTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDeidentifyTemplateRequest.php new file mode 100644 index 000000000000..5a3369b76e63 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDeidentifyTemplateRequest.php @@ -0,0 +1,188 @@ +google.privacy.dlp.v2.UpdateDeidentifyTemplateRequest + */ +class UpdateDeidentifyTemplateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of organization and deidentify template to be + * updated, for example + * `organizations/433245324/deidentifyTemplates/432452342` or + * projects/project-id/deidentifyTemplates/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * New DeidentifyTemplate value. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate deidentify_template = 2; + */ + protected $deidentify_template = null; + /** + * Mask to control which fields get updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; + */ + protected $update_mask = null; + + /** + * @param string $name Required. Resource name of organization and deidentify template to be + * updated, for example + * `organizations/433245324/deidentifyTemplates/432452342` or + * projects/project-id/deidentifyTemplates/432452342. Please see + * {@see DlpServiceClient::deidentifyTemplateName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $deidentifyTemplate New DeidentifyTemplate value. + * @param \Google\Protobuf\FieldMask $updateMask Mask to control which fields get updated. + * + * @return \Google\Cloud\Dlp\V2\UpdateDeidentifyTemplateRequest + * + * @experimental + */ + public static function build(string $name, \Google\Cloud\Dlp\V2\DeidentifyTemplate $deidentifyTemplate, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setName($name) + ->setDeidentifyTemplate($deidentifyTemplate) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of organization and deidentify template to be + * updated, for example + * `organizations/433245324/deidentifyTemplates/432452342` or + * projects/project-id/deidentifyTemplates/432452342. + * @type \Google\Cloud\Dlp\V2\DeidentifyTemplate $deidentify_template + * New DeidentifyTemplate value. + * @type \Google\Protobuf\FieldMask $update_mask + * Mask to control which fields get updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of organization and deidentify template to be + * updated, for example + * `organizations/433245324/deidentifyTemplates/432452342` or + * projects/project-id/deidentifyTemplates/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of organization and deidentify template to be + * updated, for example + * `organizations/433245324/deidentifyTemplates/432452342` or + * projects/project-id/deidentifyTemplates/432452342. + * + * 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; + } + + /** + * New DeidentifyTemplate value. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate deidentify_template = 2; + * @return \Google\Cloud\Dlp\V2\DeidentifyTemplate|null + */ + public function getDeidentifyTemplate() + { + return $this->deidentify_template; + } + + public function hasDeidentifyTemplate() + { + return isset($this->deidentify_template); + } + + public function clearDeidentifyTemplate() + { + unset($this->deidentify_template); + } + + /** + * New DeidentifyTemplate value. + * + * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate deidentify_template = 2; + * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $var + * @return $this + */ + public function setDeidentifyTemplate($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyTemplate::class); + $this->deidentify_template = $var; + + return $this; + } + + /** + * Mask to control which fields get updated. + * + * 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); + } + + /** + * Mask to control which fields get updated. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDiscoveryConfigRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDiscoveryConfigRequest.php new file mode 100644 index 000000000000..90b9eda83aa7 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDiscoveryConfigRequest.php @@ -0,0 +1,178 @@ +google.privacy.dlp.v2.UpdateDiscoveryConfigRequest + */ +class UpdateDiscoveryConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the project and the configuration, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Required. New DiscoveryConfig value. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $discovery_config = null; + /** + * Mask to control which fields get updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; + */ + protected $update_mask = null; + + /** + * @param string $name Required. Resource name of the project and the configuration, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. Please see + * {@see DlpServiceClient::discoveryConfigName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\DiscoveryConfig $discoveryConfig Required. New DiscoveryConfig value. + * @param \Google\Protobuf\FieldMask $updateMask Mask to control which fields get updated. + * + * @return \Google\Cloud\Dlp\V2\UpdateDiscoveryConfigRequest + * + * @experimental + */ + public static function build(string $name, \Google\Cloud\Dlp\V2\DiscoveryConfig $discoveryConfig, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setName($name) + ->setDiscoveryConfig($discoveryConfig) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the project and the configuration, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * @type \Google\Cloud\Dlp\V2\DiscoveryConfig $discovery_config + * Required. New DiscoveryConfig value. + * @type \Google\Protobuf\FieldMask $update_mask + * Mask to control which fields get updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the project and the configuration, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the project and the configuration, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * + * 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; + } + + /** + * Required. New DiscoveryConfig value. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Dlp\V2\DiscoveryConfig|null + */ + public function getDiscoveryConfig() + { + return $this->discovery_config; + } + + public function hasDiscoveryConfig() + { + return isset($this->discovery_config); + } + + public function clearDiscoveryConfig() + { + unset($this->discovery_config); + } + + /** + * Required. New DiscoveryConfig value. + * + * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Dlp\V2\DiscoveryConfig $var + * @return $this + */ + public function setDiscoveryConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryConfig::class); + $this->discovery_config = $var; + + return $this; + } + + /** + * Mask to control which fields get updated. + * + * 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); + } + + /** + * Mask to control which fields get updated. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateInspectTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateInspectTemplateRequest.php new file mode 100644 index 000000000000..9333298d1856 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateInspectTemplateRequest.php @@ -0,0 +1,183 @@ +google.privacy.dlp.v2.UpdateInspectTemplateRequest + */ +class UpdateInspectTemplateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of organization and inspectTemplate to be updated, + * for example `organizations/433245324/inspectTemplates/432452342` or + * projects/project-id/inspectTemplates/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * New InspectTemplate value. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate inspect_template = 2; + */ + protected $inspect_template = null; + /** + * Mask to control which fields get updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; + */ + protected $update_mask = null; + + /** + * @param string $name Required. Resource name of organization and inspectTemplate to be updated, + * for example `organizations/433245324/inspectTemplates/432452342` or + * projects/project-id/inspectTemplates/432452342. Please see + * {@see DlpServiceClient::inspectTemplateName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\InspectTemplate $inspectTemplate New InspectTemplate value. + * @param \Google\Protobuf\FieldMask $updateMask Mask to control which fields get updated. + * + * @return \Google\Cloud\Dlp\V2\UpdateInspectTemplateRequest + * + * @experimental + */ + public static function build(string $name, \Google\Cloud\Dlp\V2\InspectTemplate $inspectTemplate, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setName($name) + ->setInspectTemplate($inspectTemplate) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of organization and inspectTemplate to be updated, + * for example `organizations/433245324/inspectTemplates/432452342` or + * projects/project-id/inspectTemplates/432452342. + * @type \Google\Cloud\Dlp\V2\InspectTemplate $inspect_template + * New InspectTemplate value. + * @type \Google\Protobuf\FieldMask $update_mask + * Mask to control which fields get updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of organization and inspectTemplate to be updated, + * for example `organizations/433245324/inspectTemplates/432452342` or + * projects/project-id/inspectTemplates/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of organization and inspectTemplate to be updated, + * for example `organizations/433245324/inspectTemplates/432452342` or + * projects/project-id/inspectTemplates/432452342. + * + * 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; + } + + /** + * New InspectTemplate value. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate inspect_template = 2; + * @return \Google\Cloud\Dlp\V2\InspectTemplate|null + */ + public function getInspectTemplate() + { + return $this->inspect_template; + } + + public function hasInspectTemplate() + { + return isset($this->inspect_template); + } + + public function clearInspectTemplate() + { + unset($this->inspect_template); + } + + /** + * New InspectTemplate value. + * + * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate inspect_template = 2; + * @param \Google\Cloud\Dlp\V2\InspectTemplate $var + * @return $this + */ + public function setInspectTemplate($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectTemplate::class); + $this->inspect_template = $var; + + return $this; + } + + /** + * Mask to control which fields get updated. + * + * 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); + } + + /** + * Mask to control which fields get updated. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateJobTriggerRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateJobTriggerRequest.php new file mode 100644 index 000000000000..faa41ba7a46a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateJobTriggerRequest.php @@ -0,0 +1,178 @@ +google.privacy.dlp.v2.UpdateJobTriggerRequest + */ +class UpdateJobTriggerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * New JobTrigger value. + * + * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger job_trigger = 2; + */ + protected $job_trigger = null; + /** + * Mask to control which fields get updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; + */ + protected $update_mask = null; + + /** + * @param string $name Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. Please see + * {@see DlpServiceClient::jobTriggerName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\JobTrigger $jobTrigger New JobTrigger value. + * @param \Google\Protobuf\FieldMask $updateMask Mask to control which fields get updated. + * + * @return \Google\Cloud\Dlp\V2\UpdateJobTriggerRequest + * + * @experimental + */ + public static function build(string $name, \Google\Cloud\Dlp\V2\JobTrigger $jobTrigger, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setName($name) + ->setJobTrigger($jobTrigger) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * @type \Google\Cloud\Dlp\V2\JobTrigger $job_trigger + * New JobTrigger value. + * @type \Google\Protobuf\FieldMask $update_mask + * Mask to control which fields get updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * + * 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; + } + + /** + * New JobTrigger value. + * + * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger job_trigger = 2; + * @return \Google\Cloud\Dlp\V2\JobTrigger|null + */ + public function getJobTrigger() + { + return $this->job_trigger; + } + + public function hasJobTrigger() + { + return isset($this->job_trigger); + } + + public function clearJobTrigger() + { + unset($this->job_trigger); + } + + /** + * New JobTrigger value. + * + * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger job_trigger = 2; + * @param \Google\Cloud\Dlp\V2\JobTrigger $var + * @return $this + */ + public function setJobTrigger($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\JobTrigger::class); + $this->job_trigger = $var; + + return $this; + } + + /** + * Mask to control which fields get updated. + * + * 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); + } + + /** + * Mask to control which fields get updated. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateStoredInfoTypeRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateStoredInfoTypeRequest.php new file mode 100644 index 000000000000..65cf0b18fe2b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateStoredInfoTypeRequest.php @@ -0,0 +1,193 @@ +google.privacy.dlp.v2.UpdateStoredInfoTypeRequest + */ +class UpdateStoredInfoTypeRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of organization and storedInfoType to be updated, + * for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Updated configuration for the storedInfoType. If not provided, a new + * version of the storedInfoType will be created with the existing + * configuration. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 2; + */ + protected $config = null; + /** + * Mask to control which fields get updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; + */ + protected $update_mask = null; + + /** + * @param string $name Required. Resource name of organization and storedInfoType to be updated, + * for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. Please see + * {@see DlpServiceClient::storedInfoTypeName()} for help formatting this field. + * @param \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config Updated configuration for the storedInfoType. If not provided, a new + * version of the storedInfoType will be created with the existing + * configuration. + * @param \Google\Protobuf\FieldMask $updateMask Mask to control which fields get updated. + * + * @return \Google\Cloud\Dlp\V2\UpdateStoredInfoTypeRequest + * + * @experimental + */ + public static function build(string $name, \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setName($name) + ->setConfig($config) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Resource name of organization and storedInfoType to be updated, + * for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * @type \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config + * Updated configuration for the storedInfoType. If not provided, a new + * version of the storedInfoType will be created with the existing + * configuration. + * @type \Google\Protobuf\FieldMask $update_mask + * Mask to control which fields get updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of organization and storedInfoType to be updated, + * for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Resource name of organization and storedInfoType to be updated, + * for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * + * 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; + } + + /** + * Updated configuration for the storedInfoType. If not provided, a new + * version of the storedInfoType will be created with the existing + * configuration. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 2; + * @return \Google\Cloud\Dlp\V2\StoredInfoTypeConfig|null + */ + public function getConfig() + { + return $this->config; + } + + public function hasConfig() + { + return isset($this->config); + } + + public function clearConfig() + { + unset($this->config); + } + + /** + * Updated configuration for the storedInfoType. If not provided, a new + * version of the storedInfoType will be created with the existing + * configuration. + * + * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 2; + * @param \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $var + * @return $this + */ + public function setConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StoredInfoTypeConfig::class); + $this->config = $var; + + return $this; + } + + /** + * Mask to control which fields get updated. + * + * 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); + } + + /** + * Mask to control which fields get updated. + * + * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Value.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Value.php new file mode 100644 index 000000000000..d32ec7e852e8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Value.php @@ -0,0 +1,311 @@ +google.privacy.dlp.v2.Value + */ +class Value extends \Google\Protobuf\Internal\Message +{ + protected $type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $integer_value + * integer + * @type float $float_value + * float + * @type string $string_value + * string + * @type bool $boolean_value + * boolean + * @type \Google\Protobuf\Timestamp $timestamp_value + * timestamp + * @type \Google\Type\TimeOfDay $time_value + * time of day + * @type \Google\Type\Date $date_value + * date + * @type int $day_of_week_value + * day of week + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * integer + * + * Generated from protobuf field int64 integer_value = 1; + * @return int|string + */ + public function getIntegerValue() + { + return $this->readOneof(1); + } + + public function hasIntegerValue() + { + return $this->hasOneof(1); + } + + /** + * integer + * + * Generated from protobuf field int64 integer_value = 1; + * @param int|string $var + * @return $this + */ + public function setIntegerValue($var) + { + GPBUtil::checkInt64($var); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * float + * + * Generated from protobuf field double float_value = 2; + * @return float + */ + public function getFloatValue() + { + return $this->readOneof(2); + } + + public function hasFloatValue() + { + return $this->hasOneof(2); + } + + /** + * float + * + * Generated from protobuf field double float_value = 2; + * @param float $var + * @return $this + */ + public function setFloatValue($var) + { + GPBUtil::checkDouble($var); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * string + * + * Generated from protobuf field string string_value = 3; + * @return string + */ + public function getStringValue() + { + return $this->readOneof(3); + } + + public function hasStringValue() + { + return $this->hasOneof(3); + } + + /** + * string + * + * Generated from protobuf field string string_value = 3; + * @param string $var + * @return $this + */ + public function setStringValue($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * boolean + * + * Generated from protobuf field bool boolean_value = 4; + * @return bool + */ + public function getBooleanValue() + { + return $this->readOneof(4); + } + + public function hasBooleanValue() + { + return $this->hasOneof(4); + } + + /** + * boolean + * + * Generated from protobuf field bool boolean_value = 4; + * @param bool $var + * @return $this + */ + public function setBooleanValue($var) + { + GPBUtil::checkBool($var); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * timestamp + * + * Generated from protobuf field .google.protobuf.Timestamp timestamp_value = 5; + * @return \Google\Protobuf\Timestamp|null + */ + public function getTimestampValue() + { + return $this->readOneof(5); + } + + public function hasTimestampValue() + { + return $this->hasOneof(5); + } + + /** + * timestamp + * + * Generated from protobuf field .google.protobuf.Timestamp timestamp_value = 5; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setTimestampValue($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * time of day + * + * Generated from protobuf field .google.type.TimeOfDay time_value = 6; + * @return \Google\Type\TimeOfDay|null + */ + public function getTimeValue() + { + return $this->readOneof(6); + } + + public function hasTimeValue() + { + return $this->hasOneof(6); + } + + /** + * time of day + * + * Generated from protobuf field .google.type.TimeOfDay time_value = 6; + * @param \Google\Type\TimeOfDay $var + * @return $this + */ + public function setTimeValue($var) + { + GPBUtil::checkMessage($var, \Google\Type\TimeOfDay::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * date + * + * Generated from protobuf field .google.type.Date date_value = 7; + * @return \Google\Type\Date|null + */ + public function getDateValue() + { + return $this->readOneof(7); + } + + public function hasDateValue() + { + return $this->hasOneof(7); + } + + /** + * date + * + * Generated from protobuf field .google.type.Date date_value = 7; + * @param \Google\Type\Date $var + * @return $this + */ + public function setDateValue($var) + { + GPBUtil::checkMessage($var, \Google\Type\Date::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * day of week + * + * Generated from protobuf field .google.type.DayOfWeek day_of_week_value = 8; + * @return int + */ + public function getDayOfWeekValue() + { + return $this->readOneof(8); + } + + public function hasDayOfWeekValue() + { + return $this->hasOneof(8); + } + + /** + * day of week + * + * Generated from protobuf field .google.type.DayOfWeek day_of_week_value = 8; + * @param int $var + * @return $this + */ + public function setDayOfWeekValue($var) + { + GPBUtil::checkEnum($var, \Google\Type\DayOfWeek::class); + $this->writeOneof(8, $var); + + return $this; + } + + /** + * @return string + */ + public function getType() + { + return $this->whichOneof("type"); + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ValueFrequency.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ValueFrequency.php new file mode 100644 index 000000000000..577cbb1ecedf --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ValueFrequency.php @@ -0,0 +1,111 @@ +google.privacy.dlp.v2.ValueFrequency + */ +class ValueFrequency extends \Google\Protobuf\Internal\Message +{ + /** + * A value contained in the field in question. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value value = 1; + */ + protected $value = null; + /** + * How many times the value is contained in the field. + * + * Generated from protobuf field int64 count = 2; + */ + protected $count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Dlp\V2\Value $value + * A value contained in the field in question. + * @type int|string $count + * How many times the value is contained in the field. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * A value contained in the field in question. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value value = 1; + * @return \Google\Cloud\Dlp\V2\Value|null + */ + public function getValue() + { + return $this->value; + } + + public function hasValue() + { + return isset($this->value); + } + + public function clearValue() + { + unset($this->value); + } + + /** + * A value contained in the field in question. + * + * Generated from protobuf field .google.privacy.dlp.v2.Value value = 1; + * @param \Google\Cloud\Dlp\V2\Value $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); + $this->value = $var; + + return $this; + } + + /** + * How many times the value is contained in the field. + * + * Generated from protobuf field int64 count = 2; + * @return int|string + */ + public function getCount() + { + return $this->count; + } + + /** + * How many times the value is contained in the field. + * + * Generated from protobuf field int64 count = 2; + * @param int|string $var + * @return $this + */ + public function setCount($var) + { + GPBUtil::checkInt64($var); + $this->count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/VersionDescription.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/VersionDescription.php new file mode 100644 index 000000000000..af4ade2c2724 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/VersionDescription.php @@ -0,0 +1,101 @@ +google.privacy.dlp.v2.VersionDescription + */ +class VersionDescription extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the version + * + * Generated from protobuf field string version = 1; + */ + protected $version = ''; + /** + * Description of the version. + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $version + * Name of the version + * @type string $description + * Description of the version. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); + parent::__construct($data); + } + + /** + * Name of the version + * + * Generated from protobuf field string version = 1; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * Name of the version + * + * Generated from protobuf field string version = 1; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + + /** + * Description of the version. + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Description of the version. + * + * 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; + } + +} + diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/activate_job_trigger.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/activate_job_trigger.php new file mode 100644 index 000000000000..3ac8b7fe7b8a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/activate_job_trigger.php @@ -0,0 +1,73 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var DlpJob $response */ + $response = $dlpServiceClient->activateJobTrigger($request); + 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 = DlpServiceClient::jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + + activate_job_trigger_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_ActivateJobTrigger_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/cancel_dlp_job.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/cancel_dlp_job.php new file mode 100644 index 000000000000..b410e49dfc12 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/cancel_dlp_job.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $dlpServiceClient->cancelDlpJob($request); + 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 = DlpServiceClient::dlpJobName('[PROJECT]', '[DLP_JOB]'); + + cancel_dlp_job_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_CancelDlpJob_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_connection.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_connection.php new file mode 100644 index 000000000000..abbf09650f9a --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_connection.php @@ -0,0 +1,78 @@ +setState($connectionState); + $request = (new CreateConnectionRequest()) + ->setParent($formattedParent) + ->setConnection($connection); + + // Call the API and handle any network failures. + try { + /** @var Connection $response */ + $response = $dlpServiceClient->createConnection($request); + 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 = DlpServiceClient::locationName('[PROJECT]', '[LOCATION]'); + $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; + + create_connection_sample($formattedParent, $connectionState); +} +// [END dlp_v2_generated_DlpService_CreateConnection_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_deidentify_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_deidentify_template.php new file mode 100644 index 000000000000..d5439ac39162 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_deidentify_template.php @@ -0,0 +1,96 @@ + + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + */ +function create_deidentify_template_sample(string $formattedParent): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $deidentifyTemplate = new DeidentifyTemplate(); + $request = (new CreateDeidentifyTemplateRequest()) + ->setParent($formattedParent) + ->setDeidentifyTemplate($deidentifyTemplate); + + // Call the API and handle any network failures. + try { + /** @var DeidentifyTemplate $response */ + $response = $dlpServiceClient->createDeidentifyTemplate($request); + 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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + create_deidentify_template_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_CreateDeidentifyTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_discovery_config.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_discovery_config.php new file mode 100644 index 000000000000..9da45eea0f0f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_discovery_config.php @@ -0,0 +1,86 @@ +PROJECT_ID`/locations/`LOCATION_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::locationName()} for help formatting this field. + * @param int $discoveryConfigStatus A status for this configuration. + */ +function create_discovery_config_sample(string $formattedParent, int $discoveryConfigStatus): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $discoveryConfig = (new DiscoveryConfig()) + ->setStatus($discoveryConfigStatus); + $request = (new CreateDiscoveryConfigRequest()) + ->setParent($formattedParent) + ->setDiscoveryConfig($discoveryConfig); + + // Call the API and handle any network failures. + try { + /** @var DiscoveryConfig $response */ + $response = $dlpServiceClient->createDiscoveryConfig($request); + 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 = DlpServiceClient::locationName('[PROJECT]', '[LOCATION]'); + $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; + + create_discovery_config_sample($formattedParent, $discoveryConfigStatus); +} +// [END dlp_v2_generated_DlpService_CreateDiscoveryConfig_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_dlp_job.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_dlp_job.php new file mode 100644 index 000000000000..3e997b6520b5 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_dlp_job.php @@ -0,0 +1,95 @@ + + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::projectName()} for help formatting this field. + */ +function create_dlp_job_sample(string $formattedParent): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $request = (new CreateDlpJobRequest()) + ->setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var DlpJob $response */ + $response = $dlpServiceClient->createDlpJob($request); + 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 = DlpServiceClient::projectName('[PROJECT]'); + + create_dlp_job_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_CreateDlpJob_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_inspect_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_inspect_template.php new file mode 100644 index 000000000000..c9dd64e3fa12 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_inspect_template.php @@ -0,0 +1,96 @@ + + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + */ +function create_inspect_template_sample(string $formattedParent): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $inspectTemplate = new InspectTemplate(); + $request = (new CreateInspectTemplateRequest()) + ->setParent($formattedParent) + ->setInspectTemplate($inspectTemplate); + + // Call the API and handle any network failures. + try { + /** @var InspectTemplate $response */ + $response = $dlpServiceClient->createInspectTemplate($request); + 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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + create_inspect_template_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_CreateInspectTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_job_trigger.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_job_trigger.php new file mode 100644 index 000000000000..ae8c2c18bea1 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_job_trigger.php @@ -0,0 +1,96 @@ + + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::projectName()} for help formatting this field. + * @param int $jobTriggerStatus A status for this trigger. + */ +function create_job_trigger_sample(string $formattedParent, int $jobTriggerStatus): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $jobTrigger = (new JobTrigger()) + ->setStatus($jobTriggerStatus); + $request = (new CreateJobTriggerRequest()) + ->setParent($formattedParent) + ->setJobTrigger($jobTrigger); + + // Call the API and handle any network failures. + try { + /** @var JobTrigger $response */ + $response = $dlpServiceClient->createJobTrigger($request); + 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 = DlpServiceClient::projectName('[PROJECT]'); + $jobTriggerStatus = Status::STATUS_UNSPECIFIED; + + create_job_trigger_sample($formattedParent, $jobTriggerStatus); +} +// [END dlp_v2_generated_DlpService_CreateJobTrigger_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_stored_info_type.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_stored_info_type.php new file mode 100644 index 000000000000..7a0d31df44e8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_stored_info_type.php @@ -0,0 +1,96 @@ + + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + */ +function create_stored_info_type_sample(string $formattedParent): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $config = new StoredInfoTypeConfig(); + $request = (new CreateStoredInfoTypeRequest()) + ->setParent($formattedParent) + ->setConfig($config); + + // Call the API and handle any network failures. + try { + /** @var StoredInfoType $response */ + $response = $dlpServiceClient->createStoredInfoType($request); + 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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + create_stored_info_type_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_CreateStoredInfoType_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/deidentify_content.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/deidentify_content.php new file mode 100644 index 000000000000..0ae7367e3e2d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/deidentify_content.php @@ -0,0 +1,65 @@ +deidentifyContent($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END dlp_v2_generated_DlpService_DeidentifyContent_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_connection.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_connection.php new file mode 100644 index 000000000000..13dbad8fcf6d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_connection.php @@ -0,0 +1,70 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $dlpServiceClient->deleteConnection($request); + 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 = DlpServiceClient::connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + + delete_connection_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_DeleteConnection_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_deidentify_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_deidentify_template.php new file mode 100644 index 000000000000..36870d8af3d8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_deidentify_template.php @@ -0,0 +1,78 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $dlpServiceClient->deleteDeidentifyTemplate($request); + 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 = DlpServiceClient::deidentifyTemplateName( + '[ORGANIZATION]', + '[DEIDENTIFY_TEMPLATE]' + ); + + delete_deidentify_template_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_DeleteDeidentifyTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_discovery_config.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_discovery_config.php new file mode 100644 index 000000000000..8f5fba101b53 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_discovery_config.php @@ -0,0 +1,74 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $dlpServiceClient->deleteDiscoveryConfig($request); + 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 = DlpServiceClient::discoveryConfigName( + '[PROJECT]', + '[LOCATION]', + '[DISCOVERY_CONFIG]' + ); + + delete_discovery_config_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_DeleteDiscoveryConfig_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_dlp_job.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_dlp_job.php new file mode 100644 index 000000000000..829b2413c84f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_dlp_job.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $dlpServiceClient->deleteDlpJob($request); + 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 = DlpServiceClient::dlpJobName('[PROJECT]', '[DLP_JOB]'); + + delete_dlp_job_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_DeleteDlpJob_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_inspect_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_inspect_template.php new file mode 100644 index 000000000000..b8fd4bbdb772 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_inspect_template.php @@ -0,0 +1,74 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $dlpServiceClient->deleteInspectTemplate($request); + 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 = DlpServiceClient::inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + + delete_inspect_template_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_DeleteInspectTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_job_trigger.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_job_trigger.php new file mode 100644 index 000000000000..5660e40af05f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_job_trigger.php @@ -0,0 +1,73 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $dlpServiceClient->deleteJobTrigger($request); + 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 = DlpServiceClient::jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + + delete_job_trigger_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_DeleteJobTrigger_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_stored_info_type.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_stored_info_type.php new file mode 100644 index 000000000000..48a1cc206f7b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_stored_info_type.php @@ -0,0 +1,74 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $dlpServiceClient->deleteStoredInfoType($request); + 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 = DlpServiceClient::storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + + delete_stored_info_type_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_DeleteStoredInfoType_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_table_data_profile.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_table_data_profile.php new file mode 100644 index 000000000000..05e273d94ca0 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_table_data_profile.php @@ -0,0 +1,74 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $dlpServiceClient->deleteTableDataProfile($request); + 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 = DlpServiceClient::tableDataProfileName( + '[ORGANIZATION]', + '[LOCATION]', + '[TABLE_DATA_PROFILE]' + ); + + delete_table_data_profile_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_DeleteTableDataProfile_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/finish_dlp_job.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/finish_dlp_job.php new file mode 100644 index 000000000000..ce0e1c6b5cad --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/finish_dlp_job.php @@ -0,0 +1,70 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $dlpServiceClient->finishDlpJob($request); + 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 = DlpServiceClient::dlpJobName('[PROJECT]', '[DLP_JOB]'); + + finish_dlp_job_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_FinishDlpJob_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_column_data_profile.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_column_data_profile.php new file mode 100644 index 000000000000..1ff5cabcb1f6 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_column_data_profile.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var ColumnDataProfile $response */ + $response = $dlpServiceClient->getColumnDataProfile($request); + 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 = DlpServiceClient::columnDataProfileName( + '[ORGANIZATION]', + '[LOCATION]', + '[COLUMN_DATA_PROFILE]' + ); + + get_column_data_profile_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_GetColumnDataProfile_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_connection.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_connection.php new file mode 100644 index 000000000000..e5af3e946341 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_connection.php @@ -0,0 +1,72 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Connection $response */ + $response = $dlpServiceClient->getConnection($request); + 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 = DlpServiceClient::connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + + get_connection_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_GetConnection_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_deidentify_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_deidentify_template.php new file mode 100644 index 000000000000..a896ef5090b4 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_deidentify_template.php @@ -0,0 +1,79 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var DeidentifyTemplate $response */ + $response = $dlpServiceClient->getDeidentifyTemplate($request); + 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 = DlpServiceClient::deidentifyTemplateName( + '[ORGANIZATION]', + '[DEIDENTIFY_TEMPLATE]' + ); + + get_deidentify_template_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_GetDeidentifyTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_discovery_config.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_discovery_config.php new file mode 100644 index 000000000000..0eb106a1d567 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_discovery_config.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var DiscoveryConfig $response */ + $response = $dlpServiceClient->getDiscoveryConfig($request); + 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 = DlpServiceClient::discoveryConfigName( + '[PROJECT]', + '[LOCATION]', + '[DISCOVERY_CONFIG]' + ); + + get_discovery_config_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_GetDiscoveryConfig_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_dlp_job.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_dlp_job.php new file mode 100644 index 000000000000..a06e53cdf0f6 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_dlp_job.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var DlpJob $response */ + $response = $dlpServiceClient->getDlpJob($request); + 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 = DlpServiceClient::dlpJobName('[PROJECT]', '[DLP_JOB]'); + + get_dlp_job_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_GetDlpJob_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_inspect_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_inspect_template.php new file mode 100644 index 000000000000..f5626a183e68 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_inspect_template.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var InspectTemplate $response */ + $response = $dlpServiceClient->getInspectTemplate($request); + 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 = DlpServiceClient::inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + + get_inspect_template_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_GetInspectTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_job_trigger.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_job_trigger.php new file mode 100644 index 000000000000..ac5bfce6ed72 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_job_trigger.php @@ -0,0 +1,75 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var JobTrigger $response */ + $response = $dlpServiceClient->getJobTrigger($request); + 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 = DlpServiceClient::jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + + get_job_trigger_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_GetJobTrigger_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_project_data_profile.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_project_data_profile.php new file mode 100644 index 000000000000..7c1e508c3485 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_project_data_profile.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var ProjectDataProfile $response */ + $response = $dlpServiceClient->getProjectDataProfile($request); + 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 = DlpServiceClient::projectDataProfileName( + '[ORGANIZATION]', + '[LOCATION]', + '[PROJECT_DATA_PROFILE]' + ); + + get_project_data_profile_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_GetProjectDataProfile_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_stored_info_type.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_stored_info_type.php new file mode 100644 index 000000000000..6491468fabde --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_stored_info_type.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var StoredInfoType $response */ + $response = $dlpServiceClient->getStoredInfoType($request); + 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 = DlpServiceClient::storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + + get_stored_info_type_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_GetStoredInfoType_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_table_data_profile.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_table_data_profile.php new file mode 100644 index 000000000000..4fddfb768cd8 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_table_data_profile.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var TableDataProfile $response */ + $response = $dlpServiceClient->getTableDataProfile($request); + 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 = DlpServiceClient::tableDataProfileName( + '[ORGANIZATION]', + '[LOCATION]', + '[TABLE_DATA_PROFILE]' + ); + + get_table_data_profile_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_GetTableDataProfile_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_dlp_job.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_dlp_job.php new file mode 100644 index 000000000000..70a712699349 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_dlp_job.php @@ -0,0 +1,74 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var HybridInspectResponse $response */ + $response = $dlpServiceClient->hybridInspectDlpJob($request); + 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 = DlpServiceClient::dlpJobName('[PROJECT]', '[DLP_JOB]'); + + hybrid_inspect_dlp_job_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_HybridInspectDlpJob_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_job_trigger.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_job_trigger.php new file mode 100644 index 000000000000..116810f1d105 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_job_trigger.php @@ -0,0 +1,74 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var HybridInspectResponse $response */ + $response = $dlpServiceClient->hybridInspectJobTrigger($request); + 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 = DlpServiceClient::jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + + hybrid_inspect_job_trigger_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_HybridInspectJobTrigger_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/inspect_content.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/inspect_content.php new file mode 100644 index 000000000000..164e183c94db --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/inspect_content.php @@ -0,0 +1,67 @@ +inspectContent($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END dlp_v2_generated_DlpService_InspectContent_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_column_data_profiles.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_column_data_profiles.php new file mode 100644 index 000000000000..a285f12d5096 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_column_data_profiles.php @@ -0,0 +1,78 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dlpServiceClient->listColumnDataProfiles($request); + + /** @var ColumnDataProfile $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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + list_column_data_profiles_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_ListColumnDataProfiles_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_connections.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_connections.php new file mode 100644 index 000000000000..31cee6928593 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_connections.php @@ -0,0 +1,77 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dlpServiceClient->listConnections($request); + + /** @var Connection $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 = DlpServiceClient::locationName('[PROJECT]', '[LOCATION]'); + + list_connections_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_ListConnections_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_deidentify_templates.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_deidentify_templates.php new file mode 100644 index 000000000000..e3a467950c3f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_deidentify_templates.php @@ -0,0 +1,98 @@ + + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + */ +function list_deidentify_templates_sample(string $formattedParent): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $request = (new ListDeidentifyTemplatesRequest()) + ->setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dlpServiceClient->listDeidentifyTemplates($request); + + /** @var DeidentifyTemplate $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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + list_deidentify_templates_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_ListDeidentifyTemplates_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_discovery_configs.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_discovery_configs.php new file mode 100644 index 000000000000..accf03e2f512 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_discovery_configs.php @@ -0,0 +1,85 @@ +PROJECT_ID`/locations/`LOCATION_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::locationName()} for help formatting this field. + */ +function list_discovery_configs_sample(string $formattedParent): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $request = (new ListDiscoveryConfigsRequest()) + ->setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dlpServiceClient->listDiscoveryConfigs($request); + + /** @var DiscoveryConfig $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 = DlpServiceClient::locationName('[PROJECT]', '[LOCATION]'); + + list_discovery_configs_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_ListDiscoveryConfigs_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_dlp_jobs.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_dlp_jobs.php new file mode 100644 index 000000000000..43ad531dae5d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_dlp_jobs.php @@ -0,0 +1,96 @@ + + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::projectName()} for help formatting this field. + */ +function list_dlp_jobs_sample(string $formattedParent): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $request = (new ListDlpJobsRequest()) + ->setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dlpServiceClient->listDlpJobs($request); + + /** @var DlpJob $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 = DlpServiceClient::projectName('[PROJECT]'); + + list_dlp_jobs_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_ListDlpJobs_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_info_types.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_info_types.php new file mode 100644 index 000000000000..3ba2a2be6eaf --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_info_types.php @@ -0,0 +1,60 @@ +listInfoTypes($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END dlp_v2_generated_DlpService_ListInfoTypes_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_inspect_templates.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_inspect_templates.php new file mode 100644 index 000000000000..538de701a50b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_inspect_templates.php @@ -0,0 +1,98 @@ + + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + */ +function list_inspect_templates_sample(string $formattedParent): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $request = (new ListInspectTemplatesRequest()) + ->setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dlpServiceClient->listInspectTemplates($request); + + /** @var InspectTemplate $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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + list_inspect_templates_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_ListInspectTemplates_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_job_triggers.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_job_triggers.php new file mode 100644 index 000000000000..6f75c9282169 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_job_triggers.php @@ -0,0 +1,94 @@ + + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::projectName()} for help formatting this field. + */ +function list_job_triggers_sample(string $formattedParent): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $request = (new ListJobTriggersRequest()) + ->setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dlpServiceClient->listJobTriggers($request); + + /** @var JobTrigger $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 = DlpServiceClient::projectName('[PROJECT]'); + + list_job_triggers_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_ListJobTriggers_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_project_data_profiles.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_project_data_profiles.php new file mode 100644 index 000000000000..d5548dedc860 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_project_data_profiles.php @@ -0,0 +1,76 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dlpServiceClient->listProjectDataProfiles($request); + + /** @var ProjectDataProfile $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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + list_project_data_profiles_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_ListProjectDataProfiles_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_stored_info_types.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_stored_info_types.php new file mode 100644 index 000000000000..15de2ce15026 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_stored_info_types.php @@ -0,0 +1,94 @@ + + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. + */ +function list_stored_info_types_sample(string $formattedParent): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $request = (new ListStoredInfoTypesRequest()) + ->setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dlpServiceClient->listStoredInfoTypes($request); + + /** @var StoredInfoType $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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + list_stored_info_types_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_ListStoredInfoTypes_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_table_data_profiles.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_table_data_profiles.php new file mode 100644 index 000000000000..256859c421db --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_table_data_profiles.php @@ -0,0 +1,78 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dlpServiceClient->listTableDataProfiles($request); + + /** @var TableDataProfile $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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + list_table_data_profiles_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_ListTableDataProfiles_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/redact_image.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/redact_image.php new file mode 100644 index 000000000000..e8c3b377d874 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/redact_image.php @@ -0,0 +1,65 @@ +redactImage($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END dlp_v2_generated_DlpService_RedactImage_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/reidentify_content.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/reidentify_content.php new file mode 100644 index 000000000000..005c337558fb --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/reidentify_content.php @@ -0,0 +1,89 @@ + + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * Please see {@see DlpServiceClient::projectName()} for help formatting this field. + */ +function reidentify_content_sample(string $formattedParent): void +{ + // Create a client. + $dlpServiceClient = new DlpServiceClient(); + + // Prepare the request message. + $request = (new ReidentifyContentRequest()) + ->setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var ReidentifyContentResponse $response */ + $response = $dlpServiceClient->reidentifyContent($request); + 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 = DlpServiceClient::projectName('[PROJECT]'); + + reidentify_content_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_ReidentifyContent_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/search_connections.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/search_connections.php new file mode 100644 index 000000000000..8156bf13200e --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/search_connections.php @@ -0,0 +1,77 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dlpServiceClient->searchConnections($request); + + /** @var Connection $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 = DlpServiceClient::locationName('[PROJECT]', '[LOCATION]'); + + search_connections_sample($formattedParent); +} +// [END dlp_v2_generated_DlpService_SearchConnections_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_connection.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_connection.php new file mode 100644 index 000000000000..05f37b598201 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_connection.php @@ -0,0 +1,78 @@ +setState($connectionState); + $request = (new UpdateConnectionRequest()) + ->setName($formattedName) + ->setConnection($connection); + + // Call the API and handle any network failures. + try { + /** @var Connection $response */ + $response = $dlpServiceClient->updateConnection($request); + 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 = DlpServiceClient::connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; + + update_connection_sample($formattedName, $connectionState); +} +// [END dlp_v2_generated_DlpService_UpdateConnection_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_deidentify_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_deidentify_template.php new file mode 100644 index 000000000000..7989fa347c7d --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_deidentify_template.php @@ -0,0 +1,80 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var DeidentifyTemplate $response */ + $response = $dlpServiceClient->updateDeidentifyTemplate($request); + 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 = DlpServiceClient::deidentifyTemplateName( + '[ORGANIZATION]', + '[DEIDENTIFY_TEMPLATE]' + ); + + update_deidentify_template_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_UpdateDeidentifyTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_discovery_config.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_discovery_config.php new file mode 100644 index 000000000000..a815aa24c00b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_discovery_config.php @@ -0,0 +1,82 @@ +setStatus($discoveryConfigStatus); + $request = (new UpdateDiscoveryConfigRequest()) + ->setName($formattedName) + ->setDiscoveryConfig($discoveryConfig); + + // Call the API and handle any network failures. + try { + /** @var DiscoveryConfig $response */ + $response = $dlpServiceClient->updateDiscoveryConfig($request); + 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 = DlpServiceClient::discoveryConfigName( + '[PROJECT]', + '[LOCATION]', + '[DISCOVERY_CONFIG]' + ); + $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; + + update_discovery_config_sample($formattedName, $discoveryConfigStatus); +} +// [END dlp_v2_generated_DlpService_UpdateDiscoveryConfig_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_inspect_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_inspect_template.php new file mode 100644 index 000000000000..530580f344e4 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_inspect_template.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var InspectTemplate $response */ + $response = $dlpServiceClient->updateInspectTemplate($request); + 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 = DlpServiceClient::inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + + update_inspect_template_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_UpdateInspectTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_job_trigger.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_job_trigger.php new file mode 100644 index 000000000000..d8db2492a4d2 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_job_trigger.php @@ -0,0 +1,75 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var JobTrigger $response */ + $response = $dlpServiceClient->updateJobTrigger($request); + 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 = DlpServiceClient::jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + + update_job_trigger_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_UpdateJobTrigger_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_stored_info_type.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_stored_info_type.php new file mode 100644 index 000000000000..c5d29a624887 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_stored_info_type.php @@ -0,0 +1,77 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var StoredInfoType $response */ + $response = $dlpServiceClient->updateStoredInfoType($request); + 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 = DlpServiceClient::storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + + update_stored_info_type_sample($formattedName); +} +// [END dlp_v2_generated_DlpService_UpdateStoredInfoType_sync] diff --git a/owl-bot-staging/Dlp/v2/src/V2/Client/DlpServiceClient.php b/owl-bot-staging/Dlp/v2/src/V2/Client/DlpServiceClient.php new file mode 100644 index 000000000000..08f750231f74 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/src/V2/Client/DlpServiceClient.php @@ -0,0 +1,2469 @@ + self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/dlp_service_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/dlp_service_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/dlp_service_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/dlp_service_rest_client_config.php', + ], + ], + ]; + } + + /** + * Formats a string containing the fully-qualified path to represent a + * column_data_profile resource. + * + * @param string $organization + * @param string $location + * @param string $columnDataProfile + * + * @return string The formatted column_data_profile resource. + */ + public static function columnDataProfileName(string $organization, string $location, string $columnDataProfile): string + { + return self::getPathTemplate('columnDataProfile')->render([ + 'organization' => $organization, + 'location' => $location, + 'column_data_profile' => $columnDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a connection + * resource. + * + * @param string $project + * @param string $location + * @param string $connection + * + * @return string The formatted connection resource. + */ + public static function connectionName(string $project, string $location, string $connection): string + { + return self::getPathTemplate('connection')->render([ + 'project' => $project, + 'location' => $location, + 'connection' => $connection, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * deidentify_template resource. + * + * @param string $organization + * @param string $deidentifyTemplate + * + * @return string The formatted deidentify_template resource. + */ + public static function deidentifyTemplateName(string $organization, string $deidentifyTemplate): string + { + return self::getPathTemplate('deidentifyTemplate')->render([ + 'organization' => $organization, + 'deidentify_template' => $deidentifyTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * discovery_config resource. + * + * @param string $project + * @param string $location + * @param string $discoveryConfig + * + * @return string The formatted discovery_config resource. + */ + public static function discoveryConfigName(string $project, string $location, string $discoveryConfig): string + { + return self::getPathTemplate('discoveryConfig')->render([ + 'project' => $project, + 'location' => $location, + 'discovery_config' => $discoveryConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a dlp_job + * resource. + * + * @param string $project + * @param string $dlpJob + * + * @return string The formatted dlp_job resource. + */ + public static function dlpJobName(string $project, string $dlpJob): string + { + return self::getPathTemplate('dlpJob')->render([ + 'project' => $project, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * inspect_template resource. + * + * @param string $organization + * @param string $inspectTemplate + * + * @return string The formatted inspect_template resource. + */ + public static function inspectTemplateName(string $organization, string $inspectTemplate): string + { + return self::getPathTemplate('inspectTemplate')->render([ + 'organization' => $organization, + 'inspect_template' => $inspectTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a job_trigger + * resource. + * + * @param string $project + * @param string $jobTrigger + * + * @return string The formatted job_trigger resource. + */ + public static function jobTriggerName(string $project, string $jobTrigger): string + { + return self::getPathTemplate('jobTrigger')->render([ + 'project' => $project, + 'job_trigger' => $jobTrigger, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a location + * resource. + * + * @param string $project + * @param string $location + * + * @return string The formatted location resource. + */ + public static function locationName(string $project, string $location): string + { + return self::getPathTemplate('location')->render([ + 'project' => $project, + 'location' => $location, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a organization + * resource. + * + * @param string $organization + * + * @return string The formatted organization resource. + */ + public static function organizationName(string $organization): string + { + return self::getPathTemplate('organization')->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_deidentify_template resource. + * + * @param string $organization + * @param string $deidentifyTemplate + * + * @return string The formatted organization_deidentify_template resource. + */ + public static function organizationDeidentifyTemplateName(string $organization, string $deidentifyTemplate): string + { + return self::getPathTemplate('organizationDeidentifyTemplate')->render([ + 'organization' => $organization, + 'deidentify_template' => $deidentifyTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_inspect_template resource. + * + * @param string $organization + * @param string $inspectTemplate + * + * @return string The formatted organization_inspect_template resource. + */ + public static function organizationInspectTemplateName(string $organization, string $inspectTemplate): string + { + return self::getPathTemplate('organizationInspectTemplate')->render([ + 'organization' => $organization, + 'inspect_template' => $inspectTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location resource. + * + * @param string $organization + * @param string $location + * + * @return string The formatted organization_location resource. + */ + public static function organizationLocationName(string $organization, string $location): string + { + return self::getPathTemplate('organizationLocation')->render([ + 'organization' => $organization, + 'location' => $location, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_column_data_profile resource. + * + * @param string $organization + * @param string $location + * @param string $columnDataProfile + * + * @return string The formatted organization_location_column_data_profile resource. + */ + public static function organizationLocationColumnDataProfileName(string $organization, string $location, string $columnDataProfile): string + { + return self::getPathTemplate('organizationLocationColumnDataProfile')->render([ + 'organization' => $organization, + 'location' => $location, + 'column_data_profile' => $columnDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_deidentify_template resource. + * + * @param string $organization + * @param string $location + * @param string $deidentifyTemplate + * + * @return string The formatted organization_location_deidentify_template resource. + */ + public static function organizationLocationDeidentifyTemplateName(string $organization, string $location, string $deidentifyTemplate): string + { + return self::getPathTemplate('organizationLocationDeidentifyTemplate')->render([ + 'organization' => $organization, + 'location' => $location, + 'deidentify_template' => $deidentifyTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_inspect_template resource. + * + * @param string $organization + * @param string $location + * @param string $inspectTemplate + * + * @return string The formatted organization_location_inspect_template resource. + */ + public static function organizationLocationInspectTemplateName(string $organization, string $location, string $inspectTemplate): string + { + return self::getPathTemplate('organizationLocationInspectTemplate')->render([ + 'organization' => $organization, + 'location' => $location, + 'inspect_template' => $inspectTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_project_data_profile resource. + * + * @param string $organization + * @param string $location + * @param string $projectDataProfile + * + * @return string The formatted organization_location_project_data_profile resource. + */ + public static function organizationLocationProjectDataProfileName(string $organization, string $location, string $projectDataProfile): string + { + return self::getPathTemplate('organizationLocationProjectDataProfile')->render([ + 'organization' => $organization, + 'location' => $location, + 'project_data_profile' => $projectDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_stored_info_type resource. + * + * @param string $organization + * @param string $location + * @param string $storedInfoType + * + * @return string The formatted organization_location_stored_info_type resource. + */ + public static function organizationLocationStoredInfoTypeName(string $organization, string $location, string $storedInfoType): string + { + return self::getPathTemplate('organizationLocationStoredInfoType')->render([ + 'organization' => $organization, + 'location' => $location, + 'stored_info_type' => $storedInfoType, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_table_data_profile resource. + * + * @param string $organization + * @param string $location + * @param string $tableDataProfile + * + * @return string The formatted organization_location_table_data_profile resource. + */ + public static function organizationLocationTableDataProfileName(string $organization, string $location, string $tableDataProfile): string + { + return self::getPathTemplate('organizationLocationTableDataProfile')->render([ + 'organization' => $organization, + 'location' => $location, + 'table_data_profile' => $tableDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_stored_info_type resource. + * + * @param string $organization + * @param string $storedInfoType + * + * @return string The formatted organization_stored_info_type resource. + */ + public static function organizationStoredInfoTypeName(string $organization, string $storedInfoType): string + { + return self::getPathTemplate('organizationStoredInfoType')->render([ + 'organization' => $organization, + 'stored_info_type' => $storedInfoType, + ]); + } + + /** + * 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(string $project): string + { + return self::getPathTemplate('project')->render([ + 'project' => $project, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_data_profile resource. + * + * @param string $organization + * @param string $location + * @param string $projectDataProfile + * + * @return string The formatted project_data_profile resource. + */ + public static function projectDataProfileName(string $organization, string $location, string $projectDataProfile): string + { + return self::getPathTemplate('projectDataProfile')->render([ + 'organization' => $organization, + 'location' => $location, + 'project_data_profile' => $projectDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_deidentify_template resource. + * + * @param string $project + * @param string $deidentifyTemplate + * + * @return string The formatted project_deidentify_template resource. + */ + public static function projectDeidentifyTemplateName(string $project, string $deidentifyTemplate): string + { + return self::getPathTemplate('projectDeidentifyTemplate')->render([ + 'project' => $project, + 'deidentify_template' => $deidentifyTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_dlp_job resource. + * + * @param string $project + * @param string $dlpJob + * + * @return string The formatted project_dlp_job resource. + */ + public static function projectDlpJobName(string $project, string $dlpJob): string + { + return self::getPathTemplate('projectDlpJob')->render([ + 'project' => $project, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_inspect_template resource. + * + * @param string $project + * @param string $inspectTemplate + * + * @return string The formatted project_inspect_template resource. + */ + public static function projectInspectTemplateName(string $project, string $inspectTemplate): string + { + return self::getPathTemplate('projectInspectTemplate')->render([ + 'project' => $project, + 'inspect_template' => $inspectTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_job_trigger resource. + * + * @param string $project + * @param string $jobTrigger + * + * @return string The formatted project_job_trigger resource. + */ + public static function projectJobTriggerName(string $project, string $jobTrigger): string + { + return self::getPathTemplate('projectJobTrigger')->render([ + 'project' => $project, + 'job_trigger' => $jobTrigger, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_column_data_profile resource. + * + * @param string $project + * @param string $location + * @param string $columnDataProfile + * + * @return string The formatted project_location_column_data_profile resource. + */ + public static function projectLocationColumnDataProfileName(string $project, string $location, string $columnDataProfile): string + { + return self::getPathTemplate('projectLocationColumnDataProfile')->render([ + 'project' => $project, + 'location' => $location, + 'column_data_profile' => $columnDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_deidentify_template resource. + * + * @param string $project + * @param string $location + * @param string $deidentifyTemplate + * + * @return string The formatted project_location_deidentify_template resource. + */ + public static function projectLocationDeidentifyTemplateName(string $project, string $location, string $deidentifyTemplate): string + { + return self::getPathTemplate('projectLocationDeidentifyTemplate')->render([ + 'project' => $project, + 'location' => $location, + 'deidentify_template' => $deidentifyTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_dlp_job resource. + * + * @param string $project + * @param string $location + * @param string $dlpJob + * + * @return string The formatted project_location_dlp_job resource. + */ + public static function projectLocationDlpJobName(string $project, string $location, string $dlpJob): string + { + return self::getPathTemplate('projectLocationDlpJob')->render([ + 'project' => $project, + 'location' => $location, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_inspect_template resource. + * + * @param string $project + * @param string $location + * @param string $inspectTemplate + * + * @return string The formatted project_location_inspect_template resource. + */ + public static function projectLocationInspectTemplateName(string $project, string $location, string $inspectTemplate): string + { + return self::getPathTemplate('projectLocationInspectTemplate')->render([ + 'project' => $project, + 'location' => $location, + 'inspect_template' => $inspectTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_job_trigger resource. + * + * @param string $project + * @param string $location + * @param string $jobTrigger + * + * @return string The formatted project_location_job_trigger resource. + */ + public static function projectLocationJobTriggerName(string $project, string $location, string $jobTrigger): string + { + return self::getPathTemplate('projectLocationJobTrigger')->render([ + 'project' => $project, + 'location' => $location, + 'job_trigger' => $jobTrigger, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_project_data_profile resource. + * + * @param string $project + * @param string $location + * @param string $projectDataProfile + * + * @return string The formatted project_location_project_data_profile resource. + */ + public static function projectLocationProjectDataProfileName(string $project, string $location, string $projectDataProfile): string + { + return self::getPathTemplate('projectLocationProjectDataProfile')->render([ + 'project' => $project, + 'location' => $location, + 'project_data_profile' => $projectDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_stored_info_type resource. + * + * @param string $project + * @param string $location + * @param string $storedInfoType + * + * @return string The formatted project_location_stored_info_type resource. + */ + public static function projectLocationStoredInfoTypeName(string $project, string $location, string $storedInfoType): string + { + return self::getPathTemplate('projectLocationStoredInfoType')->render([ + 'project' => $project, + 'location' => $location, + 'stored_info_type' => $storedInfoType, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_table_data_profile resource. + * + * @param string $project + * @param string $location + * @param string $tableDataProfile + * + * @return string The formatted project_location_table_data_profile resource. + */ + public static function projectLocationTableDataProfileName(string $project, string $location, string $tableDataProfile): string + { + return self::getPathTemplate('projectLocationTableDataProfile')->render([ + 'project' => $project, + 'location' => $location, + 'table_data_profile' => $tableDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_stored_info_type resource. + * + * @param string $project + * @param string $storedInfoType + * + * @return string The formatted project_stored_info_type resource. + */ + public static function projectStoredInfoTypeName(string $project, string $storedInfoType): string + { + return self::getPathTemplate('projectStoredInfoType')->render([ + 'project' => $project, + 'stored_info_type' => $storedInfoType, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * stored_info_type resource. + * + * @param string $organization + * @param string $storedInfoType + * + * @return string The formatted stored_info_type resource. + */ + public static function storedInfoTypeName(string $organization, string $storedInfoType): string + { + return self::getPathTemplate('storedInfoType')->render([ + 'organization' => $organization, + 'stored_info_type' => $storedInfoType, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * table_data_profile resource. + * + * @param string $organization + * @param string $location + * @param string $tableDataProfile + * + * @return string The formatted table_data_profile resource. + */ + public static function tableDataProfileName(string $organization, string $location, string $tableDataProfile): string + { + return self::getPathTemplate('tableDataProfile')->render([ + 'organization' => $organization, + 'location' => $location, + 'table_data_profile' => $tableDataProfile, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - columnDataProfile: organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile} + * - connection: projects/{project}/locations/{location}/connections/{connection} + * - deidentifyTemplate: organizations/{organization}/deidentifyTemplates/{deidentify_template} + * - discoveryConfig: projects/{project}/locations/{location}/discoveryConfigs/{discovery_config} + * - dlpJob: projects/{project}/dlpJobs/{dlp_job} + * - inspectTemplate: organizations/{organization}/inspectTemplates/{inspect_template} + * - jobTrigger: projects/{project}/jobTriggers/{job_trigger} + * - location: projects/{project}/locations/{location} + * - organization: organizations/{organization} + * - organizationDeidentifyTemplate: organizations/{organization}/deidentifyTemplates/{deidentify_template} + * - organizationInspectTemplate: organizations/{organization}/inspectTemplates/{inspect_template} + * - organizationLocation: organizations/{organization}/locations/{location} + * - organizationLocationColumnDataProfile: organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile} + * - organizationLocationDeidentifyTemplate: organizations/{organization}/locations/{location}/deidentifyTemplates/{deidentify_template} + * - organizationLocationInspectTemplate: organizations/{organization}/locations/{location}/inspectTemplates/{inspect_template} + * - organizationLocationProjectDataProfile: organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile} + * - organizationLocationStoredInfoType: organizations/{organization}/locations/{location}/storedInfoTypes/{stored_info_type} + * - organizationLocationTableDataProfile: organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile} + * - organizationStoredInfoType: organizations/{organization}/storedInfoTypes/{stored_info_type} + * - project: projects/{project} + * - projectDataProfile: organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile} + * - projectDeidentifyTemplate: projects/{project}/deidentifyTemplates/{deidentify_template} + * - projectDlpJob: projects/{project}/dlpJobs/{dlp_job} + * - projectInspectTemplate: projects/{project}/inspectTemplates/{inspect_template} + * - projectJobTrigger: projects/{project}/jobTriggers/{job_trigger} + * - projectLocationColumnDataProfile: projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile} + * - projectLocationDeidentifyTemplate: projects/{project}/locations/{location}/deidentifyTemplates/{deidentify_template} + * - projectLocationDlpJob: projects/{project}/locations/{location}/dlpJobs/{dlp_job} + * - projectLocationInspectTemplate: projects/{project}/locations/{location}/inspectTemplates/{inspect_template} + * - projectLocationJobTrigger: projects/{project}/locations/{location}/jobTriggers/{job_trigger} + * - projectLocationProjectDataProfile: projects/{project}/locations/{location}/projectDataProfiles/{project_data_profile} + * - projectLocationStoredInfoType: projects/{project}/locations/{location}/storedInfoTypes/{stored_info_type} + * - projectLocationTableDataProfile: projects/{project}/locations/{location}/tableDataProfiles/{table_data_profile} + * - projectStoredInfoType: projects/{project}/storedInfoTypes/{stored_info_type} + * - storedInfoType: organizations/{organization}/storedInfoTypes/{stored_info_type} + * - tableDataProfile: organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile} + * + * 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(string $formattedName, string $template = null): array + { + return self::parseFormattedName($formattedName, $template); + } + + /** + * 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 'dlp.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); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Activate a job trigger. Causes the immediate execute of a trigger + * instead of waiting on the trigger event to occur. + * + * The async variant is {@see DlpServiceClient::activateJobTriggerAsync()} . + * + * @example samples/V2/DlpServiceClient/activate_job_trigger.php + * + * @param ActivateJobTriggerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DlpJob + * + * @throws ApiException Thrown if the API call fails. + */ + public function activateJobTrigger(ActivateJobTriggerRequest $request, array $callOptions = []): DlpJob + { + return $this->startApiCall('ActivateJobTrigger', $request, $callOptions)->wait(); + } + + /** + * Starts asynchronous cancellation on a long-running DlpJob. The server + * makes a best effort to cancel the DlpJob, but success is not + * guaranteed. + * See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage + * and + * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis + * to learn more. + * + * The async variant is {@see DlpServiceClient::cancelDlpJobAsync()} . + * + * @example samples/V2/DlpServiceClient/cancel_dlp_job.php + * + * @param CancelDlpJobRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Thrown if the API call fails. + */ + public function cancelDlpJob(CancelDlpJobRequest $request, array $callOptions = []): void + { + $this->startApiCall('CancelDlpJob', $request, $callOptions)->wait(); + } + + /** + * Create a Connection to an external data source. + * + * The async variant is {@see DlpServiceClient::createConnectionAsync()} . + * + * @example samples/V2/DlpServiceClient/create_connection.php + * + * @param CreateConnectionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Connection + * + * @throws ApiException Thrown if the API call fails. + */ + public function createConnection(CreateConnectionRequest $request, array $callOptions = []): Connection + { + return $this->startApiCall('CreateConnection', $request, $callOptions)->wait(); + } + + /** + * Creates a DeidentifyTemplate for reusing frequently used configuration + * for de-identifying content, images, and storage. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid + * to learn more. + * + * The async variant is {@see DlpServiceClient::createDeidentifyTemplateAsync()} . + * + * @example samples/V2/DlpServiceClient/create_deidentify_template.php + * + * @param CreateDeidentifyTemplateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DeidentifyTemplate + * + * @throws ApiException Thrown if the API call fails. + */ + public function createDeidentifyTemplate(CreateDeidentifyTemplateRequest $request, array $callOptions = []): DeidentifyTemplate + { + return $this->startApiCall('CreateDeidentifyTemplate', $request, $callOptions)->wait(); + } + + /** + * Creates a config for discovery to scan and profile storage. + * + * The async variant is {@see DlpServiceClient::createDiscoveryConfigAsync()} . + * + * @example samples/V2/DlpServiceClient/create_discovery_config.php + * + * @param CreateDiscoveryConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DiscoveryConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function createDiscoveryConfig(CreateDiscoveryConfigRequest $request, array $callOptions = []): DiscoveryConfig + { + return $this->startApiCall('CreateDiscoveryConfig', $request, $callOptions)->wait(); + } + + /** + * Creates a new job to inspect storage or calculate risk metrics. + * See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage + * and + * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis + * to learn more. + * + * When no InfoTypes or CustomInfoTypes are specified in inspect jobs, the + * system will automatically choose what detectors to run. By default this may + * be all types, but may change over time as detectors are updated. + * + * The async variant is {@see DlpServiceClient::createDlpJobAsync()} . + * + * @example samples/V2/DlpServiceClient/create_dlp_job.php + * + * @param CreateDlpJobRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DlpJob + * + * @throws ApiException Thrown if the API call fails. + */ + public function createDlpJob(CreateDlpJobRequest $request, array $callOptions = []): DlpJob + { + return $this->startApiCall('CreateDlpJob', $request, $callOptions)->wait(); + } + + /** + * Creates an InspectTemplate for reusing frequently used configuration + * for inspecting content, images, and storage. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates + * to learn more. + * + * The async variant is {@see DlpServiceClient::createInspectTemplateAsync()} . + * + * @example samples/V2/DlpServiceClient/create_inspect_template.php + * + * @param CreateInspectTemplateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 InspectTemplate + * + * @throws ApiException Thrown if the API call fails. + */ + public function createInspectTemplate(CreateInspectTemplateRequest $request, array $callOptions = []): InspectTemplate + { + return $this->startApiCall('CreateInspectTemplate', $request, $callOptions)->wait(); + } + + /** + * Creates a job trigger to run DLP actions such as scanning storage for + * sensitive information on a set schedule. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers + * to learn more. + * + * The async variant is {@see DlpServiceClient::createJobTriggerAsync()} . + * + * @example samples/V2/DlpServiceClient/create_job_trigger.php + * + * @param CreateJobTriggerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 JobTrigger + * + * @throws ApiException Thrown if the API call fails. + */ + public function createJobTrigger(CreateJobTriggerRequest $request, array $callOptions = []): JobTrigger + { + return $this->startApiCall('CreateJobTrigger', $request, $callOptions)->wait(); + } + + /** + * Creates a pre-built stored infoType to be used for inspection. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes + * to learn more. + * + * The async variant is {@see DlpServiceClient::createStoredInfoTypeAsync()} . + * + * @example samples/V2/DlpServiceClient/create_stored_info_type.php + * + * @param CreateStoredInfoTypeRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 StoredInfoType + * + * @throws ApiException Thrown if the API call fails. + */ + public function createStoredInfoType(CreateStoredInfoTypeRequest $request, array $callOptions = []): StoredInfoType + { + return $this->startApiCall('CreateStoredInfoType', $request, $callOptions)->wait(); + } + + /** + * De-identifies potentially sensitive info from a ContentItem. + * This method has limits on input size and output size. + * See + * https://cloud.google.com/sensitive-data-protection/docs/deidentify-sensitive-data + * to learn more. + * + * When no InfoTypes or CustomInfoTypes are specified in this request, the + * system will automatically choose what detectors to run. By default this may + * be all types, but may change over time as detectors are updated. + * + * The async variant is {@see DlpServiceClient::deidentifyContentAsync()} . + * + * @example samples/V2/DlpServiceClient/deidentify_content.php + * + * @param DeidentifyContentRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DeidentifyContentResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deidentifyContent(DeidentifyContentRequest $request, array $callOptions = []): DeidentifyContentResponse + { + return $this->startApiCall('DeidentifyContent', $request, $callOptions)->wait(); + } + + /** + * Delete a Connection. + * + * The async variant is {@see DlpServiceClient::deleteConnectionAsync()} . + * + * @example samples/V2/DlpServiceClient/delete_connection.php + * + * @param DeleteConnectionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Thrown if the API call fails. + */ + public function deleteConnection(DeleteConnectionRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteConnection', $request, $callOptions)->wait(); + } + + /** + * Deletes a DeidentifyTemplate. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid + * to learn more. + * + * The async variant is {@see DlpServiceClient::deleteDeidentifyTemplateAsync()} . + * + * @example samples/V2/DlpServiceClient/delete_deidentify_template.php + * + * @param DeleteDeidentifyTemplateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Thrown if the API call fails. + */ + public function deleteDeidentifyTemplate(DeleteDeidentifyTemplateRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteDeidentifyTemplate', $request, $callOptions)->wait(); + } + + /** + * Deletes a discovery configuration. + * + * The async variant is {@see DlpServiceClient::deleteDiscoveryConfigAsync()} . + * + * @example samples/V2/DlpServiceClient/delete_discovery_config.php + * + * @param DeleteDiscoveryConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Thrown if the API call fails. + */ + public function deleteDiscoveryConfig(DeleteDiscoveryConfigRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteDiscoveryConfig', $request, $callOptions)->wait(); + } + + /** + * Deletes a long-running DlpJob. This method indicates that the client is + * no longer interested in the DlpJob result. The job will be canceled if + * possible. + * See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage + * and + * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis + * to learn more. + * + * The async variant is {@see DlpServiceClient::deleteDlpJobAsync()} . + * + * @example samples/V2/DlpServiceClient/delete_dlp_job.php + * + * @param DeleteDlpJobRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Thrown if the API call fails. + */ + public function deleteDlpJob(DeleteDlpJobRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteDlpJob', $request, $callOptions)->wait(); + } + + /** + * Deletes an InspectTemplate. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates + * to learn more. + * + * The async variant is {@see DlpServiceClient::deleteInspectTemplateAsync()} . + * + * @example samples/V2/DlpServiceClient/delete_inspect_template.php + * + * @param DeleteInspectTemplateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Thrown if the API call fails. + */ + public function deleteInspectTemplate(DeleteInspectTemplateRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteInspectTemplate', $request, $callOptions)->wait(); + } + + /** + * Deletes a job trigger. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers + * to learn more. + * + * The async variant is {@see DlpServiceClient::deleteJobTriggerAsync()} . + * + * @example samples/V2/DlpServiceClient/delete_job_trigger.php + * + * @param DeleteJobTriggerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Thrown if the API call fails. + */ + public function deleteJobTrigger(DeleteJobTriggerRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteJobTrigger', $request, $callOptions)->wait(); + } + + /** + * Deletes a stored infoType. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes + * to learn more. + * + * The async variant is {@see DlpServiceClient::deleteStoredInfoTypeAsync()} . + * + * @example samples/V2/DlpServiceClient/delete_stored_info_type.php + * + * @param DeleteStoredInfoTypeRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Thrown if the API call fails. + */ + public function deleteStoredInfoType(DeleteStoredInfoTypeRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteStoredInfoType', $request, $callOptions)->wait(); + } + + /** + * Delete a TableDataProfile. Will not prevent the profile from being + * regenerated if the table is still included in a discovery configuration. + * + * The async variant is {@see DlpServiceClient::deleteTableDataProfileAsync()} . + * + * @example samples/V2/DlpServiceClient/delete_table_data_profile.php + * + * @param DeleteTableDataProfileRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Thrown if the API call fails. + */ + public function deleteTableDataProfile(DeleteTableDataProfileRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteTableDataProfile', $request, $callOptions)->wait(); + } + + /** + * Finish a running hybrid DlpJob. Triggers the finalization steps and running + * of any enabled actions that have not yet run. + * + * The async variant is {@see DlpServiceClient::finishDlpJobAsync()} . + * + * @example samples/V2/DlpServiceClient/finish_dlp_job.php + * + * @param FinishDlpJobRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Thrown if the API call fails. + */ + public function finishDlpJob(FinishDlpJobRequest $request, array $callOptions = []): void + { + $this->startApiCall('FinishDlpJob', $request, $callOptions)->wait(); + } + + /** + * Gets a column data profile. + * + * The async variant is {@see DlpServiceClient::getColumnDataProfileAsync()} . + * + * @example samples/V2/DlpServiceClient/get_column_data_profile.php + * + * @param GetColumnDataProfileRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 ColumnDataProfile + * + * @throws ApiException Thrown if the API call fails. + */ + public function getColumnDataProfile(GetColumnDataProfileRequest $request, array $callOptions = []): ColumnDataProfile + { + return $this->startApiCall('GetColumnDataProfile', $request, $callOptions)->wait(); + } + + /** + * Get a Connection by name. + * + * The async variant is {@see DlpServiceClient::getConnectionAsync()} . + * + * @example samples/V2/DlpServiceClient/get_connection.php + * + * @param GetConnectionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Connection + * + * @throws ApiException Thrown if the API call fails. + */ + public function getConnection(GetConnectionRequest $request, array $callOptions = []): Connection + { + return $this->startApiCall('GetConnection', $request, $callOptions)->wait(); + } + + /** + * Gets a DeidentifyTemplate. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid + * to learn more. + * + * The async variant is {@see DlpServiceClient::getDeidentifyTemplateAsync()} . + * + * @example samples/V2/DlpServiceClient/get_deidentify_template.php + * + * @param GetDeidentifyTemplateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DeidentifyTemplate + * + * @throws ApiException Thrown if the API call fails. + */ + public function getDeidentifyTemplate(GetDeidentifyTemplateRequest $request, array $callOptions = []): DeidentifyTemplate + { + return $this->startApiCall('GetDeidentifyTemplate', $request, $callOptions)->wait(); + } + + /** + * Gets a discovery configuration. + * + * The async variant is {@see DlpServiceClient::getDiscoveryConfigAsync()} . + * + * @example samples/V2/DlpServiceClient/get_discovery_config.php + * + * @param GetDiscoveryConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DiscoveryConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function getDiscoveryConfig(GetDiscoveryConfigRequest $request, array $callOptions = []): DiscoveryConfig + { + return $this->startApiCall('GetDiscoveryConfig', $request, $callOptions)->wait(); + } + + /** + * Gets the latest state of a long-running DlpJob. + * See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage + * and + * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis + * to learn more. + * + * The async variant is {@see DlpServiceClient::getDlpJobAsync()} . + * + * @example samples/V2/DlpServiceClient/get_dlp_job.php + * + * @param GetDlpJobRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DlpJob + * + * @throws ApiException Thrown if the API call fails. + */ + public function getDlpJob(GetDlpJobRequest $request, array $callOptions = []): DlpJob + { + return $this->startApiCall('GetDlpJob', $request, $callOptions)->wait(); + } + + /** + * Gets an InspectTemplate. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates + * to learn more. + * + * The async variant is {@see DlpServiceClient::getInspectTemplateAsync()} . + * + * @example samples/V2/DlpServiceClient/get_inspect_template.php + * + * @param GetInspectTemplateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 InspectTemplate + * + * @throws ApiException Thrown if the API call fails. + */ + public function getInspectTemplate(GetInspectTemplateRequest $request, array $callOptions = []): InspectTemplate + { + return $this->startApiCall('GetInspectTemplate', $request, $callOptions)->wait(); + } + + /** + * Gets a job trigger. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers + * to learn more. + * + * The async variant is {@see DlpServiceClient::getJobTriggerAsync()} . + * + * @example samples/V2/DlpServiceClient/get_job_trigger.php + * + * @param GetJobTriggerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 JobTrigger + * + * @throws ApiException Thrown if the API call fails. + */ + public function getJobTrigger(GetJobTriggerRequest $request, array $callOptions = []): JobTrigger + { + return $this->startApiCall('GetJobTrigger', $request, $callOptions)->wait(); + } + + /** + * Gets a project data profile. + * + * The async variant is {@see DlpServiceClient::getProjectDataProfileAsync()} . + * + * @example samples/V2/DlpServiceClient/get_project_data_profile.php + * + * @param GetProjectDataProfileRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 ProjectDataProfile + * + * @throws ApiException Thrown if the API call fails. + */ + public function getProjectDataProfile(GetProjectDataProfileRequest $request, array $callOptions = []): ProjectDataProfile + { + return $this->startApiCall('GetProjectDataProfile', $request, $callOptions)->wait(); + } + + /** + * Gets a stored infoType. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes + * to learn more. + * + * The async variant is {@see DlpServiceClient::getStoredInfoTypeAsync()} . + * + * @example samples/V2/DlpServiceClient/get_stored_info_type.php + * + * @param GetStoredInfoTypeRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 StoredInfoType + * + * @throws ApiException Thrown if the API call fails. + */ + public function getStoredInfoType(GetStoredInfoTypeRequest $request, array $callOptions = []): StoredInfoType + { + return $this->startApiCall('GetStoredInfoType', $request, $callOptions)->wait(); + } + + /** + * Gets a table data profile. + * + * The async variant is {@see DlpServiceClient::getTableDataProfileAsync()} . + * + * @example samples/V2/DlpServiceClient/get_table_data_profile.php + * + * @param GetTableDataProfileRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 TableDataProfile + * + * @throws ApiException Thrown if the API call fails. + */ + public function getTableDataProfile(GetTableDataProfileRequest $request, array $callOptions = []): TableDataProfile + { + return $this->startApiCall('GetTableDataProfile', $request, $callOptions)->wait(); + } + + /** + * Inspect hybrid content and store findings to a job. + * To review the findings, inspect the job. Inspection will occur + * asynchronously. + * + * The async variant is {@see DlpServiceClient::hybridInspectDlpJobAsync()} . + * + * @example samples/V2/DlpServiceClient/hybrid_inspect_dlp_job.php + * + * @param HybridInspectDlpJobRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 HybridInspectResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function hybridInspectDlpJob(HybridInspectDlpJobRequest $request, array $callOptions = []): HybridInspectResponse + { + return $this->startApiCall('HybridInspectDlpJob', $request, $callOptions)->wait(); + } + + /** + * Inspect hybrid content and store findings to a trigger. The inspection + * will be processed asynchronously. To review the findings monitor the + * jobs within the trigger. + * + * The async variant is {@see DlpServiceClient::hybridInspectJobTriggerAsync()} . + * + * @example samples/V2/DlpServiceClient/hybrid_inspect_job_trigger.php + * + * @param HybridInspectJobTriggerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 HybridInspectResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function hybridInspectJobTrigger(HybridInspectJobTriggerRequest $request, array $callOptions = []): HybridInspectResponse + { + return $this->startApiCall('HybridInspectJobTrigger', $request, $callOptions)->wait(); + } + + /** + * Finds potentially sensitive info in content. + * This method has limits on input size, processing time, and output size. + * + * When no InfoTypes or CustomInfoTypes are specified in this request, the + * system will automatically choose what detectors to run. By default this may + * be all types, but may change over time as detectors are updated. + * + * For how to guides, see + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-images + * and + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-text, + * + * The async variant is {@see DlpServiceClient::inspectContentAsync()} . + * + * @example samples/V2/DlpServiceClient/inspect_content.php + * + * @param InspectContentRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 InspectContentResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function inspectContent(InspectContentRequest $request, array $callOptions = []): InspectContentResponse + { + return $this->startApiCall('InspectContent', $request, $callOptions)->wait(); + } + + /** + * Lists column data profiles for an organization. + * + * The async variant is {@see DlpServiceClient::listColumnDataProfilesAsync()} . + * + * @example samples/V2/DlpServiceClient/list_column_data_profiles.php + * + * @param ListColumnDataProfilesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listColumnDataProfiles(ListColumnDataProfilesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListColumnDataProfiles', $request, $callOptions); + } + + /** + * Lists Connections in a parent. + * + * The async variant is {@see DlpServiceClient::listConnectionsAsync()} . + * + * @example samples/V2/DlpServiceClient/list_connections.php + * + * @param ListConnectionsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listConnections(ListConnectionsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListConnections', $request, $callOptions); + } + + /** + * Lists DeidentifyTemplates. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid + * to learn more. + * + * The async variant is {@see DlpServiceClient::listDeidentifyTemplatesAsync()} . + * + * @example samples/V2/DlpServiceClient/list_deidentify_templates.php + * + * @param ListDeidentifyTemplatesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listDeidentifyTemplates(ListDeidentifyTemplatesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListDeidentifyTemplates', $request, $callOptions); + } + + /** + * Lists discovery configurations. + * + * The async variant is {@see DlpServiceClient::listDiscoveryConfigsAsync()} . + * + * @example samples/V2/DlpServiceClient/list_discovery_configs.php + * + * @param ListDiscoveryConfigsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listDiscoveryConfigs(ListDiscoveryConfigsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListDiscoveryConfigs', $request, $callOptions); + } + + /** + * Lists DlpJobs that match the specified filter in the request. + * See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage + * and + * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis + * to learn more. + * + * The async variant is {@see DlpServiceClient::listDlpJobsAsync()} . + * + * @example samples/V2/DlpServiceClient/list_dlp_jobs.php + * + * @param ListDlpJobsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listDlpJobs(ListDlpJobsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListDlpJobs', $request, $callOptions); + } + + /** + * Returns a list of the sensitive information types that DLP API + * supports. See + * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference + * to learn more. + * + * The async variant is {@see DlpServiceClient::listInfoTypesAsync()} . + * + * @example samples/V2/DlpServiceClient/list_info_types.php + * + * @param ListInfoTypesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 ListInfoTypesResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listInfoTypes(ListInfoTypesRequest $request, array $callOptions = []): ListInfoTypesResponse + { + return $this->startApiCall('ListInfoTypes', $request, $callOptions)->wait(); + } + + /** + * Lists InspectTemplates. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates + * to learn more. + * + * The async variant is {@see DlpServiceClient::listInspectTemplatesAsync()} . + * + * @example samples/V2/DlpServiceClient/list_inspect_templates.php + * + * @param ListInspectTemplatesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listInspectTemplates(ListInspectTemplatesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListInspectTemplates', $request, $callOptions); + } + + /** + * Lists job triggers. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers + * to learn more. + * + * The async variant is {@see DlpServiceClient::listJobTriggersAsync()} . + * + * @example samples/V2/DlpServiceClient/list_job_triggers.php + * + * @param ListJobTriggersRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listJobTriggers(ListJobTriggersRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListJobTriggers', $request, $callOptions); + } + + /** + * Lists project data profiles for an organization. + * + * The async variant is {@see DlpServiceClient::listProjectDataProfilesAsync()} . + * + * @example samples/V2/DlpServiceClient/list_project_data_profiles.php + * + * @param ListProjectDataProfilesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listProjectDataProfiles(ListProjectDataProfilesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListProjectDataProfiles', $request, $callOptions); + } + + /** + * Lists stored infoTypes. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes + * to learn more. + * + * The async variant is {@see DlpServiceClient::listStoredInfoTypesAsync()} . + * + * @example samples/V2/DlpServiceClient/list_stored_info_types.php + * + * @param ListStoredInfoTypesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listStoredInfoTypes(ListStoredInfoTypesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListStoredInfoTypes', $request, $callOptions); + } + + /** + * Lists table data profiles for an organization. + * + * The async variant is {@see DlpServiceClient::listTableDataProfilesAsync()} . + * + * @example samples/V2/DlpServiceClient/list_table_data_profiles.php + * + * @param ListTableDataProfilesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listTableDataProfiles(ListTableDataProfilesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListTableDataProfiles', $request, $callOptions); + } + + /** + * Redacts potentially sensitive info from an image. + * This method has limits on input size, processing time, and output size. + * See + * https://cloud.google.com/sensitive-data-protection/docs/redacting-sensitive-data-images + * to learn more. + * + * When no InfoTypes or CustomInfoTypes are specified in this request, the + * system will automatically choose what detectors to run. By default this may + * be all types, but may change over time as detectors are updated. + * + * The async variant is {@see DlpServiceClient::redactImageAsync()} . + * + * @example samples/V2/DlpServiceClient/redact_image.php + * + * @param RedactImageRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 RedactImageResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function redactImage(RedactImageRequest $request, array $callOptions = []): RedactImageResponse + { + return $this->startApiCall('RedactImage', $request, $callOptions)->wait(); + } + + /** + * Re-identifies content that has been de-identified. + * See + * https://cloud.google.com/sensitive-data-protection/docs/pseudonymization#re-identification_in_free_text_code_example + * to learn more. + * + * The async variant is {@see DlpServiceClient::reidentifyContentAsync()} . + * + * @example samples/V2/DlpServiceClient/reidentify_content.php + * + * @param ReidentifyContentRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 ReidentifyContentResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function reidentifyContent(ReidentifyContentRequest $request, array $callOptions = []): ReidentifyContentResponse + { + return $this->startApiCall('ReidentifyContent', $request, $callOptions)->wait(); + } + + /** + * Searches for Connections in a parent. + * + * The async variant is {@see DlpServiceClient::searchConnectionsAsync()} . + * + * @example samples/V2/DlpServiceClient/search_connections.php + * + * @param SearchConnectionsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function searchConnections(SearchConnectionsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('SearchConnections', $request, $callOptions); + } + + /** + * Update a Connection. + * + * The async variant is {@see DlpServiceClient::updateConnectionAsync()} . + * + * @example samples/V2/DlpServiceClient/update_connection.php + * + * @param UpdateConnectionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Connection + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateConnection(UpdateConnectionRequest $request, array $callOptions = []): Connection + { + return $this->startApiCall('UpdateConnection', $request, $callOptions)->wait(); + } + + /** + * Updates the DeidentifyTemplate. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid + * to learn more. + * + * The async variant is {@see DlpServiceClient::updateDeidentifyTemplateAsync()} . + * + * @example samples/V2/DlpServiceClient/update_deidentify_template.php + * + * @param UpdateDeidentifyTemplateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DeidentifyTemplate + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateDeidentifyTemplate(UpdateDeidentifyTemplateRequest $request, array $callOptions = []): DeidentifyTemplate + { + return $this->startApiCall('UpdateDeidentifyTemplate', $request, $callOptions)->wait(); + } + + /** + * Updates a discovery configuration. + * + * The async variant is {@see DlpServiceClient::updateDiscoveryConfigAsync()} . + * + * @example samples/V2/DlpServiceClient/update_discovery_config.php + * + * @param UpdateDiscoveryConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DiscoveryConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateDiscoveryConfig(UpdateDiscoveryConfigRequest $request, array $callOptions = []): DiscoveryConfig + { + return $this->startApiCall('UpdateDiscoveryConfig', $request, $callOptions)->wait(); + } + + /** + * Updates the InspectTemplate. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates + * to learn more. + * + * The async variant is {@see DlpServiceClient::updateInspectTemplateAsync()} . + * + * @example samples/V2/DlpServiceClient/update_inspect_template.php + * + * @param UpdateInspectTemplateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 InspectTemplate + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateInspectTemplate(UpdateInspectTemplateRequest $request, array $callOptions = []): InspectTemplate + { + return $this->startApiCall('UpdateInspectTemplate', $request, $callOptions)->wait(); + } + + /** + * Updates a job trigger. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers + * to learn more. + * + * The async variant is {@see DlpServiceClient::updateJobTriggerAsync()} . + * + * @example samples/V2/DlpServiceClient/update_job_trigger.php + * + * @param UpdateJobTriggerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 JobTrigger + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateJobTrigger(UpdateJobTriggerRequest $request, array $callOptions = []): JobTrigger + { + return $this->startApiCall('UpdateJobTrigger', $request, $callOptions)->wait(); + } + + /** + * Updates the stored infoType by creating a new version. The existing version + * will continue to be used until the new version is ready. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes + * to learn more. + * + * The async variant is {@see DlpServiceClient::updateStoredInfoTypeAsync()} . + * + * @example samples/V2/DlpServiceClient/update_stored_info_type.php + * + * @param UpdateStoredInfoTypeRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 StoredInfoType + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateStoredInfoType(UpdateStoredInfoTypeRequest $request, array $callOptions = []): StoredInfoType + { + return $this->startApiCall('UpdateStoredInfoType', $request, $callOptions)->wait(); + } +} diff --git a/owl-bot-staging/Dlp/v2/src/V2/DlpServiceClient.php b/owl-bot-staging/Dlp/v2/src/V2/DlpServiceClient.php new file mode 100644 index 000000000000..feca6924635f --- /dev/null +++ b/owl-bot-staging/Dlp/v2/src/V2/DlpServiceClient.php @@ -0,0 +1,34 @@ +jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + * $response = $dlpServiceClient->activateJobTrigger($formattedName); + * } finally { + * $dlpServiceClient->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. + * + * @deprecated Please use the new service client {@see \Google\Cloud\Dlp\V2\Client\DlpServiceClient}. + */ +class DlpServiceGapicClient +{ + use GapicClientTrait; + + /** The name of the service. */ + const SERVICE_NAME = 'google.privacy.dlp.v2.DlpService'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + const SERVICE_ADDRESS = 'dlp.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'dlp.UNIVERSE_DOMAIN'; + + /** 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 = [ + 'https://www.googleapis.com/auth/cloud-platform', + ]; + + private static $columnDataProfileNameTemplate; + + private static $connectionNameTemplate; + + private static $deidentifyTemplateNameTemplate; + + private static $discoveryConfigNameTemplate; + + private static $dlpJobNameTemplate; + + private static $inspectTemplateNameTemplate; + + private static $jobTriggerNameTemplate; + + private static $locationNameTemplate; + + private static $organizationNameTemplate; + + private static $organizationDeidentifyTemplateNameTemplate; + + private static $organizationInspectTemplateNameTemplate; + + private static $organizationLocationNameTemplate; + + private static $organizationLocationColumnDataProfileNameTemplate; + + private static $organizationLocationDeidentifyTemplateNameTemplate; + + private static $organizationLocationInspectTemplateNameTemplate; + + private static $organizationLocationProjectDataProfileNameTemplate; + + private static $organizationLocationStoredInfoTypeNameTemplate; + + private static $organizationLocationTableDataProfileNameTemplate; + + private static $organizationStoredInfoTypeNameTemplate; + + private static $projectNameTemplate; + + private static $projectDataProfileNameTemplate; + + private static $projectDeidentifyTemplateNameTemplate; + + private static $projectDlpJobNameTemplate; + + private static $projectInspectTemplateNameTemplate; + + private static $projectJobTriggerNameTemplate; + + private static $projectLocationColumnDataProfileNameTemplate; + + private static $projectLocationDeidentifyTemplateNameTemplate; + + private static $projectLocationDlpJobNameTemplate; + + private static $projectLocationInspectTemplateNameTemplate; + + private static $projectLocationJobTriggerNameTemplate; + + private static $projectLocationProjectDataProfileNameTemplate; + + private static $projectLocationStoredInfoTypeNameTemplate; + + private static $projectLocationTableDataProfileNameTemplate; + + private static $projectStoredInfoTypeNameTemplate; + + private static $storedInfoTypeNameTemplate; + + private static $tableDataProfileNameTemplate; + + private static $pathTemplateMap; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/dlp_service_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/dlp_service_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/dlp_service_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/dlp_service_rest_client_config.php', + ], + ], + ]; + } + + private static function getColumnDataProfileNameTemplate() + { + if (self::$columnDataProfileNameTemplate == null) { + self::$columnDataProfileNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}'); + } + + return self::$columnDataProfileNameTemplate; + } + + private static function getConnectionNameTemplate() + { + if (self::$connectionNameTemplate == null) { + self::$connectionNameTemplate = new PathTemplate('projects/{project}/locations/{location}/connections/{connection}'); + } + + return self::$connectionNameTemplate; + } + + private static function getDeidentifyTemplateNameTemplate() + { + if (self::$deidentifyTemplateNameTemplate == null) { + self::$deidentifyTemplateNameTemplate = new PathTemplate('organizations/{organization}/deidentifyTemplates/{deidentify_template}'); + } + + return self::$deidentifyTemplateNameTemplate; + } + + private static function getDiscoveryConfigNameTemplate() + { + if (self::$discoveryConfigNameTemplate == null) { + self::$discoveryConfigNameTemplate = new PathTemplate('projects/{project}/locations/{location}/discoveryConfigs/{discovery_config}'); + } + + return self::$discoveryConfigNameTemplate; + } + + private static function getDlpJobNameTemplate() + { + if (self::$dlpJobNameTemplate == null) { + self::$dlpJobNameTemplate = new PathTemplate('projects/{project}/dlpJobs/{dlp_job}'); + } + + return self::$dlpJobNameTemplate; + } + + private static function getInspectTemplateNameTemplate() + { + if (self::$inspectTemplateNameTemplate == null) { + self::$inspectTemplateNameTemplate = new PathTemplate('organizations/{organization}/inspectTemplates/{inspect_template}'); + } + + return self::$inspectTemplateNameTemplate; + } + + private static function getJobTriggerNameTemplate() + { + if (self::$jobTriggerNameTemplate == null) { + self::$jobTriggerNameTemplate = new PathTemplate('projects/{project}/jobTriggers/{job_trigger}'); + } + + return self::$jobTriggerNameTemplate; + } + + private static function getLocationNameTemplate() + { + if (self::$locationNameTemplate == null) { + self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); + } + + return self::$locationNameTemplate; + } + + private static function getOrganizationNameTemplate() + { + if (self::$organizationNameTemplate == null) { + self::$organizationNameTemplate = new PathTemplate('organizations/{organization}'); + } + + return self::$organizationNameTemplate; + } + + private static function getOrganizationDeidentifyTemplateNameTemplate() + { + if (self::$organizationDeidentifyTemplateNameTemplate == null) { + self::$organizationDeidentifyTemplateNameTemplate = new PathTemplate('organizations/{organization}/deidentifyTemplates/{deidentify_template}'); + } + + return self::$organizationDeidentifyTemplateNameTemplate; + } + + private static function getOrganizationInspectTemplateNameTemplate() + { + if (self::$organizationInspectTemplateNameTemplate == null) { + self::$organizationInspectTemplateNameTemplate = new PathTemplate('organizations/{organization}/inspectTemplates/{inspect_template}'); + } + + return self::$organizationInspectTemplateNameTemplate; + } + + private static function getOrganizationLocationNameTemplate() + { + if (self::$organizationLocationNameTemplate == null) { + self::$organizationLocationNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}'); + } + + return self::$organizationLocationNameTemplate; + } + + private static function getOrganizationLocationColumnDataProfileNameTemplate() + { + if (self::$organizationLocationColumnDataProfileNameTemplate == null) { + self::$organizationLocationColumnDataProfileNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}'); + } + + return self::$organizationLocationColumnDataProfileNameTemplate; + } + + private static function getOrganizationLocationDeidentifyTemplateNameTemplate() + { + if (self::$organizationLocationDeidentifyTemplateNameTemplate == null) { + self::$organizationLocationDeidentifyTemplateNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/deidentifyTemplates/{deidentify_template}'); + } + + return self::$organizationLocationDeidentifyTemplateNameTemplate; + } + + private static function getOrganizationLocationInspectTemplateNameTemplate() + { + if (self::$organizationLocationInspectTemplateNameTemplate == null) { + self::$organizationLocationInspectTemplateNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/inspectTemplates/{inspect_template}'); + } + + return self::$organizationLocationInspectTemplateNameTemplate; + } + + private static function getOrganizationLocationProjectDataProfileNameTemplate() + { + if (self::$organizationLocationProjectDataProfileNameTemplate == null) { + self::$organizationLocationProjectDataProfileNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile}'); + } + + return self::$organizationLocationProjectDataProfileNameTemplate; + } + + private static function getOrganizationLocationStoredInfoTypeNameTemplate() + { + if (self::$organizationLocationStoredInfoTypeNameTemplate == null) { + self::$organizationLocationStoredInfoTypeNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/storedInfoTypes/{stored_info_type}'); + } + + return self::$organizationLocationStoredInfoTypeNameTemplate; + } + + private static function getOrganizationLocationTableDataProfileNameTemplate() + { + if (self::$organizationLocationTableDataProfileNameTemplate == null) { + self::$organizationLocationTableDataProfileNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile}'); + } + + return self::$organizationLocationTableDataProfileNameTemplate; + } + + private static function getOrganizationStoredInfoTypeNameTemplate() + { + if (self::$organizationStoredInfoTypeNameTemplate == null) { + self::$organizationStoredInfoTypeNameTemplate = new PathTemplate('organizations/{organization}/storedInfoTypes/{stored_info_type}'); + } + + return self::$organizationStoredInfoTypeNameTemplate; + } + + private static function getProjectNameTemplate() + { + if (self::$projectNameTemplate == null) { + self::$projectNameTemplate = new PathTemplate('projects/{project}'); + } + + return self::$projectNameTemplate; + } + + private static function getProjectDataProfileNameTemplate() + { + if (self::$projectDataProfileNameTemplate == null) { + self::$projectDataProfileNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile}'); + } + + return self::$projectDataProfileNameTemplate; + } + + private static function getProjectDeidentifyTemplateNameTemplate() + { + if (self::$projectDeidentifyTemplateNameTemplate == null) { + self::$projectDeidentifyTemplateNameTemplate = new PathTemplate('projects/{project}/deidentifyTemplates/{deidentify_template}'); + } + + return self::$projectDeidentifyTemplateNameTemplate; + } + + private static function getProjectDlpJobNameTemplate() + { + if (self::$projectDlpJobNameTemplate == null) { + self::$projectDlpJobNameTemplate = new PathTemplate('projects/{project}/dlpJobs/{dlp_job}'); + } + + return self::$projectDlpJobNameTemplate; + } + + private static function getProjectInspectTemplateNameTemplate() + { + if (self::$projectInspectTemplateNameTemplate == null) { + self::$projectInspectTemplateNameTemplate = new PathTemplate('projects/{project}/inspectTemplates/{inspect_template}'); + } + + return self::$projectInspectTemplateNameTemplate; + } + + private static function getProjectJobTriggerNameTemplate() + { + if (self::$projectJobTriggerNameTemplate == null) { + self::$projectJobTriggerNameTemplate = new PathTemplate('projects/{project}/jobTriggers/{job_trigger}'); + } + + return self::$projectJobTriggerNameTemplate; + } + + private static function getProjectLocationColumnDataProfileNameTemplate() + { + if (self::$projectLocationColumnDataProfileNameTemplate == null) { + self::$projectLocationColumnDataProfileNameTemplate = new PathTemplate('projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile}'); + } + + return self::$projectLocationColumnDataProfileNameTemplate; + } + + private static function getProjectLocationDeidentifyTemplateNameTemplate() + { + if (self::$projectLocationDeidentifyTemplateNameTemplate == null) { + self::$projectLocationDeidentifyTemplateNameTemplate = new PathTemplate('projects/{project}/locations/{location}/deidentifyTemplates/{deidentify_template}'); + } + + return self::$projectLocationDeidentifyTemplateNameTemplate; + } + + private static function getProjectLocationDlpJobNameTemplate() + { + if (self::$projectLocationDlpJobNameTemplate == null) { + self::$projectLocationDlpJobNameTemplate = new PathTemplate('projects/{project}/locations/{location}/dlpJobs/{dlp_job}'); + } + + return self::$projectLocationDlpJobNameTemplate; + } + + private static function getProjectLocationInspectTemplateNameTemplate() + { + if (self::$projectLocationInspectTemplateNameTemplate == null) { + self::$projectLocationInspectTemplateNameTemplate = new PathTemplate('projects/{project}/locations/{location}/inspectTemplates/{inspect_template}'); + } + + return self::$projectLocationInspectTemplateNameTemplate; + } + + private static function getProjectLocationJobTriggerNameTemplate() + { + if (self::$projectLocationJobTriggerNameTemplate == null) { + self::$projectLocationJobTriggerNameTemplate = new PathTemplate('projects/{project}/locations/{location}/jobTriggers/{job_trigger}'); + } + + return self::$projectLocationJobTriggerNameTemplate; + } + + private static function getProjectLocationProjectDataProfileNameTemplate() + { + if (self::$projectLocationProjectDataProfileNameTemplate == null) { + self::$projectLocationProjectDataProfileNameTemplate = new PathTemplate('projects/{project}/locations/{location}/projectDataProfiles/{project_data_profile}'); + } + + return self::$projectLocationProjectDataProfileNameTemplate; + } + + private static function getProjectLocationStoredInfoTypeNameTemplate() + { + if (self::$projectLocationStoredInfoTypeNameTemplate == null) { + self::$projectLocationStoredInfoTypeNameTemplate = new PathTemplate('projects/{project}/locations/{location}/storedInfoTypes/{stored_info_type}'); + } + + return self::$projectLocationStoredInfoTypeNameTemplate; + } + + private static function getProjectLocationTableDataProfileNameTemplate() + { + if (self::$projectLocationTableDataProfileNameTemplate == null) { + self::$projectLocationTableDataProfileNameTemplate = new PathTemplate('projects/{project}/locations/{location}/tableDataProfiles/{table_data_profile}'); + } + + return self::$projectLocationTableDataProfileNameTemplate; + } + + private static function getProjectStoredInfoTypeNameTemplate() + { + if (self::$projectStoredInfoTypeNameTemplate == null) { + self::$projectStoredInfoTypeNameTemplate = new PathTemplate('projects/{project}/storedInfoTypes/{stored_info_type}'); + } + + return self::$projectStoredInfoTypeNameTemplate; + } + + private static function getStoredInfoTypeNameTemplate() + { + if (self::$storedInfoTypeNameTemplate == null) { + self::$storedInfoTypeNameTemplate = new PathTemplate('organizations/{organization}/storedInfoTypes/{stored_info_type}'); + } + + return self::$storedInfoTypeNameTemplate; + } + + private static function getTableDataProfileNameTemplate() + { + if (self::$tableDataProfileNameTemplate == null) { + self::$tableDataProfileNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile}'); + } + + return self::$tableDataProfileNameTemplate; + } + + private static function getPathTemplateMap() + { + if (self::$pathTemplateMap == null) { + self::$pathTemplateMap = [ + 'columnDataProfile' => self::getColumnDataProfileNameTemplate(), + 'connection' => self::getConnectionNameTemplate(), + 'deidentifyTemplate' => self::getDeidentifyTemplateNameTemplate(), + 'discoveryConfig' => self::getDiscoveryConfigNameTemplate(), + 'dlpJob' => self::getDlpJobNameTemplate(), + 'inspectTemplate' => self::getInspectTemplateNameTemplate(), + 'jobTrigger' => self::getJobTriggerNameTemplate(), + 'location' => self::getLocationNameTemplate(), + 'organization' => self::getOrganizationNameTemplate(), + 'organizationDeidentifyTemplate' => self::getOrganizationDeidentifyTemplateNameTemplate(), + 'organizationInspectTemplate' => self::getOrganizationInspectTemplateNameTemplate(), + 'organizationLocation' => self::getOrganizationLocationNameTemplate(), + 'organizationLocationColumnDataProfile' => self::getOrganizationLocationColumnDataProfileNameTemplate(), + 'organizationLocationDeidentifyTemplate' => self::getOrganizationLocationDeidentifyTemplateNameTemplate(), + 'organizationLocationInspectTemplate' => self::getOrganizationLocationInspectTemplateNameTemplate(), + 'organizationLocationProjectDataProfile' => self::getOrganizationLocationProjectDataProfileNameTemplate(), + 'organizationLocationStoredInfoType' => self::getOrganizationLocationStoredInfoTypeNameTemplate(), + 'organizationLocationTableDataProfile' => self::getOrganizationLocationTableDataProfileNameTemplate(), + 'organizationStoredInfoType' => self::getOrganizationStoredInfoTypeNameTemplate(), + 'project' => self::getProjectNameTemplate(), + 'projectDataProfile' => self::getProjectDataProfileNameTemplate(), + 'projectDeidentifyTemplate' => self::getProjectDeidentifyTemplateNameTemplate(), + 'projectDlpJob' => self::getProjectDlpJobNameTemplate(), + 'projectInspectTemplate' => self::getProjectInspectTemplateNameTemplate(), + 'projectJobTrigger' => self::getProjectJobTriggerNameTemplate(), + 'projectLocationColumnDataProfile' => self::getProjectLocationColumnDataProfileNameTemplate(), + 'projectLocationDeidentifyTemplate' => self::getProjectLocationDeidentifyTemplateNameTemplate(), + 'projectLocationDlpJob' => self::getProjectLocationDlpJobNameTemplate(), + 'projectLocationInspectTemplate' => self::getProjectLocationInspectTemplateNameTemplate(), + 'projectLocationJobTrigger' => self::getProjectLocationJobTriggerNameTemplate(), + 'projectLocationProjectDataProfile' => self::getProjectLocationProjectDataProfileNameTemplate(), + 'projectLocationStoredInfoType' => self::getProjectLocationStoredInfoTypeNameTemplate(), + 'projectLocationTableDataProfile' => self::getProjectLocationTableDataProfileNameTemplate(), + 'projectStoredInfoType' => self::getProjectStoredInfoTypeNameTemplate(), + 'storedInfoType' => self::getStoredInfoTypeNameTemplate(), + 'tableDataProfile' => self::getTableDataProfileNameTemplate(), + ]; + } + + return self::$pathTemplateMap; + } + + /** + * Formats a string containing the fully-qualified path to represent a + * column_data_profile resource. + * + * @param string $organization + * @param string $location + * @param string $columnDataProfile + * + * @return string The formatted column_data_profile resource. + */ + public static function columnDataProfileName($organization, $location, $columnDataProfile) + { + return self::getColumnDataProfileNameTemplate()->render([ + 'organization' => $organization, + 'location' => $location, + 'column_data_profile' => $columnDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a connection + * resource. + * + * @param string $project + * @param string $location + * @param string $connection + * + * @return string The formatted connection resource. + */ + public static function connectionName($project, $location, $connection) + { + return self::getConnectionNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + 'connection' => $connection, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * deidentify_template resource. + * + * @param string $organization + * @param string $deidentifyTemplate + * + * @return string The formatted deidentify_template resource. + */ + public static function deidentifyTemplateName($organization, $deidentifyTemplate) + { + return self::getDeidentifyTemplateNameTemplate()->render([ + 'organization' => $organization, + 'deidentify_template' => $deidentifyTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * discovery_config resource. + * + * @param string $project + * @param string $location + * @param string $discoveryConfig + * + * @return string The formatted discovery_config resource. + */ + public static function discoveryConfigName($project, $location, $discoveryConfig) + { + return self::getDiscoveryConfigNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + 'discovery_config' => $discoveryConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a dlp_job + * resource. + * + * @param string $project + * @param string $dlpJob + * + * @return string The formatted dlp_job resource. + */ + public static function dlpJobName($project, $dlpJob) + { + return self::getDlpJobNameTemplate()->render([ + 'project' => $project, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * inspect_template resource. + * + * @param string $organization + * @param string $inspectTemplate + * + * @return string The formatted inspect_template resource. + */ + public static function inspectTemplateName($organization, $inspectTemplate) + { + return self::getInspectTemplateNameTemplate()->render([ + 'organization' => $organization, + 'inspect_template' => $inspectTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a job_trigger + * resource. + * + * @param string $project + * @param string $jobTrigger + * + * @return string The formatted job_trigger resource. + */ + public static function jobTriggerName($project, $jobTrigger) + { + return self::getJobTriggerNameTemplate()->render([ + 'project' => $project, + 'job_trigger' => $jobTrigger, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a location + * resource. + * + * @param string $project + * @param string $location + * + * @return string The formatted location resource. + */ + public static function locationName($project, $location) + { + return self::getLocationNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a organization + * resource. + * + * @param string $organization + * + * @return string The formatted organization resource. + */ + public static function organizationName($organization) + { + return self::getOrganizationNameTemplate()->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_deidentify_template resource. + * + * @param string $organization + * @param string $deidentifyTemplate + * + * @return string The formatted organization_deidentify_template resource. + */ + public static function organizationDeidentifyTemplateName($organization, $deidentifyTemplate) + { + return self::getOrganizationDeidentifyTemplateNameTemplate()->render([ + 'organization' => $organization, + 'deidentify_template' => $deidentifyTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_inspect_template resource. + * + * @param string $organization + * @param string $inspectTemplate + * + * @return string The formatted organization_inspect_template resource. + */ + public static function organizationInspectTemplateName($organization, $inspectTemplate) + { + return self::getOrganizationInspectTemplateNameTemplate()->render([ + 'organization' => $organization, + 'inspect_template' => $inspectTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location resource. + * + * @param string $organization + * @param string $location + * + * @return string The formatted organization_location resource. + */ + public static function organizationLocationName($organization, $location) + { + return self::getOrganizationLocationNameTemplate()->render([ + 'organization' => $organization, + 'location' => $location, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_column_data_profile resource. + * + * @param string $organization + * @param string $location + * @param string $columnDataProfile + * + * @return string The formatted organization_location_column_data_profile resource. + */ + public static function organizationLocationColumnDataProfileName($organization, $location, $columnDataProfile) + { + return self::getOrganizationLocationColumnDataProfileNameTemplate()->render([ + 'organization' => $organization, + 'location' => $location, + 'column_data_profile' => $columnDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_deidentify_template resource. + * + * @param string $organization + * @param string $location + * @param string $deidentifyTemplate + * + * @return string The formatted organization_location_deidentify_template resource. + */ + public static function organizationLocationDeidentifyTemplateName($organization, $location, $deidentifyTemplate) + { + return self::getOrganizationLocationDeidentifyTemplateNameTemplate()->render([ + 'organization' => $organization, + 'location' => $location, + 'deidentify_template' => $deidentifyTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_inspect_template resource. + * + * @param string $organization + * @param string $location + * @param string $inspectTemplate + * + * @return string The formatted organization_location_inspect_template resource. + */ + public static function organizationLocationInspectTemplateName($organization, $location, $inspectTemplate) + { + return self::getOrganizationLocationInspectTemplateNameTemplate()->render([ + 'organization' => $organization, + 'location' => $location, + 'inspect_template' => $inspectTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_project_data_profile resource. + * + * @param string $organization + * @param string $location + * @param string $projectDataProfile + * + * @return string The formatted organization_location_project_data_profile resource. + */ + public static function organizationLocationProjectDataProfileName($organization, $location, $projectDataProfile) + { + return self::getOrganizationLocationProjectDataProfileNameTemplate()->render([ + 'organization' => $organization, + 'location' => $location, + 'project_data_profile' => $projectDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_stored_info_type resource. + * + * @param string $organization + * @param string $location + * @param string $storedInfoType + * + * @return string The formatted organization_location_stored_info_type resource. + */ + public static function organizationLocationStoredInfoTypeName($organization, $location, $storedInfoType) + { + return self::getOrganizationLocationStoredInfoTypeNameTemplate()->render([ + 'organization' => $organization, + 'location' => $location, + 'stored_info_type' => $storedInfoType, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_table_data_profile resource. + * + * @param string $organization + * @param string $location + * @param string $tableDataProfile + * + * @return string The formatted organization_location_table_data_profile resource. + */ + public static function organizationLocationTableDataProfileName($organization, $location, $tableDataProfile) + { + return self::getOrganizationLocationTableDataProfileNameTemplate()->render([ + 'organization' => $organization, + 'location' => $location, + 'table_data_profile' => $tableDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_stored_info_type resource. + * + * @param string $organization + * @param string $storedInfoType + * + * @return string The formatted organization_stored_info_type resource. + */ + public static function organizationStoredInfoTypeName($organization, $storedInfoType) + { + return self::getOrganizationStoredInfoTypeNameTemplate()->render([ + 'organization' => $organization, + 'stored_info_type' => $storedInfoType, + ]); + } + + /** + * 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, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_data_profile resource. + * + * @param string $organization + * @param string $location + * @param string $projectDataProfile + * + * @return string The formatted project_data_profile resource. + */ + public static function projectDataProfileName($organization, $location, $projectDataProfile) + { + return self::getProjectDataProfileNameTemplate()->render([ + 'organization' => $organization, + 'location' => $location, + 'project_data_profile' => $projectDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_deidentify_template resource. + * + * @param string $project + * @param string $deidentifyTemplate + * + * @return string The formatted project_deidentify_template resource. + */ + public static function projectDeidentifyTemplateName($project, $deidentifyTemplate) + { + return self::getProjectDeidentifyTemplateNameTemplate()->render([ + 'project' => $project, + 'deidentify_template' => $deidentifyTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_dlp_job resource. + * + * @param string $project + * @param string $dlpJob + * + * @return string The formatted project_dlp_job resource. + */ + public static function projectDlpJobName($project, $dlpJob) + { + return self::getProjectDlpJobNameTemplate()->render([ + 'project' => $project, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_inspect_template resource. + * + * @param string $project + * @param string $inspectTemplate + * + * @return string The formatted project_inspect_template resource. + */ + public static function projectInspectTemplateName($project, $inspectTemplate) + { + return self::getProjectInspectTemplateNameTemplate()->render([ + 'project' => $project, + 'inspect_template' => $inspectTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_job_trigger resource. + * + * @param string $project + * @param string $jobTrigger + * + * @return string The formatted project_job_trigger resource. + */ + public static function projectJobTriggerName($project, $jobTrigger) + { + return self::getProjectJobTriggerNameTemplate()->render([ + 'project' => $project, + 'job_trigger' => $jobTrigger, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_column_data_profile resource. + * + * @param string $project + * @param string $location + * @param string $columnDataProfile + * + * @return string The formatted project_location_column_data_profile resource. + */ + public static function projectLocationColumnDataProfileName($project, $location, $columnDataProfile) + { + return self::getProjectLocationColumnDataProfileNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + 'column_data_profile' => $columnDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_deidentify_template resource. + * + * @param string $project + * @param string $location + * @param string $deidentifyTemplate + * + * @return string The formatted project_location_deidentify_template resource. + */ + public static function projectLocationDeidentifyTemplateName($project, $location, $deidentifyTemplate) + { + return self::getProjectLocationDeidentifyTemplateNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + 'deidentify_template' => $deidentifyTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_dlp_job resource. + * + * @param string $project + * @param string $location + * @param string $dlpJob + * + * @return string The formatted project_location_dlp_job resource. + */ + public static function projectLocationDlpJobName($project, $location, $dlpJob) + { + return self::getProjectLocationDlpJobNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_inspect_template resource. + * + * @param string $project + * @param string $location + * @param string $inspectTemplate + * + * @return string The formatted project_location_inspect_template resource. + */ + public static function projectLocationInspectTemplateName($project, $location, $inspectTemplate) + { + return self::getProjectLocationInspectTemplateNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + 'inspect_template' => $inspectTemplate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_job_trigger resource. + * + * @param string $project + * @param string $location + * @param string $jobTrigger + * + * @return string The formatted project_location_job_trigger resource. + */ + public static function projectLocationJobTriggerName($project, $location, $jobTrigger) + { + return self::getProjectLocationJobTriggerNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + 'job_trigger' => $jobTrigger, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_project_data_profile resource. + * + * @param string $project + * @param string $location + * @param string $projectDataProfile + * + * @return string The formatted project_location_project_data_profile resource. + */ + public static function projectLocationProjectDataProfileName($project, $location, $projectDataProfile) + { + return self::getProjectLocationProjectDataProfileNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + 'project_data_profile' => $projectDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_stored_info_type resource. + * + * @param string $project + * @param string $location + * @param string $storedInfoType + * + * @return string The formatted project_location_stored_info_type resource. + */ + public static function projectLocationStoredInfoTypeName($project, $location, $storedInfoType) + { + return self::getProjectLocationStoredInfoTypeNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + 'stored_info_type' => $storedInfoType, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_table_data_profile resource. + * + * @param string $project + * @param string $location + * @param string $tableDataProfile + * + * @return string The formatted project_location_table_data_profile resource. + */ + public static function projectLocationTableDataProfileName($project, $location, $tableDataProfile) + { + return self::getProjectLocationTableDataProfileNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + 'table_data_profile' => $tableDataProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_stored_info_type resource. + * + * @param string $project + * @param string $storedInfoType + * + * @return string The formatted project_stored_info_type resource. + */ + public static function projectStoredInfoTypeName($project, $storedInfoType) + { + return self::getProjectStoredInfoTypeNameTemplate()->render([ + 'project' => $project, + 'stored_info_type' => $storedInfoType, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * stored_info_type resource. + * + * @param string $organization + * @param string $storedInfoType + * + * @return string The formatted stored_info_type resource. + */ + public static function storedInfoTypeName($organization, $storedInfoType) + { + return self::getStoredInfoTypeNameTemplate()->render([ + 'organization' => $organization, + 'stored_info_type' => $storedInfoType, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * table_data_profile resource. + * + * @param string $organization + * @param string $location + * @param string $tableDataProfile + * + * @return string The formatted table_data_profile resource. + */ + public static function tableDataProfileName($organization, $location, $tableDataProfile) + { + return self::getTableDataProfileNameTemplate()->render([ + 'organization' => $organization, + 'location' => $location, + 'table_data_profile' => $tableDataProfile, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - columnDataProfile: organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile} + * - connection: projects/{project}/locations/{location}/connections/{connection} + * - deidentifyTemplate: organizations/{organization}/deidentifyTemplates/{deidentify_template} + * - discoveryConfig: projects/{project}/locations/{location}/discoveryConfigs/{discovery_config} + * - dlpJob: projects/{project}/dlpJobs/{dlp_job} + * - inspectTemplate: organizations/{organization}/inspectTemplates/{inspect_template} + * - jobTrigger: projects/{project}/jobTriggers/{job_trigger} + * - location: projects/{project}/locations/{location} + * - organization: organizations/{organization} + * - organizationDeidentifyTemplate: organizations/{organization}/deidentifyTemplates/{deidentify_template} + * - organizationInspectTemplate: organizations/{organization}/inspectTemplates/{inspect_template} + * - organizationLocation: organizations/{organization}/locations/{location} + * - organizationLocationColumnDataProfile: organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile} + * - organizationLocationDeidentifyTemplate: organizations/{organization}/locations/{location}/deidentifyTemplates/{deidentify_template} + * - organizationLocationInspectTemplate: organizations/{organization}/locations/{location}/inspectTemplates/{inspect_template} + * - organizationLocationProjectDataProfile: organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile} + * - organizationLocationStoredInfoType: organizations/{organization}/locations/{location}/storedInfoTypes/{stored_info_type} + * - organizationLocationTableDataProfile: organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile} + * - organizationStoredInfoType: organizations/{organization}/storedInfoTypes/{stored_info_type} + * - project: projects/{project} + * - projectDataProfile: organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile} + * - projectDeidentifyTemplate: projects/{project}/deidentifyTemplates/{deidentify_template} + * - projectDlpJob: projects/{project}/dlpJobs/{dlp_job} + * - projectInspectTemplate: projects/{project}/inspectTemplates/{inspect_template} + * - projectJobTrigger: projects/{project}/jobTriggers/{job_trigger} + * - projectLocationColumnDataProfile: projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile} + * - projectLocationDeidentifyTemplate: projects/{project}/locations/{location}/deidentifyTemplates/{deidentify_template} + * - projectLocationDlpJob: projects/{project}/locations/{location}/dlpJobs/{dlp_job} + * - projectLocationInspectTemplate: projects/{project}/locations/{location}/inspectTemplates/{inspect_template} + * - projectLocationJobTrigger: projects/{project}/locations/{location}/jobTriggers/{job_trigger} + * - projectLocationProjectDataProfile: projects/{project}/locations/{location}/projectDataProfiles/{project_data_profile} + * - projectLocationStoredInfoType: projects/{project}/locations/{location}/storedInfoTypes/{stored_info_type} + * - projectLocationTableDataProfile: projects/{project}/locations/{location}/tableDataProfiles/{table_data_profile} + * - projectStoredInfoType: projects/{project}/storedInfoTypes/{stored_info_type} + * - storedInfoType: organizations/{organization}/storedInfoTypes/{stored_info_type} + * - tableDataProfile: organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile} + * + * 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 'dlp.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); + } + + /** + * Activate a job trigger. Causes the immediate execute of a trigger + * instead of waiting on the trigger event to occur. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + * $response = $dlpServiceClient->activateJobTrigger($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the trigger to activate, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * @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 \Google\Cloud\Dlp\V2\DlpJob + * + * @throws ApiException if the remote call fails + */ + public function activateJobTrigger($name, array $optionalArgs = []) + { + $request = new ActivateJobTriggerRequest(); + $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('ActivateJobTrigger', DlpJob::class, $optionalArgs, $request)->wait(); + } + + /** + * Starts asynchronous cancellation on a long-running DlpJob. The server + * makes a best effort to cancel the DlpJob, but success is not + * guaranteed. + * See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage + * and + * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + * $dlpServiceClient->cancelDlpJob($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. The name of the DlpJob resource to be cancelled. + * @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 cancelDlpJob($name, array $optionalArgs = []) + { + $request = new CancelDlpJobRequest(); + $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('CancelDlpJob', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Create a Connection to an external data source. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->locationName('[PROJECT]', '[LOCATION]'); + * $connection = new Connection(); + * $response = $dlpServiceClient->createConnection($formattedParent, $connection); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name in the format: + * `projects/{project}/locations/{location}`. + * @param Connection $connection Required. The connection resource. + * @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 \Google\Cloud\Dlp\V2\Connection + * + * @throws ApiException if the remote call fails + */ + public function createConnection($parent, $connection, array $optionalArgs = []) + { + $request = new CreateConnectionRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setConnection($connection); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateConnection', Connection::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a DeidentifyTemplate for reusing frequently used configuration + * for de-identifying content, images, and storage. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + * $deidentifyTemplate = new DeidentifyTemplate(); + * $response = $dlpServiceClient->createDeidentifyTemplate($formattedParent, $deidentifyTemplate); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param DeidentifyTemplate $deidentifyTemplate Required. The DeidentifyTemplate to create. + * @param array $optionalArgs { + * Optional. + * + * @type string $templateId + * The template id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * @type string $locationId + * Deprecated. This field has no effect. + * @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\Cloud\Dlp\V2\DeidentifyTemplate + * + * @throws ApiException if the remote call fails + */ + public function createDeidentifyTemplate($parent, $deidentifyTemplate, array $optionalArgs = []) + { + $request = new CreateDeidentifyTemplateRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setDeidentifyTemplate($deidentifyTemplate); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['templateId'])) { + $request->setTemplateId($optionalArgs['templateId']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateDeidentifyTemplate', DeidentifyTemplate::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a config for discovery to scan and profile storage. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->locationName('[PROJECT]', '[LOCATION]'); + * $discoveryConfig = new DiscoveryConfig(); + * $response = $dlpServiceClient->createDiscoveryConfig($formattedParent, $discoveryConfig); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value is as follows: + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param DiscoveryConfig $discoveryConfig Required. The DiscoveryConfig to create. + * @param array $optionalArgs { + * Optional. + * + * @type string $configId + * The config ID can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * @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\Cloud\Dlp\V2\DiscoveryConfig + * + * @throws ApiException if the remote call fails + */ + public function createDiscoveryConfig($parent, $discoveryConfig, array $optionalArgs = []) + { + $request = new CreateDiscoveryConfigRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setDiscoveryConfig($discoveryConfig); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['configId'])) { + $request->setConfigId($optionalArgs['configId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateDiscoveryConfig', DiscoveryConfig::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a new job to inspect storage or calculate risk metrics. + * See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage + * and + * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis + * to learn more. + * + * When no InfoTypes or CustomInfoTypes are specified in inspect jobs, the + * system will automatically choose what detectors to run. By default this may + * be all types, but may change over time as detectors are updated. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->projectName('[PROJECT]'); + * $response = $dlpServiceClient->createDlpJob($formattedParent); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param array $optionalArgs { + * Optional. + * + * @type InspectJobConfig $inspectJob + * An inspection job scans a storage repository for InfoTypes. + * @type RiskAnalysisJobConfig $riskJob + * A risk analysis job calculates re-identification risk metrics for a + * BigQuery table. + * @type string $jobId + * The job id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * @type string $locationId + * Deprecated. This field has no effect. + * @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\Cloud\Dlp\V2\DlpJob + * + * @throws ApiException if the remote call fails + */ + public function createDlpJob($parent, array $optionalArgs = []) + { + $request = new CreateDlpJobRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['inspectJob'])) { + $request->setInspectJob($optionalArgs['inspectJob']); + } + + if (isset($optionalArgs['riskJob'])) { + $request->setRiskJob($optionalArgs['riskJob']); + } + + if (isset($optionalArgs['jobId'])) { + $request->setJobId($optionalArgs['jobId']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateDlpJob', DlpJob::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates an InspectTemplate for reusing frequently used configuration + * for inspecting content, images, and storage. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + * $inspectTemplate = new InspectTemplate(); + * $response = $dlpServiceClient->createInspectTemplate($formattedParent, $inspectTemplate); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param InspectTemplate $inspectTemplate Required. The InspectTemplate to create. + * @param array $optionalArgs { + * Optional. + * + * @type string $templateId + * The template id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * @type string $locationId + * Deprecated. This field has no effect. + * @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\Cloud\Dlp\V2\InspectTemplate + * + * @throws ApiException if the remote call fails + */ + public function createInspectTemplate($parent, $inspectTemplate, array $optionalArgs = []) + { + $request = new CreateInspectTemplateRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setInspectTemplate($inspectTemplate); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['templateId'])) { + $request->setTemplateId($optionalArgs['templateId']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateInspectTemplate', InspectTemplate::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a job trigger to run DLP actions such as scanning storage for + * sensitive information on a set schedule. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->projectName('[PROJECT]'); + * $jobTrigger = new JobTrigger(); + * $response = $dlpServiceClient->createJobTrigger($formattedParent, $jobTrigger); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param JobTrigger $jobTrigger Required. The JobTrigger to create. + * @param array $optionalArgs { + * Optional. + * + * @type string $triggerId + * The trigger id can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * @type string $locationId + * Deprecated. This field has no effect. + * @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\Cloud\Dlp\V2\JobTrigger + * + * @throws ApiException if the remote call fails + */ + public function createJobTrigger($parent, $jobTrigger, array $optionalArgs = []) + { + $request = new CreateJobTriggerRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setJobTrigger($jobTrigger); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['triggerId'])) { + $request->setTriggerId($optionalArgs['triggerId']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateJobTrigger', JobTrigger::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a pre-built stored infoType to be used for inspection. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + * $config = new StoredInfoTypeConfig(); + * $response = $dlpServiceClient->createStoredInfoType($formattedParent, $config); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param StoredInfoTypeConfig $config Required. Configuration of the storedInfoType to create. + * @param array $optionalArgs { + * Optional. + * + * @type string $storedInfoTypeId + * The storedInfoType ID can contain uppercase and lowercase letters, + * numbers, and hyphens; that is, it must match the regular + * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 + * characters. Can be empty to allow the system to generate one. + * @type string $locationId + * Deprecated. This field has no effect. + * @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\Cloud\Dlp\V2\StoredInfoType + * + * @throws ApiException if the remote call fails + */ + public function createStoredInfoType($parent, $config, array $optionalArgs = []) + { + $request = new CreateStoredInfoTypeRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setConfig($config); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['storedInfoTypeId'])) { + $request->setStoredInfoTypeId($optionalArgs['storedInfoTypeId']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateStoredInfoType', StoredInfoType::class, $optionalArgs, $request)->wait(); + } + + /** + * De-identifies potentially sensitive info from a ContentItem. + * This method has limits on input size and output size. + * See + * https://cloud.google.com/sensitive-data-protection/docs/deidentify-sensitive-data + * to learn more. + * + * When no InfoTypes or CustomInfoTypes are specified in this request, the + * system will automatically choose what detectors to run. By default this may + * be all types, but may change over time as detectors are updated. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $response = $dlpServiceClient->deidentifyContent(); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param array $optionalArgs { + * Optional. + * + * @type string $parent + * Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @type DeidentifyConfig $deidentifyConfig + * Configuration for the de-identification of the content item. + * Items specified here will override the template referenced by the + * deidentify_template_name argument. + * @type InspectConfig $inspectConfig + * Configuration for the inspector. + * Items specified here will override the template referenced by the + * inspect_template_name argument. + * @type ContentItem $item + * The item to de-identify. Will be treated as text. + * + * This value must be of type + * [Table][google.privacy.dlp.v2.Table] if your + * [deidentify_config][google.privacy.dlp.v2.DeidentifyContentRequest.deidentify_config] + * is a + * [RecordTransformations][google.privacy.dlp.v2.RecordTransformations] + * object. + * @type string $inspectTemplateName + * Template to use. Any configuration directly specified in + * inspect_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * @type string $deidentifyTemplateName + * Template to use. Any configuration directly specified in + * deidentify_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * @type string $locationId + * Deprecated. This field has no effect. + * @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\Cloud\Dlp\V2\DeidentifyContentResponse + * + * @throws ApiException if the remote call fails + */ + public function deidentifyContent(array $optionalArgs = []) + { + $request = new DeidentifyContentRequest(); + $requestParamHeaders = []; + if (isset($optionalArgs['parent'])) { + $request->setParent($optionalArgs['parent']); + $requestParamHeaders['parent'] = $optionalArgs['parent']; + } + + if (isset($optionalArgs['deidentifyConfig'])) { + $request->setDeidentifyConfig($optionalArgs['deidentifyConfig']); + } + + if (isset($optionalArgs['inspectConfig'])) { + $request->setInspectConfig($optionalArgs['inspectConfig']); + } + + if (isset($optionalArgs['item'])) { + $request->setItem($optionalArgs['item']); + } + + if (isset($optionalArgs['inspectTemplateName'])) { + $request->setInspectTemplateName($optionalArgs['inspectTemplateName']); + } + + if (isset($optionalArgs['deidentifyTemplateName'])) { + $request->setDeidentifyTemplateName($optionalArgs['deidentifyTemplateName']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('DeidentifyContent', DeidentifyContentResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Delete a Connection. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + * $dlpServiceClient->deleteConnection($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the Connection to be deleted, in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * @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 deleteConnection($name, array $optionalArgs = []) + { + $request = new DeleteConnectionRequest(); + $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('DeleteConnection', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Deletes a DeidentifyTemplate. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + * $dlpServiceClient->deleteDeidentifyTemplate($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the organization and deidentify template to be + * deleted, for example + * `organizations/433245324/deidentifyTemplates/432452342` or + * projects/project-id/deidentifyTemplates/432452342. + * @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 deleteDeidentifyTemplate($name, array $optionalArgs = []) + { + $request = new DeleteDeidentifyTemplateRequest(); + $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('DeleteDeidentifyTemplate', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Deletes a discovery configuration. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + * $dlpServiceClient->deleteDiscoveryConfig($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the project and the config, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * @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 deleteDiscoveryConfig($name, array $optionalArgs = []) + { + $request = new DeleteDiscoveryConfigRequest(); + $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('DeleteDiscoveryConfig', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Deletes a long-running DlpJob. This method indicates that the client is + * no longer interested in the DlpJob result. The job will be canceled if + * possible. + * See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage + * and + * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + * $dlpServiceClient->deleteDlpJob($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. The name of the DlpJob resource to be deleted. + * @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 deleteDlpJob($name, array $optionalArgs = []) + { + $request = new DeleteDlpJobRequest(); + $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('DeleteDlpJob', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Deletes an InspectTemplate. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + * $dlpServiceClient->deleteInspectTemplate($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the organization and inspectTemplate to be + * deleted, for example `organizations/433245324/inspectTemplates/432452342` + * or projects/project-id/inspectTemplates/432452342. + * @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 deleteInspectTemplate($name, array $optionalArgs = []) + { + $request = new DeleteInspectTemplateRequest(); + $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('DeleteInspectTemplate', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Deletes a job trigger. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + * $dlpServiceClient->deleteJobTrigger($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * @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 deleteJobTrigger($name, array $optionalArgs = []) + { + $request = new DeleteJobTriggerRequest(); + $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('DeleteJobTrigger', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Deletes a stored infoType. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + * $dlpServiceClient->deleteStoredInfoType($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the organization and storedInfoType to be + * deleted, for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * @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 deleteStoredInfoType($name, array $optionalArgs = []) + { + $request = new DeleteStoredInfoTypeRequest(); + $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('DeleteStoredInfoType', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Delete a TableDataProfile. Will not prevent the profile from being + * regenerated if the table is still included in a discovery configuration. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); + * $dlpServiceClient->deleteTableDataProfile($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the table data profile. + * @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 deleteTableDataProfile($name, array $optionalArgs = []) + { + $request = new DeleteTableDataProfileRequest(); + $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('DeleteTableDataProfile', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Finish a running hybrid DlpJob. Triggers the finalization steps and running + * of any enabled actions that have not yet run. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + * $dlpServiceClient->finishDlpJob($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. The name of the DlpJob resource to be finished. + * @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 finishDlpJob($name, array $optionalArgs = []) + { + $request = new FinishDlpJobRequest(); + $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('FinishDlpJob', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a column data profile. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->columnDataProfileName('[ORGANIZATION]', '[LOCATION]', '[COLUMN_DATA_PROFILE]'); + * $response = $dlpServiceClient->getColumnDataProfile($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name, for example + * `organizations/12345/locations/us/columnDataProfiles/53234423`. + * @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 \Google\Cloud\Dlp\V2\ColumnDataProfile + * + * @throws ApiException if the remote call fails + */ + public function getColumnDataProfile($name, array $optionalArgs = []) + { + $request = new GetColumnDataProfileRequest(); + $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('GetColumnDataProfile', ColumnDataProfile::class, $optionalArgs, $request)->wait(); + } + + /** + * Get a Connection by name. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + * $response = $dlpServiceClient->getConnection($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * @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 \Google\Cloud\Dlp\V2\Connection + * + * @throws ApiException if the remote call fails + */ + public function getConnection($name, array $optionalArgs = []) + { + $request = new GetConnectionRequest(); + $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('GetConnection', Connection::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a DeidentifyTemplate. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + * $response = $dlpServiceClient->getDeidentifyTemplate($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the organization and deidentify template to be + * read, for example `organizations/433245324/deidentifyTemplates/432452342` + * or projects/project-id/deidentifyTemplates/432452342. + * @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 \Google\Cloud\Dlp\V2\DeidentifyTemplate + * + * @throws ApiException if the remote call fails + */ + public function getDeidentifyTemplate($name, array $optionalArgs = []) + { + $request = new GetDeidentifyTemplateRequest(); + $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('GetDeidentifyTemplate', DeidentifyTemplate::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a discovery configuration. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + * $response = $dlpServiceClient->getDiscoveryConfig($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the project and the configuration, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * @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 \Google\Cloud\Dlp\V2\DiscoveryConfig + * + * @throws ApiException if the remote call fails + */ + public function getDiscoveryConfig($name, array $optionalArgs = []) + { + $request = new GetDiscoveryConfigRequest(); + $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('GetDiscoveryConfig', DiscoveryConfig::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets the latest state of a long-running DlpJob. + * See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage + * and + * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + * $response = $dlpServiceClient->getDlpJob($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. The name of the DlpJob resource. + * @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 \Google\Cloud\Dlp\V2\DlpJob + * + * @throws ApiException if the remote call fails + */ + public function getDlpJob($name, array $optionalArgs = []) + { + $request = new GetDlpJobRequest(); + $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('GetDlpJob', DlpJob::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets an InspectTemplate. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + * $response = $dlpServiceClient->getInspectTemplate($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the organization and inspectTemplate to be read, + * for example `organizations/433245324/inspectTemplates/432452342` or + * projects/project-id/inspectTemplates/432452342. + * @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 \Google\Cloud\Dlp\V2\InspectTemplate + * + * @throws ApiException if the remote call fails + */ + public function getInspectTemplate($name, array $optionalArgs = []) + { + $request = new GetInspectTemplateRequest(); + $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('GetInspectTemplate', InspectTemplate::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a job trigger. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + * $response = $dlpServiceClient->getJobTrigger($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * @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 \Google\Cloud\Dlp\V2\JobTrigger + * + * @throws ApiException if the remote call fails + */ + public function getJobTrigger($name, array $optionalArgs = []) + { + $request = new GetJobTriggerRequest(); + $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('GetJobTrigger', JobTrigger::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a project data profile. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->projectDataProfileName('[ORGANIZATION]', '[LOCATION]', '[PROJECT_DATA_PROFILE]'); + * $response = $dlpServiceClient->getProjectDataProfile($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name, for example + * `organizations/12345/locations/us/projectDataProfiles/53234423`. + * @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 \Google\Cloud\Dlp\V2\ProjectDataProfile + * + * @throws ApiException if the remote call fails + */ + public function getProjectDataProfile($name, array $optionalArgs = []) + { + $request = new GetProjectDataProfileRequest(); + $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('GetProjectDataProfile', ProjectDataProfile::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a stored infoType. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + * $response = $dlpServiceClient->getStoredInfoType($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the organization and storedInfoType to be read, + * for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * @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 \Google\Cloud\Dlp\V2\StoredInfoType + * + * @throws ApiException if the remote call fails + */ + public function getStoredInfoType($name, array $optionalArgs = []) + { + $request = new GetStoredInfoTypeRequest(); + $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('GetStoredInfoType', StoredInfoType::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a table data profile. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); + * $response = $dlpServiceClient->getTableDataProfile($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name, for example + * `organizations/12345/locations/us/tableDataProfiles/53234423`. + * @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 \Google\Cloud\Dlp\V2\TableDataProfile + * + * @throws ApiException if the remote call fails + */ + public function getTableDataProfile($name, array $optionalArgs = []) + { + $request = new GetTableDataProfileRequest(); + $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('GetTableDataProfile', TableDataProfile::class, $optionalArgs, $request)->wait(); + } + + /** + * Inspect hybrid content and store findings to a job. + * To review the findings, inspect the job. Inspection will occur + * asynchronously. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + * $response = $dlpServiceClient->hybridInspectDlpJob($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the job to execute a hybrid inspect on, for + * example `projects/dlp-test-project/dlpJob/53234423`. + * @param array $optionalArgs { + * Optional. + * + * @type HybridContentItem $hybridItem + * The item to inspect. + * @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\Cloud\Dlp\V2\HybridInspectResponse + * + * @throws ApiException if the remote call fails + */ + public function hybridInspectDlpJob($name, array $optionalArgs = []) + { + $request = new HybridInspectDlpJobRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['hybridItem'])) { + $request->setHybridItem($optionalArgs['hybridItem']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('HybridInspectDlpJob', HybridInspectResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Inspect hybrid content and store findings to a trigger. The inspection + * will be processed asynchronously. To review the findings monitor the + * jobs within the trigger. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + * $response = $dlpServiceClient->hybridInspectJobTrigger($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the trigger to execute a hybrid inspect on, for + * example `projects/dlp-test-project/jobTriggers/53234423`. + * @param array $optionalArgs { + * Optional. + * + * @type HybridContentItem $hybridItem + * The item to inspect. + * @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\Cloud\Dlp\V2\HybridInspectResponse + * + * @throws ApiException if the remote call fails + */ + public function hybridInspectJobTrigger($name, array $optionalArgs = []) + { + $request = new HybridInspectJobTriggerRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['hybridItem'])) { + $request->setHybridItem($optionalArgs['hybridItem']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('HybridInspectJobTrigger', HybridInspectResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Finds potentially sensitive info in content. + * This method has limits on input size, processing time, and output size. + * + * When no InfoTypes or CustomInfoTypes are specified in this request, the + * system will automatically choose what detectors to run. By default this may + * be all types, but may change over time as detectors are updated. + * + * For how to guides, see + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-images + * and + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-text, + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $response = $dlpServiceClient->inspectContent(); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param array $optionalArgs { + * Optional. + * + * @type string $parent + * Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @type InspectConfig $inspectConfig + * Configuration for the inspector. What specified here will override + * the template referenced by the inspect_template_name argument. + * @type ContentItem $item + * The item to inspect. + * @type string $inspectTemplateName + * Template to use. Any configuration directly specified in + * inspect_config will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * @type string $locationId + * Deprecated. This field has no effect. + * @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\Cloud\Dlp\V2\InspectContentResponse + * + * @throws ApiException if the remote call fails + */ + public function inspectContent(array $optionalArgs = []) + { + $request = new InspectContentRequest(); + $requestParamHeaders = []; + if (isset($optionalArgs['parent'])) { + $request->setParent($optionalArgs['parent']); + $requestParamHeaders['parent'] = $optionalArgs['parent']; + } + + if (isset($optionalArgs['inspectConfig'])) { + $request->setInspectConfig($optionalArgs['inspectConfig']); + } + + if (isset($optionalArgs['item'])) { + $request->setItem($optionalArgs['item']); + } + + if (isset($optionalArgs['inspectTemplateName'])) { + $request->setInspectTemplateName($optionalArgs['inspectTemplateName']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('InspectContent', InspectContentResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Lists column data profiles for an organization. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + * // Iterate over pages of elements + * $pagedResponse = $dlpServiceClient->listColumnDataProfiles($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $dlpServiceClient->listColumnDataProfiles($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Resource name of the organization or project, for + * example `organizations/433245324/locations/europe` or + * `projects/project-id/locations/asia`. + * @param array $optionalArgs { + * Optional. + * + * @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 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 $orderBy + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * + * Examples: + * * `project_id asc` + * * `table_id` + * * `sensitivity_level desc` + * + * Supported fields are: + * + * - `project_id`: The Google Cloud project ID. + * - `dataset_id`: The ID of a BigQuery dataset. + * - `table_id`: The ID of a BigQuery table. + * - `sensitivity_level`: How sensitive the data in a column is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * @type string $filter + * Allows filtering. + * + * Supported syntax: + * + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `table_data_profile_name` - The name of the related table data + * profile. + * - `project_id` - The Google Cloud project ID. (REQUIRED) + * - `dataset_id` - The BigQuery dataset ID. (REQUIRED) + * - `table_id` - The BigQuery table ID. (REQUIRED) + * - `field_id` - The ID of the BigQuery field. + * - `info_type` - The infotype detected in the resource. + * - `sensitivity_level` - HIGH|MEDIUM|LOW + * - `data_risk_level`: How much risk is associated with this data. + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` for project_id, dataset_id, and table_id. Other + * filters also support `!=`. + * + * Examples: + * + * * project_id = 12345 AND status_code = 1 + * * project_id = 12345 AND sensitivity_level = HIGH + * * project_id = 12345 AND info_type = STREET_ADDRESS + * + * The length of this field should be no more than 500 characters. + * @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 listColumnDataProfiles($parent, array $optionalArgs = []) + { + $request = new ListColumnDataProfilesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListColumnDataProfiles', $optionalArgs, ListColumnDataProfilesResponse::class, $request); + } + + /** + * Lists Connections in a parent. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->locationName('[PROJECT]', '[LOCATION]'); + * // Iterate over pages of elements + * $pagedResponse = $dlpServiceClient->listConnections($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $dlpServiceClient->listConnections($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent name, for example: + * `projects/project-id/locations/global`. + * @param array $optionalArgs { + * Optional. + * + * @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 string $filter + * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR + * @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 listConnections($parent, array $optionalArgs = []) + { + $request = new ListConnectionsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListConnections', $optionalArgs, ListConnectionsResponse::class, $request); + } + + /** + * Lists DeidentifyTemplates. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + * // Iterate over pages of elements + * $pagedResponse = $dlpServiceClient->listDeidentifyTemplates($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $dlpServiceClient->listDeidentifyTemplates($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param array $optionalArgs { + * Optional. + * + * @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 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 $orderBy + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * + * Example: `name asc,update_time, create_time desc` + * + * Supported fields are: + * + * - `create_time`: corresponds to the time the template was created. + * - `update_time`: corresponds to the time the template was last updated. + * - `name`: corresponds to the template's name. + * - `display_name`: corresponds to the template's display name. + * @type string $locationId + * Deprecated. This field has no effect. + * @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 listDeidentifyTemplates($parent, array $optionalArgs = []) + { + $request = new ListDeidentifyTemplatesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListDeidentifyTemplates', $optionalArgs, ListDeidentifyTemplatesResponse::class, $request); + } + + /** + * Lists discovery configurations. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->locationName('[PROJECT]', '[LOCATION]'); + * // Iterate over pages of elements + * $pagedResponse = $dlpServiceClient->listDiscoveryConfigs($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $dlpServiceClient->listDiscoveryConfigs($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value is as follows: + * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param array $optionalArgs { + * Optional. + * + * @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 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 $orderBy + * Comma separated list of config fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * + * Example: `name asc,update_time, create_time desc` + * + * Supported fields are: + * + * - `last_run_time`: corresponds to the last time the DiscoveryConfig ran. + * - `name`: corresponds to the DiscoveryConfig's name. + * - `status`: corresponds to DiscoveryConfig's status. + * @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 listDiscoveryConfigs($parent, array $optionalArgs = []) + { + $request = new ListDiscoveryConfigsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListDiscoveryConfigs', $optionalArgs, ListDiscoveryConfigsResponse::class, $request); + } + + /** + * Lists DlpJobs that match the specified filter in the request. + * See + * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage + * and + * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->projectName('[PROJECT]'); + * // Iterate over pages of elements + * $pagedResponse = $dlpServiceClient->listDlpJobs($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $dlpServiceClient->listDlpJobs($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * Allows filtering. + * + * Supported syntax: + * + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values for inspect jobs: + * - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED + * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY + * - `trigger_name` - The name of the trigger that created the job. + * - 'end_time` - Corresponds to the time the job finished. + * - 'start_time` - Corresponds to the time the job finished. + * * Supported fields for risk analysis jobs: + * - `state` - RUNNING|CANCELED|FINISHED|FAILED + * - 'end_time` - Corresponds to the time the job finished. + * - 'start_time` - Corresponds to the time the job finished. + * * The operator must be `=` or `!=`. + * + * Examples: + * + * * inspected_storage = cloud_storage AND state = done + * * inspected_storage = cloud_storage OR inspected_storage = bigquery + * * inspected_storage = cloud_storage AND (state = done OR state = canceled) + * * end_time > \"2017-12-12T00:00:00+00:00\" + * + * The length of this field should be no more than 500 characters. + * @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 int $type + * The type of job. Defaults to `DlpJobType.INSPECT` + * For allowed values, use constants defined on {@see \Google\Cloud\Dlp\V2\DlpJobType} + * @type string $orderBy + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * + * Example: `name asc, end_time asc, create_time desc` + * + * Supported fields are: + * + * - `create_time`: corresponds to the time the job was created. + * - `end_time`: corresponds to the time the job ended. + * - `name`: corresponds to the job's name. + * - `state`: corresponds to `state` + * @type string $locationId + * Deprecated. This field has no effect. + * @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 listDlpJobs($parent, array $optionalArgs = []) + { + $request = new ListDlpJobsRequest(); + $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']); + } + + if (isset($optionalArgs['type'])) { + $request->setType($optionalArgs['type']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListDlpJobs', $optionalArgs, ListDlpJobsResponse::class, $request); + } + + /** + * Returns a list of the sensitive information types that DLP API + * supports. See + * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $response = $dlpServiceClient->listInfoTypes(); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param array $optionalArgs { + * Optional. + * + * @type string $parent + * The parent resource name. + * + * The format of this value is as follows: + * + * locations/LOCATION_ID + * @type string $languageCode + * BCP-47 language code for localized infoType friendly + * names. If omitted, or if localized strings are not available, + * en-US strings will be returned. + * @type string $filter + * filter to only return infoTypes supported by certain parts of the + * API. Defaults to supported_by=INSPECT. + * @type string $locationId + * Deprecated. This field has no effect. + * @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\Cloud\Dlp\V2\ListInfoTypesResponse + * + * @throws ApiException if the remote call fails + */ + public function listInfoTypes(array $optionalArgs = []) + { + $request = new ListInfoTypesRequest(); + $requestParamHeaders = []; + if (isset($optionalArgs['parent'])) { + $request->setParent($optionalArgs['parent']); + $requestParamHeaders['parent'] = $optionalArgs['parent']; + } + + if (isset($optionalArgs['languageCode'])) { + $request->setLanguageCode($optionalArgs['languageCode']); + } + + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('ListInfoTypes', ListInfoTypesResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Lists InspectTemplates. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + * // Iterate over pages of elements + * $pagedResponse = $dlpServiceClient->listInspectTemplates($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $dlpServiceClient->listInspectTemplates($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + Organizations scope, location specified:
+ * `organizations/`ORG_ID`/locations/`LOCATION_ID + * + Organizations scope, no location specified (defaults to global):
+ * `organizations/`ORG_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param array $optionalArgs { + * Optional. + * + * @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 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 $orderBy + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * + * Example: `name asc,update_time, create_time desc` + * + * Supported fields are: + * + * - `create_time`: corresponds to the time the template was created. + * - `update_time`: corresponds to the time the template was last updated. + * - `name`: corresponds to the template's name. + * - `display_name`: corresponds to the template's display name. + * @type string $locationId + * Deprecated. This field has no effect. + * @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 listInspectTemplates($parent, array $optionalArgs = []) + { + $request = new ListInspectTemplatesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListInspectTemplates', $optionalArgs, ListInspectTemplatesResponse::class, $request); + } + + /** + * Lists job triggers. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->projectName('[PROJECT]'); + * // Iterate over pages of elements + * $pagedResponse = $dlpServiceClient->listJobTriggers($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $dlpServiceClient->listJobTriggers($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param array $optionalArgs { + * Optional. + * + * @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 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 $orderBy + * Comma separated list of triggeredJob fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * + * Example: `name asc,update_time, create_time desc` + * + * Supported fields are: + * + * - `create_time`: corresponds to the time the JobTrigger was created. + * - `update_time`: corresponds to the time the JobTrigger was last updated. + * - `last_run_time`: corresponds to the last time the JobTrigger ran. + * - `name`: corresponds to the JobTrigger's name. + * - `display_name`: corresponds to the JobTrigger's display name. + * - `status`: corresponds to JobTrigger's status. + * @type string $filter + * Allows filtering. + * + * Supported syntax: + * + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values for inspect triggers: + * - `status` - HEALTHY|PAUSED|CANCELLED + * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY + * - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by + * quotation marks. Nanoseconds are ignored. + * - 'error_count' - Number of errors that have occurred while running. + * * The operator must be `=` or `!=` for status and inspected_storage. + * + * Examples: + * + * * inspected_storage = cloud_storage AND status = HEALTHY + * * inspected_storage = cloud_storage OR inspected_storage = bigquery + * * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) + * * last_run_time > \"2017-12-12T00:00:00+00:00\" + * + * The length of this field should be no more than 500 characters. + * @type int $type + * The type of jobs. Will use `DlpJobType.INSPECT` if not set. + * For allowed values, use constants defined on {@see \Google\Cloud\Dlp\V2\DlpJobType} + * @type string $locationId + * Deprecated. This field has no effect. + * @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 listJobTriggers($parent, array $optionalArgs = []) + { + $request = new ListJobTriggersRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['type'])) { + $request->setType($optionalArgs['type']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListJobTriggers', $optionalArgs, ListJobTriggersResponse::class, $request); + } + + /** + * Lists project data profiles for an organization. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + * // Iterate over pages of elements + * $pagedResponse = $dlpServiceClient->listProjectDataProfiles($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $dlpServiceClient->listProjectDataProfiles($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. organizations/{org_id}/locations/{loc_id} + * @param array $optionalArgs { + * Optional. + * + * @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 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 $orderBy + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * + * Examples: + * * `project_id` + * * `sensitivity_level desc` + * + * Supported fields are: + * + * - `project_id`: Google Cloud project ID + * - `sensitivity_level`: How sensitive the data in a project is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * @type string $filter + * Allows filtering. + * + * Supported syntax: + * + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `sensitivity_level` - HIGH|MODERATE|LOW + * - `data_risk_level` - HIGH|MODERATE|LOW + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` or `!=`. + * + * Examples: + * + * * `project_id = 12345 AND status_code = 1` + * * `project_id = 12345 AND sensitivity_level = HIGH` + * + * The length of this field should be no more than 500 characters. + * @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 listProjectDataProfiles($parent, array $optionalArgs = []) + { + $request = new ListProjectDataProfilesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListProjectDataProfiles', $optionalArgs, ListProjectDataProfilesResponse::class, $request); + } + + /** + * Lists stored infoTypes. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + * // Iterate over pages of elements + * $pagedResponse = $dlpServiceClient->listStoredInfoTypes($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $dlpServiceClient->listStoredInfoTypes($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on the scope of the request + * (project or organization) and whether you have [specified a processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param array $optionalArgs { + * Optional. + * + * @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 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 $orderBy + * Comma separated list of fields to order by, + * followed by `asc` or `desc` postfix. This list is case insensitive. The + * default sorting order is ascending. Redundant space characters are + * insignificant. + * + * Example: `name asc, display_name, create_time desc` + * + * Supported fields are: + * + * - `create_time`: corresponds to the time the most recent version of the + * resource was created. + * - `state`: corresponds to the state of the resource. + * - `name`: corresponds to resource name. + * - `display_name`: corresponds to info type's display name. + * @type string $locationId + * Deprecated. This field has no effect. + * @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 listStoredInfoTypes($parent, array $optionalArgs = []) + { + $request = new ListStoredInfoTypesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListStoredInfoTypes', $optionalArgs, ListStoredInfoTypesResponse::class, $request); + } + + /** + * Lists table data profiles for an organization. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + * // Iterate over pages of elements + * $pagedResponse = $dlpServiceClient->listTableDataProfiles($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $dlpServiceClient->listTableDataProfiles($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Resource name of the organization or project, for + * example `organizations/433245324/locations/europe` or + * `projects/project-id/locations/asia`. + * @param array $optionalArgs { + * Optional. + * + * @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 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 $orderBy + * Comma separated list of fields to order by, followed by `asc` or `desc` + * postfix. This list is case insensitive. The default sorting order is + * ascending. Redundant space characters are insignificant. Only one order + * field at a time is allowed. + * + * Examples: + * * `project_id asc` + * * `table_id` + * * `sensitivity_level desc` + * + * Supported fields are: + * + * - `project_id`: The Google Cloud project ID. + * - `dataset_id`: The ID of a BigQuery dataset. + * - `table_id`: The ID of a BigQuery table. + * - `sensitivity_level`: How sensitive the data in a table is, at most. + * - `data_risk_level`: How much risk is associated with this data. + * - `profile_last_generated`: When the profile was last updated in epoch + * seconds. + * - `last_modified`: The last time the resource was modified. + * - `resource_visibility`: Visibility restriction for this resource. + * - `row_count`: Number of rows in this resource. + * @type string $filter + * Allows filtering. + * + * Supported syntax: + * + * * Filter expressions are made up of one or more restrictions. + * * Restrictions can be combined by `AND` or `OR` logical operators. A + * sequence of restrictions implicitly uses `AND`. + * * A restriction has the form of `{field} {operator} {value}`. + * * Supported fields/values: + * - `project_id` - The Google Cloud project ID. + * - `dataset_id` - The BigQuery dataset ID. + * - `table_id` - The ID of the BigQuery table. + * - `sensitivity_level` - HIGH|MODERATE|LOW + * - `data_risk_level` - HIGH|MODERATE|LOW + * - `resource_visibility`: PUBLIC|RESTRICTED + * - `status_code` - an RPC status code as defined in + * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto + * * The operator must be `=` or `!=`. + * + * Examples: + * + * * `project_id = 12345 AND status_code = 1` + * * `project_id = 12345 AND sensitivity_level = HIGH` + * * `project_id = 12345 AND resource_visibility = PUBLIC` + * + * The length of this field should be no more than 500 characters. + * @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 listTableDataProfiles($parent, array $optionalArgs = []) + { + $request = new ListTableDataProfilesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListTableDataProfiles', $optionalArgs, ListTableDataProfilesResponse::class, $request); + } + + /** + * Redacts potentially sensitive info from an image. + * This method has limits on input size, processing time, and output size. + * See + * https://cloud.google.com/sensitive-data-protection/docs/redacting-sensitive-data-images + * to learn more. + * + * When no InfoTypes or CustomInfoTypes are specified in this request, the + * system will automatically choose what detectors to run. By default this may + * be all types, but may change over time as detectors are updated. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $response = $dlpServiceClient->redactImage(); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param array $optionalArgs { + * Optional. + * + * @type string $parent + * Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @type string $locationId + * Deprecated. This field has no effect. + * @type InspectConfig $inspectConfig + * Configuration for the inspector. + * @type ImageRedactionConfig[] $imageRedactionConfigs + * The configuration for specifying what content to redact from images. + * @type bool $includeFindings + * Whether the response should include findings along with the redacted + * image. + * @type ByteContentItem $byteItem + * The content must be PNG, JPEG, SVG or BMP. + * @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\Cloud\Dlp\V2\RedactImageResponse + * + * @throws ApiException if the remote call fails + */ + public function redactImage(array $optionalArgs = []) + { + $request = new RedactImageRequest(); + $requestParamHeaders = []; + if (isset($optionalArgs['parent'])) { + $request->setParent($optionalArgs['parent']); + $requestParamHeaders['parent'] = $optionalArgs['parent']; + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + if (isset($optionalArgs['inspectConfig'])) { + $request->setInspectConfig($optionalArgs['inspectConfig']); + } + + if (isset($optionalArgs['imageRedactionConfigs'])) { + $request->setImageRedactionConfigs($optionalArgs['imageRedactionConfigs']); + } + + if (isset($optionalArgs['includeFindings'])) { + $request->setIncludeFindings($optionalArgs['includeFindings']); + } + + if (isset($optionalArgs['byteItem'])) { + $request->setByteItem($optionalArgs['byteItem']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('RedactImage', RedactImageResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Re-identifies content that has been de-identified. + * See + * https://cloud.google.com/sensitive-data-protection/docs/pseudonymization#re-identification_in_free_text_code_example + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->projectName('[PROJECT]'); + * $response = $dlpServiceClient->reidentifyContent($formattedParent); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent resource name. + * + * The format of this value varies depending on whether you have [specified a + * processing + * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + * + * + Projects scope, location specified:
+ * `projects/`PROJECT_ID`/locations/`LOCATION_ID + * + Projects scope, no location specified (defaults to global):
+ * `projects/`PROJECT_ID + * + * The following example `parent` string specifies a parent project with the + * identifier `example-project`, and specifies the `europe-west3` location + * for processing data: + * + * parent=projects/example-project/locations/europe-west3 + * @param array $optionalArgs { + * Optional. + * + * @type DeidentifyConfig $reidentifyConfig + * Configuration for the re-identification of the content item. + * This field shares the same proto message type that is used for + * de-identification, however its usage here is for the reversal of the + * previous de-identification. Re-identification is performed by examining + * the transformations used to de-identify the items and executing the + * reverse. This requires that only reversible transformations + * be provided here. The reversible transformations are: + * + * - `CryptoDeterministicConfig` + * - `CryptoReplaceFfxFpeConfig` + * @type InspectConfig $inspectConfig + * Configuration for the inspector. + * @type ContentItem $item + * The item to re-identify. Will be treated as text. + * @type string $inspectTemplateName + * Template to use. Any configuration directly specified in + * `inspect_config` will override those set in the template. Singular fields + * that are set in this request will replace their corresponding fields in the + * template. Repeated fields are appended. Singular sub-messages and groups + * are recursively merged. + * @type string $reidentifyTemplateName + * Template to use. References an instance of `DeidentifyTemplate`. + * Any configuration directly specified in `reidentify_config` or + * `inspect_config` will override those set in the template. The + * `DeidentifyTemplate` used must include only reversible transformations. + * Singular fields that are set in this request will replace their + * corresponding fields in the template. Repeated fields are appended. + * Singular sub-messages and groups are recursively merged. + * @type string $locationId + * Deprecated. This field has no effect. + * @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\Cloud\Dlp\V2\ReidentifyContentResponse + * + * @throws ApiException if the remote call fails + */ + public function reidentifyContent($parent, array $optionalArgs = []) + { + $request = new ReidentifyContentRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['reidentifyConfig'])) { + $request->setReidentifyConfig($optionalArgs['reidentifyConfig']); + } + + if (isset($optionalArgs['inspectConfig'])) { + $request->setInspectConfig($optionalArgs['inspectConfig']); + } + + if (isset($optionalArgs['item'])) { + $request->setItem($optionalArgs['item']); + } + + if (isset($optionalArgs['inspectTemplateName'])) { + $request->setInspectTemplateName($optionalArgs['inspectTemplateName']); + } + + if (isset($optionalArgs['reidentifyTemplateName'])) { + $request->setReidentifyTemplateName($optionalArgs['reidentifyTemplateName']); + } + + if (isset($optionalArgs['locationId'])) { + $request->setLocationId($optionalArgs['locationId']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('ReidentifyContent', ReidentifyContentResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Searches for Connections in a parent. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedParent = $dlpServiceClient->locationName('[PROJECT]', '[LOCATION]'); + * // Iterate over pages of elements + * $pagedResponse = $dlpServiceClient->searchConnections($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $dlpServiceClient->searchConnections($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $parent Required. Parent name, typically an organization, without location. + * For example: `organizations/12345678`. + * @param array $optionalArgs { + * Optional. + * + * @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 string $filter + * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR + * @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 searchConnections($parent, array $optionalArgs = []) + { + $request = new SearchConnectionsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('SearchConnections', $optionalArgs, SearchConnectionsResponse::class, $request); + } + + /** + * Update a Connection. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + * $connection = new Connection(); + * $response = $dlpServiceClient->updateConnection($formattedName, $connection); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name in the format: + * `projects/{project}/locations/{location}/connections/{connection}`. + * @param Connection $connection Required. The connection with new values for the relevant fields. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * Optional. Mask to control which fields get updated. + * @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\Cloud\Dlp\V2\Connection + * + * @throws ApiException if the remote call fails + */ + public function updateConnection($name, $connection, array $optionalArgs = []) + { + $request = new UpdateConnectionRequest(); + $requestParamHeaders = []; + $request->setName($name); + $request->setConnection($connection); + $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('UpdateConnection', Connection::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates the DeidentifyTemplate. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + * $response = $dlpServiceClient->updateDeidentifyTemplate($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of organization and deidentify template to be + * updated, for example + * `organizations/433245324/deidentifyTemplates/432452342` or + * projects/project-id/deidentifyTemplates/432452342. + * @param array $optionalArgs { + * Optional. + * + * @type DeidentifyTemplate $deidentifyTemplate + * New DeidentifyTemplate value. + * @type FieldMask $updateMask + * Mask to control which fields get updated. + * @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\Cloud\Dlp\V2\DeidentifyTemplate + * + * @throws ApiException if the remote call fails + */ + public function updateDeidentifyTemplate($name, array $optionalArgs = []) + { + $request = new UpdateDeidentifyTemplateRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['deidentifyTemplate'])) { + $request->setDeidentifyTemplate($optionalArgs['deidentifyTemplate']); + } + + 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('UpdateDeidentifyTemplate', DeidentifyTemplate::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates a discovery configuration. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + * $discoveryConfig = new DiscoveryConfig(); + * $response = $dlpServiceClient->updateDiscoveryConfig($formattedName, $discoveryConfig); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the project and the configuration, for example + * `projects/dlp-test-project/discoveryConfigs/53234423`. + * @param DiscoveryConfig $discoveryConfig Required. New DiscoveryConfig value. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * Mask to control which fields get updated. + * @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\Cloud\Dlp\V2\DiscoveryConfig + * + * @throws ApiException if the remote call fails + */ + public function updateDiscoveryConfig($name, $discoveryConfig, array $optionalArgs = []) + { + $request = new UpdateDiscoveryConfigRequest(); + $requestParamHeaders = []; + $request->setName($name); + $request->setDiscoveryConfig($discoveryConfig); + $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('UpdateDiscoveryConfig', DiscoveryConfig::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates the InspectTemplate. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-templates + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + * $response = $dlpServiceClient->updateInspectTemplate($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of organization and inspectTemplate to be updated, + * for example `organizations/433245324/inspectTemplates/432452342` or + * projects/project-id/inspectTemplates/432452342. + * @param array $optionalArgs { + * Optional. + * + * @type InspectTemplate $inspectTemplate + * New InspectTemplate value. + * @type FieldMask $updateMask + * Mask to control which fields get updated. + * @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\Cloud\Dlp\V2\InspectTemplate + * + * @throws ApiException if the remote call fails + */ + public function updateInspectTemplate($name, array $optionalArgs = []) + { + $request = new UpdateInspectTemplateRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['inspectTemplate'])) { + $request->setInspectTemplate($optionalArgs['inspectTemplate']); + } + + 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('UpdateInspectTemplate', InspectTemplate::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates a job trigger. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + * $response = $dlpServiceClient->updateJobTrigger($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of the project and the triggeredJob, for example + * `projects/dlp-test-project/jobTriggers/53234423`. + * @param array $optionalArgs { + * Optional. + * + * @type JobTrigger $jobTrigger + * New JobTrigger value. + * @type FieldMask $updateMask + * Mask to control which fields get updated. + * @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\Cloud\Dlp\V2\JobTrigger + * + * @throws ApiException if the remote call fails + */ + public function updateJobTrigger($name, array $optionalArgs = []) + { + $request = new UpdateJobTriggerRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['jobTrigger'])) { + $request->setJobTrigger($optionalArgs['jobTrigger']); + } + + 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('UpdateJobTrigger', JobTrigger::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates the stored infoType by creating a new version. The existing version + * will continue to be used until the new version is ready. + * See + * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes + * to learn more. + * + * Sample code: + * ``` + * $dlpServiceClient = new DlpServiceClient(); + * try { + * $formattedName = $dlpServiceClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + * $response = $dlpServiceClient->updateStoredInfoType($formattedName); + * } finally { + * $dlpServiceClient->close(); + * } + * ``` + * + * @param string $name Required. Resource name of organization and storedInfoType to be updated, + * for example `organizations/433245324/storedInfoTypes/432452342` or + * projects/project-id/storedInfoTypes/432452342. + * @param array $optionalArgs { + * Optional. + * + * @type StoredInfoTypeConfig $config + * Updated configuration for the storedInfoType. If not provided, a new + * version of the storedInfoType will be created with the existing + * configuration. + * @type FieldMask $updateMask + * Mask to control which fields get updated. + * @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\Cloud\Dlp\V2\StoredInfoType + * + * @throws ApiException if the remote call fails + */ + public function updateStoredInfoType($name, array $optionalArgs = []) + { + $request = new UpdateStoredInfoTypeRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['config'])) { + $request->setConfig($optionalArgs['config']); + } + + 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('UpdateStoredInfoType', StoredInfoType::class, $optionalArgs, $request)->wait(); + } +} diff --git a/owl-bot-staging/Dlp/v2/src/V2/gapic_metadata.json b/owl-bot-staging/Dlp/v2/src/V2/gapic_metadata.json new file mode 100644 index 000000000000..57d81805f598 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/src/V2/gapic_metadata.json @@ -0,0 +1,278 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", + "language": "php", + "protoPackage": "google.privacy.dlp.v2", + "libraryPackage": "Google\\Cloud\\Dlp\\V2", + "services": { + "DlpService": { + "clients": { + "grpc": { + "libraryClient": "DlpServiceGapicClient", + "rpcs": { + "ActivateJobTrigger": { + "methods": [ + "activateJobTrigger" + ] + }, + "CancelDlpJob": { + "methods": [ + "cancelDlpJob" + ] + }, + "CreateConnection": { + "methods": [ + "createConnection" + ] + }, + "CreateDeidentifyTemplate": { + "methods": [ + "createDeidentifyTemplate" + ] + }, + "CreateDiscoveryConfig": { + "methods": [ + "createDiscoveryConfig" + ] + }, + "CreateDlpJob": { + "methods": [ + "createDlpJob" + ] + }, + "CreateInspectTemplate": { + "methods": [ + "createInspectTemplate" + ] + }, + "CreateJobTrigger": { + "methods": [ + "createJobTrigger" + ] + }, + "CreateStoredInfoType": { + "methods": [ + "createStoredInfoType" + ] + }, + "DeidentifyContent": { + "methods": [ + "deidentifyContent" + ] + }, + "DeleteConnection": { + "methods": [ + "deleteConnection" + ] + }, + "DeleteDeidentifyTemplate": { + "methods": [ + "deleteDeidentifyTemplate" + ] + }, + "DeleteDiscoveryConfig": { + "methods": [ + "deleteDiscoveryConfig" + ] + }, + "DeleteDlpJob": { + "methods": [ + "deleteDlpJob" + ] + }, + "DeleteInspectTemplate": { + "methods": [ + "deleteInspectTemplate" + ] + }, + "DeleteJobTrigger": { + "methods": [ + "deleteJobTrigger" + ] + }, + "DeleteStoredInfoType": { + "methods": [ + "deleteStoredInfoType" + ] + }, + "DeleteTableDataProfile": { + "methods": [ + "deleteTableDataProfile" + ] + }, + "FinishDlpJob": { + "methods": [ + "finishDlpJob" + ] + }, + "GetColumnDataProfile": { + "methods": [ + "getColumnDataProfile" + ] + }, + "GetConnection": { + "methods": [ + "getConnection" + ] + }, + "GetDeidentifyTemplate": { + "methods": [ + "getDeidentifyTemplate" + ] + }, + "GetDiscoveryConfig": { + "methods": [ + "getDiscoveryConfig" + ] + }, + "GetDlpJob": { + "methods": [ + "getDlpJob" + ] + }, + "GetInspectTemplate": { + "methods": [ + "getInspectTemplate" + ] + }, + "GetJobTrigger": { + "methods": [ + "getJobTrigger" + ] + }, + "GetProjectDataProfile": { + "methods": [ + "getProjectDataProfile" + ] + }, + "GetStoredInfoType": { + "methods": [ + "getStoredInfoType" + ] + }, + "GetTableDataProfile": { + "methods": [ + "getTableDataProfile" + ] + }, + "HybridInspectDlpJob": { + "methods": [ + "hybridInspectDlpJob" + ] + }, + "HybridInspectJobTrigger": { + "methods": [ + "hybridInspectJobTrigger" + ] + }, + "InspectContent": { + "methods": [ + "inspectContent" + ] + }, + "ListColumnDataProfiles": { + "methods": [ + "listColumnDataProfiles" + ] + }, + "ListConnections": { + "methods": [ + "listConnections" + ] + }, + "ListDeidentifyTemplates": { + "methods": [ + "listDeidentifyTemplates" + ] + }, + "ListDiscoveryConfigs": { + "methods": [ + "listDiscoveryConfigs" + ] + }, + "ListDlpJobs": { + "methods": [ + "listDlpJobs" + ] + }, + "ListInfoTypes": { + "methods": [ + "listInfoTypes" + ] + }, + "ListInspectTemplates": { + "methods": [ + "listInspectTemplates" + ] + }, + "ListJobTriggers": { + "methods": [ + "listJobTriggers" + ] + }, + "ListProjectDataProfiles": { + "methods": [ + "listProjectDataProfiles" + ] + }, + "ListStoredInfoTypes": { + "methods": [ + "listStoredInfoTypes" + ] + }, + "ListTableDataProfiles": { + "methods": [ + "listTableDataProfiles" + ] + }, + "RedactImage": { + "methods": [ + "redactImage" + ] + }, + "ReidentifyContent": { + "methods": [ + "reidentifyContent" + ] + }, + "SearchConnections": { + "methods": [ + "searchConnections" + ] + }, + "UpdateConnection": { + "methods": [ + "updateConnection" + ] + }, + "UpdateDeidentifyTemplate": { + "methods": [ + "updateDeidentifyTemplate" + ] + }, + "UpdateDiscoveryConfig": { + "methods": [ + "updateDiscoveryConfig" + ] + }, + "UpdateInspectTemplate": { + "methods": [ + "updateInspectTemplate" + ] + }, + "UpdateJobTrigger": { + "methods": [ + "updateJobTrigger" + ] + }, + "UpdateStoredInfoType": { + "methods": [ + "updateStoredInfoType" + ] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_client_config.json b/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_client_config.json new file mode 100644 index 000000000000..78363c7bd2aa --- /dev/null +++ b/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_client_config.json @@ -0,0 +1,305 @@ +{ + "interfaces": { + "google.privacy.dlp.v2.DlpService": { + "retry_codes": { + "no_retry_codes": [], + "retry_policy_1_codes": [ + "UNAVAILABLE", + "DEADLINE_EXCEEDED" + ], + "no_retry_1_codes": [] + }, + "retry_params": { + "no_retry_params": { + "initial_retry_delay_millis": 0, + "retry_delay_multiplier": 0.0, + "max_retry_delay_millis": 0, + "initial_rpc_timeout_millis": 0, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 0, + "total_timeout_millis": 0 + }, + "retry_policy_1_params": { + "initial_retry_delay_millis": 100, + "retry_delay_multiplier": 1.3, + "max_retry_delay_millis": 60000, + "initial_rpc_timeout_millis": 300000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 300000, + "total_timeout_millis": 300000 + }, + "no_retry_1_params": { + "initial_retry_delay_millis": 0, + "retry_delay_multiplier": 0.0, + "max_retry_delay_millis": 0, + "initial_rpc_timeout_millis": 300000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 300000, + "total_timeout_millis": 300000 + } + }, + "methods": { + "ActivateJobTrigger": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "CancelDlpJob": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "CreateConnection": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_codes", + "retry_params_name": "no_retry_params" + }, + "CreateDeidentifyTemplate": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "CreateDiscoveryConfig": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "CreateDlpJob": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "CreateInspectTemplate": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "CreateJobTrigger": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "CreateStoredInfoType": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "DeidentifyContent": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeleteConnection": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_codes", + "retry_params_name": "no_retry_params" + }, + "DeleteDeidentifyTemplate": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeleteDiscoveryConfig": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeleteDlpJob": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeleteInspectTemplate": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeleteJobTrigger": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeleteStoredInfoType": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeleteTableDataProfile": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_codes", + "retry_params_name": "no_retry_params" + }, + "FinishDlpJob": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "GetColumnDataProfile": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetConnection": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_codes", + "retry_params_name": "no_retry_params" + }, + "GetDeidentifyTemplate": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetDiscoveryConfig": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetDlpJob": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetInspectTemplate": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetJobTrigger": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetProjectDataProfile": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetStoredInfoType": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetTableDataProfile": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "HybridInspectDlpJob": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "HybridInspectJobTrigger": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "InspectContent": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListColumnDataProfiles": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListConnections": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_codes", + "retry_params_name": "no_retry_params" + }, + "ListDeidentifyTemplates": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListDiscoveryConfigs": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListDlpJobs": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListInfoTypes": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListInspectTemplates": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListJobTriggers": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListProjectDataProfiles": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListStoredInfoTypes": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListTableDataProfiles": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "RedactImage": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ReidentifyContent": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "SearchConnections": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_codes", + "retry_params_name": "no_retry_params" + }, + "UpdateConnection": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_codes", + "retry_params_name": "no_retry_params" + }, + "UpdateDeidentifyTemplate": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "UpdateDiscoveryConfig": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "UpdateInspectTemplate": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "UpdateJobTrigger": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "UpdateStoredInfoType": { + "timeout_millis": 300000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + } + } + } + } +} diff --git a/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_descriptor_config.php b/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_descriptor_config.php new file mode 100644 index 000000000000..0ce9d36ad4b5 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_descriptor_config.php @@ -0,0 +1,778 @@ + [ + 'google.privacy.dlp.v2.DlpService' => [ + 'ActivateJobTrigger' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\DlpJob', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'CancelDlpJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'CreateConnection' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\Connection', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateDeidentifyTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\DeidentifyTemplate', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateDiscoveryConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\DiscoveryConfig', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateDlpJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\DlpJob', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateInspectTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\InspectTemplate', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateJobTrigger' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\JobTrigger', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateStoredInfoType' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\StoredInfoType', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeidentifyContent' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\DeidentifyContentResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteConnection' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteDeidentifyTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteDiscoveryConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteDlpJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteInspectTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteJobTrigger' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteStoredInfoType' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteTableDataProfile' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'FinishDlpJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetColumnDataProfile' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ColumnDataProfile', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetConnection' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\Connection', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetDeidentifyTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\DeidentifyTemplate', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetDiscoveryConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\DiscoveryConfig', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetDlpJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\DlpJob', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetInspectTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\InspectTemplate', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetJobTrigger' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\JobTrigger', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetProjectDataProfile' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ProjectDataProfile', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetStoredInfoType' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\StoredInfoType', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetTableDataProfile' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\TableDataProfile', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'HybridInspectDlpJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\HybridInspectResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'HybridInspectJobTrigger' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\HybridInspectResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'InspectContent' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\InspectContentResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListColumnDataProfiles' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getColumnDataProfiles', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ListColumnDataProfilesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListConnections' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getConnections', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ListConnectionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListDeidentifyTemplates' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getDeidentifyTemplates', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ListDeidentifyTemplatesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListDiscoveryConfigs' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getDiscoveryConfigs', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ListDiscoveryConfigsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListDlpJobs' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getJobs', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ListDlpJobsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListInfoTypes' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ListInfoTypesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListInspectTemplates' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getInspectTemplates', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ListInspectTemplatesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListJobTriggers' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getJobTriggers', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ListJobTriggersResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListProjectDataProfiles' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getProjectDataProfiles', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ListProjectDataProfilesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListStoredInfoTypes' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getStoredInfoTypes', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ListStoredInfoTypesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListTableDataProfiles' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getTableDataProfiles', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ListTableDataProfilesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'RedactImage' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\RedactImageResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ReidentifyContent' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\ReidentifyContentResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'SearchConnections' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getConnections', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\SearchConnectionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'UpdateConnection' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\Connection', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateDeidentifyTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\DeidentifyTemplate', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateDiscoveryConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\DiscoveryConfig', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateInspectTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\InspectTemplate', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateJobTrigger' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\JobTrigger', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateStoredInfoType' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dlp\V2\StoredInfoType', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'templateMap' => [ + 'columnDataProfile' => 'organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}', + 'connection' => 'projects/{project}/locations/{location}/connections/{connection}', + 'deidentifyTemplate' => 'organizations/{organization}/deidentifyTemplates/{deidentify_template}', + 'discoveryConfig' => 'projects/{project}/locations/{location}/discoveryConfigs/{discovery_config}', + 'dlpJob' => 'projects/{project}/dlpJobs/{dlp_job}', + 'inspectTemplate' => 'organizations/{organization}/inspectTemplates/{inspect_template}', + 'jobTrigger' => 'projects/{project}/jobTriggers/{job_trigger}', + 'location' => 'projects/{project}/locations/{location}', + 'organization' => 'organizations/{organization}', + 'organizationDeidentifyTemplate' => 'organizations/{organization}/deidentifyTemplates/{deidentify_template}', + 'organizationInspectTemplate' => 'organizations/{organization}/inspectTemplates/{inspect_template}', + 'organizationLocation' => 'organizations/{organization}/locations/{location}', + 'organizationLocationColumnDataProfile' => 'organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}', + 'organizationLocationDeidentifyTemplate' => 'organizations/{organization}/locations/{location}/deidentifyTemplates/{deidentify_template}', + 'organizationLocationInspectTemplate' => 'organizations/{organization}/locations/{location}/inspectTemplates/{inspect_template}', + 'organizationLocationProjectDataProfile' => 'organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile}', + 'organizationLocationStoredInfoType' => 'organizations/{organization}/locations/{location}/storedInfoTypes/{stored_info_type}', + 'organizationLocationTableDataProfile' => 'organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile}', + 'organizationStoredInfoType' => 'organizations/{organization}/storedInfoTypes/{stored_info_type}', + 'project' => 'projects/{project}', + 'projectDataProfile' => 'organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile}', + 'projectDeidentifyTemplate' => 'projects/{project}/deidentifyTemplates/{deidentify_template}', + 'projectDlpJob' => 'projects/{project}/dlpJobs/{dlp_job}', + 'projectInspectTemplate' => 'projects/{project}/inspectTemplates/{inspect_template}', + 'projectJobTrigger' => 'projects/{project}/jobTriggers/{job_trigger}', + 'projectLocationColumnDataProfile' => 'projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile}', + 'projectLocationDeidentifyTemplate' => 'projects/{project}/locations/{location}/deidentifyTemplates/{deidentify_template}', + 'projectLocationDlpJob' => 'projects/{project}/locations/{location}/dlpJobs/{dlp_job}', + 'projectLocationInspectTemplate' => 'projects/{project}/locations/{location}/inspectTemplates/{inspect_template}', + 'projectLocationJobTrigger' => 'projects/{project}/locations/{location}/jobTriggers/{job_trigger}', + 'projectLocationProjectDataProfile' => 'projects/{project}/locations/{location}/projectDataProfiles/{project_data_profile}', + 'projectLocationStoredInfoType' => 'projects/{project}/locations/{location}/storedInfoTypes/{stored_info_type}', + 'projectLocationTableDataProfile' => 'projects/{project}/locations/{location}/tableDataProfiles/{table_data_profile}', + 'projectStoredInfoType' => 'projects/{project}/storedInfoTypes/{stored_info_type}', + 'storedInfoType' => 'organizations/{organization}/storedInfoTypes/{stored_info_type}', + 'tableDataProfile' => 'organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile}', + ], + ], + ], +]; diff --git a/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_rest_client_config.php b/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_rest_client_config.php new file mode 100644 index 000000000000..e2def05b8c3b --- /dev/null +++ b/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_rest_client_config.php @@ -0,0 +1,1062 @@ + [ + 'google.privacy.dlp.v2.DlpService' => [ + 'ActivateJobTrigger' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/jobTriggers/*}:activate', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/jobTriggers/*}:activate', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'CancelDlpJob' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/dlpJobs/*}:cancel', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/dlpJobs/*}:cancel', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'CreateConnection' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/connections', + 'body' => '*', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateDeidentifyTemplate' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*}/deidentifyTemplates', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/deidentifyTemplates', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*}/deidentifyTemplates', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/deidentifyTemplates', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateDiscoveryConfig' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/discoveryConfigs', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/discoveryConfigs', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateDlpJob' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*}/dlpJobs', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/dlpJobs', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateInspectTemplate' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*}/inspectTemplates', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/inspectTemplates', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*}/inspectTemplates', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/inspectTemplates', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateJobTrigger' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*}/jobTriggers', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/jobTriggers', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/jobTriggers', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateStoredInfoType' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*}/storedInfoTypes', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/storedInfoTypes', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*}/storedInfoTypes', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/storedInfoTypes', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'DeidentifyContent' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*}/content:deidentify', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/content:deidentify', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteConnection' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/connections/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteDeidentifyTemplate' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/deidentifyTemplates/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/deidentifyTemplates/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/deidentifyTemplates/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/deidentifyTemplates/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteDiscoveryConfig' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/discoveryConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/discoveryConfigs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteDlpJob' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/dlpJobs/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/dlpJobs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteInspectTemplate' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/inspectTemplates/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/inspectTemplates/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/inspectTemplates/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/inspectTemplates/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteJobTrigger' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/jobTriggers/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/jobTriggers/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/jobTriggers/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteStoredInfoType' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/storedInfoTypes/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/storedInfoTypes/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/storedInfoTypes/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/storedInfoTypes/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteTableDataProfile' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/tableDataProfiles/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/tableDataProfiles/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'FinishDlpJob' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/dlpJobs/*}:finish', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetColumnDataProfile' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/columnDataProfiles/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/columnDataProfiles/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetConnection' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/connections/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetDeidentifyTemplate' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/deidentifyTemplates/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/deidentifyTemplates/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/deidentifyTemplates/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/deidentifyTemplates/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetDiscoveryConfig' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/discoveryConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/discoveryConfigs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetDlpJob' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/dlpJobs/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/dlpJobs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetInspectTemplate' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/inspectTemplates/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/inspectTemplates/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/inspectTemplates/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/inspectTemplates/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetJobTrigger' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/jobTriggers/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/jobTriggers/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/jobTriggers/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetProjectDataProfile' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/projectDataProfiles/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/projectDataProfiles/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetStoredInfoType' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/storedInfoTypes/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/storedInfoTypes/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/storedInfoTypes/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/storedInfoTypes/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetTableDataProfile' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/tableDataProfiles/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/tableDataProfiles/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'HybridInspectDlpJob' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/dlpJobs/*}:hybridInspect', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'HybridInspectJobTrigger' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/jobTriggers/*}:hybridInspect', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'InspectContent' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*}/content:inspect', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/content:inspect', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListColumnDataProfiles' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/columnDataProfiles', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/columnDataProfiles', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListConnections' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/connections', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListDeidentifyTemplates' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*}/deidentifyTemplates', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/deidentifyTemplates', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*}/deidentifyTemplates', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/deidentifyTemplates', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListDiscoveryConfigs' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/discoveryConfigs', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/discoveryConfigs', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListDlpJobs' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*}/dlpJobs', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/dlpJobs', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/dlpJobs', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListInfoTypes' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/infoTypes', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=locations/*}/infoTypes', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListInspectTemplates' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*}/inspectTemplates', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/inspectTemplates', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*}/inspectTemplates', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/inspectTemplates', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListJobTriggers' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*}/jobTriggers', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/jobTriggers', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/jobTriggers', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListProjectDataProfiles' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/projectDataProfiles', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/projectDataProfiles', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListStoredInfoTypes' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*}/storedInfoTypes', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/storedInfoTypes', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*}/storedInfoTypes', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/storedInfoTypes', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListTableDataProfiles' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/tableDataProfiles', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/tableDataProfiles', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'RedactImage' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*}/image:redact', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/image:redact', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ReidentifyContent' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*}/content:reidentify', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/content:reidentify', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'SearchConnections' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/connections:search', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/connections:search', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'UpdateConnection' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/connections/*}', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UpdateDeidentifyTemplate' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=organizations/*/deidentifyTemplates/*}', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/deidentifyTemplates/*}', + 'body' => '*', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=projects/*/deidentifyTemplates/*}', + 'body' => '*', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/deidentifyTemplates/*}', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UpdateDiscoveryConfig' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/discoveryConfigs/*}', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/discoveryConfigs/*}', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UpdateInspectTemplate' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=organizations/*/inspectTemplates/*}', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/inspectTemplates/*}', + 'body' => '*', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=projects/*/inspectTemplates/*}', + 'body' => '*', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/inspectTemplates/*}', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UpdateJobTrigger' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=projects/*/jobTriggers/*}', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/jobTriggers/*}', + 'body' => '*', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/jobTriggers/*}', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UpdateStoredInfoType' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=organizations/*/storedInfoTypes/*}', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/storedInfoTypes/*}', + 'body' => '*', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=projects/*/storedInfoTypes/*}', + 'body' => '*', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/storedInfoTypes/*}', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + ], + ], + 'numericEnums' => true, +]; diff --git a/owl-bot-staging/Dlp/v2/tests/Unit/V2/Client/DlpServiceClientTest.php b/owl-bot-staging/Dlp/v2/tests/Unit/V2/Client/DlpServiceClientTest.php new file mode 100644 index 000000000000..8679243ae398 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/tests/Unit/V2/Client/DlpServiceClientTest.php @@ -0,0 +1,3672 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return DlpServiceClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new DlpServiceClient($options); + } + + /** @test */ + public function activateJobTriggerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $jobTriggerName = 'jobTriggerName1819490804'; + $expectedResponse = new DlpJob(); + $expectedResponse->setName($name2); + $expectedResponse->setJobTriggerName($jobTriggerName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $request = (new ActivateJobTriggerRequest()) + ->setName($formattedName); + $response = $gapicClient->activateJobTrigger($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ActivateJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function activateJobTriggerExceptionTest() + { + $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $request = (new ActivateJobTriggerRequest()) + ->setName($formattedName); + try { + $gapicClient->activateJobTrigger($request); + // 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 cancelDlpJobTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $request = (new CancelDlpJobRequest()) + ->setName($formattedName); + $gapicClient->cancelDlpJob($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CancelDlpJob', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function cancelDlpJobExceptionTest() + { + $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $request = (new CancelDlpJobRequest()) + ->setName($formattedName); + try { + $gapicClient->cancelDlpJob($request); + // 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 createConnectionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $expectedResponse = new Connection(); + $expectedResponse->setName($name); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $connection = new Connection(); + $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; + $connection->setState($connectionState); + $request = (new CreateConnectionRequest()) + ->setParent($formattedParent) + ->setConnection($connection); + $response = $gapicClient->createConnection($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateConnection', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getConnection(); + $this->assertProtobufEquals($connection, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createConnectionExceptionTest() + { + $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->locationName('[PROJECT]', '[LOCATION]'); + $connection = new Connection(); + $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; + $connection->setState($connectionState); + $request = (new CreateConnectionRequest()) + ->setParent($formattedParent) + ->setConnection($connection); + try { + $gapicClient->createConnection($request); + // 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 createDeidentifyTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new DeidentifyTemplate(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $deidentifyTemplate = new DeidentifyTemplate(); + $request = (new CreateDeidentifyTemplateRequest()) + ->setParent($formattedParent) + ->setDeidentifyTemplate($deidentifyTemplate); + $response = $gapicClient->createDeidentifyTemplate($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateDeidentifyTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getDeidentifyTemplate(); + $this->assertProtobufEquals($deidentifyTemplate, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createDeidentifyTemplateExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $deidentifyTemplate = new DeidentifyTemplate(); + $request = (new CreateDeidentifyTemplateRequest()) + ->setParent($formattedParent) + ->setDeidentifyTemplate($deidentifyTemplate); + try { + $gapicClient->createDeidentifyTemplate($request); + // 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 createDiscoveryConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $expectedResponse = new DiscoveryConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $discoveryConfig = new DiscoveryConfig(); + $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; + $discoveryConfig->setStatus($discoveryConfigStatus); + $request = (new CreateDiscoveryConfigRequest()) + ->setParent($formattedParent) + ->setDiscoveryConfig($discoveryConfig); + $response = $gapicClient->createDiscoveryConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateDiscoveryConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getDiscoveryConfig(); + $this->assertProtobufEquals($discoveryConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createDiscoveryConfigExceptionTest() + { + $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->locationName('[PROJECT]', '[LOCATION]'); + $discoveryConfig = new DiscoveryConfig(); + $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; + $discoveryConfig->setStatus($discoveryConfigStatus); + $request = (new CreateDiscoveryConfigRequest()) + ->setParent($formattedParent) + ->setDiscoveryConfig($discoveryConfig); + try { + $gapicClient->createDiscoveryConfig($request); + // 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 createDlpJobTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $jobTriggerName = 'jobTriggerName1819490804'; + $expectedResponse = new DlpJob(); + $expectedResponse->setName($name); + $expectedResponse->setJobTriggerName($jobTriggerName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new CreateDlpJobRequest()) + ->setParent($formattedParent); + $response = $gapicClient->createDlpJob($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateDlpJob', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createDlpJobExceptionTest() + { + $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]'); + $request = (new CreateDlpJobRequest()) + ->setParent($formattedParent); + try { + $gapicClient->createDlpJob($request); + // 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 createInspectTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new InspectTemplate(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $inspectTemplate = new InspectTemplate(); + $request = (new CreateInspectTemplateRequest()) + ->setParent($formattedParent) + ->setInspectTemplate($inspectTemplate); + $response = $gapicClient->createInspectTemplate($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateInspectTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getInspectTemplate(); + $this->assertProtobufEquals($inspectTemplate, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createInspectTemplateExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $inspectTemplate = new InspectTemplate(); + $request = (new CreateInspectTemplateRequest()) + ->setParent($formattedParent) + ->setInspectTemplate($inspectTemplate); + try { + $gapicClient->createInspectTemplate($request); + // 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 createJobTriggerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new JobTrigger(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $jobTrigger = new JobTrigger(); + $jobTriggerStatus = \Google\Cloud\Dlp\V2\JobTrigger\Status::STATUS_UNSPECIFIED; + $jobTrigger->setStatus($jobTriggerStatus); + $request = (new CreateJobTriggerRequest()) + ->setParent($formattedParent) + ->setJobTrigger($jobTrigger); + $response = $gapicClient->createJobTrigger($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getJobTrigger(); + $this->assertProtobufEquals($jobTrigger, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createJobTriggerExceptionTest() + { + $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]'); + $jobTrigger = new JobTrigger(); + $jobTriggerStatus = \Google\Cloud\Dlp\V2\JobTrigger\Status::STATUS_UNSPECIFIED; + $jobTrigger->setStatus($jobTriggerStatus); + $request = (new CreateJobTriggerRequest()) + ->setParent($formattedParent) + ->setJobTrigger($jobTrigger); + try { + $gapicClient->createJobTrigger($request); + // 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 createStoredInfoTypeTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $expectedResponse = new StoredInfoType(); + $expectedResponse->setName($name); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $config = new StoredInfoTypeConfig(); + $request = (new CreateStoredInfoTypeRequest()) + ->setParent($formattedParent) + ->setConfig($config); + $response = $gapicClient->createStoredInfoType($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateStoredInfoType', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getConfig(); + $this->assertProtobufEquals($config, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createStoredInfoTypeExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $config = new StoredInfoTypeConfig(); + $request = (new CreateStoredInfoTypeRequest()) + ->setParent($formattedParent) + ->setConfig($config); + try { + $gapicClient->createStoredInfoType($request); + // 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 deidentifyContentTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new DeidentifyContentResponse(); + $transport->addResponse($expectedResponse); + $request = new DeidentifyContentRequest(); + $response = $gapicClient->deidentifyContent($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeidentifyContent', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deidentifyContentExceptionTest() + { + $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); + $request = new DeidentifyContentRequest(); + try { + $gapicClient->deidentifyContent($request); + // 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 deleteConnectionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + $request = (new DeleteConnectionRequest()) + ->setName($formattedName); + $gapicClient->deleteConnection($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteConnection', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteConnectionExceptionTest() + { + $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->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + $request = (new DeleteConnectionRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteConnection($request); + // 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 deleteDeidentifyTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + $request = (new DeleteDeidentifyTemplateRequest()) + ->setName($formattedName); + $gapicClient->deleteDeidentifyTemplate($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteDeidentifyTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteDeidentifyTemplateExceptionTest() + { + $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->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + $request = (new DeleteDeidentifyTemplateRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteDeidentifyTemplate($request); + // 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 deleteDiscoveryConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + $request = (new DeleteDiscoveryConfigRequest()) + ->setName($formattedName); + $gapicClient->deleteDiscoveryConfig($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteDiscoveryConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteDiscoveryConfigExceptionTest() + { + $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->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + $request = (new DeleteDiscoveryConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteDiscoveryConfig($request); + // 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 deleteDlpJobTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $request = (new DeleteDlpJobRequest()) + ->setName($formattedName); + $gapicClient->deleteDlpJob($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteDlpJob', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteDlpJobExceptionTest() + { + $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $request = (new DeleteDlpJobRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteDlpJob($request); + // 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 deleteInspectTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + $request = (new DeleteInspectTemplateRequest()) + ->setName($formattedName); + $gapicClient->deleteInspectTemplate($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteInspectTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteInspectTemplateExceptionTest() + { + $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->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + $request = (new DeleteInspectTemplateRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteInspectTemplate($request); + // 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 deleteJobTriggerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $request = (new DeleteJobTriggerRequest()) + ->setName($formattedName); + $gapicClient->deleteJobTrigger($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteJobTriggerExceptionTest() + { + $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $request = (new DeleteJobTriggerRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteJobTrigger($request); + // 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 deleteStoredInfoTypeTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + $request = (new DeleteStoredInfoTypeRequest()) + ->setName($formattedName); + $gapicClient->deleteStoredInfoType($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteStoredInfoType', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteStoredInfoTypeExceptionTest() + { + $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->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + $request = (new DeleteStoredInfoTypeRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteStoredInfoType($request); + // 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 deleteTableDataProfileTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); + $request = (new DeleteTableDataProfileRequest()) + ->setName($formattedName); + $gapicClient->deleteTableDataProfile($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteTableDataProfile', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteTableDataProfileExceptionTest() + { + $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->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); + $request = (new DeleteTableDataProfileRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteTableDataProfile($request); + // 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 finishDlpJobTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $request = (new FinishDlpJobRequest()) + ->setName($formattedName); + $gapicClient->finishDlpJob($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/FinishDlpJob', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function finishDlpJobExceptionTest() + { + $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $request = (new FinishDlpJobRequest()) + ->setName($formattedName); + try { + $gapicClient->finishDlpJob($request); + // 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 getColumnDataProfileTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $tableDataProfile = 'tableDataProfile1230971621'; + $tableFullResource = 'tableFullResource1490522381'; + $datasetProjectId = 'datasetProjectId1943685672'; + $datasetLocation = 'datasetLocation1011262364'; + $datasetId = 'datasetId-2115646910'; + $tableId = 'tableId-895419604'; + $column = 'column-1354837162'; + $freeTextScore = 1.21823761E8; + $expectedResponse = new ColumnDataProfile(); + $expectedResponse->setName($name2); + $expectedResponse->setTableDataProfile($tableDataProfile); + $expectedResponse->setTableFullResource($tableFullResource); + $expectedResponse->setDatasetProjectId($datasetProjectId); + $expectedResponse->setDatasetLocation($datasetLocation); + $expectedResponse->setDatasetId($datasetId); + $expectedResponse->setTableId($tableId); + $expectedResponse->setColumn($column); + $expectedResponse->setFreeTextScore($freeTextScore); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->columnDataProfileName('[ORGANIZATION]', '[LOCATION]', '[COLUMN_DATA_PROFILE]'); + $request = (new GetColumnDataProfileRequest()) + ->setName($formattedName); + $response = $gapicClient->getColumnDataProfile($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetColumnDataProfile', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getColumnDataProfileExceptionTest() + { + $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->columnDataProfileName('[ORGANIZATION]', '[LOCATION]', '[COLUMN_DATA_PROFILE]'); + $request = (new GetColumnDataProfileRequest()) + ->setName($formattedName); + try { + $gapicClient->getColumnDataProfile($request); + // 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 getConnectionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new Connection(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + $request = (new GetConnectionRequest()) + ->setName($formattedName); + $response = $gapicClient->getConnection($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetConnection', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getConnectionExceptionTest() + { + $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->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + $request = (new GetConnectionRequest()) + ->setName($formattedName); + try { + $gapicClient->getConnection($request); + // 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 getDeidentifyTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new DeidentifyTemplate(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + $request = (new GetDeidentifyTemplateRequest()) + ->setName($formattedName); + $response = $gapicClient->getDeidentifyTemplate($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetDeidentifyTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getDeidentifyTemplateExceptionTest() + { + $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->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + $request = (new GetDeidentifyTemplateRequest()) + ->setName($formattedName); + try { + $gapicClient->getDeidentifyTemplate($request); + // 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 getDiscoveryConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $expectedResponse = new DiscoveryConfig(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + $request = (new GetDiscoveryConfigRequest()) + ->setName($formattedName); + $response = $gapicClient->getDiscoveryConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetDiscoveryConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getDiscoveryConfigExceptionTest() + { + $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->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + $request = (new GetDiscoveryConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->getDiscoveryConfig($request); + // 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 getDlpJobTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $jobTriggerName = 'jobTriggerName1819490804'; + $expectedResponse = new DlpJob(); + $expectedResponse->setName($name2); + $expectedResponse->setJobTriggerName($jobTriggerName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $request = (new GetDlpJobRequest()) + ->setName($formattedName); + $response = $gapicClient->getDlpJob($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetDlpJob', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getDlpJobExceptionTest() + { + $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $request = (new GetDlpJobRequest()) + ->setName($formattedName); + try { + $gapicClient->getDlpJob($request); + // 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 getInspectTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new InspectTemplate(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + $request = (new GetInspectTemplateRequest()) + ->setName($formattedName); + $response = $gapicClient->getInspectTemplate($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetInspectTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getInspectTemplateExceptionTest() + { + $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->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + $request = (new GetInspectTemplateRequest()) + ->setName($formattedName); + try { + $gapicClient->getInspectTemplate($request); + // 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 getJobTriggerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new JobTrigger(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $request = (new GetJobTriggerRequest()) + ->setName($formattedName); + $response = $gapicClient->getJobTrigger($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getJobTriggerExceptionTest() + { + $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $request = (new GetJobTriggerRequest()) + ->setName($formattedName); + try { + $gapicClient->getJobTrigger($request); + // 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 getProjectDataProfileTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $projectId = 'projectId-1969970175'; + $expectedResponse = new ProjectDataProfile(); + $expectedResponse->setName($name2); + $expectedResponse->setProjectId($projectId); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->projectDataProfileName('[ORGANIZATION]', '[LOCATION]', '[PROJECT_DATA_PROFILE]'); + $request = (new GetProjectDataProfileRequest()) + ->setName($formattedName); + $response = $gapicClient->getProjectDataProfile($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetProjectDataProfile', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getProjectDataProfileExceptionTest() + { + $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->projectDataProfileName('[ORGANIZATION]', '[LOCATION]', '[PROJECT_DATA_PROFILE]'); + $request = (new GetProjectDataProfileRequest()) + ->setName($formattedName); + try { + $gapicClient->getProjectDataProfile($request); + // 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 getStoredInfoTypeTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new StoredInfoType(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + $request = (new GetStoredInfoTypeRequest()) + ->setName($formattedName); + $response = $gapicClient->getStoredInfoType($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetStoredInfoType', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getStoredInfoTypeExceptionTest() + { + $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->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + $request = (new GetStoredInfoTypeRequest()) + ->setName($formattedName); + try { + $gapicClient->getStoredInfoType($request); + // 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 getTableDataProfileTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $projectDataProfile = 'projectDataProfile-316045958'; + $datasetProjectId = 'datasetProjectId1943685672'; + $datasetLocation = 'datasetLocation1011262364'; + $datasetId = 'datasetId-2115646910'; + $tableId = 'tableId-895419604'; + $fullResource = 'fullResource1559053246'; + $scannedColumnCount = 787756843; + $failedColumnCount = 706572376; + $tableSizeBytes = 927763390; + $rowCount = 1340416618; + $expectedResponse = new TableDataProfile(); + $expectedResponse->setName($name2); + $expectedResponse->setProjectDataProfile($projectDataProfile); + $expectedResponse->setDatasetProjectId($datasetProjectId); + $expectedResponse->setDatasetLocation($datasetLocation); + $expectedResponse->setDatasetId($datasetId); + $expectedResponse->setTableId($tableId); + $expectedResponse->setFullResource($fullResource); + $expectedResponse->setScannedColumnCount($scannedColumnCount); + $expectedResponse->setFailedColumnCount($failedColumnCount); + $expectedResponse->setTableSizeBytes($tableSizeBytes); + $expectedResponse->setRowCount($rowCount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); + $request = (new GetTableDataProfileRequest()) + ->setName($formattedName); + $response = $gapicClient->getTableDataProfile($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetTableDataProfile', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getTableDataProfileExceptionTest() + { + $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->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); + $request = (new GetTableDataProfileRequest()) + ->setName($formattedName); + try { + $gapicClient->getTableDataProfile($request); + // 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 hybridInspectDlpJobTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new HybridInspectResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $request = (new HybridInspectDlpJobRequest()) + ->setName($formattedName); + $response = $gapicClient->hybridInspectDlpJob($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/HybridInspectDlpJob', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function hybridInspectDlpJobExceptionTest() + { + $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $request = (new HybridInspectDlpJobRequest()) + ->setName($formattedName); + try { + $gapicClient->hybridInspectDlpJob($request); + // 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 hybridInspectJobTriggerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new HybridInspectResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $request = (new HybridInspectJobTriggerRequest()) + ->setName($formattedName); + $response = $gapicClient->hybridInspectJobTrigger($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/HybridInspectJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function hybridInspectJobTriggerExceptionTest() + { + $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $request = (new HybridInspectJobTriggerRequest()) + ->setName($formattedName); + try { + $gapicClient->hybridInspectJobTrigger($request); + // 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 inspectContentTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new InspectContentResponse(); + $transport->addResponse($expectedResponse); + $request = new InspectContentRequest(); + $response = $gapicClient->inspectContent($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/InspectContent', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function inspectContentExceptionTest() + { + $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); + $request = new InspectContentRequest(); + try { + $gapicClient->inspectContent($request); + // 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 listColumnDataProfilesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $columnDataProfilesElement = new ColumnDataProfile(); + $columnDataProfiles = [ + $columnDataProfilesElement, + ]; + $expectedResponse = new ListColumnDataProfilesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setColumnDataProfiles($columnDataProfiles); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListColumnDataProfilesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listColumnDataProfiles($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getColumnDataProfiles()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListColumnDataProfiles', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listColumnDataProfilesExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListColumnDataProfilesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listColumnDataProfiles($request); + // 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 listConnectionsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $connectionsElement = new Connection(); + $connections = [ + $connectionsElement, + ]; + $expectedResponse = new ListConnectionsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setConnections($connections); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListConnectionsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listConnections($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getConnections()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListConnections', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listConnectionsExceptionTest() + { + $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->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListConnectionsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listConnections($request); + // 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 listDeidentifyTemplatesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $deidentifyTemplatesElement = new DeidentifyTemplate(); + $deidentifyTemplates = [ + $deidentifyTemplatesElement, + ]; + $expectedResponse = new ListDeidentifyTemplatesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setDeidentifyTemplates($deidentifyTemplates); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListDeidentifyTemplatesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listDeidentifyTemplates($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getDeidentifyTemplates()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListDeidentifyTemplates', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listDeidentifyTemplatesExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListDeidentifyTemplatesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listDeidentifyTemplates($request); + // 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 listDiscoveryConfigsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $discoveryConfigsElement = new DiscoveryConfig(); + $discoveryConfigs = [ + $discoveryConfigsElement, + ]; + $expectedResponse = new ListDiscoveryConfigsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setDiscoveryConfigs($discoveryConfigs); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListDiscoveryConfigsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listDiscoveryConfigs($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getDiscoveryConfigs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListDiscoveryConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listDiscoveryConfigsExceptionTest() + { + $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->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListDiscoveryConfigsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listDiscoveryConfigs($request); + // 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 listDlpJobsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $jobsElement = new DlpJob(); + $jobs = [ + $jobsElement, + ]; + $expectedResponse = new ListDlpJobsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setJobs($jobs); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListDlpJobsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listDlpJobs($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getJobs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListDlpJobs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listDlpJobsExceptionTest() + { + $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]'); + $request = (new ListDlpJobsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listDlpJobs($request); + // 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 listInfoTypesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new ListInfoTypesResponse(); + $transport->addResponse($expectedResponse); + $request = new ListInfoTypesRequest(); + $response = $gapicClient->listInfoTypes($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListInfoTypes', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listInfoTypesExceptionTest() + { + $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); + $request = new ListInfoTypesRequest(); + try { + $gapicClient->listInfoTypes($request); + // 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 listInspectTemplatesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $inspectTemplatesElement = new InspectTemplate(); + $inspectTemplates = [ + $inspectTemplatesElement, + ]; + $expectedResponse = new ListInspectTemplatesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setInspectTemplates($inspectTemplates); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListInspectTemplatesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listInspectTemplates($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getInspectTemplates()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListInspectTemplates', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listInspectTemplatesExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListInspectTemplatesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listInspectTemplates($request); + // 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 listJobTriggersTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $jobTriggersElement = new JobTrigger(); + $jobTriggers = [ + $jobTriggersElement, + ]; + $expectedResponse = new ListJobTriggersResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setJobTriggers($jobTriggers); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListJobTriggersRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listJobTriggers($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getJobTriggers()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListJobTriggers', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listJobTriggersExceptionTest() + { + $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]'); + $request = (new ListJobTriggersRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listJobTriggers($request); + // 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 listProjectDataProfilesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $projectDataProfilesElement = new ProjectDataProfile(); + $projectDataProfiles = [ + $projectDataProfilesElement, + ]; + $expectedResponse = new ListProjectDataProfilesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setProjectDataProfiles($projectDataProfiles); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListProjectDataProfilesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listProjectDataProfiles($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getProjectDataProfiles()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListProjectDataProfiles', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listProjectDataProfilesExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListProjectDataProfilesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listProjectDataProfiles($request); + // 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 listStoredInfoTypesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $storedInfoTypesElement = new StoredInfoType(); + $storedInfoTypes = [ + $storedInfoTypesElement, + ]; + $expectedResponse = new ListStoredInfoTypesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setStoredInfoTypes($storedInfoTypes); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListStoredInfoTypesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listStoredInfoTypes($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getStoredInfoTypes()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListStoredInfoTypes', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listStoredInfoTypesExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListStoredInfoTypesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listStoredInfoTypes($request); + // 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 listTableDataProfilesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $tableDataProfilesElement = new TableDataProfile(); + $tableDataProfiles = [ + $tableDataProfilesElement, + ]; + $expectedResponse = new ListTableDataProfilesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTableDataProfiles($tableDataProfiles); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListTableDataProfilesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listTableDataProfiles($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getTableDataProfiles()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListTableDataProfiles', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listTableDataProfilesExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListTableDataProfilesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listTableDataProfiles($request); + // 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 redactImageTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $redactedImage = '28'; + $extractedText = 'extractedText998260012'; + $expectedResponse = new RedactImageResponse(); + $expectedResponse->setRedactedImage($redactedImage); + $expectedResponse->setExtractedText($extractedText); + $transport->addResponse($expectedResponse); + $request = new RedactImageRequest(); + $response = $gapicClient->redactImage($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/RedactImage', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function redactImageExceptionTest() + { + $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); + $request = new RedactImageRequest(); + try { + $gapicClient->redactImage($request); + // 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 reidentifyContentTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new ReidentifyContentResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ReidentifyContentRequest()) + ->setParent($formattedParent); + $response = $gapicClient->reidentifyContent($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ReidentifyContent', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function reidentifyContentExceptionTest() + { + $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]'); + $request = (new ReidentifyContentRequest()) + ->setParent($formattedParent); + try { + $gapicClient->reidentifyContent($request); + // 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 searchConnectionsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $connectionsElement = new Connection(); + $connections = [ + $connectionsElement, + ]; + $expectedResponse = new SearchConnectionsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setConnections($connections); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new SearchConnectionsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->searchConnections($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getConnections()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/SearchConnections', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function searchConnectionsExceptionTest() + { + $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->locationName('[PROJECT]', '[LOCATION]'); + $request = (new SearchConnectionsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->searchConnections($request); + // 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 updateConnectionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new Connection(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + $connection = new Connection(); + $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; + $connection->setState($connectionState); + $request = (new UpdateConnectionRequest()) + ->setName($formattedName) + ->setConnection($connection); + $response = $gapicClient->updateConnection($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateConnection', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getConnection(); + $this->assertProtobufEquals($connection, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateConnectionExceptionTest() + { + $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->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + $connection = new Connection(); + $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; + $connection->setState($connectionState); + $request = (new UpdateConnectionRequest()) + ->setName($formattedName) + ->setConnection($connection); + try { + $gapicClient->updateConnection($request); + // 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 updateDeidentifyTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new DeidentifyTemplate(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + $request = (new UpdateDeidentifyTemplateRequest()) + ->setName($formattedName); + $response = $gapicClient->updateDeidentifyTemplate($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateDeidentifyTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateDeidentifyTemplateExceptionTest() + { + $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->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + $request = (new UpdateDeidentifyTemplateRequest()) + ->setName($formattedName); + try { + $gapicClient->updateDeidentifyTemplate($request); + // 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 updateDiscoveryConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $expectedResponse = new DiscoveryConfig(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + $discoveryConfig = new DiscoveryConfig(); + $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; + $discoveryConfig->setStatus($discoveryConfigStatus); + $request = (new UpdateDiscoveryConfigRequest()) + ->setName($formattedName) + ->setDiscoveryConfig($discoveryConfig); + $response = $gapicClient->updateDiscoveryConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateDiscoveryConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getDiscoveryConfig(); + $this->assertProtobufEquals($discoveryConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateDiscoveryConfigExceptionTest() + { + $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->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + $discoveryConfig = new DiscoveryConfig(); + $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; + $discoveryConfig->setStatus($discoveryConfigStatus); + $request = (new UpdateDiscoveryConfigRequest()) + ->setName($formattedName) + ->setDiscoveryConfig($discoveryConfig); + try { + $gapicClient->updateDiscoveryConfig($request); + // 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 updateInspectTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new InspectTemplate(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + $request = (new UpdateInspectTemplateRequest()) + ->setName($formattedName); + $response = $gapicClient->updateInspectTemplate($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateInspectTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateInspectTemplateExceptionTest() + { + $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->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + $request = (new UpdateInspectTemplateRequest()) + ->setName($formattedName); + try { + $gapicClient->updateInspectTemplate($request); + // 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 updateJobTriggerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new JobTrigger(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $request = (new UpdateJobTriggerRequest()) + ->setName($formattedName); + $response = $gapicClient->updateJobTrigger($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateJobTriggerExceptionTest() + { + $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $request = (new UpdateJobTriggerRequest()) + ->setName($formattedName); + try { + $gapicClient->updateJobTrigger($request); + // 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 updateStoredInfoTypeTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new StoredInfoType(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + $request = (new UpdateStoredInfoTypeRequest()) + ->setName($formattedName); + $response = $gapicClient->updateStoredInfoType($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateStoredInfoType', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateStoredInfoTypeExceptionTest() + { + $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->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + $request = (new UpdateStoredInfoTypeRequest()) + ->setName($formattedName); + try { + $gapicClient->updateStoredInfoType($request); + // 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 activateJobTriggerAsyncTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $jobTriggerName = 'jobTriggerName1819490804'; + $expectedResponse = new DlpJob(); + $expectedResponse->setName($name2); + $expectedResponse->setJobTriggerName($jobTriggerName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $request = (new ActivateJobTriggerRequest()) + ->setName($formattedName); + $response = $gapicClient->activateJobTriggerAsync($request)->wait(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ActivateJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } +} diff --git a/owl-bot-staging/Dlp/v2/tests/Unit/V2/DlpServiceClientTest.php b/owl-bot-staging/Dlp/v2/tests/Unit/V2/DlpServiceClientTest.php new file mode 100644 index 000000000000..2944dc62f3d3 --- /dev/null +++ b/owl-bot-staging/Dlp/v2/tests/Unit/V2/DlpServiceClientTest.php @@ -0,0 +1,3373 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return DlpServiceClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new DlpServiceClient($options); + } + + /** @test */ + public function activateJobTriggerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $jobTriggerName = 'jobTriggerName1819490804'; + $expectedResponse = new DlpJob(); + $expectedResponse->setName($name2); + $expectedResponse->setJobTriggerName($jobTriggerName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $response = $gapicClient->activateJobTrigger($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ActivateJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function activateJobTriggerExceptionTest() + { + $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + try { + $gapicClient->activateJobTrigger($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 cancelDlpJobTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $gapicClient->cancelDlpJob($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CancelDlpJob', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function cancelDlpJobExceptionTest() + { + $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); + try { + $gapicClient->cancelDlpJob($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 createConnectionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $expectedResponse = new Connection(); + $expectedResponse->setName($name); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $connection = new Connection(); + $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; + $connection->setState($connectionState); + $response = $gapicClient->createConnection($formattedParent, $connection); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateConnection', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getConnection(); + $this->assertProtobufEquals($connection, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createConnectionExceptionTest() + { + $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->locationName('[PROJECT]', '[LOCATION]'); + $connection = new Connection(); + $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; + $connection->setState($connectionState); + try { + $gapicClient->createConnection($formattedParent, $connection); + // 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 createDeidentifyTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new DeidentifyTemplate(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $deidentifyTemplate = new DeidentifyTemplate(); + $response = $gapicClient->createDeidentifyTemplate($formattedParent, $deidentifyTemplate); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateDeidentifyTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getDeidentifyTemplate(); + $this->assertProtobufEquals($deidentifyTemplate, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createDeidentifyTemplateExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $deidentifyTemplate = new DeidentifyTemplate(); + try { + $gapicClient->createDeidentifyTemplate($formattedParent, $deidentifyTemplate); + // 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 createDiscoveryConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $expectedResponse = new DiscoveryConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $discoveryConfig = new DiscoveryConfig(); + $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; + $discoveryConfig->setStatus($discoveryConfigStatus); + $response = $gapicClient->createDiscoveryConfig($formattedParent, $discoveryConfig); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateDiscoveryConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getDiscoveryConfig(); + $this->assertProtobufEquals($discoveryConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createDiscoveryConfigExceptionTest() + { + $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->locationName('[PROJECT]', '[LOCATION]'); + $discoveryConfig = new DiscoveryConfig(); + $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; + $discoveryConfig->setStatus($discoveryConfigStatus); + try { + $gapicClient->createDiscoveryConfig($formattedParent, $discoveryConfig); + // 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 createDlpJobTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $jobTriggerName = 'jobTriggerName1819490804'; + $expectedResponse = new DlpJob(); + $expectedResponse->setName($name); + $expectedResponse->setJobTriggerName($jobTriggerName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->createDlpJob($formattedParent); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateDlpJob', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createDlpJobExceptionTest() + { + $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->createDlpJob($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 createInspectTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new InspectTemplate(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $inspectTemplate = new InspectTemplate(); + $response = $gapicClient->createInspectTemplate($formattedParent, $inspectTemplate); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateInspectTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getInspectTemplate(); + $this->assertProtobufEquals($inspectTemplate, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createInspectTemplateExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $inspectTemplate = new InspectTemplate(); + try { + $gapicClient->createInspectTemplate($formattedParent, $inspectTemplate); + // 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 createJobTriggerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new JobTrigger(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $jobTrigger = new JobTrigger(); + $jobTriggerStatus = \Google\Cloud\Dlp\V2\JobTrigger\Status::STATUS_UNSPECIFIED; + $jobTrigger->setStatus($jobTriggerStatus); + $response = $gapicClient->createJobTrigger($formattedParent, $jobTrigger); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getJobTrigger(); + $this->assertProtobufEquals($jobTrigger, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createJobTriggerExceptionTest() + { + $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]'); + $jobTrigger = new JobTrigger(); + $jobTriggerStatus = \Google\Cloud\Dlp\V2\JobTrigger\Status::STATUS_UNSPECIFIED; + $jobTrigger->setStatus($jobTriggerStatus); + try { + $gapicClient->createJobTrigger($formattedParent, $jobTrigger); + // 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 createStoredInfoTypeTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $expectedResponse = new StoredInfoType(); + $expectedResponse->setName($name); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $config = new StoredInfoTypeConfig(); + $response = $gapicClient->createStoredInfoType($formattedParent, $config); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateStoredInfoType', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getConfig(); + $this->assertProtobufEquals($config, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createStoredInfoTypeExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $config = new StoredInfoTypeConfig(); + try { + $gapicClient->createStoredInfoType($formattedParent, $config); + // 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 deidentifyContentTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new DeidentifyContentResponse(); + $transport->addResponse($expectedResponse); + $response = $gapicClient->deidentifyContent(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeidentifyContent', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deidentifyContentExceptionTest() + { + $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); + try { + $gapicClient->deidentifyContent(); + // 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 deleteConnectionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + $gapicClient->deleteConnection($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteConnection', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteConnectionExceptionTest() + { + $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->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + try { + $gapicClient->deleteConnection($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 deleteDeidentifyTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + $gapicClient->deleteDeidentifyTemplate($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteDeidentifyTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteDeidentifyTemplateExceptionTest() + { + $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->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + try { + $gapicClient->deleteDeidentifyTemplate($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 deleteDiscoveryConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + $gapicClient->deleteDiscoveryConfig($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteDiscoveryConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteDiscoveryConfigExceptionTest() + { + $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->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + try { + $gapicClient->deleteDiscoveryConfig($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 deleteDlpJobTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $gapicClient->deleteDlpJob($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteDlpJob', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteDlpJobExceptionTest() + { + $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); + try { + $gapicClient->deleteDlpJob($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 deleteInspectTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + $gapicClient->deleteInspectTemplate($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteInspectTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteInspectTemplateExceptionTest() + { + $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->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + try { + $gapicClient->deleteInspectTemplate($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 deleteJobTriggerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $gapicClient->deleteJobTrigger($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteJobTriggerExceptionTest() + { + $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + try { + $gapicClient->deleteJobTrigger($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 deleteStoredInfoTypeTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + $gapicClient->deleteStoredInfoType($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteStoredInfoType', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteStoredInfoTypeExceptionTest() + { + $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->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + try { + $gapicClient->deleteStoredInfoType($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 deleteTableDataProfileTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); + $gapicClient->deleteTableDataProfile($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteTableDataProfile', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteTableDataProfileExceptionTest() + { + $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->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); + try { + $gapicClient->deleteTableDataProfile($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 finishDlpJobTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $gapicClient->finishDlpJob($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/FinishDlpJob', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function finishDlpJobExceptionTest() + { + $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); + try { + $gapicClient->finishDlpJob($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 getColumnDataProfileTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $tableDataProfile = 'tableDataProfile1230971621'; + $tableFullResource = 'tableFullResource1490522381'; + $datasetProjectId = 'datasetProjectId1943685672'; + $datasetLocation = 'datasetLocation1011262364'; + $datasetId = 'datasetId-2115646910'; + $tableId = 'tableId-895419604'; + $column = 'column-1354837162'; + $freeTextScore = 1.21823761E8; + $expectedResponse = new ColumnDataProfile(); + $expectedResponse->setName($name2); + $expectedResponse->setTableDataProfile($tableDataProfile); + $expectedResponse->setTableFullResource($tableFullResource); + $expectedResponse->setDatasetProjectId($datasetProjectId); + $expectedResponse->setDatasetLocation($datasetLocation); + $expectedResponse->setDatasetId($datasetId); + $expectedResponse->setTableId($tableId); + $expectedResponse->setColumn($column); + $expectedResponse->setFreeTextScore($freeTextScore); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->columnDataProfileName('[ORGANIZATION]', '[LOCATION]', '[COLUMN_DATA_PROFILE]'); + $response = $gapicClient->getColumnDataProfile($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetColumnDataProfile', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getColumnDataProfileExceptionTest() + { + $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->columnDataProfileName('[ORGANIZATION]', '[LOCATION]', '[COLUMN_DATA_PROFILE]'); + try { + $gapicClient->getColumnDataProfile($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 getConnectionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new Connection(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + $response = $gapicClient->getConnection($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetConnection', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getConnectionExceptionTest() + { + $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->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + try { + $gapicClient->getConnection($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 getDeidentifyTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new DeidentifyTemplate(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + $response = $gapicClient->getDeidentifyTemplate($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetDeidentifyTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getDeidentifyTemplateExceptionTest() + { + $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->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + try { + $gapicClient->getDeidentifyTemplate($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 getDiscoveryConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $expectedResponse = new DiscoveryConfig(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + $response = $gapicClient->getDiscoveryConfig($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetDiscoveryConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getDiscoveryConfigExceptionTest() + { + $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->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + try { + $gapicClient->getDiscoveryConfig($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 getDlpJobTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $jobTriggerName = 'jobTriggerName1819490804'; + $expectedResponse = new DlpJob(); + $expectedResponse->setName($name2); + $expectedResponse->setJobTriggerName($jobTriggerName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $response = $gapicClient->getDlpJob($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetDlpJob', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getDlpJobExceptionTest() + { + $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); + try { + $gapicClient->getDlpJob($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 getInspectTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new InspectTemplate(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + $response = $gapicClient->getInspectTemplate($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetInspectTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getInspectTemplateExceptionTest() + { + $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->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + try { + $gapicClient->getInspectTemplate($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 getJobTriggerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new JobTrigger(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $response = $gapicClient->getJobTrigger($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getJobTriggerExceptionTest() + { + $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + try { + $gapicClient->getJobTrigger($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 getProjectDataProfileTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $projectId = 'projectId-1969970175'; + $expectedResponse = new ProjectDataProfile(); + $expectedResponse->setName($name2); + $expectedResponse->setProjectId($projectId); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->projectDataProfileName('[ORGANIZATION]', '[LOCATION]', '[PROJECT_DATA_PROFILE]'); + $response = $gapicClient->getProjectDataProfile($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetProjectDataProfile', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getProjectDataProfileExceptionTest() + { + $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->projectDataProfileName('[ORGANIZATION]', '[LOCATION]', '[PROJECT_DATA_PROFILE]'); + try { + $gapicClient->getProjectDataProfile($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 getStoredInfoTypeTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new StoredInfoType(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + $response = $gapicClient->getStoredInfoType($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetStoredInfoType', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getStoredInfoTypeExceptionTest() + { + $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->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + try { + $gapicClient->getStoredInfoType($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 getTableDataProfileTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $projectDataProfile = 'projectDataProfile-316045958'; + $datasetProjectId = 'datasetProjectId1943685672'; + $datasetLocation = 'datasetLocation1011262364'; + $datasetId = 'datasetId-2115646910'; + $tableId = 'tableId-895419604'; + $fullResource = 'fullResource1559053246'; + $scannedColumnCount = 787756843; + $failedColumnCount = 706572376; + $tableSizeBytes = 927763390; + $rowCount = 1340416618; + $expectedResponse = new TableDataProfile(); + $expectedResponse->setName($name2); + $expectedResponse->setProjectDataProfile($projectDataProfile); + $expectedResponse->setDatasetProjectId($datasetProjectId); + $expectedResponse->setDatasetLocation($datasetLocation); + $expectedResponse->setDatasetId($datasetId); + $expectedResponse->setTableId($tableId); + $expectedResponse->setFullResource($fullResource); + $expectedResponse->setScannedColumnCount($scannedColumnCount); + $expectedResponse->setFailedColumnCount($failedColumnCount); + $expectedResponse->setTableSizeBytes($tableSizeBytes); + $expectedResponse->setRowCount($rowCount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); + $response = $gapicClient->getTableDataProfile($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/GetTableDataProfile', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getTableDataProfileExceptionTest() + { + $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->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); + try { + $gapicClient->getTableDataProfile($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 hybridInspectDlpJobTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new HybridInspectResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); + $response = $gapicClient->hybridInspectDlpJob($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/HybridInspectDlpJob', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function hybridInspectDlpJobExceptionTest() + { + $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); + try { + $gapicClient->hybridInspectDlpJob($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 hybridInspectJobTriggerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new HybridInspectResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $response = $gapicClient->hybridInspectJobTrigger($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/HybridInspectJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function hybridInspectJobTriggerExceptionTest() + { + $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + try { + $gapicClient->hybridInspectJobTrigger($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 inspectContentTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new InspectContentResponse(); + $transport->addResponse($expectedResponse); + $response = $gapicClient->inspectContent(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/InspectContent', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function inspectContentExceptionTest() + { + $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); + try { + $gapicClient->inspectContent(); + // 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 listColumnDataProfilesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $columnDataProfilesElement = new ColumnDataProfile(); + $columnDataProfiles = [ + $columnDataProfilesElement, + ]; + $expectedResponse = new ListColumnDataProfilesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setColumnDataProfiles($columnDataProfiles); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $response = $gapicClient->listColumnDataProfiles($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getColumnDataProfiles()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListColumnDataProfiles', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listColumnDataProfilesExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + try { + $gapicClient->listColumnDataProfiles($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 listConnectionsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $connectionsElement = new Connection(); + $connections = [ + $connectionsElement, + ]; + $expectedResponse = new ListConnectionsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setConnections($connections); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $response = $gapicClient->listConnections($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getConnections()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListConnections', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listConnectionsExceptionTest() + { + $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->locationName('[PROJECT]', '[LOCATION]'); + try { + $gapicClient->listConnections($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 listDeidentifyTemplatesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $deidentifyTemplatesElement = new DeidentifyTemplate(); + $deidentifyTemplates = [ + $deidentifyTemplatesElement, + ]; + $expectedResponse = new ListDeidentifyTemplatesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setDeidentifyTemplates($deidentifyTemplates); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $response = $gapicClient->listDeidentifyTemplates($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getDeidentifyTemplates()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListDeidentifyTemplates', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listDeidentifyTemplatesExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + try { + $gapicClient->listDeidentifyTemplates($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 listDiscoveryConfigsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $discoveryConfigsElement = new DiscoveryConfig(); + $discoveryConfigs = [ + $discoveryConfigsElement, + ]; + $expectedResponse = new ListDiscoveryConfigsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setDiscoveryConfigs($discoveryConfigs); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $response = $gapicClient->listDiscoveryConfigs($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getDiscoveryConfigs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListDiscoveryConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listDiscoveryConfigsExceptionTest() + { + $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->locationName('[PROJECT]', '[LOCATION]'); + try { + $gapicClient->listDiscoveryConfigs($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 listDlpJobsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $jobsElement = new DlpJob(); + $jobs = [ + $jobsElement, + ]; + $expectedResponse = new ListDlpJobsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setJobs($jobs); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->listDlpJobs($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getJobs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListDlpJobs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listDlpJobsExceptionTest() + { + $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->listDlpJobs($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 listInfoTypesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new ListInfoTypesResponse(); + $transport->addResponse($expectedResponse); + $response = $gapicClient->listInfoTypes(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListInfoTypes', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listInfoTypesExceptionTest() + { + $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); + try { + $gapicClient->listInfoTypes(); + // 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 listInspectTemplatesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $inspectTemplatesElement = new InspectTemplate(); + $inspectTemplates = [ + $inspectTemplatesElement, + ]; + $expectedResponse = new ListInspectTemplatesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setInspectTemplates($inspectTemplates); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $response = $gapicClient->listInspectTemplates($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getInspectTemplates()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListInspectTemplates', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listInspectTemplatesExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + try { + $gapicClient->listInspectTemplates($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 listJobTriggersTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $jobTriggersElement = new JobTrigger(); + $jobTriggers = [ + $jobTriggersElement, + ]; + $expectedResponse = new ListJobTriggersResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setJobTriggers($jobTriggers); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->listJobTriggers($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getJobTriggers()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListJobTriggers', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listJobTriggersExceptionTest() + { + $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->listJobTriggers($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 listProjectDataProfilesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $projectDataProfilesElement = new ProjectDataProfile(); + $projectDataProfiles = [ + $projectDataProfilesElement, + ]; + $expectedResponse = new ListProjectDataProfilesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setProjectDataProfiles($projectDataProfiles); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $response = $gapicClient->listProjectDataProfiles($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getProjectDataProfiles()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListProjectDataProfiles', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listProjectDataProfilesExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + try { + $gapicClient->listProjectDataProfiles($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 listStoredInfoTypesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $storedInfoTypesElement = new StoredInfoType(); + $storedInfoTypes = [ + $storedInfoTypesElement, + ]; + $expectedResponse = new ListStoredInfoTypesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setStoredInfoTypes($storedInfoTypes); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $response = $gapicClient->listStoredInfoTypes($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getStoredInfoTypes()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListStoredInfoTypes', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listStoredInfoTypesExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + try { + $gapicClient->listStoredInfoTypes($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 listTableDataProfilesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $tableDataProfilesElement = new TableDataProfile(); + $tableDataProfiles = [ + $tableDataProfilesElement, + ]; + $expectedResponse = new ListTableDataProfilesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTableDataProfiles($tableDataProfiles); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $response = $gapicClient->listTableDataProfiles($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getTableDataProfiles()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ListTableDataProfiles', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listTableDataProfilesExceptionTest() + { + $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + try { + $gapicClient->listTableDataProfiles($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 redactImageTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $redactedImage = '28'; + $extractedText = 'extractedText998260012'; + $expectedResponse = new RedactImageResponse(); + $expectedResponse->setRedactedImage($redactedImage); + $expectedResponse->setExtractedText($extractedText); + $transport->addResponse($expectedResponse); + $response = $gapicClient->redactImage(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/RedactImage', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function redactImageExceptionTest() + { + $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); + try { + $gapicClient->redactImage(); + // 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 reidentifyContentTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new ReidentifyContentResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->reidentifyContent($formattedParent); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/ReidentifyContent', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function reidentifyContentExceptionTest() + { + $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->reidentifyContent($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 searchConnectionsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $connectionsElement = new Connection(); + $connections = [ + $connectionsElement, + ]; + $expectedResponse = new SearchConnectionsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setConnections($connections); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $response = $gapicClient->searchConnections($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getConnections()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/SearchConnections', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function searchConnectionsExceptionTest() + { + $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->locationName('[PROJECT]', '[LOCATION]'); + try { + $gapicClient->searchConnections($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 updateConnectionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new Connection(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + $connection = new Connection(); + $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; + $connection->setState($connectionState); + $response = $gapicClient->updateConnection($formattedName, $connection); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateConnection', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getConnection(); + $this->assertProtobufEquals($connection, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateConnectionExceptionTest() + { + $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->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); + $connection = new Connection(); + $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; + $connection->setState($connectionState); + try { + $gapicClient->updateConnection($formattedName, $connection); + // 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 updateDeidentifyTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new DeidentifyTemplate(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + $response = $gapicClient->updateDeidentifyTemplate($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateDeidentifyTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateDeidentifyTemplateExceptionTest() + { + $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->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); + try { + $gapicClient->updateDeidentifyTemplate($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 updateDiscoveryConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $expectedResponse = new DiscoveryConfig(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + $discoveryConfig = new DiscoveryConfig(); + $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; + $discoveryConfig->setStatus($discoveryConfigStatus); + $response = $gapicClient->updateDiscoveryConfig($formattedName, $discoveryConfig); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateDiscoveryConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getDiscoveryConfig(); + $this->assertProtobufEquals($discoveryConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateDiscoveryConfigExceptionTest() + { + $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->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); + $discoveryConfig = new DiscoveryConfig(); + $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; + $discoveryConfig->setStatus($discoveryConfigStatus); + try { + $gapicClient->updateDiscoveryConfig($formattedName, $discoveryConfig); + // 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 updateInspectTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new InspectTemplate(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + $response = $gapicClient->updateInspectTemplate($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateInspectTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateInspectTemplateExceptionTest() + { + $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->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); + try { + $gapicClient->updateInspectTemplate($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 updateJobTriggerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new JobTrigger(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + $response = $gapicClient->updateJobTrigger($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateJobTrigger', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateJobTriggerExceptionTest() + { + $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); + try { + $gapicClient->updateJobTrigger($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 updateStoredInfoTypeTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new StoredInfoType(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + $response = $gapicClient->updateStoredInfoType($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateStoredInfoType', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateStoredInfoTypeExceptionTest() + { + $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->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); + try { + $gapicClient->updateStoredInfoType($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()); + } +} From 9f4df57a7cfe9647708b9eecb6a54f6820ea176b Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Thu, 23 May 2024 19:04:42 +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 --- Dlp/metadata/V2/Dlp.php | Bin 72278 -> 72515 bytes Dlp/metadata/V2/Storage.php | Bin 6216 -> 6272 bytes Dlp/src/V2/CloudSqlIamCredential.php | 4 +- .../V2/CloudSqlProperties/DatabaseEngine.php | 4 +- Dlp/src/V2/ConnectionState.php | 8 +- Dlp/src/V2/DataProfileAction/EventType.php | 10 +- Dlp/src/V2/DatabaseResourceReference.php | 88 +- Dlp/src/V2/DatabaseResourceRegex.php | 8 +- Dlp/src/V2/DiscoveryBigQueryFilter.php | 39 + .../DatabaseEngine.php | 4 +- .../V2/DiscoveryCloudSqlGenerationCadence.php | 8 +- .../SchemaModifiedCadence.php | 2 +- .../CloudSqlSchemaModification.php | 2 +- Dlp/src/V2/DiscoveryTarget.php | 39 + Dlp/src/V2/Gapic/DlpServiceGapicClient.php | 6 +- .../V2/InfoTypeCategory/LocationCategory.php | 7 + .../V2/InspectDataSourceDetails/Result.php | 8 +- Dlp/src/V2/JobTrigger.php | 2 +- Dlp/src/V2/ListConnectionsRequest.php | 12 +- Dlp/src/V2/ResourceVisibility.php | 4 +- Dlp/src/V2/SearchConnectionsRequest.php | 12 +- .../src}/V2/SecretsDiscoveryTarget.php | 0 .../Dlp => Dlp/src}/V2/TableReference.php | 4 +- .../GPBMetadata/Google/Privacy/Dlp/V2/Dlp.php | Bin 72515 -> 0 bytes .../Google/Privacy/Dlp/V2/Storage.php | Bin 6272 -> 0 bytes .../proto/src/Google/Cloud/Dlp/V2/Action.php | 281 - .../Google/Cloud/Dlp/V2/Action/Deidentify.php | 277 - .../Dlp/V2/Action/JobNotificationEmails.php | 38 - .../PublishFindingsToCloudDataCatalog.php | 51 - .../Dlp/V2/Action/PublishSummaryToCscc.php | 43 - .../Cloud/Dlp/V2/Action/PublishToPubSub.php | 86 - .../Dlp/V2/Action/PublishToStackdriver.php | 39 - .../Cloud/Dlp/V2/Action/SaveFindings.php | 83 - .../src/Google/Cloud/Dlp/V2/ActionDetails.php | 75 - .../Dlp/V2/ActivateJobTriggerRequest.php | 71 - .../Dlp/V2/AllOtherDatabaseResources.php | 33 - .../Dlp/V2/AnalyzeDataSourceRiskDetails.php | 372 -- .../CategoricalStatsResult.php | 70 - .../CategoricalStatsHistogramBucket.php | 210 - .../DeltaPresenceEstimationResult.php | 99 - ...DeltaPresenceEstimationHistogramBucket.php | 218 - .../DeltaPresenceEstimationQuasiIdValues.php | 132 - .../KAnonymityResult.php | 70 - .../KAnonymityEquivalenceClass.php | 116 - .../KAnonymityHistogramBucket.php | 210 - .../KMapEstimationResult.php | 99 - .../KMapEstimationHistogramBucket.php | 217 - .../KMapEstimationQuasiIdValues.php | 104 - .../LDiversityResult.php | 70 - .../LDiversityEquivalenceClass.php | 176 - .../LDiversityHistogramBucket.php | 218 - .../NumericalStatsResult.php | 162 - .../RequestedRiskAnalysisOptions.php | 80 - .../Cloud/Dlp/V2/BigQueryDiscoveryTarget.php | 210 - .../src/Google/Cloud/Dlp/V2/BigQueryField.php | 121 - .../src/Google/Cloud/Dlp/V2/BigQueryKey.php | 127 - .../Google/Cloud/Dlp/V2/BigQueryOptions.php | 369 -- .../Dlp/V2/BigQueryOptions/SampleMethod.php | 68 - .../src/Google/Cloud/Dlp/V2/BigQueryRegex.php | 143 - .../Google/Cloud/Dlp/V2/BigQueryRegexes.php | 72 - .../Dlp/V2/BigQuerySchemaModification.php | 63 - .../src/Google/Cloud/Dlp/V2/BigQueryTable.php | 143 - .../Cloud/Dlp/V2/BigQueryTableCollection.php | 75 - .../Dlp/V2/BigQueryTableModification.php | 56 - .../Google/Cloud/Dlp/V2/BigQueryTableType.php | 62 - .../Dlp/V2/BigQueryTableTypeCollection.php | 68 - .../Cloud/Dlp/V2/BigQueryTableTypes.php | 67 - .../src/Google/Cloud/Dlp/V2/BoundingBox.php | 169 - .../Google/Cloud/Dlp/V2/BucketingConfig.php | 77 - .../Cloud/Dlp/V2/BucketingConfig/Bucket.php | 172 - .../Google/Cloud/Dlp/V2/ByteContentItem.php | 101 - .../Dlp/V2/ByteContentItem/BytesType.php | 143 - .../Cloud/Dlp/V2/CancelDlpJobRequest.php | 67 - .../Cloud/Dlp/V2/CharacterMaskConfig.php | 266 - .../src/Google/Cloud/Dlp/V2/CharsToIgnore.php | 112 - .../V2/CharsToIgnore/CommonCharsToIgnore.php | 85 - .../Cloud/Dlp/V2/CloudSqlDiscoveryTarget.php | 210 - .../Cloud/Dlp/V2/CloudSqlIamCredential.php | 36 - .../Cloud/Dlp/V2/CloudSqlProperties.php | 250 - .../V2/CloudSqlProperties/DatabaseEngine.php | 65 - .../Cloud/Dlp/V2/CloudStorageFileSet.php | 71 - .../Cloud/Dlp/V2/CloudStorageOptions.php | 332 -- .../Dlp/V2/CloudStorageOptions/FileSet.php | 146 - .../V2/CloudStorageOptions/SampleMethod.php | 67 - .../Google/Cloud/Dlp/V2/CloudStoragePath.php | 71 - .../Cloud/Dlp/V2/CloudStorageRegexFileSet.php | 208 - .../proto/src/Google/Cloud/Dlp/V2/Color.php | 135 - .../Google/Cloud/Dlp/V2/ColumnDataProfile.php | 795 --- .../V2/ColumnDataProfile/ColumnDataType.php | 177 - .../ColumnDataProfile/ColumnPolicyState.php | 57 - .../Cloud/Dlp/V2/ColumnDataProfile/State.php | 67 - .../src/Google/Cloud/Dlp/V2/Connection.php | 186 - .../Google/Cloud/Dlp/V2/ConnectionState.php | 75 - .../src/Google/Cloud/Dlp/V2/Container.php | 354 -- .../src/Google/Cloud/Dlp/V2/ContentItem.php | 147 - .../Google/Cloud/Dlp/V2/ContentLocation.php | 331 -- .../src/Google/Cloud/Dlp/V2/ContentOption.php | 61 - .../Cloud/Dlp/V2/CreateConnectionRequest.php | 132 - .../V2/CreateDeidentifyTemplateRequest.php | 286 - .../Dlp/V2/CreateDiscoveryConfigRequest.php | 206 - .../Cloud/Dlp/V2/CreateDlpJobRequest.php | 334 -- .../Dlp/V2/CreateInspectTemplateRequest.php | 286 - .../Cloud/Dlp/V2/CreateJobTriggerRequest.php | 266 - .../Dlp/V2/CreateStoredInfoTypeRequest.php | 286 - .../Dlp/V2/CryptoDeterministicConfig.php | 327 -- .../Google/Cloud/Dlp/V2/CryptoHashConfig.php | 84 - .../src/Google/Cloud/Dlp/V2/CryptoKey.php | 146 - .../Dlp/V2/CryptoReplaceFfxFpeConfig.php | 448 -- .../FfxCommonNativeAlphabet.php | 80 - .../Google/Cloud/Dlp/V2/CustomInfoType.php | 427 -- .../Dlp/V2/CustomInfoType/DetectionRule.php | 81 - .../DetectionRule/HotwordRule.php | 213 - .../DetectionRule/LikelihoodAdjustment.php | 133 - .../DetectionRule/Proximity.php | 121 - .../Dlp/V2/CustomInfoType/Dictionary.php | 134 - .../V2/CustomInfoType/Dictionary/WordList.php | 78 - .../Dlp/V2/CustomInfoType/ExclusionType.php | 58 - .../Cloud/Dlp/V2/CustomInfoType/Regex.php | 116 - .../Dlp/V2/CustomInfoType/SurrogateType.php | 43 - .../Google/Cloud/Dlp/V2/DataProfileAction.php | 108 - .../Dlp/V2/DataProfileAction/EventType.php | 80 - .../Cloud/Dlp/V2/DataProfileAction/Export.php | 113 - .../DataProfileAction/PubSubNotification.php | 204 - .../PubSubNotification/DetailLevel.php | 64 - .../Dlp/V2/DataProfileBigQueryRowSchema.php | 109 - .../Dlp/V2/DataProfileConfigSnapshot.php | 270 - .../Cloud/Dlp/V2/DataProfileJobConfig.php | 240 - .../Cloud/Dlp/V2/DataProfileLocation.php | 108 - .../Dlp/V2/DataProfilePubSubCondition.php | 77 - .../ProfileScoreBucket.php | 64 - .../PubSubCondition.php | 111 - .../PubSubExpressions.php | 104 - .../PubSubLogicalOperator.php | 68 - .../Cloud/Dlp/V2/DataProfilePubSubMessage.php | 121 - .../Dlp/V2/DataProfileUpdateFrequency.php | 69 - .../src/Google/Cloud/Dlp/V2/DataRiskLevel.php | 68 - .../V2/DataRiskLevel/DataRiskLevelScore.php | 77 - .../Google/Cloud/Dlp/V2/DataSourceType.php | 71 - .../Dlp/V2/DatabaseResourceCollection.php | 76 - .../Dlp/V2/DatabaseResourceReference.php | 181 - .../Cloud/Dlp/V2/DatabaseResourceRegex.php | 188 - .../Cloud/Dlp/V2/DatabaseResourceRegexes.php | 80 - .../src/Google/Cloud/Dlp/V2/DatastoreKey.php | 77 - .../Google/Cloud/Dlp/V2/DatastoreOptions.php | 125 - .../Google/Cloud/Dlp/V2/DateShiftConfig.php | 220 - .../src/Google/Cloud/Dlp/V2/DateTime.php | 204 - .../Google/Cloud/Dlp/V2/DateTime/TimeZone.php | 74 - .../Google/Cloud/Dlp/V2/DeidentifyConfig.php | 198 - .../Cloud/Dlp/V2/DeidentifyContentRequest.php | 417 -- .../Dlp/V2/DeidentifyContentResponse.php | 121 - .../Dlp/V2/DeidentifyDataSourceDetails.php | 122 - .../RequestedDeidentifyOptions.php | 184 - .../Dlp/V2/DeidentifyDataSourceStats.php | 135 - .../Cloud/Dlp/V2/DeidentifyTemplate.php | 282 - .../Cloud/Dlp/V2/DeleteConnectionRequest.php | 86 - .../V2/DeleteDeidentifyTemplateRequest.php | 96 - .../Dlp/V2/DeleteDiscoveryConfigRequest.php | 86 - .../Cloud/Dlp/V2/DeleteDlpJobRequest.php | 81 - .../Dlp/V2/DeleteInspectTemplateRequest.php | 91 - .../Cloud/Dlp/V2/DeleteJobTriggerRequest.php | 86 - .../Dlp/V2/DeleteStoredInfoTypeRequest.php | 91 - .../Dlp/V2/DeleteTableDataProfileRequest.php | 81 - .../src/Google/Cloud/Dlp/V2/Disabled.php | 33 - .../Dlp/V2/DiscoveryBigQueryConditions.php | 204 - .../OrConditions.php | 123 - .../Cloud/Dlp/V2/DiscoveryBigQueryFilter.php | 167 - .../AllOtherBigQueryTables.php | 38 - .../Dlp/V2/DiscoveryCloudSqlConditions.php | 114 - .../DatabaseEngine.php | 71 - .../DatabaseResourceType.php | 64 - .../Cloud/Dlp/V2/DiscoveryCloudSqlFilter.php | 155 - .../V2/DiscoveryCloudSqlGenerationCadence.php | 125 - .../SchemaModifiedCadence.php | 112 - .../CloudSqlSchemaModification.php | 64 - .../Google/Cloud/Dlp/V2/DiscoveryConfig.php | 520 -- .../Dlp/V2/DiscoveryConfig/OrgConfig.php | 122 - .../Cloud/Dlp/V2/DiscoveryConfig/Status.php | 65 - .../Dlp/V2/DiscoveryGenerationCadence.php | 124 - .../Dlp/V2/DiscoverySchemaModifiedCadence.php | 113 - .../Dlp/V2/DiscoveryStartingLocation.php | 109 - .../Dlp/V2/DiscoveryTableModifiedCadence.php | 113 - .../Google/Cloud/Dlp/V2/DiscoveryTarget.php | 153 - .../proto/src/Google/Cloud/Dlp/V2/DlpJob.php | 492 -- .../Google/Cloud/Dlp/V2/DlpJob/JobState.php | 96 - .../src/Google/Cloud/Dlp/V2/DlpJobType.php | 61 - .../Google/Cloud/Dlp/V2/DocumentLocation.php | 71 - .../Google/Cloud/Dlp/V2/EncryptionStatus.php | 61 - .../src/Google/Cloud/Dlp/V2/EntityId.php | 81 - .../proto/src/Google/Cloud/Dlp/V2/Error.php | 116 - .../Google/Cloud/Dlp/V2/ExcludeByHotword.php | 136 - .../Google/Cloud/Dlp/V2/ExcludeInfoTypes.php | 95 - .../src/Google/Cloud/Dlp/V2/ExclusionRule.php | 212 - .../proto/src/Google/Cloud/Dlp/V2/FieldId.php | 67 - .../Cloud/Dlp/V2/FieldTransformation.php | 225 - .../src/Google/Cloud/Dlp/V2/FileType.php | 150 - .../proto/src/Google/Cloud/Dlp/V2/Finding.php | 593 -- .../Cloud/Dlp/V2/FinishDlpJobRequest.php | 67 - .../Cloud/Dlp/V2/FixedSizeBucketingConfig.php | 196 - .../Dlp/V2/GetColumnDataProfileRequest.php | 86 - .../Cloud/Dlp/V2/GetConnectionRequest.php | 86 - .../Dlp/V2/GetDeidentifyTemplateRequest.php | 91 - .../Dlp/V2/GetDiscoveryConfigRequest.php | 86 - .../Google/Cloud/Dlp/V2/GetDlpJobRequest.php | 81 - .../Dlp/V2/GetInspectTemplateRequest.php | 91 - .../Cloud/Dlp/V2/GetJobTriggerRequest.php | 86 - .../Dlp/V2/GetProjectDataProfileRequest.php | 86 - .../Cloud/Dlp/V2/GetStoredInfoTypeRequest.php | 91 - .../Dlp/V2/GetTableDataProfileRequest.php | 86 - .../Google/Cloud/Dlp/V2/HybridContentItem.php | 122 - .../Cloud/Dlp/V2/HybridFindingDetails.php | 303 - .../Dlp/V2/HybridInspectDlpJobRequest.php | 130 - .../Dlp/V2/HybridInspectJobTriggerRequest.php | 130 - .../Cloud/Dlp/V2/HybridInspectResponse.php | 33 - .../Cloud/Dlp/V2/HybridInspectStatistics.php | 155 - .../src/Google/Cloud/Dlp/V2/HybridOptions.php | 240 - .../src/Google/Cloud/Dlp/V2/ImageLocation.php | 67 - .../Cloud/Dlp/V2/ImageTransformations.php | 67 - .../ImageTransformation.php | 201 - .../ImageTransformation/AllInfoTypes.php | 36 - .../ImageTransformation/AllText.php | 36 - .../ImageTransformation/SelectedInfoTypes.php | 74 - .../src/Google/Cloud/Dlp/V2/InfoType.php | 173 - .../Google/Cloud/Dlp/V2/InfoTypeCategory.php | 145 - .../V2/InfoTypeCategory/IndustryCategory.php | 72 - .../V2/InfoTypeCategory/LocationCategory.php | 392 -- .../Dlp/V2/InfoTypeCategory/TypeCategory.php | 104 - .../Cloud/Dlp/V2/InfoTypeDescription.php | 285 - .../src/Google/Cloud/Dlp/V2/InfoTypeStats.php | 111 - .../Google/Cloud/Dlp/V2/InfoTypeSummary.php | 116 - .../Cloud/Dlp/V2/InfoTypeSupportedBy.php | 61 - .../Cloud/Dlp/V2/InfoTypeTransformations.php | 74 - .../InfoTypeTransformation.php | 123 - .../src/Google/Cloud/Dlp/V2/InspectConfig.php | 495 -- .../Dlp/V2/InspectConfig/FindingLimits.php | 204 - .../FindingLimits/InfoTypeLimit.php | 127 - .../V2/InspectConfig/InfoTypeLikelihood.php | 130 - .../Cloud/Dlp/V2/InspectContentRequest.php | 287 - .../Cloud/Dlp/V2/InspectContentResponse.php | 77 - .../Cloud/Dlp/V2/InspectDataSourceDetails.php | 121 - .../RequestedOptions.php | 128 - .../V2/InspectDataSourceDetails/Result.php | 224 - .../Google/Cloud/Dlp/V2/InspectJobConfig.php | 197 - .../src/Google/Cloud/Dlp/V2/InspectResult.php | 121 - .../Google/Cloud/Dlp/V2/InspectTemplate.php | 283 - .../Google/Cloud/Dlp/V2/InspectionRule.php | 109 - .../Google/Cloud/Dlp/V2/InspectionRuleSet.php | 102 - .../src/Google/Cloud/Dlp/V2/JobTrigger.php | 442 -- .../Google/Cloud/Dlp/V2/JobTrigger/Status.php | 74 - .../Cloud/Dlp/V2/JobTrigger/Trigger.php | 111 - .../v2/proto/src/Google/Cloud/Dlp/V2/Key.php | 150 - .../Google/Cloud/Dlp/V2/Key/PathElement.php | 174 - .../Google/Cloud/Dlp/V2/KindExpression.php | 67 - .../Cloud/Dlp/V2/KmsWrappedCryptoKey.php | 109 - .../Dlp/V2/LargeCustomDictionaryConfig.php | 169 - .../Dlp/V2/LargeCustomDictionaryStats.php | 67 - .../src/Google/Cloud/Dlp/V2/Likelihood.php | 93 - .../Dlp/V2/ListColumnDataProfilesRequest.php | 387 -- .../Dlp/V2/ListColumnDataProfilesResponse.php | 101 - .../Cloud/Dlp/V2/ListConnectionsRequest.php | 192 - .../Cloud/Dlp/V2/ListConnectionsResponse.php | 105 - .../Dlp/V2/ListDeidentifyTemplatesRequest.php | 340 -- .../V2/ListDeidentifyTemplatesResponse.php | 109 - .../Dlp/V2/ListDiscoveryConfigsRequest.php | 256 - .../Dlp/V2/ListDiscoveryConfigsResponse.php | 105 - .../Cloud/Dlp/V2/ListDlpJobsRequest.php | 468 -- .../Cloud/Dlp/V2/ListDlpJobsResponse.php | 101 - .../Cloud/Dlp/V2/ListInfoTypesRequest.php | 206 - .../Cloud/Dlp/V2/ListInfoTypesResponse.php | 67 - .../Dlp/V2/ListInspectTemplatesRequest.php | 340 -- .../Dlp/V2/ListInspectTemplatesResponse.php | 105 - .../Cloud/Dlp/V2/ListJobTriggersRequest.php | 468 -- .../Cloud/Dlp/V2/ListJobTriggersResponse.php | 105 - .../Dlp/V2/ListProjectDataProfilesRequest.php | 329 -- .../V2/ListProjectDataProfilesResponse.php | 101 - .../Dlp/V2/ListStoredInfoTypesRequest.php | 324 -- .../Dlp/V2/ListStoredInfoTypesResponse.php | 105 - .../Dlp/V2/ListTableDataProfilesRequest.php | 383 -- .../Dlp/V2/ListTableDataProfilesResponse.php | 101 - .../src/Google/Cloud/Dlp/V2/Location.php | 227 - .../proto/src/Google/Cloud/Dlp/V2/Manual.php | 34 - .../src/Google/Cloud/Dlp/V2/MatchingType.php | 79 - .../Google/Cloud/Dlp/V2/MetadataLocation.php | 109 - .../src/Google/Cloud/Dlp/V2/MetadataType.php | 54 - .../Cloud/Dlp/V2/NullPercentageLevel.php | 76 - .../Cloud/Dlp/V2/OtherInfoTypeSummary.php | 153 - .../Cloud/Dlp/V2/OutputStorageConfig.php | 174 - .../V2/OutputStorageConfig/OutputSchema.php | 87 - .../src/Google/Cloud/Dlp/V2/PartitionId.php | 105 - .../Cloud/Dlp/V2/PrimitiveTransformation.php | 438 -- .../src/Google/Cloud/Dlp/V2/PrivacyMetric.php | 240 - .../PrivacyMetric/CategoricalStatsConfig.php | 93 - .../DeltaPresenceEstimationConfig.php | 161 - .../Dlp/V2/PrivacyMetric/KAnonymityConfig.php | 162 - .../V2/PrivacyMetric/KMapEstimationConfig.php | 163 - .../KMapEstimationConfig/AuxiliaryTable.php | 168 - .../AuxiliaryTable/QuasiIdField.php | 115 - .../KMapEstimationConfig/TaggedField.php | 209 - .../Dlp/V2/PrivacyMetric/LDiversityConfig.php | 122 - .../V2/PrivacyMetric/NumericalStatsConfig.php | 85 - .../src/Google/Cloud/Dlp/V2/ProfileStatus.php | 125 - .../Cloud/Dlp/V2/ProjectDataProfile.php | 278 - .../proto/src/Google/Cloud/Dlp/V2/QuasiId.php | 206 - .../src/Google/Cloud/Dlp/V2/QuoteInfo.php | 75 - .../proto/src/Google/Cloud/Dlp/V2/Range.php | 101 - .../Google/Cloud/Dlp/V2/RecordCondition.php | 78 - .../Dlp/V2/RecordCondition/Condition.php | 174 - .../Dlp/V2/RecordCondition/Conditions.php | 70 - .../Dlp/V2/RecordCondition/Expressions.php | 116 - .../Expressions/LogicalOperator.php | 61 - .../src/Google/Cloud/Dlp/V2/RecordKey.php | 146 - .../Google/Cloud/Dlp/V2/RecordLocation.php | 165 - .../Google/Cloud/Dlp/V2/RecordSuppression.php | 82 - .../Cloud/Dlp/V2/RecordTransformation.php | 155 - .../Cloud/Dlp/V2/RecordTransformations.php | 106 - .../src/Google/Cloud/Dlp/V2/RedactConfig.php | 35 - .../Cloud/Dlp/V2/RedactImageRequest.php | 306 - .../ImageRedactionConfig.php | 171 - .../Cloud/Dlp/V2/RedactImageResponse.php | 153 - .../Cloud/Dlp/V2/ReidentifyContentRequest.php | 417 -- .../Dlp/V2/ReidentifyContentResponse.php | 121 - .../Cloud/Dlp/V2/RelationalOperator.php | 96 - .../Cloud/Dlp/V2/ReplaceDictionaryConfig.php | 81 - .../Cloud/Dlp/V2/ReplaceValueConfig.php | 77 - .../Dlp/V2/ReplaceWithInfoTypeConfig.php | 33 - .../Cloud/Dlp/V2/ResourceVisibility.php | 71 - .../Cloud/Dlp/V2/RiskAnalysisJobConfig.php | 161 - .../src/Google/Cloud/Dlp/V2/Schedule.php | 90 - .../Cloud/Dlp/V2/SearchConnectionsRequest.php | 192 - .../Dlp/V2/SearchConnectionsResponse.php | 113 - .../Cloud/Dlp/V2/SecretManagerCredential.php | 108 - .../Google/Cloud/Dlp/V2/SensitivityScore.php | 68 - .../SensitivityScoreLevel.php | 78 - .../Google/Cloud/Dlp/V2/StatisticalTable.php | 165 - .../StatisticalTable/QuasiIdentifierField.php | 123 - .../src/Google/Cloud/Dlp/V2/StorageConfig.php | 218 - .../Dlp/V2/StorageConfig/TimespanConfig.php | 367 -- .../Cloud/Dlp/V2/StorageMetadataLabel.php | 67 - .../Google/Cloud/Dlp/V2/StoredInfoType.php | 150 - .../Cloud/Dlp/V2/StoredInfoTypeConfig.php | 211 - .../Cloud/Dlp/V2/StoredInfoTypeState.php | 78 - .../Cloud/Dlp/V2/StoredInfoTypeStats.php | 75 - .../Cloud/Dlp/V2/StoredInfoTypeVersion.php | 282 - .../src/Google/Cloud/Dlp/V2/StoredType.php | 123 - .../proto/src/Google/Cloud/Dlp/V2/Table.php | 103 - .../src/Google/Cloud/Dlp/V2/Table/Row.php | 70 - .../Google/Cloud/Dlp/V2/TableDataProfile.php | 1027 ---- .../Cloud/Dlp/V2/TableDataProfile/State.php | 67 - .../src/Google/Cloud/Dlp/V2/TableLocation.php | 87 - .../src/Google/Cloud/Dlp/V2/TableOptions.php | 79 - .../Google/Cloud/Dlp/V2/TimePartConfig.php | 68 - .../Cloud/Dlp/V2/TimePartConfig/TimePart.php | 92 - .../Cloud/Dlp/V2/TransformationConfig.php | 193 - .../Dlp/V2/TransformationContainerType.php | 68 - .../Dlp/V2/TransformationDescription.php | 224 - .../Cloud/Dlp/V2/TransformationDetails.php | 296 - .../V2/TransformationDetailsStorageConfig.php | 90 - .../Dlp/V2/TransformationErrorHandling.php | 115 - .../LeaveUntransformed.php | 39 - .../ThrowError.php | 36 - .../Cloud/Dlp/V2/TransformationLocation.php | 158 - .../Cloud/Dlp/V2/TransformationOverview.php | 101 - .../Dlp/V2/TransformationResultStatus.php | 115 - .../Dlp/V2/TransformationResultStatusType.php | 82 - .../Cloud/Dlp/V2/TransformationSummary.php | 321 -- .../TransformationSummary/SummaryResult.php | 143 - .../TransformationResultCode.php | 64 - .../Cloud/Dlp/V2/TransformationType.php | 147 - .../Cloud/Dlp/V2/TransientCryptoKey.php | 88 - .../Cloud/Dlp/V2/UniquenessScoreLevel.php | 72 - .../Cloud/Dlp/V2/UnwrappedCryptoKey.php | 68 - .../Cloud/Dlp/V2/UpdateConnectionRequest.php | 174 - .../V2/UpdateDeidentifyTemplateRequest.php | 188 - .../Dlp/V2/UpdateDiscoveryConfigRequest.php | 178 - .../Dlp/V2/UpdateInspectTemplateRequest.php | 183 - .../Cloud/Dlp/V2/UpdateJobTriggerRequest.php | 178 - .../Dlp/V2/UpdateStoredInfoTypeRequest.php | 193 - .../proto/src/Google/Cloud/Dlp/V2/Value.php | 311 - .../Google/Cloud/Dlp/V2/ValueFrequency.php | 111 - .../Cloud/Dlp/V2/VersionDescription.php | 101 - .../DlpServiceClient/activate_job_trigger.php | 73 - .../V2/DlpServiceClient/cancel_dlp_job.php | 76 - .../V2/DlpServiceClient/create_connection.php | 78 - .../create_deidentify_template.php | 96 - .../create_discovery_config.php | 86 - .../V2/DlpServiceClient/create_dlp_job.php | 95 - .../create_inspect_template.php | 96 - .../DlpServiceClient/create_job_trigger.php | 96 - .../create_stored_info_type.php | 96 - .../DlpServiceClient/deidentify_content.php | 65 - .../V2/DlpServiceClient/delete_connection.php | 70 - .../delete_deidentify_template.php | 78 - .../delete_discovery_config.php | 74 - .../V2/DlpServiceClient/delete_dlp_job.php | 76 - .../delete_inspect_template.php | 74 - .../DlpServiceClient/delete_job_trigger.php | 73 - .../delete_stored_info_type.php | 74 - .../delete_table_data_profile.php | 74 - .../V2/DlpServiceClient/finish_dlp_job.php | 70 - .../get_column_data_profile.php | 76 - .../V2/DlpServiceClient/get_connection.php | 72 - .../get_deidentify_template.php | 79 - .../DlpServiceClient/get_discovery_config.php | 76 - .../V2/DlpServiceClient/get_dlp_job.php | 76 - .../DlpServiceClient/get_inspect_template.php | 76 - .../V2/DlpServiceClient/get_job_trigger.php | 75 - .../get_project_data_profile.php | 76 - .../DlpServiceClient/get_stored_info_type.php | 76 - .../get_table_data_profile.php | 76 - .../hybrid_inspect_dlp_job.php | 74 - .../hybrid_inspect_job_trigger.php | 74 - .../V2/DlpServiceClient/inspect_content.php | 67 - .../list_column_data_profiles.php | 78 - .../V2/DlpServiceClient/list_connections.php | 77 - .../list_deidentify_templates.php | 98 - .../list_discovery_configs.php | 85 - .../V2/DlpServiceClient/list_dlp_jobs.php | 96 - .../V2/DlpServiceClient/list_info_types.php | 60 - .../list_inspect_templates.php | 98 - .../V2/DlpServiceClient/list_job_triggers.php | 94 - .../list_project_data_profiles.php | 76 - .../list_stored_info_types.php | 94 - .../list_table_data_profiles.php | 78 - .../V2/DlpServiceClient/redact_image.php | 65 - .../DlpServiceClient/reidentify_content.php | 89 - .../DlpServiceClient/search_connections.php | 77 - .../V2/DlpServiceClient/update_connection.php | 78 - .../update_deidentify_template.php | 80 - .../update_discovery_config.php | 82 - .../update_inspect_template.php | 76 - .../DlpServiceClient/update_job_trigger.php | 75 - .../update_stored_info_type.php | 77 - .../Dlp/v2/src/V2/Client/DlpServiceClient.php | 2469 -------- .../Dlp/v2/src/V2/DlpServiceClient.php | 34 - .../v2/src/V2/Gapic/DlpServiceGapicClient.php | 4978 ----------------- .../Dlp/v2/src/V2/gapic_metadata.json | 278 - .../resources/dlp_service_client_config.json | 305 - .../dlp_service_descriptor_config.php | 778 --- .../dlp_service_rest_client_config.php | 1062 ---- .../Unit/V2/Client/DlpServiceClientTest.php | 3672 ------------ .../v2/tests/Unit/V2/DlpServiceClientTest.php | 3373 ----------- 440 files changed, 207 insertions(+), 74448 deletions(-) rename {owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp => Dlp/src}/V2/SecretsDiscoveryTarget.php (100%) rename {owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp => Dlp/src}/V2/TableReference.php (97%) delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/GPBMetadata/Google/Privacy/Dlp/V2/Dlp.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/GPBMetadata/Google/Privacy/Dlp/V2/Storage.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/Deidentify.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/JobNotificationEmails.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishFindingsToCloudDataCatalog.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishSummaryToCscc.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToPubSub.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToStackdriver.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/SaveFindings.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActionDetails.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActivateJobTriggerRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AllOtherDatabaseResources.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult/CategoricalStatsHistogramBucket.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationHistogramBucket.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationQuasiIdValues.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityEquivalenceClass.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityHistogramBucket.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationHistogramBucket.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationQuasiIdValues.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityEquivalenceClass.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityHistogramBucket.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/NumericalStatsResult.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/RequestedRiskAnalysisOptions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryDiscoveryTarget.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryField.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryKey.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions/SampleMethod.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegex.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegexes.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQuerySchemaModification.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTable.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableCollection.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableModification.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypeCollection.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypes.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BoundingBox.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig/Bucket.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem/BytesType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CancelDlpJobRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharacterMaskConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore/CommonCharsToIgnore.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlDiscoveryTarget.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlIamCredential.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties/DatabaseEngine.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageFileSet.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/FileSet.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/SampleMethod.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStoragePath.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageRegexFileSet.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Color.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnDataType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnPolicyState.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/State.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Connection.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ConnectionState.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Container.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentItem.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentLocation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentOption.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateConnectionRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDeidentifyTemplateRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDiscoveryConfigRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDlpJobRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateInspectTemplateRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateJobTriggerRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateStoredInfoTypeRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoDeterministicConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoHashConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoKey.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig/FfxCommonNativeAlphabet.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/HotwordRule.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/LikelihoodAdjustment.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/Proximity.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary/WordList.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/ExclusionType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Regex.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/SurrogateType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/EventType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/Export.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification/DetailLevel.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileBigQueryRowSchema.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileConfigSnapshot.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileJobConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileLocation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/ProfileScoreBucket.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubCondition.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions/PubSubLogicalOperator.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubMessage.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileUpdateFrequency.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel/DataRiskLevelScore.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataSourceType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceCollection.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceReference.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegex.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegexes.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreKey.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreOptions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateShiftConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime/TimeZone.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails/RequestedDeidentifyOptions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceStats.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyTemplate.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteConnectionRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDeidentifyTemplateRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDiscoveryConfigRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDlpJobRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteInspectTemplateRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteJobTriggerRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteStoredInfoTypeRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteTableDataProfileRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Disabled.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions/OrConditions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter/AllOtherBigQueryTables.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseEngine.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseResourceType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlFilter.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence/CloudSqlSchemaModification.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/OrgConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/Status.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryGenerationCadence.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoverySchemaModifiedCadence.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryStartingLocation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTableModifiedCadence.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTarget.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob/JobState.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJobType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DocumentLocation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EncryptionStatus.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EntityId.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Error.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeByHotword.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeInfoTypes.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExclusionRule.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldId.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldTransformation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FileType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Finding.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FinishDlpJobRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FixedSizeBucketingConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetColumnDataProfileRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetConnectionRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDeidentifyTemplateRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDiscoveryConfigRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDlpJobRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetInspectTemplateRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetJobTriggerRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetProjectDataProfileRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetStoredInfoTypeRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetTableDataProfileRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridContentItem.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridFindingDetails.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectDlpJobRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectJobTriggerRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectStatistics.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridOptions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageLocation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllInfoTypes.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllText.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/SelectedInfoTypes.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/IndustryCategory.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/LocationCategory.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/TypeCategory.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeDescription.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeStats.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSummary.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSupportedBy.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations/InfoTypeTransformation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits/InfoTypeLimit.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/InfoTypeLikelihood.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/RequestedOptions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/Result.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectJobConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectResult.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectTemplate.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRule.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRuleSet.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Status.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Trigger.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key/PathElement.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KindExpression.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KmsWrappedCryptoKey.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryStats.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Likelihood.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Location.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Manual.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MatchingType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataLocation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/NullPercentageLevel.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OtherInfoTypeSummary.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig/OutputSchema.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PartitionId.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrimitiveTransformation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/CategoricalStatsConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/DeltaPresenceEstimationConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KAnonymityConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable/QuasiIdField.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/TaggedField.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/LDiversityConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/NumericalStatsConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProfileStatus.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProjectDataProfile.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuasiId.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuoteInfo.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Range.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Condition.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Conditions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions/LogicalOperator.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordKey.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordLocation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordSuppression.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformations.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest/ImageRedactionConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RelationalOperator.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceDictionaryConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceValueConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceWithInfoTypeConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ResourceVisibility.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RiskAnalysisJobConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Schedule.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsResponse.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretManagerCredential.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore/SensitivityScoreLevel.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable/QuasiIdentifierField.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig/TimespanConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageMetadataLabel.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeState.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeStats.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeVersion.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table/Row.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile/State.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableLocation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableOptions.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig/TimePart.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationContainerType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDescription.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetails.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetailsStorageConfig.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/LeaveUntransformed.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/ThrowError.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationLocation.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationOverview.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatus.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatusType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/SummaryResult.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/TransformationResultCode.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationType.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransientCryptoKey.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UniquenessScoreLevel.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UnwrappedCryptoKey.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateConnectionRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDeidentifyTemplateRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDiscoveryConfigRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateInspectTemplateRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateJobTriggerRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateStoredInfoTypeRequest.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Value.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ValueFrequency.php delete mode 100644 owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/VersionDescription.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/activate_job_trigger.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/cancel_dlp_job.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_connection.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_deidentify_template.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_discovery_config.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_dlp_job.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_inspect_template.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_job_trigger.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_stored_info_type.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/deidentify_content.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_connection.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_deidentify_template.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_discovery_config.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_dlp_job.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_inspect_template.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_job_trigger.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_stored_info_type.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_table_data_profile.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/finish_dlp_job.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_column_data_profile.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_connection.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_deidentify_template.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_discovery_config.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_dlp_job.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_inspect_template.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_job_trigger.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_project_data_profile.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_stored_info_type.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_table_data_profile.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_dlp_job.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_job_trigger.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/inspect_content.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_column_data_profiles.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_connections.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_deidentify_templates.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_discovery_configs.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_dlp_jobs.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_info_types.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_inspect_templates.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_job_triggers.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_project_data_profiles.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_stored_info_types.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_table_data_profiles.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/redact_image.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/reidentify_content.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/search_connections.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_connection.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_deidentify_template.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_discovery_config.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_inspect_template.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_job_trigger.php delete mode 100644 owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_stored_info_type.php delete mode 100644 owl-bot-staging/Dlp/v2/src/V2/Client/DlpServiceClient.php delete mode 100644 owl-bot-staging/Dlp/v2/src/V2/DlpServiceClient.php delete mode 100644 owl-bot-staging/Dlp/v2/src/V2/Gapic/DlpServiceGapicClient.php delete mode 100644 owl-bot-staging/Dlp/v2/src/V2/gapic_metadata.json delete mode 100644 owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_client_config.json delete mode 100644 owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_descriptor_config.php delete mode 100644 owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_rest_client_config.php delete mode 100644 owl-bot-staging/Dlp/v2/tests/Unit/V2/Client/DlpServiceClientTest.php delete mode 100644 owl-bot-staging/Dlp/v2/tests/Unit/V2/DlpServiceClientTest.php diff --git a/Dlp/metadata/V2/Dlp.php b/Dlp/metadata/V2/Dlp.php index b25541a6106d4cc8fa514dbe4987f1b2cb6a8ae9..ede415345d0961fc7dfba3e707f918f7c41c385c 100644 GIT binary patch delta 243 zcmcb%h2`)zmJRDzm}aioyn!V^mGQ!6MlC@`#@&;JwIlfXxVRjnT!Wk(J-r1z$#Dt7gn?!j=a&`%jbzyzGfSLBQi4ki>Ij$2;^h3Y Q)S}7|unRXA&3jS}0N(9Up8x;= delta 74 zcmV-Q0JZ2XDiHwztCJHeShIU8{bK>MlX;J-vuuz& g0Rr9uld6%rv!;>`2mwozwwg<`IGYXxvtXa&dw~icQUCw| diff --git a/Dlp/metadata/V2/Storage.php b/Dlp/metadata/V2/Storage.php index b0e44d618339e32ec1d3110b9092ac244c737a25..54322abd217f78acd1fafae8298baff681c16b6c 100644 GIT binary patch delta 77 zcmX?M&|tX1m5Jr8Hka~5Z{^K7Opk<&&A9kN5|eULgHqE{i&FEFQ-y@MxKa{J5{pwy d;xkhu7!?>bIE4hbI7&dOKq5?=Jw^XB0RXZ!7e4?1 delta 25 hcmZoLJYlfGm5F7mHka~5Z{^K7Opk;%w~78@0swMi2@n7P diff --git a/Dlp/src/V2/CloudSqlIamCredential.php b/Dlp/src/V2/CloudSqlIamCredential.php index 24f7585f2adb..bd753580e0b9 100644 --- a/Dlp/src/V2/CloudSqlIamCredential.php +++ b/Dlp/src/V2/CloudSqlIamCredential.php @@ -9,8 +9,8 @@ use Google\Protobuf\Internal\GPBUtil; /** - * Use IAM auth to connect. This requires the Cloud SQL IAM feature to be - * enabled on the instance, which is not the default for Cloud SQL. + * Use IAM authentication to connect. This requires the Cloud SQL IAM feature + * to be enabled on the instance, which is not the default for Cloud SQL. * See https://cloud.google.com/sql/docs/postgres/authentication and * https://cloud.google.com/sql/docs/mysql/authentication. * diff --git a/Dlp/src/V2/CloudSqlProperties/DatabaseEngine.php b/Dlp/src/V2/CloudSqlProperties/DatabaseEngine.php index 17cbeb998f1c..c21e1f3d23c8 100644 --- a/Dlp/src/V2/CloudSqlProperties/DatabaseEngine.php +++ b/Dlp/src/V2/CloudSqlProperties/DatabaseEngine.php @@ -15,7 +15,7 @@ class DatabaseEngine { /** - * An engine that is not currently supported by SDP. + * An engine that is not currently supported by Sensitive Data Protection. * * Generated from protobuf enum DATABASE_ENGINE_UNKNOWN = 0; */ @@ -27,7 +27,7 @@ class DatabaseEngine */ const DATABASE_ENGINE_MYSQL = 1; /** - * Cloud SQL for Postgres instance. + * Cloud SQL for PostgreSQL instance. * * Generated from protobuf enum DATABASE_ENGINE_POSTGRES = 2; */ diff --git a/Dlp/src/V2/ConnectionState.php b/Dlp/src/V2/ConnectionState.php index 8217300c3910..84cec3815510 100644 --- a/Dlp/src/V2/ConnectionState.php +++ b/Dlp/src/V2/ConnectionState.php @@ -36,10 +36,10 @@ class ConnectionState /** * A configured connection that encountered errors during its last use. It * will not be used again until it is set to AVAILABLE. - * If the resolution requires external action, then a request to set the - * status to AVAILABLE will mark this connection for use. Otherwise, any - * changes to the connection properties will automatically mark it as - * AVAILABLE. + * If the resolution requires external action, then the client must send a + * request to set the status to AVAILABLE when the connection is ready for + * use. If the resolution doesn't require external action, then any changes to + * the connection properties will automatically mark it as AVAILABLE. * * Generated from protobuf enum ERROR = 3; */ diff --git a/Dlp/src/V2/DataProfileAction/EventType.php b/Dlp/src/V2/DataProfileAction/EventType.php index 51cee6a4953d..0c49c9ad18c9 100644 --- a/Dlp/src/V2/DataProfileAction/EventType.php +++ b/Dlp/src/V2/DataProfileAction/EventType.php @@ -26,13 +26,9 @@ class EventType */ const NEW_PROFILE = 1; /** - * Changed one of the following profile metrics: - * * Data risk score - * * Sensitivity score - * * Resource visibility - * * Encryption type - * * Predicted infoTypes - * * Other infoTypes + * One of the following profile metrics changed: Data risk score, + * Sensitivity score, Resource visibility, Encryption type, Predicted + * infoTypes, Other infoTypes * * Generated from protobuf enum CHANGED_PROFILE = 2; */ diff --git a/Dlp/src/V2/DatabaseResourceReference.php b/Dlp/src/V2/DatabaseResourceReference.php index 6bb585aa212f..6c7574dd66a1 100644 --- a/Dlp/src/V2/DatabaseResourceReference.php +++ b/Dlp/src/V2/DatabaseResourceReference.php @@ -17,18 +17,31 @@ class DatabaseResourceReference extends \Google\Protobuf\Internal\Message { /** * Required. If within a project-level config, then this must match the - * config's project id. + * config's project ID. * * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; */ private $project_id = ''; /** * Required. The instance where this resource is located. For example: Cloud - * SQL's instance id. + * SQL instance ID. * * Generated from protobuf field string instance = 2 [(.google.api.field_behavior) = REQUIRED]; */ private $instance = ''; + /** + * Required. Name of a database within the instance. + * + * Generated from protobuf field string database = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + private $database = ''; + /** + * Required. Name of a database resource, for example, a table within the + * database. + * + * Generated from protobuf field string database_resource = 4 [(.google.api.field_behavior) = REQUIRED]; + */ + private $database_resource = ''; /** * Constructor. @@ -38,10 +51,15 @@ class DatabaseResourceReference extends \Google\Protobuf\Internal\Message * * @type string $project_id * Required. If within a project-level config, then this must match the - * config's project id. + * config's project ID. * @type string $instance * Required. The instance where this resource is located. For example: Cloud - * SQL's instance id. + * SQL instance ID. + * @type string $database + * Required. Name of a database within the instance. + * @type string $database_resource + * Required. Name of a database resource, for example, a table within the + * database. * } */ public function __construct($data = NULL) { @@ -51,7 +69,7 @@ public function __construct($data = NULL) { /** * Required. If within a project-level config, then this must match the - * config's project id. + * config's project ID. * * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; * @return string @@ -63,7 +81,7 @@ public function getProjectId() /** * Required. If within a project-level config, then this must match the - * config's project id. + * config's project ID. * * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; * @param string $var @@ -79,7 +97,7 @@ public function setProjectId($var) /** * Required. The instance where this resource is located. For example: Cloud - * SQL's instance id. + * SQL instance ID. * * Generated from protobuf field string instance = 2 [(.google.api.field_behavior) = REQUIRED]; * @return string @@ -91,7 +109,7 @@ public function getInstance() /** * Required. The instance where this resource is located. For example: Cloud - * SQL's instance id. + * SQL instance ID. * * Generated from protobuf field string instance = 2 [(.google.api.field_behavior) = REQUIRED]; * @param string $var @@ -105,5 +123,59 @@ public function setInstance($var) return $this; } + /** + * Required. Name of a database within the instance. + * + * Generated from protobuf field string database = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getDatabase() + { + return $this->database; + } + + /** + * Required. Name of a database within the instance. + * + * Generated from protobuf field string database = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setDatabase($var) + { + GPBUtil::checkString($var, True); + $this->database = $var; + + return $this; + } + + /** + * Required. Name of a database resource, for example, a table within the + * database. + * + * Generated from protobuf field string database_resource = 4 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getDatabaseResource() + { + return $this->database_resource; + } + + /** + * Required. Name of a database resource, for example, a table within the + * database. + * + * Generated from protobuf field string database_resource = 4 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setDatabaseResource($var) + { + GPBUtil::checkString($var, True); + $this->database_resource = $var; + + return $this; + } + } diff --git a/Dlp/src/V2/DatabaseResourceRegex.php b/Dlp/src/V2/DatabaseResourceRegex.php index 94a832755dd5..6425a372eda7 100644 --- a/Dlp/src/V2/DatabaseResourceRegex.php +++ b/Dlp/src/V2/DatabaseResourceRegex.php @@ -20,7 +20,7 @@ class DatabaseResourceRegex extends \Google\Protobuf\Internal\Message { /** * For organizations, if unset, will match all projects. Has no effect - * for Data Profile configurations created within a project. + * for configurations created within a project. * * Generated from protobuf field string project_id_regex = 1; */ @@ -55,7 +55,7 @@ class DatabaseResourceRegex extends \Google\Protobuf\Internal\Message * * @type string $project_id_regex * For organizations, if unset, will match all projects. Has no effect - * for Data Profile configurations created within a project. + * for configurations created within a project. * @type string $instance_regex * Regex to test the instance name against. If empty, all instances match. * @type string $database_regex @@ -74,7 +74,7 @@ public function __construct($data = NULL) { /** * For organizations, if unset, will match all projects. Has no effect - * for Data Profile configurations created within a project. + * for configurations created within a project. * * Generated from protobuf field string project_id_regex = 1; * @return string @@ -86,7 +86,7 @@ public function getProjectIdRegex() /** * For organizations, if unset, will match all projects. Has no effect - * for Data Profile configurations created within a project. + * for configurations created within a project. * * Generated from protobuf field string project_id_regex = 1; * @param string $var diff --git a/Dlp/src/V2/DiscoveryBigQueryFilter.php b/Dlp/src/V2/DiscoveryBigQueryFilter.php index 72be4db89f46..a87ee0ec1d3b 100644 --- a/Dlp/src/V2/DiscoveryBigQueryFilter.php +++ b/Dlp/src/V2/DiscoveryBigQueryFilter.php @@ -35,6 +35,10 @@ class DiscoveryBigQueryFilter extends \Google\Protobuf\Internal\Message * anything above it will apply first. Should only appear once in a * configuration. If none is specified, a default one will be added * automatically. + * @type \Google\Cloud\Dlp\V2\TableReference $table_reference + * The table to scan. Discovery configurations including this can only + * include one DiscoveryTarget (the DiscoveryTarget with this + * TableReference). * } */ public function __construct($data = NULL) { @@ -116,6 +120,41 @@ public function setOtherTables($var) return $this; } + /** + * The table to scan. Discovery configurations including this can only + * include one DiscoveryTarget (the DiscoveryTarget with this + * TableReference). + * + * Generated from protobuf field .google.privacy.dlp.v2.TableReference table_reference = 3; + * @return \Google\Cloud\Dlp\V2\TableReference|null + */ + public function getTableReference() + { + return $this->readOneof(3); + } + + public function hasTableReference() + { + return $this->hasOneof(3); + } + + /** + * The table to scan. Discovery configurations including this can only + * include one DiscoveryTarget (the DiscoveryTarget with this + * TableReference). + * + * Generated from protobuf field .google.privacy.dlp.v2.TableReference table_reference = 3; + * @param \Google\Cloud\Dlp\V2\TableReference $var + * @return $this + */ + public function setTableReference($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableReference::class); + $this->writeOneof(3, $var); + + return $this; + } + /** * @return string */ diff --git a/Dlp/src/V2/DiscoveryCloudSqlConditions/DatabaseEngine.php b/Dlp/src/V2/DiscoveryCloudSqlConditions/DatabaseEngine.php index 77ce5455887b..8438c6877e4a 100644 --- a/Dlp/src/V2/DiscoveryCloudSqlConditions/DatabaseEngine.php +++ b/Dlp/src/V2/DiscoveryCloudSqlConditions/DatabaseEngine.php @@ -26,13 +26,13 @@ class DatabaseEngine */ const ALL_SUPPORTED_DATABASE_ENGINES = 1; /** - * MySql database. + * MySQL database. * * Generated from protobuf enum MYSQL = 2; */ const MYSQL = 2; /** - * PostGres database. + * PostgreSQL database. * * Generated from protobuf enum POSTGRES = 3; */ diff --git a/Dlp/src/V2/DiscoveryCloudSqlGenerationCadence.php b/Dlp/src/V2/DiscoveryCloudSqlGenerationCadence.php index a021a2f9936e..5fc3081fab3c 100644 --- a/Dlp/src/V2/DiscoveryCloudSqlGenerationCadence.php +++ b/Dlp/src/V2/DiscoveryCloudSqlGenerationCadence.php @@ -26,7 +26,7 @@ class DiscoveryCloudSqlGenerationCadence extends \Google\Protobuf\Internal\Messa /** * Data changes (non-schema changes) in Cloud SQL tables can't trigger * reprofiling. If you set this field, profiles are refreshed at this - * frequency regardless of whether the underlying tables have changes. + * frequency regardless of whether the underlying tables have changed. * Defaults to never. * * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency refresh_frequency = 2; @@ -44,7 +44,7 @@ class DiscoveryCloudSqlGenerationCadence extends \Google\Protobuf\Internal\Messa * @type int $refresh_frequency * Data changes (non-schema changes) in Cloud SQL tables can't trigger * reprofiling. If you set this field, profiles are refreshed at this - * frequency regardless of whether the underlying tables have changes. + * frequency regardless of whether the underlying tables have changed. * Defaults to never. * } */ @@ -92,7 +92,7 @@ public function setSchemaModifiedCadence($var) /** * Data changes (non-schema changes) in Cloud SQL tables can't trigger * reprofiling. If you set this field, profiles are refreshed at this - * frequency regardless of whether the underlying tables have changes. + * frequency regardless of whether the underlying tables have changed. * Defaults to never. * * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency refresh_frequency = 2; @@ -106,7 +106,7 @@ public function getRefreshFrequency() /** * Data changes (non-schema changes) in Cloud SQL tables can't trigger * reprofiling. If you set this field, profiles are refreshed at this - * frequency regardless of whether the underlying tables have changes. + * frequency regardless of whether the underlying tables have changed. * Defaults to never. * * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency refresh_frequency = 2; diff --git a/Dlp/src/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence.php b/Dlp/src/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence.php index cda43bdbfc31..ede3a084bdf9 100644 --- a/Dlp/src/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence.php +++ b/Dlp/src/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence.php @@ -9,7 +9,7 @@ use Google\Protobuf\Internal\GPBUtil; /** - * How frequency to modify the profile when the table's schema is modified. + * How frequently to modify the profile when the table's schema is modified. * * Generated from protobuf message google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence */ diff --git a/Dlp/src/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence/CloudSqlSchemaModification.php b/Dlp/src/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence/CloudSqlSchemaModification.php index 4795c5accc69..38682145dfb2 100644 --- a/Dlp/src/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence/CloudSqlSchemaModification.php +++ b/Dlp/src/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence/CloudSqlSchemaModification.php @@ -20,7 +20,7 @@ class CloudSqlSchemaModification */ const SQL_SCHEMA_MODIFICATION_UNSPECIFIED = 0; /** - * New columns has appeared. + * New columns have appeared. * * Generated from protobuf enum NEW_COLUMNS = 1; */ diff --git a/Dlp/src/V2/DiscoveryTarget.php b/Dlp/src/V2/DiscoveryTarget.php index 2d370f3c3907..b9b4cc728e9b 100644 --- a/Dlp/src/V2/DiscoveryTarget.php +++ b/Dlp/src/V2/DiscoveryTarget.php @@ -29,6 +29,10 @@ class DiscoveryTarget extends \Google\Protobuf\Internal\Message * @type \Google\Cloud\Dlp\V2\CloudSqlDiscoveryTarget $cloud_sql_target * Cloud SQL target for Discovery. The first target to match a table will be * the one applied. + * @type \Google\Cloud\Dlp\V2\SecretsDiscoveryTarget $secrets_target + * Discovery target that looks for credentials and secrets stored in cloud + * resource metadata and reports them as vulnerabilities to Security Command + * Center. Only one target of this type is allowed. * } */ public function __construct($data = NULL) { @@ -102,6 +106,41 @@ public function setCloudSqlTarget($var) return $this; } + /** + * Discovery target that looks for credentials and secrets stored in cloud + * resource metadata and reports them as vulnerabilities to Security Command + * Center. Only one target of this type is allowed. + * + * Generated from protobuf field .google.privacy.dlp.v2.SecretsDiscoveryTarget secrets_target = 3; + * @return \Google\Cloud\Dlp\V2\SecretsDiscoveryTarget|null + */ + public function getSecretsTarget() + { + return $this->readOneof(3); + } + + public function hasSecretsTarget() + { + return $this->hasOneof(3); + } + + /** + * Discovery target that looks for credentials and secrets stored in cloud + * resource metadata and reports them as vulnerabilities to Security Command + * Center. Only one target of this type is allowed. + * + * Generated from protobuf field .google.privacy.dlp.v2.SecretsDiscoveryTarget secrets_target = 3; + * @param \Google\Cloud\Dlp\V2\SecretsDiscoveryTarget $var + * @return $this + */ + public function setSecretsTarget($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SecretsDiscoveryTarget::class); + $this->writeOneof(3, $var); + + return $this; + } + /** * @return string */ diff --git a/Dlp/src/V2/Gapic/DlpServiceGapicClient.php b/Dlp/src/V2/Gapic/DlpServiceGapicClient.php index fbe3b215eec3..540d4d85394b 100644 --- a/Dlp/src/V2/Gapic/DlpServiceGapicClient.php +++ b/Dlp/src/V2/Gapic/DlpServiceGapicClient.php @@ -3773,8 +3773,7 @@ public function listColumnDataProfiles($parent, array $optionalArgs = []) * of values will be returned. Any page token used here must have * been generated by a previous call to the API. * @type string $filter - * Optional. * Supported fields/values - * - `state` - MISSING|AVAILABLE|ERROR + * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR * @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 @@ -5217,8 +5216,7 @@ public function reidentifyContent($parent, array $optionalArgs = []) * of values will be returned. Any page token used here must have * been generated by a previous call to the API. * @type string $filter - * Optional. * Supported fields/values - * - `state` - MISSING|AVAILABLE|ERROR + * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR * @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 diff --git a/Dlp/src/V2/InfoTypeCategory/LocationCategory.php b/Dlp/src/V2/InfoTypeCategory/LocationCategory.php index e8f10a77b825..5d6155f21604 100644 --- a/Dlp/src/V2/InfoTypeCategory/LocationCategory.php +++ b/Dlp/src/V2/InfoTypeCategory/LocationCategory.php @@ -39,6 +39,12 @@ class LocationCategory * Generated from protobuf enum AUSTRALIA = 3; */ const AUSTRALIA = 3; + /** + * The infoType is typically used in Azerbaijan. + * + * Generated from protobuf enum AZERBAIJAN = 48; + */ + const AZERBAIJAN = 48; /** * The infoType is typically used in Belgium. * @@ -309,6 +315,7 @@ class LocationCategory self::PBGLOBAL => 'GLOBAL', self::ARGENTINA => 'ARGENTINA', self::AUSTRALIA => 'AUSTRALIA', + self::AZERBAIJAN => 'AZERBAIJAN', self::BELGIUM => 'BELGIUM', self::BRAZIL => 'BRAZIL', self::CANADA => 'CANADA', diff --git a/Dlp/src/V2/InspectDataSourceDetails/Result.php b/Dlp/src/V2/InspectDataSourceDetails/Result.php index 8082329f0d79..0660fbd48891 100644 --- a/Dlp/src/V2/InspectDataSourceDetails/Result.php +++ b/Dlp/src/V2/InspectDataSourceDetails/Result.php @@ -35,7 +35,7 @@ class Result extends \Google\Protobuf\Internal\Message */ private $info_type_stats; /** - * Number of rows scanned post sampling and time filtering (Applicable for + * Number of rows scanned after sampling and time filtering (applicable for * row based stores such as BigQuery). * * Generated from protobuf field int64 num_rows_processed = 5; @@ -62,7 +62,7 @@ class Result extends \Google\Protobuf\Internal\Message * Statistics of how many instances of each info type were found during * inspect job. * @type int|string $num_rows_processed - * Number of rows scanned post sampling and time filtering (Applicable for + * Number of rows scanned after sampling and time filtering (applicable for * row based stores such as BigQuery). * @type \Google\Cloud\Dlp\V2\HybridInspectStatistics $hybrid_stats * Statistics related to the processing of hybrid inspect. @@ -154,7 +154,7 @@ public function setInfoTypeStats($var) } /** - * Number of rows scanned post sampling and time filtering (Applicable for + * Number of rows scanned after sampling and time filtering (applicable for * row based stores such as BigQuery). * * Generated from protobuf field int64 num_rows_processed = 5; @@ -166,7 +166,7 @@ public function getNumRowsProcessed() } /** - * Number of rows scanned post sampling and time filtering (Applicable for + * Number of rows scanned after sampling and time filtering (applicable for * row based stores such as BigQuery). * * Generated from protobuf field int64 num_rows_processed = 5; diff --git a/Dlp/src/V2/JobTrigger.php b/Dlp/src/V2/JobTrigger.php index 7311b52bd590..a6bacf9daa9d 100644 --- a/Dlp/src/V2/JobTrigger.php +++ b/Dlp/src/V2/JobTrigger.php @@ -9,7 +9,7 @@ use Google\Protobuf\Internal\GPBUtil; /** - * Contains a configuration to make api calls on a repeating basis. + * Contains a configuration to make API calls on a repeating basis. * See * https://cloud.google.com/sensitive-data-protection/docs/concepts-job-triggers * to learn more. diff --git a/Dlp/src/V2/ListConnectionsRequest.php b/Dlp/src/V2/ListConnectionsRequest.php index 757b645d927c..e6370d01f268 100644 --- a/Dlp/src/V2/ListConnectionsRequest.php +++ b/Dlp/src/V2/ListConnectionsRequest.php @@ -36,8 +36,7 @@ class ListConnectionsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; /** - * Optional. * Supported fields/values - * - `state` - MISSING|AVAILABLE|ERROR + * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR * * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; */ @@ -73,8 +72,7 @@ public static function build(string $parent): self * Optional. Page token from a previous page to return the next set of * results. If set, all other request fields must match the original request. * @type string $filter - * Optional. * Supported fields/values - * - `state` - MISSING|AVAILABLE|ERROR + * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR * } */ public function __construct($data = NULL) { @@ -165,8 +163,7 @@ public function setPageToken($var) } /** - * Optional. * Supported fields/values - * - `state` - MISSING|AVAILABLE|ERROR + * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR * * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; * @return string @@ -177,8 +174,7 @@ public function getFilter() } /** - * Optional. * Supported fields/values - * - `state` - MISSING|AVAILABLE|ERROR + * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR * * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; * @param string $var diff --git a/Dlp/src/V2/ResourceVisibility.php b/Dlp/src/V2/ResourceVisibility.php index 3fa892868cfd..091e4e5299f2 100644 --- a/Dlp/src/V2/ResourceVisibility.php +++ b/Dlp/src/V2/ResourceVisibility.php @@ -28,8 +28,8 @@ class ResourceVisibility const RESOURCE_VISIBILITY_PUBLIC = 10; /** * May contain public items. - * For example, if a GCS bucket has uniform bucket level access disabled, some - * objects inside it may be public. + * For example, if a Cloud Storage bucket has uniform bucket level access + * disabled, some objects inside it may be public. * * Generated from protobuf enum RESOURCE_VISIBILITY_INCONCLUSIVE = 15; */ diff --git a/Dlp/src/V2/SearchConnectionsRequest.php b/Dlp/src/V2/SearchConnectionsRequest.php index 7e060c5c120d..0a7adbc09c6b 100644 --- a/Dlp/src/V2/SearchConnectionsRequest.php +++ b/Dlp/src/V2/SearchConnectionsRequest.php @@ -36,8 +36,7 @@ class SearchConnectionsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; /** - * Optional. * Supported fields/values - * - `state` - MISSING|AVAILABLE|ERROR + * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR * * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; */ @@ -73,8 +72,7 @@ public static function build(string $parent): self * Optional. Page token from a previous page to return the next set of * results. If set, all other request fields must match the original request. * @type string $filter - * Optional. * Supported fields/values - * - `state` - MISSING|AVAILABLE|ERROR + * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR * } */ public function __construct($data = NULL) { @@ -165,8 +163,7 @@ public function setPageToken($var) } /** - * Optional. * Supported fields/values - * - `state` - MISSING|AVAILABLE|ERROR + * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR * * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; * @return string @@ -177,8 +174,7 @@ public function getFilter() } /** - * Optional. * Supported fields/values - * - `state` - MISSING|AVAILABLE|ERROR + * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR * * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; * @param string $var diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretsDiscoveryTarget.php b/Dlp/src/V2/SecretsDiscoveryTarget.php similarity index 100% rename from owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretsDiscoveryTarget.php rename to Dlp/src/V2/SecretsDiscoveryTarget.php diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableReference.php b/Dlp/src/V2/TableReference.php similarity index 97% rename from owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableReference.php rename to Dlp/src/V2/TableReference.php index d66eac073739..ac8f92322b63 100644 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableReference.php +++ b/Dlp/src/V2/TableReference.php @@ -21,13 +21,13 @@ class TableReference extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string dataset_id = 1; */ - protected $dataset_id = ''; + private $dataset_id = ''; /** * Name of the table. * * Generated from protobuf field string table_id = 2; */ - protected $table_id = ''; + private $table_id = ''; /** * Constructor. diff --git a/owl-bot-staging/Dlp/v2/proto/src/GPBMetadata/Google/Privacy/Dlp/V2/Dlp.php b/owl-bot-staging/Dlp/v2/proto/src/GPBMetadata/Google/Privacy/Dlp/V2/Dlp.php deleted file mode 100644 index ede415345d0961fc7dfba3e707f918f7c41c385c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 72515 zcmdsgdvv2oR^Q5QyIbXMxBBasTir9``R29b>9Kb`J1@`l%*eKEYuc7PlH5Jr(~DM? z?Iq1~2_yl|lI4*l5I7+`vmr|o;N(DfC2+!q1Ww2an`MC|kU)lT2pkR^ z9tru~x>eu1B-z~?2>Zuu`%~4es#~}2yKcSs^3LXtcxZgFwq0wLJGJWg`rdeFvo^ld zYId5HW@CJPcVna08m~0BcIu5`hf0J5#r&>Hj7rEFrebTebF1xl$WnT%BF1b;{Lpr+i~kcDu34-EPb`c5Ymm zenE&zqug$f<4^I0VjTb5*xr6_ExZW<+x9gpHxl#WxW_@XVquglM&@bF} zV|TmKsW-RBsY7nNQhV>?;|!D9KD^V!Dld(@6T!l<=o^{sPOY_FZrqr!wJWXqPN&&g zMbnv?o3)OEF8cD`$JMX|uD&t;UY_I3OlXpq#yhRuns@Z^@m8&~+uD9X&YJ+-asG89 z0!^u%`i<1~c9XEs+-}dzxNCAjm^#ii>b338{`xG`YmMq`ZL@r<-fZo!YrdvPqwh)j ziQq;7C@ay3|c&Ap|$I@g!T2^zTS~j3l9=<1Es;i@xs#cwo zwE%AOUgs>($#_hB{1b=713mbRb($N1>qtg4NgU|bbn>j~SKg^lRpdcnzLeAe>4y!X z_R_i{ch%sWr)NviwEF3x=*hI1a8;xGokmQZQ&mNs>i6@(-)lsF>PMHYs?I#cEl`K6H?#R&PV-7L&@#sAMHhv zNZ+nBcB{3__C}K^plv-RL>+&W2wHnAHa_^?k?98}d1!R=ZqlUgWq(i1fi%0f)a<;| zY*npUacq48Wc+0Gr#zK5S`_lX>c5t%^7hb-TV*@9d2Y$o`l5>px%X z)TA8A?>1_aU^NWH{;dIVOfI?&hC{zu3qn-uvT3=srzZKnJ_m97ExpHjQ4H}qd7k@O zCwixaRpY&Yq;&8`Dt9WI_3fLI7RC+% z#OU-xhMBCWwnRj;!{QK;kNpENF`C(K@3{Yyj<}fu;92bN(W6!awCgt#hD5VSNDffO)hr5jsSV7$)K$&Hlt; zaZG)hYi@7UZys#$=f&t&eY@1Czg270H=E6>M91j#gN9iwI}NQ5iVOa(rJY*KCCaf8 zxtwPWfP8azID`lMtQc<4d2Wv}aZmRJXraDc1t~7ep4Mq`tiCN7SLyBDW~U~J^N5v< zJVQkLN32)GiHhVf?n>HY!(DgAPkq)UalF!m=-cj;nmbaT8#{vjqthl5!~Rk0oNSB( zb%e;F)UI{LgdF$1-B+&o6X-Ab4p~)^47G5VG$_&ZN_RBzDVg+5%tLpe zwB$89QY_#k0a*t@+$nL?J5^qQ{nG>D`0QS%ruI66#e)?|_9u}rI&BgqfnJmJcbnL! zbyOT8TT6~`)c%c_h`YZf#hKY_#dM)mytbMytz`?V>AB28COw~cj};d~nU&OHIx%dG z3L*bldUZ9un21@&M4bPgU0F>GxPPu@7ZZc-pM@)ni9_^fG5vb6v{qbrE-_@C5XY|O z^7Ezn+}zqqI$KN}whoKI)%k_Q5$mitxthD0&adV&*`nJbZdqb9{rX&b+5IN0BjQl% zNJgB81drpxEQ)sZtT`1lZb=AKPiSf<#n)il0zfY7YsyE zq&8^&f{3pJp`|)eBTK(W4P62o0a-92;v;D0xF(jc{Q{wPutz50Ov|e<-0iv`l zGF59*9BMV+(E?!H&{_hY%s1ajJ|zb6f7V4YEZ44wF|G9qA;|uqBQIdV?KV2r`@|7_ zAVGp8dd%~bOqKYi?oootyImpIf+W8q_OA_z!|H4iVUky1Y!q7%2bl~p^Ci75?mts3 zdwVjYr-krHD3S+#NvQXWBaJ2|2@a{q!8FpcYKFZVskCZXSBaEhFn%JUq`M=mu1}Hy zB<(s#Zy{GF#l_fR+1|8+uaOKQ4r4tnj%k~tBvEyQa5H=VpQg@>b7b1EA`RoEJqaJp z6dWe6HrK7^#L-Txe)A^etn3w+z3e|tJs|Fj=!GstZVst3+$gWt8f_(0Cfp_YRCTq5 zlgqMkdb`uwgJN;~&E|T^iFRkbI+6-oB}|Q`7m&QyXkK)PiblrwOyT#NC+syLU@LA5q$bo?RPc zM#t5}s1$#6=K7R~6Nqvh&OoRlMA0S+rLMA_{Y``7co5JTG3o%~o#i9_ia6e?Rbb1N z^b{piFzd2;*;-GKwetEFoI)-DR{BgTQ-&IQ`p=6K)n;XPiqiv;Ko*ppIijyv$9J{>_W^#@f_B`|Dvw2Zy!Z@6#rX z_Lo|oR3PTXG3C=JN#>w5ZIeZ+9Cyyh#3CRC4~rq$+kQx#ifUqcPpy69F_8#j-a08p zHsBa4H8(a$?Io%jw0{Uzp`TEQ*(yTQY`{#)-1Ty8j|ClhfWTJx$e9Hlnn57HC`P3c z;Sxc2a+IQ36M$`tW4;g2jN*{*kPubn-59h#0d37WY$Pzr5S9xkok%F=q-Pu_5F5LV zMro(q*<@XZp*B1GiL{+K**mRT0|M_>jX%>7h?7v;-62m`0M6WdHe~u=2HPxzdr7%d=epHDq|F+ycK~ zq|cHNwW5S5M6cq5M5da#(9TGiO|(*H-$e|5OSP2oj1a_3ZW6CYeA3r#= zk9#Qt${tj1HT52p!RopF=>ah|U#nL^qV?ZjL?uL42AtN1lep)pOH{S$^Uc=Ph zoiqB}JmAEKq@l&OnTZXkwMrWqo&$ZlV4>}Rx7AqlV9o~5foDzr7Non!gJ)I>Q~PUU z;+$`3j9azOdY0^m?q`-Siz7`i%v<%^JL>d5X*jk;XnyUDW(z)3oY9=>WdAZYJMU~x zV6&eNu&PHsmm27UTVcOj4#>Yg`|VlNzVA#he|SKg%7$Y2kSm@ zF1J=(T`QIfb4%%!RKO<(=hqs`y5Vc1~DS(&4ql_E^(&N9zNR;tVtyRYgP7^w-J@o)Wh`q zjDhi*W(SBQnv>rQn<@l6BhIzA%R6m^qM*IY02Ks0iyA|@`-hOf4oWDM#P3QuQ2o+*T8jLVyXO@=w#4th+`?K)9VwpDlCuMQ{{7}&|!*`x%v(*$9F>Q((%~#_Gd)yJTyS`dXUqVbdA#TP98Pmx z+<44^*oL3Jf>bo@RTOYu(>{Q|Chm7&OB)C|8`5%f=F67&!n8K^4=V^aIL^mM^e0Tzxe zgv?ueB?m0+&OX3q6aWv{6)=0a#9WX>SEJJ(=y#^%;B>*+KQbf|!O2@=;?#0(E>+Cr zvH^8Wh~dTM+-z!@W1^}2A_AJ3Y>H!|skK5epIXkO5EDfNHFZ6mpG{?6O=T1BgPY;- zYr2J1nJ_3S20_`uiG7G?Q z0yLM;VREU&1pP6e&aR~LmlJ{@E#y<#xiliA_+cTFT~1}^5hcYRi|PDIDtj$)jH0tk zx$I);GX9eol|kR^Jb)diUozSGTsB?6p9$)f$)_cV69hX`$fwfF2}^bqr)a^KQ`b|MmkLGvJw-oVhC-T3oTknz>DM!Jxx^WqtK-F`bSaz0fAa*qkT^>^ zX*PYebUmGt!#z$tvbp@#)V0JIEq^tYPc5$DuX7XxUQOrM5=m;anv?C%%Qm@uacvPh zbAf)zuN7z&7im$2Om;D~in%22vl8NH0s8h*DYcN#%%u|d(>x2SsZ2KU0QDxeuK_~ee0n9fm`|-PW#;%i%;gEUAlzjf z0pMXVcLnR9lz>uZ9wz}yb8-ZR5mY`im%~b5FRrDQOPTCK4irpBGI5xK9-5`tGs22s zwjNJ4%ZUI#mtw+R$3cgdso7auiDU8=D<`nyKW`vdw@Z;I3f4)LDo)LyDHq{7(>~&FGXZZ_L5K@d1C)0d`>hnR*7w@=wqq5LGfrh%mJqgT)hkK` zG->oI5gP#R~KsW5W)`SoA!?lh=gOQlpBnL=d`DRH69bveTd`L6h-`PLI#2eI(Oqm zcM86Ed~noBg+=KVuGd;Jg@mELEG#GZv(X}hd%L2OVf#Tc(w|O6L8p|OeQX$ouRK`i z1NgDy;+UWM-VkSCPu4()uvn#njT0xsC#=vvZ$O9-%4Al9AUw6%SjHBY#F*k6Vem{n zFZ2ao@md1nAD|$tw@T&h=JpKcLI= zy0-)L#tm`ytLo4;}9w=Z{=)bfU5A zPK?^b-_o*OrkeaRc&vgOevq+W5GS?8Q7e@@kPYj*NR{Pt(qrPuFC7-AqDTYT!6781 z`=Wp-Xp_YPXOMp{B*t(!qyLX^4{RCw~G7 zh@RQ}e<;n8|9(J>`d5X-vLRLi_ASe{!uz~-uaK>UooC^;?bO<#X%j8!Lbl!Ee zpxAN7TlcFJY9toX^9LEpl}p|+yc&iYgXQyq#&G42GsasH`i2^a;{pfTB)?Q}2E(;l zv-+V%r6k#r>DLZ|Lc^(chJP!{AuZ&1s|OiR*`>9r*WOc(Vq!A^-G}Fa^sYEv#NlLE z)}Bq-F)|fgcEEKEH+$BcC(j*_h4c1q8HxvT^klC#EGLQ`bsZ=9HG^R_OU)S`hX*C3 zl4GirHesSSZ??)?rS;v)TQvlzI0fp>gP=0{oJ|HlFX=I7<&eqG#KZ$V+E@>X^TDY% zn(rVdTPC|nvvx455xmY$BT`rf$@$DnEwypqU0SGvuMOMiqaAr8BG4*A+NTocH-~E#6vI^VRbg7{w{Cm8~5T14zd?PPBiI$2;#pZlJ1Xb zcUp5)Hvn=p0Xk&ESrZ~(UFb@P*8Sp4c!?6_avvx}bIu($Fef++?C9P|4-Ia+xow}j ze=BA=GxGn@^JS+%YW`-Fz%2o^b7k;DIomG zpCw7(Oc{D&Y`cZmT6K%adi zFt~@qhUv9y^S=a=br;5D=Gp4dW_BalZ#WdROBLDvZ4gMvAL39em^X>FjRT!FpNB+E z->HY?c@=luELyN6IiMX{;{{axuO^Tm3xY)sMDlx*+9qF!`H@jJBF0kne;%H0zW>O1XWI6?IiB zCk?*_b}4yBJZxy`$HqZf9@2?iB0{dqdU+k56;)m#mi+qz;!(r+ftgYk4AGMp22oT@ z{s4;d{y;Pp3+hEoQ(qH{CaPQi&$hsi*luL@A#tIbE|0tgZ#Ed~>=zB|@Y(`S?1wVk zThjEkm&Is62YfC2me4kK!$WvyOU7wX!x*$a+?}{m$hm)rZa9F83_~@1hXYP4!^o)rsIx z&Vam~ncJ8zBZ6b$zLBWH)vKDb33@`KS~iF0gRTNUh5UGAmozs@R1rtDr#l{_(|+&( zoZGmHHV6<6^UWRmH4%4jcOqIPhoosLKdQ-_OJf(&44{x#hF~OR^~npR_OIc-q5j!= zK;HG%DR1HVTTdX5#htwz)i`hKVa%H5#@;^v>S#6+d2~0LT9rQB+}78rO?h&9o)Y!f z(LQM-bdJvSZ@M7CH@iyU1Mn?##^R9u2MDXV2~iwVunOWF!gE|$2Dgm8>GIrfWZINj zsN=gue=qDUvX9lpu^>cZI3v@>vnMYqhT$#aT7tZ<7zD?jA=3@I4D|^^yC&}Q!zpoY z+-7;Z+Q5NQ`((=O^8-v%THTWBIh(*uHXk=Iu! z@{ik&`k4IVK_qvDS8eT3(4m2wxFC0DyUDB2%~ulvD00-vfxq74$*5TkUv$TJu- zo8`M);$*7P@Q(9_IO5!5V&=4X4@M~Bh7lHVu%bj68QYR6`a`BVq#NzfzmCV z1gG*YI*H^_{7qBzT)g^<0dd|>AwJ5qiejX*N!KDJt*c}JQ_-d_fF_Fsg<-!3g+fk3 z(%||dydIkFRgHp?X;T2I8}wy@w&n%4^q%BVA>2`ur-T)5MUr6)DJ1r%4vVu0S|d)3 z*sOmf*n_xHhMY!(O)K8uw<+5&&yA&gc0#c57pWXf1%p|d=>~9K=4(2=FN@Qa&9c0_ z))h4CCbJoy$Zew>gq$ZWlLq)KPZ>_y0`)AQBYXMK&w)ED66`PY0OMn8 zybLKlgo6@_E%++B>T~8y55XQOgP|F8G&H`DZt@n8)Llhu z2LvjHsZH4|w>LEq_KF)LM!XeE=-|MaBmD@9RC}|&;mn0IQ%$HMwV*)F9Uxc5c{LfN zo7Y;<2gqeo(X%=#`M(KKJSl{x+>Q=ls114#s!p{v4VDT}nAHY_|9PjI1{xtfKZ{H0 zehgcSxR61+1FBcoKqWI9HL5B8{!(S44YR)l3ZMQBcVbT$Gb`y5QX)}d$5+1x*>~5{ zsXX%Vkkhz=+&N0^L&D>H>RKtcP~tCxGBuCCTurAhBNY!#=wH-E_8+1qOS!c?eL?5M zu)QP_!JVf|_iD>}U%KbcxO8tLPJYg~Uk8H;&-lsqF4UWwM23za@1bGqBZa8P;R@ZN z#qDC|ZKe>c3=C(gHV%#=4G+Vm;K_FF9c3Q$VPM&Bi?ap_gIXG=5{M|jhDuiq%ao1d zFETdi66@quK%mS+k2QiKGHS>$Q?Vhvy)wZ5A(ZPPcHS;FGdH)9K5ktA$I$$}O?2IU ztIl`t$(}3W2sgL3D2>S1s4hDz%fpmW?i*-wPQvkhTY8U;8c!!9ez6`EHf63NS$l3N zl}Bl-Tq(1N^xQGp71zc?buWKAuvF5$l2D)Na-bE!far^WfYOjW7)t2{BQ zYuPy@qRRZ!LzJX@bqR^RNE}AC_0TNjzPo1oJ7}I71+E;#(LF(eR0{C@(%$O zR5b9%FnR>_I57eJg3jT-`i+GHUNH&L{$DW^Nb^fp6i7SFvRP+Inr>AGI!^N6$#21} zIsT{hxEO@2QD>}su!x$LZ!50Sz3Gb-|CNf4tUTlTJ^De0{U?K(MXJN8uLXCXz?G+}PPfT^BB%F*-;)3fH&%SfU6IA;y>Krrvog@xB~Emks;EKd5BbV+iE z*>q6Q`WOkx%Jl20dDPKcL1y~^xa642Qy4@^^PNG;duP6*KOLfMcD-`@(^UUOs=HL7 z<|TMq$XcO7-ik&|CV;dcsGZXr=tBS9?RQ#b1ekS+8&m%^-Ok%TB}U%bYL_&G?yCRg zt@c$O$^(K7KThkR3O`nOmOuy>g(EQ+=QIDPu)@=Un&K4sI?C-<#L0+3aRFjP&A6mB z6YhYmIbLBq1V4E0i!r#L0;>sVrno$t@G!IzTxrTl#U~0sd-x>(Oh;>ofA$=>zElhF zUGL#$tH@ZBOOpu%Jg|&R|IKFA{>}k$R;xCCtFleUS(1}eXF~H&lL2f1P?aZL>dnNE~N??pC5SRqeJOu~&KGK0x@Q643!(#rLzU+W@jm%F03sV zp@h#z*zSe3xw&+KD&WAqmComL`NV+zNw|~z19+}TTF-jwCz@HHzdzk~4c`7I9LZXX z4qxNt`Hul}%AQup&kO_)l}@Uc*1k%Dmj!aAPE5`LjLY>`JxZ&!6mdW(OUcA*{pnmDH>*`jWn~Rnjs?IVK?vheLTj|oBynU#&+c;U$ zNk2k-MDQA2Ii>p-@&+f!N}`9RJ34K;v1kS-Pvk=`XW^M!dbjY<%_I|_T@kh)j5=BO zq7;}Tn%Be;Dm+xhV+_{IA_Y>NBQLsu_G zY^2+;SMN8v&LWZ^`Un16#MJH%qz%JtNTylfZi}P+v1p3m(I^oi)AXQkZ0%?}z6(>a ze{@&~q&F7Tg9Z8x2`SU}!vkLuBbo!e*<4o&j**fw%s!mFO2~T@e?l4~J+h!LAen4x zce>D&We?oH9+vqm`pqDdJuMOGuwO6J=3Id;m~wh~nKpaId-i$;`bW8q_Xl>jxfVF5 z0rc#53Eo|)_o1E@33rnng`$BP>`UZjq6s_7EZMVV(-~Yl~{}tQ7)AIo$kQA?F%w4wTDTMSUkclp~+NLCGe( zPP2?Z2WP%M_HGJwJ)??*yX&?tMx4Ai9l8c9!5`2|CAr+OQW32qgv)hNM__PbCl zxY`QRijK7@2g)h<&8O640dud(0=g`qlo#TblrQ&+IE=?xOYPltg>;kFuDY+%ORnwB zViW%;?5+dCnm8+;cSX`kn;i`l!mP9_6=mU@G-y9WWsDY^bLa`MZ;MAYSiL|Ax6#~% zPDYg(EBFswNb=U($n?vuUgj&U;vYq?9K#SG#0Sc_2S{KrBue{6j2*DIWCTaEWGrAf>%Sh3#Don z#gk{mDb>Qa-^qu>gX+6^hmuHI7cRnKv7PSt4Nx_4=B+0C&u>z&W`UZMj|5;T(;4WN z@7U@bBX%X4(l`9DBh3{&pHY!CtN}M=L1MX;95BOD3<8so0+0Mkde-EaVCxJYHEXAj?rPTL;~W7%dNt4a;-+dX{TWVoyB5e@ zZ5hg36(;epvLNF*lmKI|iF1oJ)LD}l4DQQ;S7Lv6Oq{0_rvTu##?jsEI3)fK)qCqS z-%{^ENDrX==G@92LR9*Q%*=rwo_CJ+*t?xFmjMUkLi9vcF*rQuR1eUX4xRK#V03G0 z8%b<<;Ke^{`*qY$M&dg?F?NsfkEeLf@{t3>P@0^^{eE62aC<|`9(mJMgp`V5dUe$8 z$HxnMrZlJ?r)yQ5BYAua34<;SJ@co0CriDm&_lhme;BCX^LlRpQVP~V5V8NWd0Cvo z*}ONimc_c6BIfI;Q45uWo+yEGppm@MaRreTPWw zUx4i3-3#>4)9#-~1pwTuNgt5q24-{D%d!8iVz~jp2V%Ja81jLu0P}*wD&CXjYVI0< zhdH_2wHhFtUfeYRs}JrP=yCU`{v*mGl?n~sn!@?i5aCPk=`jyVJ?6aC<$=h6^Men~ zew-gjC}^SlQwc0d8EK|Sa^$sCXs9TbO8iVKIFVvf+pNEe$PS51mnk{)bwIIlU}^5w zc$I=2?3JHnBTuCHu~FVI8Mp|j17vE%Z4^TatxwVFv*IY>Ny#xyroAPgnL-hFWBKo* zQ2nbCqBDh zX*#C*qhWxse&J5>n*T7-(_)whf*y4YE+n=I<-5mhoSP8pt45oAcR*NS_yN-#_Wuxa z)74uqqthm*LU`(F>Lm}yWsv|f2p1q4U;dma^z4DgGXxE&M5%Rp$c)0*bXObi@U|gK zq)t9MZMtgdfyUcB8D2IDFA&gWthIsr+#{YpDc5&Cjk4g&rRDS$yjJbMkb_*`Vrq67 zmv!>F1uE+vqx4@SIpA*19BQDaR&eLQ-W72dA*gx{K&XfvQDz&N##ANU1%_Jcxbcu( zM1gVraR7Yvcwvq%KV-5fxQ%NKa8c5*GGl^nNKpI4A&=1x!}*j45#BTHzLVVDx8v!) ztm4>Gnsa=Om_Bn)gp}(cGlyQSjpKZss^ZY;=Tk~$=~2-Ba+6ohGq5_nZ{Wow^@vj* zMG9^s9XO$!sh9^YAmW>HJm41^5>Jb|zYyP%_c3JMOZU5EC3Xgv5xl@_RE*^a9^b^( zGh`)lm6%>j?Fcw<3*`hc_@4dk zK$u~{@bm+%VDls*y4_yZ%ag(d@0C$e4aAo)zYmI|&CVv>HDox9FVh_m!#t?GMUJ5O z#^C_raS0fr7OyFIkZHV`PSeQi#?WHN#F=R5L{m^{vG4Xxm!twKgkFjl?JAAkYK^76 zgDMk$*GrIsxki^A5GPhb-Tr&@_?X^q-O@ud?-$2#THr{mmdYELnc9}HH=M3;BNVr_ zgFu85@{D;?8i5{6u1~55*t`|o;emnx)}nW`N7`WsijNkqAcjYettlN^S6VT}M!O&a z;@ZUu#R|QD>)LTt*Ta49ZV0#T4&(Y|i4=9lg*jP{E}*Dw#cRr>BiWxq7NRqw&`G4| zDy0-`l}jkNfdDIZNS|&#I;K=a2PUN&Y?W73Z*{^cy2=C|0?TVKy+!4Kl^Ys>YJV41 z3)gfO)dIOe;j<&AnEomcr>897Cah|dt9um!n)~55{F7z@R~x$&K_uZp%ZXWSp@E< z4vPJ^ypl){#2DZ!GY%KxBW2oZvPafoX~88c-+=WoAt;_wAW=FPi8K>sYoQPXMp6d_ zM97w-F~Idz5`9ntnE(d?dW4Zjy+t17q+Bn$E3Ynb+JztHoM*)78g9ni$hCGknkiOu=)&= zN?~t{QU7o#DR`cqlg6{t=~6noh^OoVZY^8fPcKLpaLYZHr`PQQ&D9m1m1~99=srBX z-yE z12)W)XrmWz{hf0NDdfqx8~591hs7|*lyICp^%9(L6tUsH!ck9)A#g>!<3tR4blPMR z@nDni1!EnZ8m=uKmGM7zuxm5Hn4U;a5*nV4fvkR&L?tIvX?Wxw9+@_UQ!?C|7*)ah zggjs&F3#o`=PmOEfo{eZ^3Q<)s>=m?Oyz8LYkyH3!PDE^x@R^uT!WlQtxbcm<8oo$ z27nj(O*i1j7yKxjI*y9AI%#|a2h&_ThO_SxLt~%0bBXV$>}7ICv%j398Ev~MjyRi* z8e^~KW=ryc(!dEpPV{OT@5M^T8vf8;wgGzklirR+umKF8)1xWQ0RP?a0sV~0Y~cdX|lT4|>>+Ub8rboD-M zJ|_}Lfnl20p-}{S-8-1GD#qSr!uEfTq242c)(pl8Si8}BsqAP--JL3F6{;1>Cp@8`y$r8S=jz_;ocAzh!K2#mSz7FcuwR= z3c+`{#ody`f%9AfX)44+;x?*KJYbx#Vgrka+dAuUQoA)O-GCgC6ROH@qr)2f;^B&=9(Q!#^RZP^CD`` z$y@3<3?jMX6Q}d|49M$i7UlK_G(x{<0K5cjZ1GVkn z9~7hh2?Q*xG?gc8(Y2A1u7SWSH+kFq&@|>3kc9#}0-F?4JX_XWgve!-AG3$S?5eWsgg}>>;ZUq$4`34j2>3ehwJxVYn(4 z+zLv{VHH0hrP+P@Z?GKJ$D)^mDmWfXMlGfv3Uax{{ui@<-K!wRpnKihCD?eiDM=cP zAFQKp-NjDdTTSaWUt|hRQz==mh!br|s_yyJ8kQ-l?gwSou24XqwJU!IeHIQ%JX9j) z{-wS3RvjvW^!32K5V#_AknCgYk{H>PU`zE*ZA+;Nrlc>P0OVH({5ym8_E&=-eABu+ zJMV6%gI6|BgeHk1KZoSvSQoGj{#ehl5ZXPiE-(1JA{5 zT$W{!ipmjO*+GHInhcW@=UL_KHS%5JpM(g9`|Qiu3&ROGf#jV0z9K?v)D=b7!NhhR zip5DgFFXe3s#wsHIK871@v2yh&ePRw$Ykh+L7G_+O2^7ul5%6C5C(zd6UW`H32?$&k`qFxLj>Y_x{ zqt?R_hzdcucbNK8x_&}n>dB9lMJ3ZAPUso{tzlGc>&9>Fq_ZhGlk2DHc=A3|3UyfYVB)gDQf6@}alidB6mg0;K>iRADI$RkS#Z)b3X>&S*F`0l zpb9v#gpuiPRvQX0>6c>htYe8$#dfrjb_?oVTXbM7ToT8t#3f|Vs6kgJlx=46Qur_l z<9k%kzYTkEx2*y-rrtmjkqz07yX~1@K|vN22aNKfq9IlMqR~_z6qen;!Gg&Jz`&kS zAAN*;$I7eEZi72hk%mkEFzuhkQ@@@iuzgF zBX51i1MMF;DiR^q>px*HE0n1G6-quFdsv<$lk!a{;Yg*-ZMc9tU+Rcf=~UnkB3I=I zgQJbU(lr#_3I^X8sTh=sqkq#xGj^Z+1;<|hg4XBcHw1K8@Zd{QenCmmja@u%ha>_S zI8}CJ_~oR-?^ z2rF*aEnQ9R2%k3R=szPY$?yG#pm*5%DRCT^8|$3O&L^j51u$HGJJqg~x3?*;mPI(H z_EPYA(1IUh1J~w)Khm|JK_Y7=RDQK>kKX>IH@@hmTHH+%ruVr9iC~aLPOlwMeIz9h zM)A|=w2@%aP6w6=5c;SiuMY67db_S3EvE3ixiT=6UwLY-I32o3)&xLxm#jr9AFbw~ zjFl6TTuiq-(3)l8oqZs{;Ws%aldTQ8U^*R#tJ=o>I6!c=ozD=I4pFb9su* zVoTefZh2bkNq#sN6uh<5TM@$*2b6*3hcq28VciUhb*xOafcNyO{G z^j3oi?u%#ZPfCZVL)-DuVj^kLdmRfE7T`8U6~W<4ib zLpX^AL~97Aqc+xDaWvk)@vkzYJR zaa0n;rFND_{fg#U+-s3{oIv)t#L-55O0p;SC6`ykIhT^RNsB^(=L#H&bX|qm?5Hu) zltt@Rr!kwIIgxb1?QYlUt`{z;D+7zvy;0-*)|}?jykdYT_=L1jRH&k=Pi&@Fc_ zJfhGiRaF+1CNnoo=7DdWI8naAh?y>_A1PaXN9> z`IDL?j*y`*d(f})Q``Zvn9eQcQ>#nY;1AGq(JzCI&^w&6V?GUM!hGT=UGC?(;DJN+ zl;JUFv{wtcY+}?I4J%IPui#0t<4!lcwy>BcRHYLMcuY<*aOb0(+X*OVr#wHn%e3sg zX3n17MAhF1)E=znmNRqLBJ&0T)8D9=TBJGzv6)XpKlo2E(Vu7P`u-J!O2|nz^@aQ` zV5qP5t0MFZ(dKL-oP&U`K*v`0k+l*Af@I?);$=m0G zzzys`D{Ea?^v>`WvRkB^idiTPIyyanfI*dwOuj*WT@qO&b#YFQ5q7GP26oSenmw$7 z6Ul!(AWraFJs7as#^;l+9bm1p_>2d;2Nwuo%F@F)`~fzqmAj>WJiGmEJ>l=d6dtxGJfl9J#Y=bC*L8K_cf_dTL|D z&sWm(nYEP?-gc7T2I#%ou@I52a9tYfIovQ-ULYoOqjD8I;rF2K4n;v#;YJ{Jn{S5e z^Sz%6TW)U{#`J)ef~7LsOjWDgZhXCpOAxwW^;G%~5W9WtZ&1a<+)s!$K-p?{tOG9X zjJF0In@#dg7F|Ab>($8&4Zf^(QeRVd?~uhLITUK;R%P?A+RWbMYGl4?si+^SP*$8> z)v>pCI`uPUr?TaHGP&(CX>qrBDH$XUUJ_#;P>Xb=Iv3JL3*TCrN_SAQ1voQ z!DP;eeY*jM4O6UBr&TwQp6<3$4XTXWMa0?F#nZ>dg`IM{EuVGg`YJjP z(DS61#37{==!Is=TP|q(2M2|ve{oTO3!CIWRvXIDc;MmBrH1J4=w)$2PYD^!JPF02 zO_!4mtAj?9M!gHpW=5@Kd#HzVuWk3iEl?Z-d~;_ zeqg-PMdx?7EjuH6&Awe}0s5oY@cU-6Feo$gCFk8fXi~TiJeyg3Z7rR@R$58DUdrdL zmI|5cxIFy&Tsl1uBX59$;wz|=N617-JfDVboxVb)@nCS{7MXt9@6f~-i}U^&&gnEF zIX&D>c7_HZxlg#6nMDb{Y&wq}Bja4ZDOj4#&C}Bzc;CbQrl)~PkumMG<;%c>6Q4ur zL;noqz%X*1ws;#nmyPl@U?8^C<=tppVlJQ|CII_CpI%)~q2?dZw}zsBG$;LOK7%W9 zxoj$b4VF4?%jMJaxFiR}U@a)um&YIJJTP0h3}*xoIhVh-TFl|CM21MOmM^TP;h2Dp zy^whwS5+nUSz#p?hICK3e;$@83aa}J@8eKe*|8O(rPMSOvK3pp~hQE z6_((nfIo%&2c^PNW}yg=1a?FtWe;#%@}(jQZ{kejcrAl3@SpNHdmE7PD7%xN5&k)+spp4b;t}cBamosb!xLW< z6GvCb#a-XNDH+v$;@nEAIJbm@AH|}u1^%BG)^J|rC#(R6+5anXfehBi4FoDB4x6LRj?hNl}yP> z;gDV{WD0)6^V4w;XwE#RwQ6D_{d0=8Y>Y|XWia|@lQE`}b zq<__SFB|XUg6bgq28dSF?Q1D$mHftG{tij@q42gOdsUzIN~VyR%`9h%LG}V(=TzwM zG+JGoh5r{a0t`IrcNC<}W#^XH3UmSdIOz>ht?&)n0c75M;uLs7A{5DgP}~QWM?#Rq zFlj5Hm%DHXJWUpJxkVJ=UBM1YmorhZ=jXXKV0cA}SZ**dftT%1Mul)55f5hRyxCglfREZ1^p`glI zHbe4(7!Ic+M$HzW!|miup&N&OQ8OB#^Aq|}PHAvr19gcVy~go+h3$rO{_# z-C!oPqNnZmMK|@YDA3J%7s{4<3s?ya%Txg*)KV|am?P!f6;_~O>TqIyOD?csPejk! z-LF zrEc3Yh24Fv^de1XHqcltaQ-tXbtgb>>(kaT+9gUGAmQA;j_19++onA|?I|2GrFGGuJ{=EHx=;l2~vi=Xy&elx;Ge)#Ww%#w= zzjEL+sRzkH7ee~Q-5uzfNFv6gWoiSac>}2Vr2zUtKz{6lsN@Dr^9Drr@lc?t|C7_a z0kXe~epB=3r+EW{&3lhz{XD!Ki1h}sZ(^$9ru#+xuY%&G!&zeY7hs}G+KI$e1a_~# zU>zK_*C(vL@p}Ck>p)1g{wuD~F{kpAhGnWp9o1N4)x>R;fCX7Y4)@VNC2Ed!0=KAi&WO{3- zvu6j1bz;B7I&n9|Ihy7>vr0OEc26J8K5Cq_9jM_uv_`l9`8 zbdP?@xZ4u7D{9aer+H(7J^C8Y`c3c~$i9eOG4Y$o)(6;CKSr@>5^Z5Tw=Gkxc0+rOY7-MPc2h$1e+Go8gZXHg z7|9SE%t!a>$r2pQhs0y_a2oTW<~>KUerW)yN-{(l#=VjAm^x_Oo5X66rY84^i=^tTR(1dCX={)J_Vx(6F-OqvpIT#)t;f?zG)`HOG5th4rILRUx2W`vbh7PpTXfQF8P;({PzC9q?9IS-ohL1ZqSP3;V zvIYk$s!JEV_=d9n3@?nbbaC-wWD3EC8ZRdC6QqfW{%B%i|1{yX%DSvQaMmrnuWC_o zX8-HtmdPm-ZmKcRy(X`HOA3b_`(orle$!#cZjp{EBpjT;fwg!OP9|zrQXKPi1q69RIEHSaypCi-h%ah)>%Qd3E z_05hWG%#x;N|f2B*THkyFG{`xC}BsaGbx3TkYwEJ!^!9XQJ7JZ@}+*=q0#-V-^Y0% zd&<97<9P@--7i|c#3wb{eRu*RX6|^=dWwXI&elhi8!@oxc2_rIu(4jZ=~zi4$d6U0 zFc02c@w*W<8hWt*;9?v!^dkd;ovq)ZH)_}}@z2wEE+SiNM3_WEV8gw9+v8pEvbW$& zLF(6E=-1sB(b@VnB=RUWCsRu-Q_R-eNUy60qyKVjrM3-}50=Whd?t0AH|3(d{)8`* z4PLPyh&BP7BKjl)jJ`3yHh^3I5aGllNvMxVisMhl__e2vUY`jUzNSjO`T79eegtVv zJ=SA3v?CXDeOh^8`XXty+J6=kapFw8xyH*rP7}TK9$WiCuTH+IRvOgF)g};)nw&X4 z+U6;vx%C5}N_C=m;-;POHqui!oi_iRCwOKu@ zxPeC{`gBZbhtZ@SDkJRG4x_vHPgL7ie^;tf7rW%sL^SU+pC;VX`dy%zwJ1L>jA)K( zyiYX$3DA6&Nc|!sIizNNIyUW5$Ad;gU=>Qgx-{)k$AewG)E3?SBC6;_5^8kw=cYM< zDR^Le4rKjX+)D+23t-!n@e^vfPgH*fsCFaGKNqw1h1csd)`5|F{c)>rj9!1*ItV(g zUmoB`S^UUsTc-CHNm2&dYJ7GJOozHCA^X{Ykaf@-edt4c!a;9z`>ssFMX&1Ys%YVH zGno$|IGk8-mzZrE~qOyDxvBk*PpZcOcV_k?T-Bg6=uGSwR^B#)|9uK2ji)gEt zZ?v(3z@@9hUA;aHJy##1Xj;2I4c*or)sf8OQ&>%ix{V?yss-*uC1;sx&7HR<Sp2^*Z+#!n^EUyv`HuHhqs}8w%fj9Sm*nn|nq>+uKOb+q6HI zq@le}+Zj(E;N?GZGW`%DM{Ewm2d!%ym?C7shI($Mz@iJ%Ml4i&)W%`TsgdN|`wXGG zy`*>S+mJLbPqc<*Oq%z#+Q*b%^6q^akwpbuwqrD-ErKmPx4Ii1C(5sHL8`DfSl8LFrgwrJ_%*z`?>yTNaDCeraFo zNU*#0%}y-U-H;x!RJWmCzv;C4X{wJ9sb_D9roIQ0W4DSsrg3t?hI(>+9M_bW_WQ}) z@Xr&RCAsjalm%|66jS}^)_+V*Zgx65?U|{mciwp?@Z(f@x3f7Vt7SY%#mP6Ct*zPL zLG5>R^upK8COv^Wg~4&h1^?Pve?k8D`vy)fHk&sa zHGXP)5UZU;ka=F-*4QwGX3tr8E!r^BY&8g!4ESt_#xGbtfYdUu|M)g z-F-@N^A^&rx<5}x{Oo#$JcU-=KJTV(+z>Y&!-pXHa;=-??fQqyRQGwgsV;Ac zo;8aaYke4#>NKBvOpL4lT^#SUc59EnAe=8$@TOjwnR&S0E^lRJ2csXqdXK4|GlJPliKciUa-BP&Hx}M6uEokD6VvTB&#Mps1x! z%mFEhBV8Y9WXmwsGkGxGQZ!@hthi;_x+#xHf$0Mn%csOLq_3$1(XwS5|GTGJk~&sxRo2vBqV?P2P}VGh zvTyGlPR0XU)yEfC%sQM`-pVG?Y5rcp!h!@oX+y9-2L zSm&EC7g&lEFhvSy#oPy;EVpjUcCF)ClRt%ceLU2=Q-cU8Sf)9&5fLMs31JOZ&xmPZ zP&by?LK&`FWNcwVoT>IyvIe?IHlp}bve>&{n0tPq;|p}?{`}t~kiEDlG$6*c(UUX9 z?FE&+rM*GUh?f5~tY18V{UF?dTb=4rr{1j}*SjyJ&Tg|^l|Db}w5q%Hy?V8hy&_zL zwcwUU^F>1uu#6U#B3mJHb*v_2N{7go-hfYz!I;RGH1$N+ zm5mkV=Q|-n4R52c2cW2|vSoAXSo{4Du~{n%6;G~qMR*P|lZ?o@lP@1GrlL(nQ2G!u z*2FaR5%U|p^)gGl$BU`yxUw`JsO~8wDRdHrdoadyg*n5IBuX}5O(8a64w1}>My!oh zF^UDSpd}SoxQ(*H0c6PeK%3ASk}71c}$W zsYse?*-oN;yqL>VE88k|EnCmqExbm7q~TffnwsUCG^q zxT{r2LyX#Jp?%TKL^%#C9JzB_5M%j6feg=~jmAN?bx4m)ePUpDQ^+~Sa0x|Yxiv`7 zWJ>PO%aERp*b7LV=r;2SjlScPPZ#t_F!+TU*FzHlZ}b!r*g($JQ$$t)?R$-;>93_e z8B&m?uoy$INjb~%5O2e(F_!yn1g`r9yQ6%GSaC|mwy+J^p?Z!<9;kbcuVJa~tHD^^ zf@>zxkO-WSpa$9sVzn#f6oBlVmHT=Ll7R~eWk`E|Vr5ScP8Q##?1dI2kl1jSILH&$ z7%n2ujH7+Oj$qyQh2)#>WMJ*vgwgkz@A~ozEK_X8Mv$H@(%X=$ezDv5yi;!;N!^#N zi|r=|H!l3nzE-N)h^O>Bu)3!bO{puh4Lkn?k}cV^u|Ml${80cv|9y#IC8-K?V1lNQ z#}er(h0#R*He?Pk->T<^Nh}IR7Zm>ndv*o6Bm>Q+LG@b*qA9~YjjG}i&WHFgXxL*| zeuc+5G5v0c#H>a6pTkBF2v}uPzSJQ$Htl48GI&L7DL`Mah}1EHt3o8+d1#R*Xl*gf z^_HV_IseZnTnp-VZ&`u(5KoaT;sRhX#NIj51=qm$;d*~+6AKFo3tTdYDN(J={ZZi_ zyg%<(x@~}kyg{2nOn3~yETM^IZN$*(Ola4q=dz}71ZfMIC|=-{*e71&fAS7@=rDO4 zCs15?53W%o0vBNxu2Ktg5=~4Vkt9SXrslxyK4e$~*qxatDTpMCTMJkbjB~yQsTpf- z!OhOjVXIM<4y)Z-vvPsUtwOZhY-J-t7EU4M7-Rx36KO60NX6Hr724hNF z53LKIkznJjZ#pIx9kO`$SuA$CN z3p1g30&7lLDX!5pMK3oR1)VbW1UaL+|YlFk9o zfvZq1brB%3g&x5AV219vs`$|KFeIMAtaF@=%68#uUmZzb(PZ;%;xzbsA&M?U43&HW znUiVXR25GHXNY0RS!0`hBar{H0n(7i(t!DjjS}JfcgC-LszF)q=G-?C$gn}jTM`NY zI6Ip*pN@D>`7hIv@Daqx7}VFIZsok^@w)Zl>RU3kwVUrkgxl?<^v((2dbKGCFC zWXcgBA^ZeZ*qViA)8Y!7#AePbG^iS@I=0Oz;!B#tlbeb>gYJf85CbJA{JBSv45~tm zN7Eehk%gbh+Jq0ZiPF;3Nd6a)bQAD^Op%WMPr%5*O&U*5`wsPu=0AayS9SCVOdblI z_%`7hHZxk!492)W|ECB3`L9t((VMTV(~I^`G*K3+5{g}6ncl}koF<#6~=}4*s#C`{f5Up zgR~DWRGK4H7@G^k6@{B!$aqMC&`&r@7s zchCPAv4U1$+wH5A;0ENluAm%ywaQz*39L~fk%}?Z@6?wcL5%fc$E}y(MgC)mW4&P} zA`kaOIhtK2`Wd9yJ)NoxVFYy8y|lSLv;qA21i8SCM*X1LsMnfraiyz}KCZT3B7nsAi++`4wm1GLF|tCh9E29{xT8agTxCg!R2TGPF6v4hoj* zM>}{b-GL{jADL>A2Wm!I90@AK&+0fj{EU*@4&Z(3fwvlRr|wfj0pE0l58^$p8QV diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action.php deleted file mode 100644 index 5d72ac3d6475..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action.php +++ /dev/null @@ -1,281 +0,0 @@ -google.privacy.dlp.v2.Action - */ -class Action extends \Google\Protobuf\Internal\Message -{ - protected $action; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\Action\SaveFindings $save_findings - * Save resulting findings in a provided location. - * @type \Google\Cloud\Dlp\V2\Action\PublishToPubSub $pub_sub - * Publish a notification to a Pub/Sub topic. - * @type \Google\Cloud\Dlp\V2\Action\PublishSummaryToCscc $publish_summary_to_cscc - * Publish summary to Cloud Security Command Center (Alpha). - * @type \Google\Cloud\Dlp\V2\Action\PublishFindingsToCloudDataCatalog $publish_findings_to_cloud_data_catalog - * Publish findings to Cloud Datahub. - * @type \Google\Cloud\Dlp\V2\Action\Deidentify $deidentify - * Create a de-identified copy of the input data. - * @type \Google\Cloud\Dlp\V2\Action\JobNotificationEmails $job_notification_emails - * Sends an email when the job completes. The email goes to IAM project - * owners and technical [Essential - * Contacts](https://cloud.google.com/resource-manager/docs/managing-notification-contacts). - * @type \Google\Cloud\Dlp\V2\Action\PublishToStackdriver $publish_to_stackdriver - * Enable Stackdriver metric dlp.googleapis.com/finding_count. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Save resulting findings in a provided location. - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.SaveFindings save_findings = 1; - * @return \Google\Cloud\Dlp\V2\Action\SaveFindings|null - */ - public function getSaveFindings() - { - return $this->readOneof(1); - } - - public function hasSaveFindings() - { - return $this->hasOneof(1); - } - - /** - * Save resulting findings in a provided location. - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.SaveFindings save_findings = 1; - * @param \Google\Cloud\Dlp\V2\Action\SaveFindings $var - * @return $this - */ - public function setSaveFindings($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\SaveFindings::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Publish a notification to a Pub/Sub topic. - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishToPubSub pub_sub = 2; - * @return \Google\Cloud\Dlp\V2\Action\PublishToPubSub|null - */ - public function getPubSub() - { - return $this->readOneof(2); - } - - public function hasPubSub() - { - return $this->hasOneof(2); - } - - /** - * Publish a notification to a Pub/Sub topic. - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishToPubSub pub_sub = 2; - * @param \Google\Cloud\Dlp\V2\Action\PublishToPubSub $var - * @return $this - */ - public function setPubSub($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\PublishToPubSub::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Publish summary to Cloud Security Command Center (Alpha). - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishSummaryToCscc publish_summary_to_cscc = 3; - * @return \Google\Cloud\Dlp\V2\Action\PublishSummaryToCscc|null - */ - public function getPublishSummaryToCscc() - { - return $this->readOneof(3); - } - - public function hasPublishSummaryToCscc() - { - return $this->hasOneof(3); - } - - /** - * Publish summary to Cloud Security Command Center (Alpha). - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishSummaryToCscc publish_summary_to_cscc = 3; - * @param \Google\Cloud\Dlp\V2\Action\PublishSummaryToCscc $var - * @return $this - */ - public function setPublishSummaryToCscc($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\PublishSummaryToCscc::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Publish findings to Cloud Datahub. - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishFindingsToCloudDataCatalog publish_findings_to_cloud_data_catalog = 5; - * @return \Google\Cloud\Dlp\V2\Action\PublishFindingsToCloudDataCatalog|null - */ - public function getPublishFindingsToCloudDataCatalog() - { - return $this->readOneof(5); - } - - public function hasPublishFindingsToCloudDataCatalog() - { - return $this->hasOneof(5); - } - - /** - * Publish findings to Cloud Datahub. - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishFindingsToCloudDataCatalog publish_findings_to_cloud_data_catalog = 5; - * @param \Google\Cloud\Dlp\V2\Action\PublishFindingsToCloudDataCatalog $var - * @return $this - */ - public function setPublishFindingsToCloudDataCatalog($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\PublishFindingsToCloudDataCatalog::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Create a de-identified copy of the input data. - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.Deidentify deidentify = 7; - * @return \Google\Cloud\Dlp\V2\Action\Deidentify|null - */ - public function getDeidentify() - { - return $this->readOneof(7); - } - - public function hasDeidentify() - { - return $this->hasOneof(7); - } - - /** - * Create a de-identified copy of the input data. - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.Deidentify deidentify = 7; - * @param \Google\Cloud\Dlp\V2\Action\Deidentify $var - * @return $this - */ - public function setDeidentify($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\Deidentify::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * Sends an email when the job completes. The email goes to IAM project - * owners and technical [Essential - * Contacts](https://cloud.google.com/resource-manager/docs/managing-notification-contacts). - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.JobNotificationEmails job_notification_emails = 8; - * @return \Google\Cloud\Dlp\V2\Action\JobNotificationEmails|null - */ - public function getJobNotificationEmails() - { - return $this->readOneof(8); - } - - public function hasJobNotificationEmails() - { - return $this->hasOneof(8); - } - - /** - * Sends an email when the job completes. The email goes to IAM project - * owners and technical [Essential - * Contacts](https://cloud.google.com/resource-manager/docs/managing-notification-contacts). - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.JobNotificationEmails job_notification_emails = 8; - * @param \Google\Cloud\Dlp\V2\Action\JobNotificationEmails $var - * @return $this - */ - public function setJobNotificationEmails($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\JobNotificationEmails::class); - $this->writeOneof(8, $var); - - return $this; - } - - /** - * Enable Stackdriver metric dlp.googleapis.com/finding_count. - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishToStackdriver publish_to_stackdriver = 9; - * @return \Google\Cloud\Dlp\V2\Action\PublishToStackdriver|null - */ - public function getPublishToStackdriver() - { - return $this->readOneof(9); - } - - public function hasPublishToStackdriver() - { - return $this->hasOneof(9); - } - - /** - * Enable Stackdriver metric dlp.googleapis.com/finding_count. - * - * Generated from protobuf field .google.privacy.dlp.v2.Action.PublishToStackdriver publish_to_stackdriver = 9; - * @param \Google\Cloud\Dlp\V2\Action\PublishToStackdriver $var - * @return $this - */ - public function setPublishToStackdriver($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Action\PublishToStackdriver::class); - $this->writeOneof(9, $var); - - return $this; - } - - /** - * @return string - */ - public function getAction() - { - return $this->whichOneof("action"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/Deidentify.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/Deidentify.php deleted file mode 100644 index 81e49cd4f2d5..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/Deidentify.php +++ /dev/null @@ -1,277 +0,0 @@ -google.privacy.dlp.v2.Action.Deidentify - */ -class Deidentify extends \Google\Protobuf\Internal\Message -{ - /** - * User specified deidentify templates and configs for structured, - * unstructured, and image files. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationConfig transformation_config = 7; - */ - protected $transformation_config = null; - /** - * Config for storing transformation details. This is separate from the - * de-identified content, and contains metadata about the successful - * transformations and/or failures that occurred while de-identifying. This - * needs to be set in order for users to access information about the status - * of each transformation (see - * [TransformationDetails][google.privacy.dlp.v2.TransformationDetails] - * message for more information about what is noted). - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationDetailsStorageConfig transformation_details_storage_config = 3; - */ - protected $transformation_details_storage_config = null; - /** - * List of user-specified file type groups to transform. If specified, only - * the files with these filetypes will be transformed. If empty, all - * supported files will be transformed. Supported types may be automatically - * added over time. If a file type is set in this field that isn't supported - * by the Deidentify action then the job will fail and will not be - * successfully created/started. Currently the only filetypes supported are: - * IMAGES, TEXT_FILES, CSV, TSV. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FileType file_types_to_transform = 8; - */ - private $file_types_to_transform; - protected $output; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\TransformationConfig $transformation_config - * User specified deidentify templates and configs for structured, - * unstructured, and image files. - * @type \Google\Cloud\Dlp\V2\TransformationDetailsStorageConfig $transformation_details_storage_config - * Config for storing transformation details. This is separate from the - * de-identified content, and contains metadata about the successful - * transformations and/or failures that occurred while de-identifying. This - * needs to be set in order for users to access information about the status - * of each transformation (see - * [TransformationDetails][google.privacy.dlp.v2.TransformationDetails] - * message for more information about what is noted). - * @type string $cloud_storage_output - * Required. User settable Cloud Storage bucket and folders to store - * de-identified files. This field must be set for cloud storage - * deidentification. The output Cloud Storage bucket must be different - * from the input bucket. De-identified files will overwrite files in the - * output path. - * Form of: gs://bucket/folder/ or gs://bucket - * @type array|\Google\Protobuf\Internal\RepeatedField $file_types_to_transform - * List of user-specified file type groups to transform. If specified, only - * the files with these filetypes will be transformed. If empty, all - * supported files will be transformed. Supported types may be automatically - * added over time. If a file type is set in this field that isn't supported - * by the Deidentify action then the job will fail and will not be - * successfully created/started. Currently the only filetypes supported are: - * IMAGES, TEXT_FILES, CSV, TSV. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * User specified deidentify templates and configs for structured, - * unstructured, and image files. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationConfig transformation_config = 7; - * @return \Google\Cloud\Dlp\V2\TransformationConfig|null - */ - public function getTransformationConfig() - { - return $this->transformation_config; - } - - public function hasTransformationConfig() - { - return isset($this->transformation_config); - } - - public function clearTransformationConfig() - { - unset($this->transformation_config); - } - - /** - * User specified deidentify templates and configs for structured, - * unstructured, and image files. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationConfig transformation_config = 7; - * @param \Google\Cloud\Dlp\V2\TransformationConfig $var - * @return $this - */ - public function setTransformationConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationConfig::class); - $this->transformation_config = $var; - - return $this; - } - - /** - * Config for storing transformation details. This is separate from the - * de-identified content, and contains metadata about the successful - * transformations and/or failures that occurred while de-identifying. This - * needs to be set in order for users to access information about the status - * of each transformation (see - * [TransformationDetails][google.privacy.dlp.v2.TransformationDetails] - * message for more information about what is noted). - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationDetailsStorageConfig transformation_details_storage_config = 3; - * @return \Google\Cloud\Dlp\V2\TransformationDetailsStorageConfig|null - */ - public function getTransformationDetailsStorageConfig() - { - return $this->transformation_details_storage_config; - } - - public function hasTransformationDetailsStorageConfig() - { - return isset($this->transformation_details_storage_config); - } - - public function clearTransformationDetailsStorageConfig() - { - unset($this->transformation_details_storage_config); - } - - /** - * Config for storing transformation details. This is separate from the - * de-identified content, and contains metadata about the successful - * transformations and/or failures that occurred while de-identifying. This - * needs to be set in order for users to access information about the status - * of each transformation (see - * [TransformationDetails][google.privacy.dlp.v2.TransformationDetails] - * message for more information about what is noted). - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationDetailsStorageConfig transformation_details_storage_config = 3; - * @param \Google\Cloud\Dlp\V2\TransformationDetailsStorageConfig $var - * @return $this - */ - public function setTransformationDetailsStorageConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationDetailsStorageConfig::class); - $this->transformation_details_storage_config = $var; - - return $this; - } - - /** - * Required. User settable Cloud Storage bucket and folders to store - * de-identified files. This field must be set for cloud storage - * deidentification. The output Cloud Storage bucket must be different - * from the input bucket. De-identified files will overwrite files in the - * output path. - * Form of: gs://bucket/folder/ or gs://bucket - * - * Generated from protobuf field string cloud_storage_output = 9 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCloudStorageOutput() - { - return $this->readOneof(9); - } - - public function hasCloudStorageOutput() - { - return $this->hasOneof(9); - } - - /** - * Required. User settable Cloud Storage bucket and folders to store - * de-identified files. This field must be set for cloud storage - * deidentification. The output Cloud Storage bucket must be different - * from the input bucket. De-identified files will overwrite files in the - * output path. - * Form of: gs://bucket/folder/ or gs://bucket - * - * Generated from protobuf field string cloud_storage_output = 9 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCloudStorageOutput($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(9, $var); - - return $this; - } - - /** - * List of user-specified file type groups to transform. If specified, only - * the files with these filetypes will be transformed. If empty, all - * supported files will be transformed. Supported types may be automatically - * added over time. If a file type is set in this field that isn't supported - * by the Deidentify action then the job will fail and will not be - * successfully created/started. Currently the only filetypes supported are: - * IMAGES, TEXT_FILES, CSV, TSV. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FileType file_types_to_transform = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFileTypesToTransform() - { - return $this->file_types_to_transform; - } - - /** - * List of user-specified file type groups to transform. If specified, only - * the files with these filetypes will be transformed. If empty, all - * supported files will be transformed. Supported types may be automatically - * added over time. If a file type is set in this field that isn't supported - * by the Deidentify action then the job will fail and will not be - * successfully created/started. Currently the only filetypes supported are: - * IMAGES, TEXT_FILES, CSV, TSV. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FileType file_types_to_transform = 8; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFileTypesToTransform($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\FileType::class); - $this->file_types_to_transform = $arr; - - return $this; - } - - /** - * @return string - */ - public function getOutput() - { - return $this->whichOneof("output"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Deidentify::class, \Google\Cloud\Dlp\V2\Action_Deidentify::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/JobNotificationEmails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/JobNotificationEmails.php deleted file mode 100644 index 24eddd43c8b5..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/JobNotificationEmails.php +++ /dev/null @@ -1,38 +0,0 @@ -google.privacy.dlp.v2.Action.JobNotificationEmails - */ -class JobNotificationEmails extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(JobNotificationEmails::class, \Google\Cloud\Dlp\V2\Action_JobNotificationEmails::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishFindingsToCloudDataCatalog.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishFindingsToCloudDataCatalog.php deleted file mode 100644 index 0afab97bd631..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishFindingsToCloudDataCatalog.php +++ /dev/null @@ -1,51 +0,0 @@ -google.privacy.dlp.v2.Action.PublishFindingsToCloudDataCatalog - */ -class PublishFindingsToCloudDataCatalog extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PublishFindingsToCloudDataCatalog::class, \Google\Cloud\Dlp\V2\Action_PublishFindingsToCloudDataCatalog::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishSummaryToCscc.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishSummaryToCscc.php deleted file mode 100644 index 56a2fa0844d2..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishSummaryToCscc.php +++ /dev/null @@ -1,43 +0,0 @@ -google.privacy.dlp.v2.Action.PublishSummaryToCscc - */ -class PublishSummaryToCscc extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PublishSummaryToCscc::class, \Google\Cloud\Dlp\V2\Action_PublishSummaryToCscc::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToPubSub.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToPubSub.php deleted file mode 100644 index afad5e77ebae..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToPubSub.php +++ /dev/null @@ -1,86 +0,0 @@ -google.privacy.dlp.v2.Action.PublishToPubSub - */ -class PublishToPubSub extends \Google\Protobuf\Internal\Message -{ - /** - * Cloud Pub/Sub topic to send notifications to. The topic must have given - * publishing access rights to the DLP API service account executing - * the long running DlpJob sending the notifications. - * Format is projects/{project}/topics/{topic}. - * - * Generated from protobuf field string topic = 1; - */ - protected $topic = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $topic - * Cloud Pub/Sub topic to send notifications to. The topic must have given - * publishing access rights to the DLP API service account executing - * the long running DlpJob sending the notifications. - * Format is projects/{project}/topics/{topic}. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Cloud Pub/Sub topic to send notifications to. The topic must have given - * publishing access rights to the DLP API service account executing - * the long running DlpJob sending the notifications. - * Format is projects/{project}/topics/{topic}. - * - * Generated from protobuf field string topic = 1; - * @return string - */ - public function getTopic() - { - return $this->topic; - } - - /** - * Cloud Pub/Sub topic to send notifications to. The topic must have given - * publishing access rights to the DLP API service account executing - * the long running DlpJob sending the notifications. - * Format is projects/{project}/topics/{topic}. - * - * Generated from protobuf field string topic = 1; - * @param string $var - * @return $this - */ - public function setTopic($var) - { - GPBUtil::checkString($var, True); - $this->topic = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PublishToPubSub::class, \Google\Cloud\Dlp\V2\Action_PublishToPubSub::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToStackdriver.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToStackdriver.php deleted file mode 100644 index 186382acf182..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/PublishToStackdriver.php +++ /dev/null @@ -1,39 +0,0 @@ -google.privacy.dlp.v2.Action.PublishToStackdriver - */ -class PublishToStackdriver extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PublishToStackdriver::class, \Google\Cloud\Dlp\V2\Action_PublishToStackdriver::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/SaveFindings.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/SaveFindings.php deleted file mode 100644 index 1b0051e218d2..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Action/SaveFindings.php +++ /dev/null @@ -1,83 +0,0 @@ -google.privacy.dlp.v2.Action.SaveFindings - */ -class SaveFindings extends \Google\Protobuf\Internal\Message -{ - /** - * Location to store findings outside of DLP. - * - * Generated from protobuf field .google.privacy.dlp.v2.OutputStorageConfig output_config = 1; - */ - protected $output_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\OutputStorageConfig $output_config - * Location to store findings outside of DLP. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Location to store findings outside of DLP. - * - * Generated from protobuf field .google.privacy.dlp.v2.OutputStorageConfig output_config = 1; - * @return \Google\Cloud\Dlp\V2\OutputStorageConfig|null - */ - public function getOutputConfig() - { - return $this->output_config; - } - - public function hasOutputConfig() - { - return isset($this->output_config); - } - - public function clearOutputConfig() - { - unset($this->output_config); - } - - /** - * Location to store findings outside of DLP. - * - * Generated from protobuf field .google.privacy.dlp.v2.OutputStorageConfig output_config = 1; - * @param \Google\Cloud\Dlp\V2\OutputStorageConfig $var - * @return $this - */ - public function setOutputConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\OutputStorageConfig::class); - $this->output_config = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SaveFindings::class, \Google\Cloud\Dlp\V2\Action_SaveFindings::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActionDetails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActionDetails.php deleted file mode 100644 index 9830d068c860..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActionDetails.php +++ /dev/null @@ -1,75 +0,0 @@ -google.privacy.dlp.v2.ActionDetails - */ -class ActionDetails extends \Google\Protobuf\Internal\Message -{ - protected $details; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails $deidentify_details - * Outcome of a de-identification action. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Outcome of a de-identification action. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceDetails deidentify_details = 1; - * @return \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails|null - */ - public function getDeidentifyDetails() - { - return $this->readOneof(1); - } - - public function hasDeidentifyDetails() - { - return $this->hasOneof(1); - } - - /** - * Outcome of a de-identification action. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceDetails deidentify_details = 1; - * @param \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails $var - * @return $this - */ - public function setDeidentifyDetails($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getDetails() - { - return $this->whichOneof("details"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActivateJobTriggerRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActivateJobTriggerRequest.php deleted file mode 100644 index bd9291228bd1..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ActivateJobTriggerRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.privacy.dlp.v2.ActivateJobTriggerRequest - */ -class ActivateJobTriggerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the trigger to activate, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * 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 - * Required. Resource name of the trigger to activate, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the trigger to activate, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the trigger to activate, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AllOtherDatabaseResources.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AllOtherDatabaseResources.php deleted file mode 100644 index 77c9979299d6..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AllOtherDatabaseResources.php +++ /dev/null @@ -1,33 +0,0 @@ -google.privacy.dlp.v2.AllOtherDatabaseResources - */ -class AllOtherDatabaseResources extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails.php deleted file mode 100644 index f61ea6917a50..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails.php +++ /dev/null @@ -1,372 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails - */ -class AnalyzeDataSourceRiskDetails extends \Google\Protobuf\Internal\Message -{ - /** - * Privacy metric to compute. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric requested_privacy_metric = 1; - */ - protected $requested_privacy_metric = null; - /** - * Input dataset to compute metrics over. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable requested_source_table = 2; - */ - protected $requested_source_table = null; - /** - * The configuration used for this job. - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.RequestedRiskAnalysisOptions requested_options = 10; - */ - protected $requested_options = null; - protected $result; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\PrivacyMetric $requested_privacy_metric - * Privacy metric to compute. - * @type \Google\Cloud\Dlp\V2\BigQueryTable $requested_source_table - * Input dataset to compute metrics over. - * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\NumericalStatsResult $numerical_stats_result - * Numerical stats result - * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult $categorical_stats_result - * Categorical stats result - * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult $k_anonymity_result - * K-anonymity result - * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult $l_diversity_result - * L-divesity result - * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult $k_map_estimation_result - * K-map result - * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult $delta_presence_estimation_result - * Delta-presence result - * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\RequestedRiskAnalysisOptions $requested_options - * The configuration used for this job. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Privacy metric to compute. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric requested_privacy_metric = 1; - * @return \Google\Cloud\Dlp\V2\PrivacyMetric|null - */ - public function getRequestedPrivacyMetric() - { - return $this->requested_privacy_metric; - } - - public function hasRequestedPrivacyMetric() - { - return isset($this->requested_privacy_metric); - } - - public function clearRequestedPrivacyMetric() - { - unset($this->requested_privacy_metric); - } - - /** - * Privacy metric to compute. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric requested_privacy_metric = 1; - * @param \Google\Cloud\Dlp\V2\PrivacyMetric $var - * @return $this - */ - public function setRequestedPrivacyMetric($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric::class); - $this->requested_privacy_metric = $var; - - return $this; - } - - /** - * Input dataset to compute metrics over. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable requested_source_table = 2; - * @return \Google\Cloud\Dlp\V2\BigQueryTable|null - */ - public function getRequestedSourceTable() - { - return $this->requested_source_table; - } - - public function hasRequestedSourceTable() - { - return isset($this->requested_source_table); - } - - public function clearRequestedSourceTable() - { - unset($this->requested_source_table); - } - - /** - * Input dataset to compute metrics over. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable requested_source_table = 2; - * @param \Google\Cloud\Dlp\V2\BigQueryTable $var - * @return $this - */ - public function setRequestedSourceTable($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); - $this->requested_source_table = $var; - - return $this; - } - - /** - * Numerical stats result - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.NumericalStatsResult numerical_stats_result = 3; - * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\NumericalStatsResult|null - */ - public function getNumericalStatsResult() - { - return $this->readOneof(3); - } - - public function hasNumericalStatsResult() - { - return $this->hasOneof(3); - } - - /** - * Numerical stats result - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.NumericalStatsResult numerical_stats_result = 3; - * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\NumericalStatsResult $var - * @return $this - */ - public function setNumericalStatsResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\NumericalStatsResult::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Categorical stats result - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult categorical_stats_result = 4; - * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult|null - */ - public function getCategoricalStatsResult() - { - return $this->readOneof(4); - } - - public function hasCategoricalStatsResult() - { - return $this->hasOneof(4); - } - - /** - * Categorical stats result - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult categorical_stats_result = 4; - * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult $var - * @return $this - */ - public function setCategoricalStatsResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * K-anonymity result - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult k_anonymity_result = 5; - * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult|null - */ - public function getKAnonymityResult() - { - return $this->readOneof(5); - } - - public function hasKAnonymityResult() - { - return $this->hasOneof(5); - } - - /** - * K-anonymity result - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult k_anonymity_result = 5; - * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult $var - * @return $this - */ - public function setKAnonymityResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * L-divesity result - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult l_diversity_result = 6; - * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult|null - */ - public function getLDiversityResult() - { - return $this->readOneof(6); - } - - public function hasLDiversityResult() - { - return $this->hasOneof(6); - } - - /** - * L-divesity result - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult l_diversity_result = 6; - * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult $var - * @return $this - */ - public function setLDiversityResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * K-map result - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult k_map_estimation_result = 7; - * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult|null - */ - public function getKMapEstimationResult() - { - return $this->readOneof(7); - } - - public function hasKMapEstimationResult() - { - return $this->hasOneof(7); - } - - /** - * K-map result - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult k_map_estimation_result = 7; - * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult $var - * @return $this - */ - public function setKMapEstimationResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * Delta-presence result - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult delta_presence_estimation_result = 9; - * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult|null - */ - public function getDeltaPresenceEstimationResult() - { - return $this->readOneof(9); - } - - public function hasDeltaPresenceEstimationResult() - { - return $this->hasOneof(9); - } - - /** - * Delta-presence result - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult delta_presence_estimation_result = 9; - * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult $var - * @return $this - */ - public function setDeltaPresenceEstimationResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult::class); - $this->writeOneof(9, $var); - - return $this; - } - - /** - * The configuration used for this job. - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.RequestedRiskAnalysisOptions requested_options = 10; - * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\RequestedRiskAnalysisOptions|null - */ - public function getRequestedOptions() - { - return $this->requested_options; - } - - public function hasRequestedOptions() - { - return isset($this->requested_options); - } - - public function clearRequestedOptions() - { - unset($this->requested_options); - } - - /** - * The configuration used for this job. - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.RequestedRiskAnalysisOptions requested_options = 10; - * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\RequestedRiskAnalysisOptions $var - * @return $this - */ - public function setRequestedOptions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\RequestedRiskAnalysisOptions::class); - $this->requested_options = $var; - - return $this; - } - - /** - * @return string - */ - public function getResult() - { - return $this->whichOneof("result"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult.php deleted file mode 100644 index d052e08ae603..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult.php +++ /dev/null @@ -1,70 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult - */ -class CategoricalStatsResult extends \Google\Protobuf\Internal\Message -{ - /** - * Histogram of value frequencies in the column. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - private $value_frequency_histogram_buckets; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult\CategoricalStatsHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $value_frequency_histogram_buckets - * Histogram of value frequencies in the column. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Histogram of value frequencies in the column. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getValueFrequencyHistogramBuckets() - { - return $this->value_frequency_histogram_buckets; - } - - /** - * Histogram of value frequencies in the column. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult\CategoricalStatsHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setValueFrequencyHistogramBuckets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\CategoricalStatsResult\CategoricalStatsHistogramBucket::class); - $this->value_frequency_histogram_buckets = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(CategoricalStatsResult::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_CategoricalStatsResult::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult/CategoricalStatsHistogramBucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult/CategoricalStatsHistogramBucket.php deleted file mode 100644 index a815c81eb646..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/CategoricalStatsResult/CategoricalStatsHistogramBucket.php +++ /dev/null @@ -1,210 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.CategoricalStatsResult.CategoricalStatsHistogramBucket - */ -class CategoricalStatsHistogramBucket extends \Google\Protobuf\Internal\Message -{ - /** - * Lower bound on the value frequency of the values in this bucket. - * - * Generated from protobuf field int64 value_frequency_lower_bound = 1; - */ - protected $value_frequency_lower_bound = 0; - /** - * Upper bound on the value frequency of the values in this bucket. - * - * Generated from protobuf field int64 value_frequency_upper_bound = 2; - */ - protected $value_frequency_upper_bound = 0; - /** - * Total number of values in this bucket. - * - * Generated from protobuf field int64 bucket_size = 3; - */ - protected $bucket_size = 0; - /** - * Sample of value frequencies in this bucket. The total number of - * values returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ValueFrequency bucket_values = 4; - */ - private $bucket_values; - /** - * Total number of distinct values in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 5; - */ - protected $bucket_value_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $value_frequency_lower_bound - * Lower bound on the value frequency of the values in this bucket. - * @type int|string $value_frequency_upper_bound - * Upper bound on the value frequency of the values in this bucket. - * @type int|string $bucket_size - * Total number of values in this bucket. - * @type array<\Google\Cloud\Dlp\V2\ValueFrequency>|\Google\Protobuf\Internal\RepeatedField $bucket_values - * Sample of value frequencies in this bucket. The total number of - * values returned per bucket is capped at 20. - * @type int|string $bucket_value_count - * Total number of distinct values in this bucket. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Lower bound on the value frequency of the values in this bucket. - * - * Generated from protobuf field int64 value_frequency_lower_bound = 1; - * @return int|string - */ - public function getValueFrequencyLowerBound() - { - return $this->value_frequency_lower_bound; - } - - /** - * Lower bound on the value frequency of the values in this bucket. - * - * Generated from protobuf field int64 value_frequency_lower_bound = 1; - * @param int|string $var - * @return $this - */ - public function setValueFrequencyLowerBound($var) - { - GPBUtil::checkInt64($var); - $this->value_frequency_lower_bound = $var; - - return $this; - } - - /** - * Upper bound on the value frequency of the values in this bucket. - * - * Generated from protobuf field int64 value_frequency_upper_bound = 2; - * @return int|string - */ - public function getValueFrequencyUpperBound() - { - return $this->value_frequency_upper_bound; - } - - /** - * Upper bound on the value frequency of the values in this bucket. - * - * Generated from protobuf field int64 value_frequency_upper_bound = 2; - * @param int|string $var - * @return $this - */ - public function setValueFrequencyUpperBound($var) - { - GPBUtil::checkInt64($var); - $this->value_frequency_upper_bound = $var; - - return $this; - } - - /** - * Total number of values in this bucket. - * - * Generated from protobuf field int64 bucket_size = 3; - * @return int|string - */ - public function getBucketSize() - { - return $this->bucket_size; - } - - /** - * Total number of values in this bucket. - * - * Generated from protobuf field int64 bucket_size = 3; - * @param int|string $var - * @return $this - */ - public function setBucketSize($var) - { - GPBUtil::checkInt64($var); - $this->bucket_size = $var; - - return $this; - } - - /** - * Sample of value frequencies in this bucket. The total number of - * values returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ValueFrequency bucket_values = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBucketValues() - { - return $this->bucket_values; - } - - /** - * Sample of value frequencies in this bucket. The total number of - * values returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ValueFrequency bucket_values = 4; - * @param array<\Google\Cloud\Dlp\V2\ValueFrequency>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBucketValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ValueFrequency::class); - $this->bucket_values = $arr; - - return $this; - } - - /** - * Total number of distinct values in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 5; - * @return int|string - */ - public function getBucketValueCount() - { - return $this->bucket_value_count; - } - - /** - * Total number of distinct values in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 5; - * @param int|string $var - * @return $this - */ - public function setBucketValueCount($var) - { - GPBUtil::checkInt64($var); - $this->bucket_value_count = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(CategoricalStatsHistogramBucket::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_CategoricalStatsResult_CategoricalStatsHistogramBucket::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult.php deleted file mode 100644 index 4ac13f1966a8..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult.php +++ /dev/null @@ -1,99 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult - */ -class DeltaPresenceEstimationResult extends \Google\Protobuf\Internal\Message -{ - /** - * The intervals [min_probability, max_probability) do not overlap. If a - * value doesn't correspond to any such interval, the associated frequency - * is zero. For example, the following records: - * {min_probability: 0, max_probability: 0.1, frequency: 17} - * {min_probability: 0.2, max_probability: 0.3, frequency: 42} - * {min_probability: 0.3, max_probability: 0.4, frequency: 99} - * mean that there are no record with an estimated probability in [0.1, 0.2) - * nor larger or equal to 0.4. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationHistogramBucket delta_presence_estimation_histogram = 1; - */ - private $delta_presence_estimation_histogram; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult\DeltaPresenceEstimationHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $delta_presence_estimation_histogram - * The intervals [min_probability, max_probability) do not overlap. If a - * value doesn't correspond to any such interval, the associated frequency - * is zero. For example, the following records: - * {min_probability: 0, max_probability: 0.1, frequency: 17} - * {min_probability: 0.2, max_probability: 0.3, frequency: 42} - * {min_probability: 0.3, max_probability: 0.4, frequency: 99} - * mean that there are no record with an estimated probability in [0.1, 0.2) - * nor larger or equal to 0.4. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The intervals [min_probability, max_probability) do not overlap. If a - * value doesn't correspond to any such interval, the associated frequency - * is zero. For example, the following records: - * {min_probability: 0, max_probability: 0.1, frequency: 17} - * {min_probability: 0.2, max_probability: 0.3, frequency: 42} - * {min_probability: 0.3, max_probability: 0.4, frequency: 99} - * mean that there are no record with an estimated probability in [0.1, 0.2) - * nor larger or equal to 0.4. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationHistogramBucket delta_presence_estimation_histogram = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDeltaPresenceEstimationHistogram() - { - return $this->delta_presence_estimation_histogram; - } - - /** - * The intervals [min_probability, max_probability) do not overlap. If a - * value doesn't correspond to any such interval, the associated frequency - * is zero. For example, the following records: - * {min_probability: 0, max_probability: 0.1, frequency: 17} - * {min_probability: 0.2, max_probability: 0.3, frequency: 42} - * {min_probability: 0.3, max_probability: 0.4, frequency: 99} - * mean that there are no record with an estimated probability in [0.1, 0.2) - * nor larger or equal to 0.4. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationHistogramBucket delta_presence_estimation_histogram = 1; - * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult\DeltaPresenceEstimationHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDeltaPresenceEstimationHistogram($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult\DeltaPresenceEstimationHistogramBucket::class); - $this->delta_presence_estimation_histogram = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DeltaPresenceEstimationResult::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_DeltaPresenceEstimationResult::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationHistogramBucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationHistogramBucket.php deleted file mode 100644 index 2d50a7c114c1..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationHistogramBucket.php +++ /dev/null @@ -1,218 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationHistogramBucket - */ -class DeltaPresenceEstimationHistogramBucket extends \Google\Protobuf\Internal\Message -{ - /** - * Between 0 and 1. - * - * Generated from protobuf field double min_probability = 1; - */ - protected $min_probability = 0.0; - /** - * Always greater than or equal to min_probability. - * - * Generated from protobuf field double max_probability = 2; - */ - protected $max_probability = 0.0; - /** - * Number of records within these probability bounds. - * - * Generated from protobuf field int64 bucket_size = 5; - */ - protected $bucket_size = 0; - /** - * Sample of quasi-identifier tuple values in this bucket. The total - * number of classes returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationQuasiIdValues bucket_values = 6; - */ - private $bucket_values; - /** - * Total number of distinct quasi-identifier tuple values in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 7; - */ - protected $bucket_value_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $min_probability - * Between 0 and 1. - * @type float $max_probability - * Always greater than or equal to min_probability. - * @type int|string $bucket_size - * Number of records within these probability bounds. - * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult\DeltaPresenceEstimationQuasiIdValues>|\Google\Protobuf\Internal\RepeatedField $bucket_values - * Sample of quasi-identifier tuple values in this bucket. The total - * number of classes returned per bucket is capped at 20. - * @type int|string $bucket_value_count - * Total number of distinct quasi-identifier tuple values in this bucket. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Between 0 and 1. - * - * Generated from protobuf field double min_probability = 1; - * @return float - */ - public function getMinProbability() - { - return $this->min_probability; - } - - /** - * Between 0 and 1. - * - * Generated from protobuf field double min_probability = 1; - * @param float $var - * @return $this - */ - public function setMinProbability($var) - { - GPBUtil::checkDouble($var); - $this->min_probability = $var; - - return $this; - } - - /** - * Always greater than or equal to min_probability. - * - * Generated from protobuf field double max_probability = 2; - * @return float - */ - public function getMaxProbability() - { - return $this->max_probability; - } - - /** - * Always greater than or equal to min_probability. - * - * Generated from protobuf field double max_probability = 2; - * @param float $var - * @return $this - */ - public function setMaxProbability($var) - { - GPBUtil::checkDouble($var); - $this->max_probability = $var; - - return $this; - } - - /** - * Number of records within these probability bounds. - * - * Generated from protobuf field int64 bucket_size = 5; - * @return int|string - */ - public function getBucketSize() - { - return $this->bucket_size; - } - - /** - * Number of records within these probability bounds. - * - * Generated from protobuf field int64 bucket_size = 5; - * @param int|string $var - * @return $this - */ - public function setBucketSize($var) - { - GPBUtil::checkInt64($var); - $this->bucket_size = $var; - - return $this; - } - - /** - * Sample of quasi-identifier tuple values in this bucket. The total - * number of classes returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationQuasiIdValues bucket_values = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBucketValues() - { - return $this->bucket_values; - } - - /** - * Sample of quasi-identifier tuple values in this bucket. The total - * number of classes returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationQuasiIdValues bucket_values = 6; - * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult\DeltaPresenceEstimationQuasiIdValues>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBucketValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\DeltaPresenceEstimationResult\DeltaPresenceEstimationQuasiIdValues::class); - $this->bucket_values = $arr; - - return $this; - } - - /** - * Total number of distinct quasi-identifier tuple values in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 7; - * @return int|string - */ - public function getBucketValueCount() - { - return $this->bucket_value_count; - } - - /** - * Total number of distinct quasi-identifier tuple values in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 7; - * @param int|string $var - * @return $this - */ - public function setBucketValueCount($var) - { - GPBUtil::checkInt64($var); - $this->bucket_value_count = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DeltaPresenceEstimationHistogramBucket::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_DeltaPresenceEstimationResult_DeltaPresenceEstimationHistogramBucket::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationQuasiIdValues.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationQuasiIdValues.php deleted file mode 100644 index 3af689322032..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/DeltaPresenceEstimationResult/DeltaPresenceEstimationQuasiIdValues.php +++ /dev/null @@ -1,132 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.DeltaPresenceEstimationResult.DeltaPresenceEstimationQuasiIdValues - */ -class DeltaPresenceEstimationQuasiIdValues extends \Google\Protobuf\Internal\Message -{ - /** - * The quasi-identifier values. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; - */ - private $quasi_ids_values; - /** - * The estimated probability that a given individual sharing these - * quasi-identifier values is in the dataset. This value, typically - * called δ, is the ratio between the number of records in the dataset - * with these quasi-identifier values, and the total number of individuals - * (inside *and* outside the dataset) with these quasi-identifier values. - * For example, if there are 15 individuals in the dataset who share the - * same quasi-identifier values, and an estimated 100 people in the entire - * population with these values, then δ is 0.15. - * - * Generated from protobuf field double estimated_probability = 2; - */ - protected $estimated_probability = 0.0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $quasi_ids_values - * The quasi-identifier values. - * @type float $estimated_probability - * The estimated probability that a given individual sharing these - * quasi-identifier values is in the dataset. This value, typically - * called δ, is the ratio between the number of records in the dataset - * with these quasi-identifier values, and the total number of individuals - * (inside *and* outside the dataset) with these quasi-identifier values. - * For example, if there are 15 individuals in the dataset who share the - * same quasi-identifier values, and an estimated 100 people in the entire - * population with these values, then δ is 0.15. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The quasi-identifier values. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQuasiIdsValues() - { - return $this->quasi_ids_values; - } - - /** - * The quasi-identifier values. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; - * @param array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQuasiIdsValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Value::class); - $this->quasi_ids_values = $arr; - - return $this; - } - - /** - * The estimated probability that a given individual sharing these - * quasi-identifier values is in the dataset. This value, typically - * called δ, is the ratio between the number of records in the dataset - * with these quasi-identifier values, and the total number of individuals - * (inside *and* outside the dataset) with these quasi-identifier values. - * For example, if there are 15 individuals in the dataset who share the - * same quasi-identifier values, and an estimated 100 people in the entire - * population with these values, then δ is 0.15. - * - * Generated from protobuf field double estimated_probability = 2; - * @return float - */ - public function getEstimatedProbability() - { - return $this->estimated_probability; - } - - /** - * The estimated probability that a given individual sharing these - * quasi-identifier values is in the dataset. This value, typically - * called δ, is the ratio between the number of records in the dataset - * with these quasi-identifier values, and the total number of individuals - * (inside *and* outside the dataset) with these quasi-identifier values. - * For example, if there are 15 individuals in the dataset who share the - * same quasi-identifier values, and an estimated 100 people in the entire - * population with these values, then δ is 0.15. - * - * Generated from protobuf field double estimated_probability = 2; - * @param float $var - * @return $this - */ - public function setEstimatedProbability($var) - { - GPBUtil::checkDouble($var); - $this->estimated_probability = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DeltaPresenceEstimationQuasiIdValues::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_DeltaPresenceEstimationResult_DeltaPresenceEstimationQuasiIdValues::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult.php deleted file mode 100644 index 3bdc61e513dc..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult.php +++ /dev/null @@ -1,70 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult - */ -class KAnonymityResult extends \Google\Protobuf\Internal\Message -{ - /** - * Histogram of k-anonymity equivalence classes. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - private $equivalence_class_histogram_buckets; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult\KAnonymityHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $equivalence_class_histogram_buckets - * Histogram of k-anonymity equivalence classes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Histogram of k-anonymity equivalence classes. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getEquivalenceClassHistogramBuckets() - { - return $this->equivalence_class_histogram_buckets; - } - - /** - * Histogram of k-anonymity equivalence classes. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult\KAnonymityHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setEquivalenceClassHistogramBuckets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult\KAnonymityHistogramBucket::class); - $this->equivalence_class_histogram_buckets = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(KAnonymityResult::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KAnonymityResult::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityEquivalenceClass.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityEquivalenceClass.php deleted file mode 100644 index fd97e7fb3704..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityEquivalenceClass.php +++ /dev/null @@ -1,116 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityEquivalenceClass - */ -class KAnonymityEquivalenceClass extends \Google\Protobuf\Internal\Message -{ - /** - * Set of values defining the equivalence class. One value per - * quasi-identifier column in the original KAnonymity metric message. - * The order is always the same as the original request. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; - */ - private $quasi_ids_values; - /** - * Size of the equivalence class, for example number of rows with the - * above set of values. - * - * Generated from protobuf field int64 equivalence_class_size = 2; - */ - protected $equivalence_class_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $quasi_ids_values - * Set of values defining the equivalence class. One value per - * quasi-identifier column in the original KAnonymity metric message. - * The order is always the same as the original request. - * @type int|string $equivalence_class_size - * Size of the equivalence class, for example number of rows with the - * above set of values. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Set of values defining the equivalence class. One value per - * quasi-identifier column in the original KAnonymity metric message. - * The order is always the same as the original request. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQuasiIdsValues() - { - return $this->quasi_ids_values; - } - - /** - * Set of values defining the equivalence class. One value per - * quasi-identifier column in the original KAnonymity metric message. - * The order is always the same as the original request. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; - * @param array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQuasiIdsValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Value::class); - $this->quasi_ids_values = $arr; - - return $this; - } - - /** - * Size of the equivalence class, for example number of rows with the - * above set of values. - * - * Generated from protobuf field int64 equivalence_class_size = 2; - * @return int|string - */ - public function getEquivalenceClassSize() - { - return $this->equivalence_class_size; - } - - /** - * Size of the equivalence class, for example number of rows with the - * above set of values. - * - * Generated from protobuf field int64 equivalence_class_size = 2; - * @param int|string $var - * @return $this - */ - public function setEquivalenceClassSize($var) - { - GPBUtil::checkInt64($var); - $this->equivalence_class_size = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(KAnonymityEquivalenceClass::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KAnonymityResult_KAnonymityEquivalenceClass::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityHistogramBucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityHistogramBucket.php deleted file mode 100644 index 3dce3345ac27..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KAnonymityResult/KAnonymityHistogramBucket.php +++ /dev/null @@ -1,210 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityHistogramBucket - */ -class KAnonymityHistogramBucket extends \Google\Protobuf\Internal\Message -{ - /** - * Lower bound on the size of the equivalence classes in this bucket. - * - * Generated from protobuf field int64 equivalence_class_size_lower_bound = 1; - */ - protected $equivalence_class_size_lower_bound = 0; - /** - * Upper bound on the size of the equivalence classes in this bucket. - * - * Generated from protobuf field int64 equivalence_class_size_upper_bound = 2; - */ - protected $equivalence_class_size_upper_bound = 0; - /** - * Total number of equivalence classes in this bucket. - * - * Generated from protobuf field int64 bucket_size = 3; - */ - protected $bucket_size = 0; - /** - * Sample of equivalence classes in this bucket. The total number of - * classes returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - private $bucket_values; - /** - * Total number of distinct equivalence classes in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 5; - */ - protected $bucket_value_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $equivalence_class_size_lower_bound - * Lower bound on the size of the equivalence classes in this bucket. - * @type int|string $equivalence_class_size_upper_bound - * Upper bound on the size of the equivalence classes in this bucket. - * @type int|string $bucket_size - * Total number of equivalence classes in this bucket. - * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult\KAnonymityEquivalenceClass>|\Google\Protobuf\Internal\RepeatedField $bucket_values - * Sample of equivalence classes in this bucket. The total number of - * classes returned per bucket is capped at 20. - * @type int|string $bucket_value_count - * Total number of distinct equivalence classes in this bucket. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Lower bound on the size of the equivalence classes in this bucket. - * - * Generated from protobuf field int64 equivalence_class_size_lower_bound = 1; - * @return int|string - */ - public function getEquivalenceClassSizeLowerBound() - { - return $this->equivalence_class_size_lower_bound; - } - - /** - * Lower bound on the size of the equivalence classes in this bucket. - * - * Generated from protobuf field int64 equivalence_class_size_lower_bound = 1; - * @param int|string $var - * @return $this - */ - public function setEquivalenceClassSizeLowerBound($var) - { - GPBUtil::checkInt64($var); - $this->equivalence_class_size_lower_bound = $var; - - return $this; - } - - /** - * Upper bound on the size of the equivalence classes in this bucket. - * - * Generated from protobuf field int64 equivalence_class_size_upper_bound = 2; - * @return int|string - */ - public function getEquivalenceClassSizeUpperBound() - { - return $this->equivalence_class_size_upper_bound; - } - - /** - * Upper bound on the size of the equivalence classes in this bucket. - * - * Generated from protobuf field int64 equivalence_class_size_upper_bound = 2; - * @param int|string $var - * @return $this - */ - public function setEquivalenceClassSizeUpperBound($var) - { - GPBUtil::checkInt64($var); - $this->equivalence_class_size_upper_bound = $var; - - return $this; - } - - /** - * Total number of equivalence classes in this bucket. - * - * Generated from protobuf field int64 bucket_size = 3; - * @return int|string - */ - public function getBucketSize() - { - return $this->bucket_size; - } - - /** - * Total number of equivalence classes in this bucket. - * - * Generated from protobuf field int64 bucket_size = 3; - * @param int|string $var - * @return $this - */ - public function setBucketSize($var) - { - GPBUtil::checkInt64($var); - $this->bucket_size = $var; - - return $this; - } - - /** - * Sample of equivalence classes in this bucket. The total number of - * classes returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBucketValues() - { - return $this->bucket_values; - } - - /** - * Sample of equivalence classes in this bucket. The total number of - * classes returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult\KAnonymityEquivalenceClass>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBucketValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KAnonymityResult\KAnonymityEquivalenceClass::class); - $this->bucket_values = $arr; - - return $this; - } - - /** - * Total number of distinct equivalence classes in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 5; - * @return int|string - */ - public function getBucketValueCount() - { - return $this->bucket_value_count; - } - - /** - * Total number of distinct equivalence classes in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 5; - * @param int|string $var - * @return $this - */ - public function setBucketValueCount($var) - { - GPBUtil::checkInt64($var); - $this->bucket_value_count = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(KAnonymityHistogramBucket::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KAnonymityResult_KAnonymityHistogramBucket::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult.php deleted file mode 100644 index a100b0ca2d17..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult.php +++ /dev/null @@ -1,99 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult - */ -class KMapEstimationResult extends \Google\Protobuf\Internal\Message -{ - /** - * The intervals [min_anonymity, max_anonymity] do not overlap. If a value - * doesn't correspond to any such interval, the associated frequency is - * zero. For example, the following records: - * {min_anonymity: 1, max_anonymity: 1, frequency: 17} - * {min_anonymity: 2, max_anonymity: 3, frequency: 42} - * {min_anonymity: 5, max_anonymity: 10, frequency: 99} - * mean that there are no record with an estimated anonymity of 4, 5, or - * larger than 10. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationHistogramBucket k_map_estimation_histogram = 1; - */ - private $k_map_estimation_histogram; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult\KMapEstimationHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $k_map_estimation_histogram - * The intervals [min_anonymity, max_anonymity] do not overlap. If a value - * doesn't correspond to any such interval, the associated frequency is - * zero. For example, the following records: - * {min_anonymity: 1, max_anonymity: 1, frequency: 17} - * {min_anonymity: 2, max_anonymity: 3, frequency: 42} - * {min_anonymity: 5, max_anonymity: 10, frequency: 99} - * mean that there are no record with an estimated anonymity of 4, 5, or - * larger than 10. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The intervals [min_anonymity, max_anonymity] do not overlap. If a value - * doesn't correspond to any such interval, the associated frequency is - * zero. For example, the following records: - * {min_anonymity: 1, max_anonymity: 1, frequency: 17} - * {min_anonymity: 2, max_anonymity: 3, frequency: 42} - * {min_anonymity: 5, max_anonymity: 10, frequency: 99} - * mean that there are no record with an estimated anonymity of 4, 5, or - * larger than 10. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationHistogramBucket k_map_estimation_histogram = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getKMapEstimationHistogram() - { - return $this->k_map_estimation_histogram; - } - - /** - * The intervals [min_anonymity, max_anonymity] do not overlap. If a value - * doesn't correspond to any such interval, the associated frequency is - * zero. For example, the following records: - * {min_anonymity: 1, max_anonymity: 1, frequency: 17} - * {min_anonymity: 2, max_anonymity: 3, frequency: 42} - * {min_anonymity: 5, max_anonymity: 10, frequency: 99} - * mean that there are no record with an estimated anonymity of 4, 5, or - * larger than 10. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationHistogramBucket k_map_estimation_histogram = 1; - * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult\KMapEstimationHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setKMapEstimationHistogram($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult\KMapEstimationHistogramBucket::class); - $this->k_map_estimation_histogram = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(KMapEstimationResult::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KMapEstimationResult::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationHistogramBucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationHistogramBucket.php deleted file mode 100644 index 1be3e59cf31b..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationHistogramBucket.php +++ /dev/null @@ -1,217 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationHistogramBucket - */ -class KMapEstimationHistogramBucket extends \Google\Protobuf\Internal\Message -{ - /** - * Always positive. - * - * Generated from protobuf field int64 min_anonymity = 1; - */ - protected $min_anonymity = 0; - /** - * Always greater than or equal to min_anonymity. - * - * Generated from protobuf field int64 max_anonymity = 2; - */ - protected $max_anonymity = 0; - /** - * Number of records within these anonymity bounds. - * - * Generated from protobuf field int64 bucket_size = 5; - */ - protected $bucket_size = 0; - /** - * Sample of quasi-identifier tuple values in this bucket. The total - * number of classes returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationQuasiIdValues bucket_values = 6; - */ - private $bucket_values; - /** - * Total number of distinct quasi-identifier tuple values in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 7; - */ - protected $bucket_value_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $min_anonymity - * Always positive. - * @type int|string $max_anonymity - * Always greater than or equal to min_anonymity. - * @type int|string $bucket_size - * Number of records within these anonymity bounds. - * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult\KMapEstimationQuasiIdValues>|\Google\Protobuf\Internal\RepeatedField $bucket_values - * Sample of quasi-identifier tuple values in this bucket. The total - * number of classes returned per bucket is capped at 20. - * @type int|string $bucket_value_count - * Total number of distinct quasi-identifier tuple values in this bucket. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Always positive. - * - * Generated from protobuf field int64 min_anonymity = 1; - * @return int|string - */ - public function getMinAnonymity() - { - return $this->min_anonymity; - } - - /** - * Always positive. - * - * Generated from protobuf field int64 min_anonymity = 1; - * @param int|string $var - * @return $this - */ - public function setMinAnonymity($var) - { - GPBUtil::checkInt64($var); - $this->min_anonymity = $var; - - return $this; - } - - /** - * Always greater than or equal to min_anonymity. - * - * Generated from protobuf field int64 max_anonymity = 2; - * @return int|string - */ - public function getMaxAnonymity() - { - return $this->max_anonymity; - } - - /** - * Always greater than or equal to min_anonymity. - * - * Generated from protobuf field int64 max_anonymity = 2; - * @param int|string $var - * @return $this - */ - public function setMaxAnonymity($var) - { - GPBUtil::checkInt64($var); - $this->max_anonymity = $var; - - return $this; - } - - /** - * Number of records within these anonymity bounds. - * - * Generated from protobuf field int64 bucket_size = 5; - * @return int|string - */ - public function getBucketSize() - { - return $this->bucket_size; - } - - /** - * Number of records within these anonymity bounds. - * - * Generated from protobuf field int64 bucket_size = 5; - * @param int|string $var - * @return $this - */ - public function setBucketSize($var) - { - GPBUtil::checkInt64($var); - $this->bucket_size = $var; - - return $this; - } - - /** - * Sample of quasi-identifier tuple values in this bucket. The total - * number of classes returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationQuasiIdValues bucket_values = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBucketValues() - { - return $this->bucket_values; - } - - /** - * Sample of quasi-identifier tuple values in this bucket. The total - * number of classes returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationQuasiIdValues bucket_values = 6; - * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult\KMapEstimationQuasiIdValues>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBucketValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\KMapEstimationResult\KMapEstimationQuasiIdValues::class); - $this->bucket_values = $arr; - - return $this; - } - - /** - * Total number of distinct quasi-identifier tuple values in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 7; - * @return int|string - */ - public function getBucketValueCount() - { - return $this->bucket_value_count; - } - - /** - * Total number of distinct quasi-identifier tuple values in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 7; - * @param int|string $var - * @return $this - */ - public function setBucketValueCount($var) - { - GPBUtil::checkInt64($var); - $this->bucket_value_count = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(KMapEstimationHistogramBucket::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KMapEstimationResult_KMapEstimationHistogramBucket::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationQuasiIdValues.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationQuasiIdValues.php deleted file mode 100644 index abdb15fe761d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/KMapEstimationResult/KMapEstimationQuasiIdValues.php +++ /dev/null @@ -1,104 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.KMapEstimationResult.KMapEstimationQuasiIdValues - */ -class KMapEstimationQuasiIdValues extends \Google\Protobuf\Internal\Message -{ - /** - * The quasi-identifier values. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; - */ - private $quasi_ids_values; - /** - * The estimated anonymity for these quasi-identifier values. - * - * Generated from protobuf field int64 estimated_anonymity = 2; - */ - protected $estimated_anonymity = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $quasi_ids_values - * The quasi-identifier values. - * @type int|string $estimated_anonymity - * The estimated anonymity for these quasi-identifier values. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The quasi-identifier values. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQuasiIdsValues() - { - return $this->quasi_ids_values; - } - - /** - * The quasi-identifier values. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; - * @param array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQuasiIdsValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Value::class); - $this->quasi_ids_values = $arr; - - return $this; - } - - /** - * The estimated anonymity for these quasi-identifier values. - * - * Generated from protobuf field int64 estimated_anonymity = 2; - * @return int|string - */ - public function getEstimatedAnonymity() - { - return $this->estimated_anonymity; - } - - /** - * The estimated anonymity for these quasi-identifier values. - * - * Generated from protobuf field int64 estimated_anonymity = 2; - * @param int|string $var - * @return $this - */ - public function setEstimatedAnonymity($var) - { - GPBUtil::checkInt64($var); - $this->estimated_anonymity = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(KMapEstimationQuasiIdValues::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KMapEstimationResult_KMapEstimationQuasiIdValues::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult.php deleted file mode 100644 index eb7cd5fd1392..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult.php +++ /dev/null @@ -1,70 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult - */ -class LDiversityResult extends \Google\Protobuf\Internal\Message -{ - /** - * Histogram of l-diversity equivalence class sensitive value frequencies. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - private $sensitive_value_frequency_histogram_buckets; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult\LDiversityHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $sensitive_value_frequency_histogram_buckets - * Histogram of l-diversity equivalence class sensitive value frequencies. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Histogram of l-diversity equivalence class sensitive value frequencies. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSensitiveValueFrequencyHistogramBuckets() - { - return $this->sensitive_value_frequency_histogram_buckets; - } - - /** - * Histogram of l-diversity equivalence class sensitive value frequencies. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult\LDiversityHistogramBucket>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSensitiveValueFrequencyHistogramBuckets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult\LDiversityHistogramBucket::class); - $this->sensitive_value_frequency_histogram_buckets = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LDiversityResult::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_LDiversityResult::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityEquivalenceClass.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityEquivalenceClass.php deleted file mode 100644 index 7b8f0fcf1822..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityEquivalenceClass.php +++ /dev/null @@ -1,176 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityEquivalenceClass - */ -class LDiversityEquivalenceClass extends \Google\Protobuf\Internal\Message -{ - /** - * Quasi-identifier values defining the k-anonymity equivalence - * class. The order is always the same as the original request. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; - */ - private $quasi_ids_values; - /** - * Size of the k-anonymity equivalence class. - * - * Generated from protobuf field int64 equivalence_class_size = 2; - */ - protected $equivalence_class_size = 0; - /** - * Number of distinct sensitive values in this equivalence class. - * - * Generated from protobuf field int64 num_distinct_sensitive_values = 3; - */ - protected $num_distinct_sensitive_values = 0; - /** - * Estimated frequencies of top sensitive values. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ValueFrequency top_sensitive_values = 4; - */ - private $top_sensitive_values; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $quasi_ids_values - * Quasi-identifier values defining the k-anonymity equivalence - * class. The order is always the same as the original request. - * @type int|string $equivalence_class_size - * Size of the k-anonymity equivalence class. - * @type int|string $num_distinct_sensitive_values - * Number of distinct sensitive values in this equivalence class. - * @type array<\Google\Cloud\Dlp\V2\ValueFrequency>|\Google\Protobuf\Internal\RepeatedField $top_sensitive_values - * Estimated frequencies of top sensitive values. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Quasi-identifier values defining the k-anonymity equivalence - * class. The order is always the same as the original request. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQuasiIdsValues() - { - return $this->quasi_ids_values; - } - - /** - * Quasi-identifier values defining the k-anonymity equivalence - * class. The order is always the same as the original request. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quasi_ids_values = 1; - * @param array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQuasiIdsValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Value::class); - $this->quasi_ids_values = $arr; - - return $this; - } - - /** - * Size of the k-anonymity equivalence class. - * - * Generated from protobuf field int64 equivalence_class_size = 2; - * @return int|string - */ - public function getEquivalenceClassSize() - { - return $this->equivalence_class_size; - } - - /** - * Size of the k-anonymity equivalence class. - * - * Generated from protobuf field int64 equivalence_class_size = 2; - * @param int|string $var - * @return $this - */ - public function setEquivalenceClassSize($var) - { - GPBUtil::checkInt64($var); - $this->equivalence_class_size = $var; - - return $this; - } - - /** - * Number of distinct sensitive values in this equivalence class. - * - * Generated from protobuf field int64 num_distinct_sensitive_values = 3; - * @return int|string - */ - public function getNumDistinctSensitiveValues() - { - return $this->num_distinct_sensitive_values; - } - - /** - * Number of distinct sensitive values in this equivalence class. - * - * Generated from protobuf field int64 num_distinct_sensitive_values = 3; - * @param int|string $var - * @return $this - */ - public function setNumDistinctSensitiveValues($var) - { - GPBUtil::checkInt64($var); - $this->num_distinct_sensitive_values = $var; - - return $this; - } - - /** - * Estimated frequencies of top sensitive values. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ValueFrequency top_sensitive_values = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTopSensitiveValues() - { - return $this->top_sensitive_values; - } - - /** - * Estimated frequencies of top sensitive values. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ValueFrequency top_sensitive_values = 4; - * @param array<\Google\Cloud\Dlp\V2\ValueFrequency>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTopSensitiveValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ValueFrequency::class); - $this->top_sensitive_values = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LDiversityEquivalenceClass::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_LDiversityResult_LDiversityEquivalenceClass::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityHistogramBucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityHistogramBucket.php deleted file mode 100644 index 6c7082628ea1..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/LDiversityResult/LDiversityHistogramBucket.php +++ /dev/null @@ -1,218 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityHistogramBucket - */ -class LDiversityHistogramBucket extends \Google\Protobuf\Internal\Message -{ - /** - * Lower bound on the sensitive value frequencies of the equivalence - * classes in this bucket. - * - * Generated from protobuf field int64 sensitive_value_frequency_lower_bound = 1; - */ - protected $sensitive_value_frequency_lower_bound = 0; - /** - * Upper bound on the sensitive value frequencies of the equivalence - * classes in this bucket. - * - * Generated from protobuf field int64 sensitive_value_frequency_upper_bound = 2; - */ - protected $sensitive_value_frequency_upper_bound = 0; - /** - * Total number of equivalence classes in this bucket. - * - * Generated from protobuf field int64 bucket_size = 3; - */ - protected $bucket_size = 0; - /** - * Sample of equivalence classes in this bucket. The total number of - * classes returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - private $bucket_values; - /** - * Total number of distinct equivalence classes in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 5; - */ - protected $bucket_value_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $sensitive_value_frequency_lower_bound - * Lower bound on the sensitive value frequencies of the equivalence - * classes in this bucket. - * @type int|string $sensitive_value_frequency_upper_bound - * Upper bound on the sensitive value frequencies of the equivalence - * classes in this bucket. - * @type int|string $bucket_size - * Total number of equivalence classes in this bucket. - * @type array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult\LDiversityEquivalenceClass>|\Google\Protobuf\Internal\RepeatedField $bucket_values - * Sample of equivalence classes in this bucket. The total number of - * classes returned per bucket is capped at 20. - * @type int|string $bucket_value_count - * Total number of distinct equivalence classes in this bucket. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Lower bound on the sensitive value frequencies of the equivalence - * classes in this bucket. - * - * Generated from protobuf field int64 sensitive_value_frequency_lower_bound = 1; - * @return int|string - */ - public function getSensitiveValueFrequencyLowerBound() - { - return $this->sensitive_value_frequency_lower_bound; - } - - /** - * Lower bound on the sensitive value frequencies of the equivalence - * classes in this bucket. - * - * Generated from protobuf field int64 sensitive_value_frequency_lower_bound = 1; - * @param int|string $var - * @return $this - */ - public function setSensitiveValueFrequencyLowerBound($var) - { - GPBUtil::checkInt64($var); - $this->sensitive_value_frequency_lower_bound = $var; - - return $this; - } - - /** - * Upper bound on the sensitive value frequencies of the equivalence - * classes in this bucket. - * - * Generated from protobuf field int64 sensitive_value_frequency_upper_bound = 2; - * @return int|string - */ - public function getSensitiveValueFrequencyUpperBound() - { - return $this->sensitive_value_frequency_upper_bound; - } - - /** - * Upper bound on the sensitive value frequencies of the equivalence - * classes in this bucket. - * - * Generated from protobuf field int64 sensitive_value_frequency_upper_bound = 2; - * @param int|string $var - * @return $this - */ - public function setSensitiveValueFrequencyUpperBound($var) - { - GPBUtil::checkInt64($var); - $this->sensitive_value_frequency_upper_bound = $var; - - return $this; - } - - /** - * Total number of equivalence classes in this bucket. - * - * Generated from protobuf field int64 bucket_size = 3; - * @return int|string - */ - public function getBucketSize() - { - return $this->bucket_size; - } - - /** - * Total number of equivalence classes in this bucket. - * - * Generated from protobuf field int64 bucket_size = 3; - * @param int|string $var - * @return $this - */ - public function setBucketSize($var) - { - GPBUtil::checkInt64($var); - $this->bucket_size = $var; - - return $this; - } - - /** - * Sample of equivalence classes in this bucket. The total number of - * classes returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBucketValues() - { - return $this->bucket_values; - } - - /** - * Sample of equivalence classes in this bucket. The total number of - * classes returned per bucket is capped at 20. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - * @param array<\Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult\LDiversityEquivalenceClass>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBucketValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails\LDiversityResult\LDiversityEquivalenceClass::class); - $this->bucket_values = $arr; - - return $this; - } - - /** - * Total number of distinct equivalence classes in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 5; - * @return int|string - */ - public function getBucketValueCount() - { - return $this->bucket_value_count; - } - - /** - * Total number of distinct equivalence classes in this bucket. - * - * Generated from protobuf field int64 bucket_value_count = 5; - * @param int|string $var - * @return $this - */ - public function setBucketValueCount($var) - { - GPBUtil::checkInt64($var); - $this->bucket_value_count = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LDiversityHistogramBucket::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_LDiversityResult_LDiversityHistogramBucket::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/NumericalStatsResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/NumericalStatsResult.php deleted file mode 100644 index 46207acfa508..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/NumericalStatsResult.php +++ /dev/null @@ -1,162 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.NumericalStatsResult - */ -class NumericalStatsResult extends \Google\Protobuf\Internal\Message -{ - /** - * Minimum value appearing in the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value min_value = 1; - */ - protected $min_value = null; - /** - * Maximum value appearing in the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value max_value = 2; - */ - protected $max_value = null; - /** - * List of 99 values that partition the set of field values into 100 equal - * sized buckets. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quantile_values = 4; - */ - private $quantile_values; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\Value $min_value - * Minimum value appearing in the column. - * @type \Google\Cloud\Dlp\V2\Value $max_value - * Maximum value appearing in the column. - * @type array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $quantile_values - * List of 99 values that partition the set of field values into 100 equal - * sized buckets. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Minimum value appearing in the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value min_value = 1; - * @return \Google\Cloud\Dlp\V2\Value|null - */ - public function getMinValue() - { - return $this->min_value; - } - - public function hasMinValue() - { - return isset($this->min_value); - } - - public function clearMinValue() - { - unset($this->min_value); - } - - /** - * Minimum value appearing in the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value min_value = 1; - * @param \Google\Cloud\Dlp\V2\Value $var - * @return $this - */ - public function setMinValue($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); - $this->min_value = $var; - - return $this; - } - - /** - * Maximum value appearing in the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value max_value = 2; - * @return \Google\Cloud\Dlp\V2\Value|null - */ - public function getMaxValue() - { - return $this->max_value; - } - - public function hasMaxValue() - { - return isset($this->max_value); - } - - public function clearMaxValue() - { - unset($this->max_value); - } - - /** - * Maximum value appearing in the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value max_value = 2; - * @param \Google\Cloud\Dlp\V2\Value $var - * @return $this - */ - public function setMaxValue($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); - $this->max_value = $var; - - return $this; - } - - /** - * List of 99 values that partition the set of field values into 100 equal - * sized buckets. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quantile_values = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQuantileValues() - { - return $this->quantile_values; - } - - /** - * List of 99 values that partition the set of field values into 100 equal - * sized buckets. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value quantile_values = 4; - * @param array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQuantileValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Value::class); - $this->quantile_values = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(NumericalStatsResult::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_NumericalStatsResult::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/RequestedRiskAnalysisOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/RequestedRiskAnalysisOptions.php deleted file mode 100644 index 3bcb2274cf7f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/AnalyzeDataSourceRiskDetails/RequestedRiskAnalysisOptions.php +++ /dev/null @@ -1,80 +0,0 @@ -google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails.RequestedRiskAnalysisOptions - */ -class RequestedRiskAnalysisOptions extends \Google\Protobuf\Internal\Message -{ - /** - * The job config for the risk job. - * - * Generated from protobuf field .google.privacy.dlp.v2.RiskAnalysisJobConfig job_config = 1; - */ - protected $job_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig $job_config - * The job config for the risk job. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The job config for the risk job. - * - * Generated from protobuf field .google.privacy.dlp.v2.RiskAnalysisJobConfig job_config = 1; - * @return \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig|null - */ - public function getJobConfig() - { - return $this->job_config; - } - - public function hasJobConfig() - { - return isset($this->job_config); - } - - public function clearJobConfig() - { - unset($this->job_config); - } - - /** - * The job config for the risk job. - * - * Generated from protobuf field .google.privacy.dlp.v2.RiskAnalysisJobConfig job_config = 1; - * @param \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig $var - * @return $this - */ - public function setJobConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig::class); - $this->job_config = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RequestedRiskAnalysisOptions::class, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_RequestedRiskAnalysisOptions::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryDiscoveryTarget.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryDiscoveryTarget.php deleted file mode 100644 index 6c568fa2188f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryDiscoveryTarget.php +++ /dev/null @@ -1,210 +0,0 @@ -google.privacy.dlp.v2.BigQueryDiscoveryTarget - */ -class BigQueryDiscoveryTarget extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The tables the discovery cadence applies to. The first target - * with a matching filter will be the one to apply to a table. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryFilter filter = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $filter = null; - /** - * In addition to matching the filter, these conditions must be true - * before a profile is generated. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryConditions conditions = 2; - */ - protected $conditions = null; - protected $frequency; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter $filter - * Required. The tables the discovery cadence applies to. The first target - * with a matching filter will be the one to apply to a table. - * @type \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions $conditions - * In addition to matching the filter, these conditions must be true - * before a profile is generated. - * @type \Google\Cloud\Dlp\V2\DiscoveryGenerationCadence $cadence - * How often and when to update profiles. New tables that match both the - * filter and conditions are scanned as quickly as possible depending on - * system capacity. - * @type \Google\Cloud\Dlp\V2\Disabled $disabled - * Tables that match this filter will not have profiles created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. The tables the discovery cadence applies to. The first target - * with a matching filter will be the one to apply to a table. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryFilter filter = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter|null - */ - public function getFilter() - { - return $this->filter; - } - - public function hasFilter() - { - return isset($this->filter); - } - - public function clearFilter() - { - unset($this->filter); - } - - /** - * Required. The tables the discovery cadence applies to. The first target - * with a matching filter will be the one to apply to a table. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryFilter filter = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter::class); - $this->filter = $var; - - return $this; - } - - /** - * In addition to matching the filter, these conditions must be true - * before a profile is generated. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryConditions conditions = 2; - * @return \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions|null - */ - public function getConditions() - { - return $this->conditions; - } - - public function hasConditions() - { - return isset($this->conditions); - } - - public function clearConditions() - { - unset($this->conditions); - } - - /** - * In addition to matching the filter, these conditions must be true - * before a profile is generated. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryConditions conditions = 2; - * @param \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions $var - * @return $this - */ - public function setConditions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions::class); - $this->conditions = $var; - - return $this; - } - - /** - * How often and when to update profiles. New tables that match both the - * filter and conditions are scanned as quickly as possible depending on - * system capacity. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryGenerationCadence cadence = 3; - * @return \Google\Cloud\Dlp\V2\DiscoveryGenerationCadence|null - */ - public function getCadence() - { - return $this->readOneof(3); - } - - public function hasCadence() - { - return $this->hasOneof(3); - } - - /** - * How often and when to update profiles. New tables that match both the - * filter and conditions are scanned as quickly as possible depending on - * system capacity. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryGenerationCadence cadence = 3; - * @param \Google\Cloud\Dlp\V2\DiscoveryGenerationCadence $var - * @return $this - */ - public function setCadence($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryGenerationCadence::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Tables that match this filter will not have profiles created. - * - * Generated from protobuf field .google.privacy.dlp.v2.Disabled disabled = 4; - * @return \Google\Cloud\Dlp\V2\Disabled|null - */ - public function getDisabled() - { - return $this->readOneof(4); - } - - public function hasDisabled() - { - return $this->hasOneof(4); - } - - /** - * Tables that match this filter will not have profiles created. - * - * Generated from protobuf field .google.privacy.dlp.v2.Disabled disabled = 4; - * @param \Google\Cloud\Dlp\V2\Disabled $var - * @return $this - */ - public function setDisabled($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Disabled::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getFrequency() - { - return $this->whichOneof("frequency"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryField.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryField.php deleted file mode 100644 index ff205ef48b1f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryField.php +++ /dev/null @@ -1,121 +0,0 @@ -google.privacy.dlp.v2.BigQueryField - */ -class BigQueryField extends \Google\Protobuf\Internal\Message -{ - /** - * Source table of the field. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; - */ - protected $table = null; - /** - * Designated field in the BigQuery table. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 2; - */ - protected $field = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\BigQueryTable $table - * Source table of the field. - * @type \Google\Cloud\Dlp\V2\FieldId $field - * Designated field in the BigQuery table. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Source table of the field. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; - * @return \Google\Cloud\Dlp\V2\BigQueryTable|null - */ - public function getTable() - { - return $this->table; - } - - public function hasTable() - { - return isset($this->table); - } - - public function clearTable() - { - unset($this->table); - } - - /** - * Source table of the field. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; - * @param \Google\Cloud\Dlp\V2\BigQueryTable $var - * @return $this - */ - public function setTable($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); - $this->table = $var; - - return $this; - } - - /** - * Designated field in the BigQuery table. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 2; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getField() - { - return $this->field; - } - - public function hasField() - { - return isset($this->field); - } - - public function clearField() - { - unset($this->field); - } - - /** - * Designated field in the BigQuery table. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 2; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setField($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->field = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryKey.php deleted file mode 100644 index 142e075dda01..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryKey.php +++ /dev/null @@ -1,127 +0,0 @@ -google.privacy.dlp.v2.BigQueryKey - */ -class BigQueryKey extends \Google\Protobuf\Internal\Message -{ - /** - * Complete BigQuery table reference. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table_reference = 1; - */ - protected $table_reference = null; - /** - * Row number inferred at the time the table was scanned. This value is - * nondeterministic, cannot be queried, and may be null for inspection - * jobs. To locate findings within a table, specify - * `inspect_job.storage_config.big_query_options.identifying_fields` in - * `CreateDlpJobRequest`. - * - * Generated from protobuf field int64 row_number = 2; - */ - protected $row_number = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\BigQueryTable $table_reference - * Complete BigQuery table reference. - * @type int|string $row_number - * Row number inferred at the time the table was scanned. This value is - * nondeterministic, cannot be queried, and may be null for inspection - * jobs. To locate findings within a table, specify - * `inspect_job.storage_config.big_query_options.identifying_fields` in - * `CreateDlpJobRequest`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Complete BigQuery table reference. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table_reference = 1; - * @return \Google\Cloud\Dlp\V2\BigQueryTable|null - */ - public function getTableReference() - { - return $this->table_reference; - } - - public function hasTableReference() - { - return isset($this->table_reference); - } - - public function clearTableReference() - { - unset($this->table_reference); - } - - /** - * Complete BigQuery table reference. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table_reference = 1; - * @param \Google\Cloud\Dlp\V2\BigQueryTable $var - * @return $this - */ - public function setTableReference($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); - $this->table_reference = $var; - - return $this; - } - - /** - * Row number inferred at the time the table was scanned. This value is - * nondeterministic, cannot be queried, and may be null for inspection - * jobs. To locate findings within a table, specify - * `inspect_job.storage_config.big_query_options.identifying_fields` in - * `CreateDlpJobRequest`. - * - * Generated from protobuf field int64 row_number = 2; - * @return int|string - */ - public function getRowNumber() - { - return $this->row_number; - } - - /** - * Row number inferred at the time the table was scanned. This value is - * nondeterministic, cannot be queried, and may be null for inspection - * jobs. To locate findings within a table, specify - * `inspect_job.storage_config.big_query_options.identifying_fields` in - * `CreateDlpJobRequest`. - * - * Generated from protobuf field int64 row_number = 2; - * @param int|string $var - * @return $this - */ - public function setRowNumber($var) - { - GPBUtil::checkInt64($var); - $this->row_number = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions.php deleted file mode 100644 index 0886b43eaab5..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions.php +++ /dev/null @@ -1,369 +0,0 @@ -google.privacy.dlp.v2.BigQueryOptions - */ -class BigQueryOptions extends \Google\Protobuf\Internal\Message -{ - /** - * Complete BigQuery table reference. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table_reference = 1; - */ - protected $table_reference = null; - /** - * Table fields that may uniquely identify a row within the table. When - * `actions.saveFindings.outputConfig.table` is specified, the values of - * columns specified here are available in the output table under - * `location.content_locations.record_location.record_key.id_values`. Nested - * fields such as `person.birthdate.year` are allowed. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId identifying_fields = 2; - */ - private $identifying_fields; - /** - * Max number of rows to scan. If the table has more rows than this value, the - * rest of the rows are omitted. If not set, or if set to 0, all rows will be - * scanned. Only one of rows_limit and rows_limit_percent can be specified. - * Cannot be used in conjunction with TimespanConfig. - * - * Generated from protobuf field int64 rows_limit = 3; - */ - protected $rows_limit = 0; - /** - * Max percentage of rows to scan. The rest are omitted. The number of rows - * scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and - * 100 means no limit. Defaults to 0. Only one of rows_limit and - * rows_limit_percent can be specified. Cannot be used in conjunction with - * TimespanConfig. - * Caution: A [known - * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-sampling) - * is causing the `rowsLimitPercent` field to behave unexpectedly. We - * recommend using `rowsLimit` instead. - * - * Generated from protobuf field int32 rows_limit_percent = 6; - */ - protected $rows_limit_percent = 0; - /** - * How to sample the data. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryOptions.SampleMethod sample_method = 4; - */ - protected $sample_method = 0; - /** - * References to fields excluded from scanning. This allows you to skip - * inspection of entire columns which you know have no findings. - * When inspecting a table, we recommend that you inspect all columns. - * Otherwise, findings might be affected because hints from excluded columns - * will not be used. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId excluded_fields = 5; - */ - private $excluded_fields; - /** - * Limit scanning only to these fields. - * When inspecting a table, we recommend that you inspect all columns. - * Otherwise, findings might be affected because hints from excluded columns - * will not be used. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId included_fields = 7; - */ - private $included_fields; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\BigQueryTable $table_reference - * Complete BigQuery table reference. - * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $identifying_fields - * Table fields that may uniquely identify a row within the table. When - * `actions.saveFindings.outputConfig.table` is specified, the values of - * columns specified here are available in the output table under - * `location.content_locations.record_location.record_key.id_values`. Nested - * fields such as `person.birthdate.year` are allowed. - * @type int|string $rows_limit - * Max number of rows to scan. If the table has more rows than this value, the - * rest of the rows are omitted. If not set, or if set to 0, all rows will be - * scanned. Only one of rows_limit and rows_limit_percent can be specified. - * Cannot be used in conjunction with TimespanConfig. - * @type int $rows_limit_percent - * Max percentage of rows to scan. The rest are omitted. The number of rows - * scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and - * 100 means no limit. Defaults to 0. Only one of rows_limit and - * rows_limit_percent can be specified. Cannot be used in conjunction with - * TimespanConfig. - * Caution: A [known - * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-sampling) - * is causing the `rowsLimitPercent` field to behave unexpectedly. We - * recommend using `rowsLimit` instead. - * @type int $sample_method - * How to sample the data. - * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $excluded_fields - * References to fields excluded from scanning. This allows you to skip - * inspection of entire columns which you know have no findings. - * When inspecting a table, we recommend that you inspect all columns. - * Otherwise, findings might be affected because hints from excluded columns - * will not be used. - * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $included_fields - * Limit scanning only to these fields. - * When inspecting a table, we recommend that you inspect all columns. - * Otherwise, findings might be affected because hints from excluded columns - * will not be used. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Complete BigQuery table reference. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table_reference = 1; - * @return \Google\Cloud\Dlp\V2\BigQueryTable|null - */ - public function getTableReference() - { - return $this->table_reference; - } - - public function hasTableReference() - { - return isset($this->table_reference); - } - - public function clearTableReference() - { - unset($this->table_reference); - } - - /** - * Complete BigQuery table reference. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table_reference = 1; - * @param \Google\Cloud\Dlp\V2\BigQueryTable $var - * @return $this - */ - public function setTableReference($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); - $this->table_reference = $var; - - return $this; - } - - /** - * Table fields that may uniquely identify a row within the table. When - * `actions.saveFindings.outputConfig.table` is specified, the values of - * columns specified here are available in the output table under - * `location.content_locations.record_location.record_key.id_values`. Nested - * fields such as `person.birthdate.year` are allowed. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId identifying_fields = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIdentifyingFields() - { - return $this->identifying_fields; - } - - /** - * Table fields that may uniquely identify a row within the table. When - * `actions.saveFindings.outputConfig.table` is specified, the values of - * columns specified here are available in the output table under - * `location.content_locations.record_location.record_key.id_values`. Nested - * fields such as `person.birthdate.year` are allowed. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId identifying_fields = 2; - * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIdentifyingFields($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); - $this->identifying_fields = $arr; - - return $this; - } - - /** - * Max number of rows to scan. If the table has more rows than this value, the - * rest of the rows are omitted. If not set, or if set to 0, all rows will be - * scanned. Only one of rows_limit and rows_limit_percent can be specified. - * Cannot be used in conjunction with TimespanConfig. - * - * Generated from protobuf field int64 rows_limit = 3; - * @return int|string - */ - public function getRowsLimit() - { - return $this->rows_limit; - } - - /** - * Max number of rows to scan. If the table has more rows than this value, the - * rest of the rows are omitted. If not set, or if set to 0, all rows will be - * scanned. Only one of rows_limit and rows_limit_percent can be specified. - * Cannot be used in conjunction with TimespanConfig. - * - * Generated from protobuf field int64 rows_limit = 3; - * @param int|string $var - * @return $this - */ - public function setRowsLimit($var) - { - GPBUtil::checkInt64($var); - $this->rows_limit = $var; - - return $this; - } - - /** - * Max percentage of rows to scan. The rest are omitted. The number of rows - * scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and - * 100 means no limit. Defaults to 0. Only one of rows_limit and - * rows_limit_percent can be specified. Cannot be used in conjunction with - * TimespanConfig. - * Caution: A [known - * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-sampling) - * is causing the `rowsLimitPercent` field to behave unexpectedly. We - * recommend using `rowsLimit` instead. - * - * Generated from protobuf field int32 rows_limit_percent = 6; - * @return int - */ - public function getRowsLimitPercent() - { - return $this->rows_limit_percent; - } - - /** - * Max percentage of rows to scan. The rest are omitted. The number of rows - * scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and - * 100 means no limit. Defaults to 0. Only one of rows_limit and - * rows_limit_percent can be specified. Cannot be used in conjunction with - * TimespanConfig. - * Caution: A [known - * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-sampling) - * is causing the `rowsLimitPercent` field to behave unexpectedly. We - * recommend using `rowsLimit` instead. - * - * Generated from protobuf field int32 rows_limit_percent = 6; - * @param int $var - * @return $this - */ - public function setRowsLimitPercent($var) - { - GPBUtil::checkInt32($var); - $this->rows_limit_percent = $var; - - return $this; - } - - /** - * How to sample the data. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryOptions.SampleMethod sample_method = 4; - * @return int - */ - public function getSampleMethod() - { - return $this->sample_method; - } - - /** - * How to sample the data. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryOptions.SampleMethod sample_method = 4; - * @param int $var - * @return $this - */ - public function setSampleMethod($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\BigQueryOptions\SampleMethod::class); - $this->sample_method = $var; - - return $this; - } - - /** - * References to fields excluded from scanning. This allows you to skip - * inspection of entire columns which you know have no findings. - * When inspecting a table, we recommend that you inspect all columns. - * Otherwise, findings might be affected because hints from excluded columns - * will not be used. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId excluded_fields = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExcludedFields() - { - return $this->excluded_fields; - } - - /** - * References to fields excluded from scanning. This allows you to skip - * inspection of entire columns which you know have no findings. - * When inspecting a table, we recommend that you inspect all columns. - * Otherwise, findings might be affected because hints from excluded columns - * will not be used. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId excluded_fields = 5; - * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExcludedFields($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); - $this->excluded_fields = $arr; - - return $this; - } - - /** - * Limit scanning only to these fields. - * When inspecting a table, we recommend that you inspect all columns. - * Otherwise, findings might be affected because hints from excluded columns - * will not be used. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId included_fields = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIncludedFields() - { - return $this->included_fields; - } - - /** - * Limit scanning only to these fields. - * When inspecting a table, we recommend that you inspect all columns. - * Otherwise, findings might be affected because hints from excluded columns - * will not be used. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId included_fields = 7; - * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIncludedFields($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); - $this->included_fields = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions/SampleMethod.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions/SampleMethod.php deleted file mode 100644 index a62e95948378..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryOptions/SampleMethod.php +++ /dev/null @@ -1,68 +0,0 @@ -google.privacy.dlp.v2.BigQueryOptions.SampleMethod - */ -class SampleMethod -{ - /** - * No sampling. - * - * Generated from protobuf enum SAMPLE_METHOD_UNSPECIFIED = 0; - */ - const SAMPLE_METHOD_UNSPECIFIED = 0; - /** - * Scan groups of rows in the order BigQuery provides (default). Multiple - * groups of rows may be scanned in parallel, so results may not appear in - * the same order the rows are read. - * - * Generated from protobuf enum TOP = 1; - */ - const TOP = 1; - /** - * Randomly pick groups of rows to scan. - * - * Generated from protobuf enum RANDOM_START = 2; - */ - const RANDOM_START = 2; - - private static $valueToName = [ - self::SAMPLE_METHOD_UNSPECIFIED => 'SAMPLE_METHOD_UNSPECIFIED', - self::TOP => 'TOP', - self::RANDOM_START => 'RANDOM_START', - ]; - - 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(SampleMethod::class, \Google\Cloud\Dlp\V2\BigQueryOptions_SampleMethod::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegex.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegex.php deleted file mode 100644 index e0379d8b0e9a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegex.php +++ /dev/null @@ -1,143 +0,0 @@ -google.privacy.dlp.v2.BigQueryRegex - */ -class BigQueryRegex extends \Google\Protobuf\Internal\Message -{ - /** - * For organizations, if unset, will match all projects. Has no effect - * for data profile configurations created within a project. - * - * Generated from protobuf field string project_id_regex = 1; - */ - protected $project_id_regex = ''; - /** - * If unset, this property matches all datasets. - * - * Generated from protobuf field string dataset_id_regex = 2; - */ - protected $dataset_id_regex = ''; - /** - * If unset, this property matches all tables. - * - * Generated from protobuf field string table_id_regex = 3; - */ - protected $table_id_regex = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $project_id_regex - * For organizations, if unset, will match all projects. Has no effect - * for data profile configurations created within a project. - * @type string $dataset_id_regex - * If unset, this property matches all datasets. - * @type string $table_id_regex - * If unset, this property matches all tables. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * For organizations, if unset, will match all projects. Has no effect - * for data profile configurations created within a project. - * - * Generated from protobuf field string project_id_regex = 1; - * @return string - */ - public function getProjectIdRegex() - { - return $this->project_id_regex; - } - - /** - * For organizations, if unset, will match all projects. Has no effect - * for data profile configurations created within a project. - * - * Generated from protobuf field string project_id_regex = 1; - * @param string $var - * @return $this - */ - public function setProjectIdRegex($var) - { - GPBUtil::checkString($var, True); - $this->project_id_regex = $var; - - return $this; - } - - /** - * If unset, this property matches all datasets. - * - * Generated from protobuf field string dataset_id_regex = 2; - * @return string - */ - public function getDatasetIdRegex() - { - return $this->dataset_id_regex; - } - - /** - * If unset, this property matches all datasets. - * - * Generated from protobuf field string dataset_id_regex = 2; - * @param string $var - * @return $this - */ - public function setDatasetIdRegex($var) - { - GPBUtil::checkString($var, True); - $this->dataset_id_regex = $var; - - return $this; - } - - /** - * If unset, this property matches all tables. - * - * Generated from protobuf field string table_id_regex = 3; - * @return string - */ - public function getTableIdRegex() - { - return $this->table_id_regex; - } - - /** - * If unset, this property matches all tables. - * - * Generated from protobuf field string table_id_regex = 3; - * @param string $var - * @return $this - */ - public function setTableIdRegex($var) - { - GPBUtil::checkString($var, True); - $this->table_id_regex = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegexes.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegexes.php deleted file mode 100644 index ead1a639827f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryRegexes.php +++ /dev/null @@ -1,72 +0,0 @@ -google.privacy.dlp.v2.BigQueryRegexes - */ -class BigQueryRegexes extends \Google\Protobuf\Internal\Message -{ - /** - * A single BigQuery regular expression pattern to match against one or more - * tables, datasets, or projects that contain BigQuery tables. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryRegex patterns = 1; - */ - private $patterns; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\BigQueryRegex>|\Google\Protobuf\Internal\RepeatedField $patterns - * A single BigQuery regular expression pattern to match against one or more - * tables, datasets, or projects that contain BigQuery tables. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A single BigQuery regular expression pattern to match against one or more - * tables, datasets, or projects that contain BigQuery tables. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryRegex patterns = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPatterns() - { - return $this->patterns; - } - - /** - * A single BigQuery regular expression pattern to match against one or more - * tables, datasets, or projects that contain BigQuery tables. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryRegex patterns = 1; - * @param array<\Google\Cloud\Dlp\V2\BigQueryRegex>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPatterns($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\BigQueryRegex::class); - $this->patterns = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQuerySchemaModification.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQuerySchemaModification.php deleted file mode 100644 index 331f232a4b09..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQuerySchemaModification.php +++ /dev/null @@ -1,63 +0,0 @@ -google.privacy.dlp.v2.BigQuerySchemaModification - */ -class BigQuerySchemaModification -{ - /** - * Unused - * - * Generated from protobuf enum SCHEMA_MODIFICATION_UNSPECIFIED = 0; - */ - const SCHEMA_MODIFICATION_UNSPECIFIED = 0; - /** - * Profiles should be regenerated when new columns are added to the table. - * Default. - * - * Generated from protobuf enum SCHEMA_NEW_COLUMNS = 1; - */ - const SCHEMA_NEW_COLUMNS = 1; - /** - * Profiles should be regenerated when columns are removed from the table. - * - * Generated from protobuf enum SCHEMA_REMOVED_COLUMNS = 2; - */ - const SCHEMA_REMOVED_COLUMNS = 2; - - private static $valueToName = [ - self::SCHEMA_MODIFICATION_UNSPECIFIED => 'SCHEMA_MODIFICATION_UNSPECIFIED', - self::SCHEMA_NEW_COLUMNS => 'SCHEMA_NEW_COLUMNS', - self::SCHEMA_REMOVED_COLUMNS => 'SCHEMA_REMOVED_COLUMNS', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTable.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTable.php deleted file mode 100644 index c3352043e7f5..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTable.php +++ /dev/null @@ -1,143 +0,0 @@ -:.` or - * `..`. - * - * Generated from protobuf message google.privacy.dlp.v2.BigQueryTable - */ -class BigQueryTable extends \Google\Protobuf\Internal\Message -{ - /** - * The Google Cloud Platform project ID of the project containing the table. - * If omitted, project ID is inferred from the API call. - * - * Generated from protobuf field string project_id = 1; - */ - protected $project_id = ''; - /** - * Dataset ID of the table. - * - * Generated from protobuf field string dataset_id = 2; - */ - protected $dataset_id = ''; - /** - * Name of the table. - * - * Generated from protobuf field string table_id = 3; - */ - protected $table_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $project_id - * The Google Cloud Platform project ID of the project containing the table. - * If omitted, project ID is inferred from the API call. - * @type string $dataset_id - * Dataset ID of the table. - * @type string $table_id - * Name of the table. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * The Google Cloud Platform project ID of the project containing the table. - * If omitted, project ID is inferred from the API call. - * - * Generated from protobuf field string project_id = 1; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * The Google Cloud Platform project ID of the project containing the table. - * If omitted, project ID is inferred from the API call. - * - * 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; - } - - /** - * Dataset ID of the table. - * - * Generated from protobuf field string dataset_id = 2; - * @return string - */ - public function getDatasetId() - { - return $this->dataset_id; - } - - /** - * Dataset ID of the table. - * - * Generated from protobuf field string dataset_id = 2; - * @param string $var - * @return $this - */ - public function setDatasetId($var) - { - GPBUtil::checkString($var, True); - $this->dataset_id = $var; - - return $this; - } - - /** - * Name of the table. - * - * Generated from protobuf field string table_id = 3; - * @return string - */ - public function getTableId() - { - return $this->table_id; - } - - /** - * Name of the table. - * - * Generated from protobuf field string table_id = 3; - * @param string $var - * @return $this - */ - public function setTableId($var) - { - GPBUtil::checkString($var, True); - $this->table_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableCollection.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableCollection.php deleted file mode 100644 index 6c26ad1fcc08..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableCollection.php +++ /dev/null @@ -1,75 +0,0 @@ -google.privacy.dlp.v2.BigQueryTableCollection - */ -class BigQueryTableCollection extends \Google\Protobuf\Internal\Message -{ - protected $pattern; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\BigQueryRegexes $include_regexes - * A collection of regular expressions to match a BigQuery table against. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A collection of regular expressions to match a BigQuery table against. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryRegexes include_regexes = 1; - * @return \Google\Cloud\Dlp\V2\BigQueryRegexes|null - */ - public function getIncludeRegexes() - { - return $this->readOneof(1); - } - - public function hasIncludeRegexes() - { - return $this->hasOneof(1); - } - - /** - * A collection of regular expressions to match a BigQuery table against. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryRegexes include_regexes = 1; - * @param \Google\Cloud\Dlp\V2\BigQueryRegexes $var - * @return $this - */ - public function setIncludeRegexes($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryRegexes::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getPattern() - { - return $this->whichOneof("pattern"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableModification.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableModification.php deleted file mode 100644 index c2f8c68bd6b5..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableModification.php +++ /dev/null @@ -1,56 +0,0 @@ -google.privacy.dlp.v2.BigQueryTableModification - */ -class BigQueryTableModification -{ - /** - * Unused. - * - * Generated from protobuf enum TABLE_MODIFICATION_UNSPECIFIED = 0; - */ - const TABLE_MODIFICATION_UNSPECIFIED = 0; - /** - * A table will be considered modified when the last_modified_time from - * BigQuery has been updated. - * - * Generated from protobuf enum TABLE_MODIFIED_TIMESTAMP = 1; - */ - const TABLE_MODIFIED_TIMESTAMP = 1; - - private static $valueToName = [ - self::TABLE_MODIFICATION_UNSPECIFIED => 'TABLE_MODIFICATION_UNSPECIFIED', - self::TABLE_MODIFIED_TIMESTAMP => 'TABLE_MODIFIED_TIMESTAMP', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableType.php deleted file mode 100644 index 476495f15848..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableType.php +++ /dev/null @@ -1,62 +0,0 @@ -google.privacy.dlp.v2.BigQueryTableType - */ -class BigQueryTableType -{ - /** - * Unused. - * - * Generated from protobuf enum BIG_QUERY_TABLE_TYPE_UNSPECIFIED = 0; - */ - const BIG_QUERY_TABLE_TYPE_UNSPECIFIED = 0; - /** - * A normal BigQuery table. - * - * Generated from protobuf enum BIG_QUERY_TABLE_TYPE_TABLE = 1; - */ - const BIG_QUERY_TABLE_TYPE_TABLE = 1; - /** - * A table that references data stored in Cloud Storage. - * - * Generated from protobuf enum BIG_QUERY_TABLE_TYPE_EXTERNAL_BIG_LAKE = 2; - */ - const BIG_QUERY_TABLE_TYPE_EXTERNAL_BIG_LAKE = 2; - - private static $valueToName = [ - self::BIG_QUERY_TABLE_TYPE_UNSPECIFIED => 'BIG_QUERY_TABLE_TYPE_UNSPECIFIED', - self::BIG_QUERY_TABLE_TYPE_TABLE => 'BIG_QUERY_TABLE_TYPE_TABLE', - self::BIG_QUERY_TABLE_TYPE_EXTERNAL_BIG_LAKE => 'BIG_QUERY_TABLE_TYPE_EXTERNAL_BIG_LAKE', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypeCollection.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypeCollection.php deleted file mode 100644 index b6e5441108ea..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypeCollection.php +++ /dev/null @@ -1,68 +0,0 @@ -google.privacy.dlp.v2.BigQueryTableTypeCollection - */ -class BigQueryTableTypeCollection -{ - /** - * Unused. - * - * Generated from protobuf enum BIG_QUERY_COLLECTION_UNSPECIFIED = 0; - */ - const BIG_QUERY_COLLECTION_UNSPECIFIED = 0; - /** - * Automatically generate profiles for all tables, even if the table type is - * not yet fully supported for analysis. Profiles for unsupported tables will - * be generated with errors to indicate their partial support. When full - * support is added, the tables will automatically be profiled during the next - * scheduled run. - * - * Generated from protobuf enum BIG_QUERY_COLLECTION_ALL_TYPES = 1; - */ - const BIG_QUERY_COLLECTION_ALL_TYPES = 1; - /** - * Only those types fully supported will be profiled. Will expand - * automatically as Cloud DLP adds support for new table types. Unsupported - * table types will not have partial profiles generated. - * - * Generated from protobuf enum BIG_QUERY_COLLECTION_ONLY_SUPPORTED_TYPES = 2; - */ - const BIG_QUERY_COLLECTION_ONLY_SUPPORTED_TYPES = 2; - - private static $valueToName = [ - self::BIG_QUERY_COLLECTION_UNSPECIFIED => 'BIG_QUERY_COLLECTION_UNSPECIFIED', - self::BIG_QUERY_COLLECTION_ALL_TYPES => 'BIG_QUERY_COLLECTION_ALL_TYPES', - self::BIG_QUERY_COLLECTION_ONLY_SUPPORTED_TYPES => 'BIG_QUERY_COLLECTION_ONLY_SUPPORTED_TYPES', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypes.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypes.php deleted file mode 100644 index 3235dd3795d3..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BigQueryTableTypes.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.BigQueryTableTypes - */ -class BigQueryTableTypes extends \Google\Protobuf\Internal\Message -{ - /** - * A set of BigQuery table types. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryTableType types = 1; - */ - private $types; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $types - * A set of BigQuery table types. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A set of BigQuery table types. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryTableType types = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTypes() - { - return $this->types; - } - - /** - * A set of BigQuery table types. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryTableType types = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\BigQueryTableType::class); - $this->types = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BoundingBox.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BoundingBox.php deleted file mode 100644 index f0032c6eab48..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BoundingBox.php +++ /dev/null @@ -1,169 +0,0 @@ -google.privacy.dlp.v2.BoundingBox - */ -class BoundingBox extends \Google\Protobuf\Internal\Message -{ - /** - * Top coordinate of the bounding box. (0,0) is upper left. - * - * Generated from protobuf field int32 top = 1; - */ - protected $top = 0; - /** - * Left coordinate of the bounding box. (0,0) is upper left. - * - * Generated from protobuf field int32 left = 2; - */ - protected $left = 0; - /** - * Width of the bounding box in pixels. - * - * Generated from protobuf field int32 width = 3; - */ - protected $width = 0; - /** - * Height of the bounding box in pixels. - * - * Generated from protobuf field int32 height = 4; - */ - protected $height = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $top - * Top coordinate of the bounding box. (0,0) is upper left. - * @type int $left - * Left coordinate of the bounding box. (0,0) is upper left. - * @type int $width - * Width of the bounding box in pixels. - * @type int $height - * Height of the bounding box in pixels. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Top coordinate of the bounding box. (0,0) is upper left. - * - * Generated from protobuf field int32 top = 1; - * @return int - */ - public function getTop() - { - return $this->top; - } - - /** - * Top coordinate of the bounding box. (0,0) is upper left. - * - * Generated from protobuf field int32 top = 1; - * @param int $var - * @return $this - */ - public function setTop($var) - { - GPBUtil::checkInt32($var); - $this->top = $var; - - return $this; - } - - /** - * Left coordinate of the bounding box. (0,0) is upper left. - * - * Generated from protobuf field int32 left = 2; - * @return int - */ - public function getLeft() - { - return $this->left; - } - - /** - * Left coordinate of the bounding box. (0,0) is upper left. - * - * Generated from protobuf field int32 left = 2; - * @param int $var - * @return $this - */ - public function setLeft($var) - { - GPBUtil::checkInt32($var); - $this->left = $var; - - return $this; - } - - /** - * Width of the bounding box in pixels. - * - * Generated from protobuf field int32 width = 3; - * @return int - */ - public function getWidth() - { - return $this->width; - } - - /** - * Width of the bounding box in pixels. - * - * Generated from protobuf field int32 width = 3; - * @param int $var - * @return $this - */ - public function setWidth($var) - { - GPBUtil::checkInt32($var); - $this->width = $var; - - return $this; - } - - /** - * Height of the bounding box in pixels. - * - * Generated from protobuf field int32 height = 4; - * @return int - */ - public function getHeight() - { - return $this->height; - } - - /** - * Height of the bounding box in pixels. - * - * Generated from protobuf field int32 height = 4; - * @param int $var - * @return $this - */ - public function setHeight($var) - { - GPBUtil::checkInt32($var); - $this->height = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig.php deleted file mode 100644 index 0fef73a3b6ba..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig.php +++ /dev/null @@ -1,77 +0,0 @@ - LOW 31-65 -> MEDIUM 66-100 -> HIGH - * This can be used on - * data of type: number, long, string, timestamp. - * If the bound `Value` type differs from the type of data being transformed, we - * will first attempt converting the type of the data to be transformed to match - * the type of the bound before comparing. - * See - * https://cloud.google.com/sensitive-data-protection/docs/concepts-bucketing to - * learn more. - * - * Generated from protobuf message google.privacy.dlp.v2.BucketingConfig - */ -class BucketingConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Set of buckets. Ranges must be non-overlapping. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BucketingConfig.Bucket buckets = 1; - */ - private $buckets; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\BucketingConfig\Bucket>|\Google\Protobuf\Internal\RepeatedField $buckets - * Set of buckets. Ranges must be non-overlapping. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Set of buckets. Ranges must be non-overlapping. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BucketingConfig.Bucket buckets = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBuckets() - { - return $this->buckets; - } - - /** - * Set of buckets. Ranges must be non-overlapping. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BucketingConfig.Bucket buckets = 1; - * @param array<\Google\Cloud\Dlp\V2\BucketingConfig\Bucket>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBuckets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\BucketingConfig\Bucket::class); - $this->buckets = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig/Bucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig/Bucket.php deleted file mode 100644 index d70110e8ae4d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/BucketingConfig/Bucket.php +++ /dev/null @@ -1,172 +0,0 @@ -google.privacy.dlp.v2.BucketingConfig.Bucket - */ -class Bucket extends \Google\Protobuf\Internal\Message -{ - /** - * Lower bound of the range, inclusive. Type should be the same as max if - * used. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value min = 1; - */ - protected $min = null; - /** - * Upper bound of the range, exclusive; type must match min. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value max = 2; - */ - protected $max = null; - /** - * Required. Replacement value for this bucket. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value replacement_value = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $replacement_value = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\Value $min - * Lower bound of the range, inclusive. Type should be the same as max if - * used. - * @type \Google\Cloud\Dlp\V2\Value $max - * Upper bound of the range, exclusive; type must match min. - * @type \Google\Cloud\Dlp\V2\Value $replacement_value - * Required. Replacement value for this bucket. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Lower bound of the range, inclusive. Type should be the same as max if - * used. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value min = 1; - * @return \Google\Cloud\Dlp\V2\Value|null - */ - public function getMin() - { - return $this->min; - } - - public function hasMin() - { - return isset($this->min); - } - - public function clearMin() - { - unset($this->min); - } - - /** - * Lower bound of the range, inclusive. Type should be the same as max if - * used. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value min = 1; - * @param \Google\Cloud\Dlp\V2\Value $var - * @return $this - */ - public function setMin($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); - $this->min = $var; - - return $this; - } - - /** - * Upper bound of the range, exclusive; type must match min. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value max = 2; - * @return \Google\Cloud\Dlp\V2\Value|null - */ - public function getMax() - { - return $this->max; - } - - public function hasMax() - { - return isset($this->max); - } - - public function clearMax() - { - unset($this->max); - } - - /** - * Upper bound of the range, exclusive; type must match min. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value max = 2; - * @param \Google\Cloud\Dlp\V2\Value $var - * @return $this - */ - public function setMax($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); - $this->max = $var; - - return $this; - } - - /** - * Required. Replacement value for this bucket. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value replacement_value = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\Value|null - */ - public function getReplacementValue() - { - return $this->replacement_value; - } - - public function hasReplacementValue() - { - return isset($this->replacement_value); - } - - public function clearReplacementValue() - { - unset($this->replacement_value); - } - - /** - * Required. Replacement value for this bucket. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value replacement_value = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\Value $var - * @return $this - */ - public function setReplacementValue($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); - $this->replacement_value = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Bucket::class, \Google\Cloud\Dlp\V2\BucketingConfig_Bucket::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem.php deleted file mode 100644 index afd0d936d3f5..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem.php +++ /dev/null @@ -1,101 +0,0 @@ -google.privacy.dlp.v2.ByteContentItem - */ -class ByteContentItem extends \Google\Protobuf\Internal\Message -{ - /** - * The type of data stored in the bytes string. Default will be TEXT_UTF8. - * - * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem.BytesType type = 1; - */ - protected $type = 0; - /** - * Content data to inspect or redact. - * - * Generated from protobuf field bytes data = 2; - */ - protected $data = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $type - * The type of data stored in the bytes string. Default will be TEXT_UTF8. - * @type string $data - * Content data to inspect or redact. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The type of data stored in the bytes string. Default will be TEXT_UTF8. - * - * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem.BytesType type = 1; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The type of data stored in the bytes string. Default will be TEXT_UTF8. - * - * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem.BytesType type = 1; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\ByteContentItem\BytesType::class); - $this->type = $var; - - return $this; - } - - /** - * Content data to inspect or redact. - * - * Generated from protobuf field bytes data = 2; - * @return string - */ - public function getData() - { - return $this->data; - } - - /** - * Content data to inspect or redact. - * - * Generated from protobuf field bytes data = 2; - * @param string $var - * @return $this - */ - public function setData($var) - { - GPBUtil::checkString($var, False); - $this->data = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem/BytesType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem/BytesType.php deleted file mode 100644 index 996665d6bd00..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ByteContentItem/BytesType.php +++ /dev/null @@ -1,143 +0,0 @@ -google.privacy.dlp.v2.ByteContentItem.BytesType - */ -class BytesType -{ - /** - * Unused - * - * Generated from protobuf enum BYTES_TYPE_UNSPECIFIED = 0; - */ - const BYTES_TYPE_UNSPECIFIED = 0; - /** - * Any image type. - * - * Generated from protobuf enum IMAGE = 6; - */ - const IMAGE = 6; - /** - * jpeg - * - * Generated from protobuf enum IMAGE_JPEG = 1; - */ - const IMAGE_JPEG = 1; - /** - * bmp - * - * Generated from protobuf enum IMAGE_BMP = 2; - */ - const IMAGE_BMP = 2; - /** - * png - * - * Generated from protobuf enum IMAGE_PNG = 3; - */ - const IMAGE_PNG = 3; - /** - * svg - * - * Generated from protobuf enum IMAGE_SVG = 4; - */ - const IMAGE_SVG = 4; - /** - * plain text - * - * Generated from protobuf enum TEXT_UTF8 = 5; - */ - const TEXT_UTF8 = 5; - /** - * docx, docm, dotx, dotm - * - * Generated from protobuf enum WORD_DOCUMENT = 7; - */ - const WORD_DOCUMENT = 7; - /** - * pdf - * - * Generated from protobuf enum PDF = 8; - */ - const PDF = 8; - /** - * pptx, pptm, potx, potm, pot - * - * Generated from protobuf enum POWERPOINT_DOCUMENT = 9; - */ - const POWERPOINT_DOCUMENT = 9; - /** - * xlsx, xlsm, xltx, xltm - * - * Generated from protobuf enum EXCEL_DOCUMENT = 10; - */ - const EXCEL_DOCUMENT = 10; - /** - * avro - * - * Generated from protobuf enum AVRO = 11; - */ - const AVRO = 11; - /** - * csv - * - * Generated from protobuf enum CSV = 12; - */ - const CSV = 12; - /** - * tsv - * - * Generated from protobuf enum TSV = 13; - */ - const TSV = 13; - - private static $valueToName = [ - self::BYTES_TYPE_UNSPECIFIED => 'BYTES_TYPE_UNSPECIFIED', - self::IMAGE => 'IMAGE', - self::IMAGE_JPEG => 'IMAGE_JPEG', - self::IMAGE_BMP => 'IMAGE_BMP', - self::IMAGE_PNG => 'IMAGE_PNG', - self::IMAGE_SVG => 'IMAGE_SVG', - self::TEXT_UTF8 => 'TEXT_UTF8', - self::WORD_DOCUMENT => 'WORD_DOCUMENT', - self::PDF => 'PDF', - self::POWERPOINT_DOCUMENT => 'POWERPOINT_DOCUMENT', - self::EXCEL_DOCUMENT => 'EXCEL_DOCUMENT', - self::AVRO => 'AVRO', - self::CSV => 'CSV', - self::TSV => 'TSV', - ]; - - 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(BytesType::class, \Google\Cloud\Dlp\V2\ByteContentItem_BytesType::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CancelDlpJobRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CancelDlpJobRequest.php deleted file mode 100644 index d9285b185051..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CancelDlpJobRequest.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.CancelDlpJobRequest - */ -class CancelDlpJobRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the DlpJob resource to be cancelled. - * - * 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 - * Required. The name of the DlpJob resource to be cancelled. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the DlpJob resource to be cancelled. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the DlpJob resource to be cancelled. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharacterMaskConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharacterMaskConfig.php deleted file mode 100644 index 82eaa69cab08..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharacterMaskConfig.php +++ /dev/null @@ -1,266 +0,0 @@ -google.privacy.dlp.v2.CharacterMaskConfig - */ -class CharacterMaskConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Character to use to mask the sensitive values—for example, `*` for an - * alphabetic string such as a name, or `0` for a numeric string such as ZIP - * code or credit card number. This string must have a length of 1. If not - * supplied, this value defaults to `*` for strings, and `0` for digits. - * - * Generated from protobuf field string masking_character = 1; - */ - protected $masking_character = ''; - /** - * Number of characters to mask. If not set, all matching chars will be - * masked. Skipped characters do not count towards this tally. - * If `number_to_mask` is negative, this denotes inverse masking. Cloud DLP - * masks all but a number of characters. - * For example, suppose you have the following values: - * - `masking_character` is `*` - * - `number_to_mask` is `-4` - * - `reverse_order` is `false` - * - `CharsToIgnore` includes `-` - * - Input string is `1234-5678-9012-3456` - * The resulting de-identified string is - * `****-****-****-3456`. Cloud DLP masks all but the last four characters. - * If `reverse_order` is `true`, all but the first four characters are masked - * as `1234-****-****-****`. - * - * Generated from protobuf field int32 number_to_mask = 2; - */ - protected $number_to_mask = 0; - /** - * Mask characters in reverse order. For example, if `masking_character` is - * `0`, `number_to_mask` is `14`, and `reverse_order` is `false`, then the - * input string `1234-5678-9012-3456` is masked as `00000000000000-3456`. - * If `masking_character` is `*`, `number_to_mask` is `3`, and `reverse_order` - * is `true`, then the string `12345` is masked as `12***`. - * - * Generated from protobuf field bool reverse_order = 3; - */ - protected $reverse_order = false; - /** - * When masking a string, items in this list will be skipped when replacing - * characters. For example, if the input string is `555-555-5555` and you - * instruct Cloud DLP to skip `-` and mask 5 characters with `*`, Cloud DLP - * returns `***-**5-5555`. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.CharsToIgnore characters_to_ignore = 4; - */ - private $characters_to_ignore; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $masking_character - * Character to use to mask the sensitive values—for example, `*` for an - * alphabetic string such as a name, or `0` for a numeric string such as ZIP - * code or credit card number. This string must have a length of 1. If not - * supplied, this value defaults to `*` for strings, and `0` for digits. - * @type int $number_to_mask - * Number of characters to mask. If not set, all matching chars will be - * masked. Skipped characters do not count towards this tally. - * If `number_to_mask` is negative, this denotes inverse masking. Cloud DLP - * masks all but a number of characters. - * For example, suppose you have the following values: - * - `masking_character` is `*` - * - `number_to_mask` is `-4` - * - `reverse_order` is `false` - * - `CharsToIgnore` includes `-` - * - Input string is `1234-5678-9012-3456` - * The resulting de-identified string is - * `****-****-****-3456`. Cloud DLP masks all but the last four characters. - * If `reverse_order` is `true`, all but the first four characters are masked - * as `1234-****-****-****`. - * @type bool $reverse_order - * Mask characters in reverse order. For example, if `masking_character` is - * `0`, `number_to_mask` is `14`, and `reverse_order` is `false`, then the - * input string `1234-5678-9012-3456` is masked as `00000000000000-3456`. - * If `masking_character` is `*`, `number_to_mask` is `3`, and `reverse_order` - * is `true`, then the string `12345` is masked as `12***`. - * @type array<\Google\Cloud\Dlp\V2\CharsToIgnore>|\Google\Protobuf\Internal\RepeatedField $characters_to_ignore - * When masking a string, items in this list will be skipped when replacing - * characters. For example, if the input string is `555-555-5555` and you - * instruct Cloud DLP to skip `-` and mask 5 characters with `*`, Cloud DLP - * returns `***-**5-5555`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Character to use to mask the sensitive values—for example, `*` for an - * alphabetic string such as a name, or `0` for a numeric string such as ZIP - * code or credit card number. This string must have a length of 1. If not - * supplied, this value defaults to `*` for strings, and `0` for digits. - * - * Generated from protobuf field string masking_character = 1; - * @return string - */ - public function getMaskingCharacter() - { - return $this->masking_character; - } - - /** - * Character to use to mask the sensitive values—for example, `*` for an - * alphabetic string such as a name, or `0` for a numeric string such as ZIP - * code or credit card number. This string must have a length of 1. If not - * supplied, this value defaults to `*` for strings, and `0` for digits. - * - * Generated from protobuf field string masking_character = 1; - * @param string $var - * @return $this - */ - public function setMaskingCharacter($var) - { - GPBUtil::checkString($var, True); - $this->masking_character = $var; - - return $this; - } - - /** - * Number of characters to mask. If not set, all matching chars will be - * masked. Skipped characters do not count towards this tally. - * If `number_to_mask` is negative, this denotes inverse masking. Cloud DLP - * masks all but a number of characters. - * For example, suppose you have the following values: - * - `masking_character` is `*` - * - `number_to_mask` is `-4` - * - `reverse_order` is `false` - * - `CharsToIgnore` includes `-` - * - Input string is `1234-5678-9012-3456` - * The resulting de-identified string is - * `****-****-****-3456`. Cloud DLP masks all but the last four characters. - * If `reverse_order` is `true`, all but the first four characters are masked - * as `1234-****-****-****`. - * - * Generated from protobuf field int32 number_to_mask = 2; - * @return int - */ - public function getNumberToMask() - { - return $this->number_to_mask; - } - - /** - * Number of characters to mask. If not set, all matching chars will be - * masked. Skipped characters do not count towards this tally. - * If `number_to_mask` is negative, this denotes inverse masking. Cloud DLP - * masks all but a number of characters. - * For example, suppose you have the following values: - * - `masking_character` is `*` - * - `number_to_mask` is `-4` - * - `reverse_order` is `false` - * - `CharsToIgnore` includes `-` - * - Input string is `1234-5678-9012-3456` - * The resulting de-identified string is - * `****-****-****-3456`. Cloud DLP masks all but the last four characters. - * If `reverse_order` is `true`, all but the first four characters are masked - * as `1234-****-****-****`. - * - * Generated from protobuf field int32 number_to_mask = 2; - * @param int $var - * @return $this - */ - public function setNumberToMask($var) - { - GPBUtil::checkInt32($var); - $this->number_to_mask = $var; - - return $this; - } - - /** - * Mask characters in reverse order. For example, if `masking_character` is - * `0`, `number_to_mask` is `14`, and `reverse_order` is `false`, then the - * input string `1234-5678-9012-3456` is masked as `00000000000000-3456`. - * If `masking_character` is `*`, `number_to_mask` is `3`, and `reverse_order` - * is `true`, then the string `12345` is masked as `12***`. - * - * Generated from protobuf field bool reverse_order = 3; - * @return bool - */ - public function getReverseOrder() - { - return $this->reverse_order; - } - - /** - * Mask characters in reverse order. For example, if `masking_character` is - * `0`, `number_to_mask` is `14`, and `reverse_order` is `false`, then the - * input string `1234-5678-9012-3456` is masked as `00000000000000-3456`. - * If `masking_character` is `*`, `number_to_mask` is `3`, and `reverse_order` - * is `true`, then the string `12345` is masked as `12***`. - * - * Generated from protobuf field bool reverse_order = 3; - * @param bool $var - * @return $this - */ - public function setReverseOrder($var) - { - GPBUtil::checkBool($var); - $this->reverse_order = $var; - - return $this; - } - - /** - * When masking a string, items in this list will be skipped when replacing - * characters. For example, if the input string is `555-555-5555` and you - * instruct Cloud DLP to skip `-` and mask 5 characters with `*`, Cloud DLP - * returns `***-**5-5555`. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.CharsToIgnore characters_to_ignore = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCharactersToIgnore() - { - return $this->characters_to_ignore; - } - - /** - * When masking a string, items in this list will be skipped when replacing - * characters. For example, if the input string is `555-555-5555` and you - * instruct Cloud DLP to skip `-` and mask 5 characters with `*`, Cloud DLP - * returns `***-**5-5555`. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.CharsToIgnore characters_to_ignore = 4; - * @param array<\Google\Cloud\Dlp\V2\CharsToIgnore>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCharactersToIgnore($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\CharsToIgnore::class); - $this->characters_to_ignore = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore.php deleted file mode 100644 index 810e5f7da92f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore.php +++ /dev/null @@ -1,112 +0,0 @@ -google.privacy.dlp.v2.CharsToIgnore - */ -class CharsToIgnore extends \Google\Protobuf\Internal\Message -{ - protected $characters; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $characters_to_skip - * Characters to not transform when masking. - * @type int $common_characters_to_ignore - * Common characters to not transform when masking. Useful to avoid removing - * punctuation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Characters to not transform when masking. - * - * Generated from protobuf field string characters_to_skip = 1; - * @return string - */ - public function getCharactersToSkip() - { - return $this->readOneof(1); - } - - public function hasCharactersToSkip() - { - return $this->hasOneof(1); - } - - /** - * Characters to not transform when masking. - * - * Generated from protobuf field string characters_to_skip = 1; - * @param string $var - * @return $this - */ - public function setCharactersToSkip($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Common characters to not transform when masking. Useful to avoid removing - * punctuation. - * - * Generated from protobuf field .google.privacy.dlp.v2.CharsToIgnore.CommonCharsToIgnore common_characters_to_ignore = 2; - * @return int - */ - public function getCommonCharactersToIgnore() - { - return $this->readOneof(2); - } - - public function hasCommonCharactersToIgnore() - { - return $this->hasOneof(2); - } - - /** - * Common characters to not transform when masking. Useful to avoid removing - * punctuation. - * - * Generated from protobuf field .google.privacy.dlp.v2.CharsToIgnore.CommonCharsToIgnore common_characters_to_ignore = 2; - * @param int $var - * @return $this - */ - public function setCommonCharactersToIgnore($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\CharsToIgnore\CommonCharsToIgnore::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getCharacters() - { - return $this->whichOneof("characters"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore/CommonCharsToIgnore.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore/CommonCharsToIgnore.php deleted file mode 100644 index bdda9d51629b..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CharsToIgnore/CommonCharsToIgnore.php +++ /dev/null @@ -1,85 +0,0 @@ -google.privacy.dlp.v2.CharsToIgnore.CommonCharsToIgnore - */ -class CommonCharsToIgnore -{ - /** - * Unused. - * - * Generated from protobuf enum COMMON_CHARS_TO_IGNORE_UNSPECIFIED = 0; - */ - const COMMON_CHARS_TO_IGNORE_UNSPECIFIED = 0; - /** - * 0-9 - * - * Generated from protobuf enum NUMERIC = 1; - */ - const NUMERIC = 1; - /** - * A-Z - * - * Generated from protobuf enum ALPHA_UPPER_CASE = 2; - */ - const ALPHA_UPPER_CASE = 2; - /** - * a-z - * - * Generated from protobuf enum ALPHA_LOWER_CASE = 3; - */ - const ALPHA_LOWER_CASE = 3; - /** - * US Punctuation, one of !"#$%&'()*+,-./:;<=>?@[\]^_`{|}~ - * - * Generated from protobuf enum PUNCTUATION = 4; - */ - const PUNCTUATION = 4; - /** - * Whitespace character, one of [ \t\n\x0B\f\r] - * - * Generated from protobuf enum WHITESPACE = 5; - */ - const WHITESPACE = 5; - - private static $valueToName = [ - self::COMMON_CHARS_TO_IGNORE_UNSPECIFIED => 'COMMON_CHARS_TO_IGNORE_UNSPECIFIED', - self::NUMERIC => 'NUMERIC', - self::ALPHA_UPPER_CASE => 'ALPHA_UPPER_CASE', - self::ALPHA_LOWER_CASE => 'ALPHA_LOWER_CASE', - self::PUNCTUATION => 'PUNCTUATION', - self::WHITESPACE => 'WHITESPACE', - ]; - - 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(CommonCharsToIgnore::class, \Google\Cloud\Dlp\V2\CharsToIgnore_CommonCharsToIgnore::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlDiscoveryTarget.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlDiscoveryTarget.php deleted file mode 100644 index 64cf2263cd10..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlDiscoveryTarget.php +++ /dev/null @@ -1,210 +0,0 @@ -google.privacy.dlp.v2.CloudSqlDiscoveryTarget - */ -class CloudSqlDiscoveryTarget extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The tables the discovery cadence applies to. The first target - * with a matching filter will be the one to apply to a table. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlFilter filter = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $filter = null; - /** - * In addition to matching the filter, these conditions must be true - * before a profile is generated. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlConditions conditions = 2; - */ - protected $conditions = null; - protected $cadence; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DiscoveryCloudSqlFilter $filter - * Required. The tables the discovery cadence applies to. The first target - * with a matching filter will be the one to apply to a table. - * @type \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions $conditions - * In addition to matching the filter, these conditions must be true - * before a profile is generated. - * @type \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence $generation_cadence - * How often and when to update profiles. New tables that match both the - * filter and conditions are scanned as quickly as possible depending on - * system capacity. - * @type \Google\Cloud\Dlp\V2\Disabled $disabled - * Disable profiling for database resources that match this filter. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. The tables the discovery cadence applies to. The first target - * with a matching filter will be the one to apply to a table. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlFilter filter = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\DiscoveryCloudSqlFilter|null - */ - public function getFilter() - { - return $this->filter; - } - - public function hasFilter() - { - return isset($this->filter); - } - - public function clearFilter() - { - unset($this->filter); - } - - /** - * Required. The tables the discovery cadence applies to. The first target - * with a matching filter will be the one to apply to a table. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlFilter filter = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\DiscoveryCloudSqlFilter $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlFilter::class); - $this->filter = $var; - - return $this; - } - - /** - * In addition to matching the filter, these conditions must be true - * before a profile is generated. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlConditions conditions = 2; - * @return \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions|null - */ - public function getConditions() - { - return $this->conditions; - } - - public function hasConditions() - { - return isset($this->conditions); - } - - public function clearConditions() - { - unset($this->conditions); - } - - /** - * In addition to matching the filter, these conditions must be true - * before a profile is generated. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlConditions conditions = 2; - * @param \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions $var - * @return $this - */ - public function setConditions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions::class); - $this->conditions = $var; - - return $this; - } - - /** - * How often and when to update profiles. New tables that match both the - * filter and conditions are scanned as quickly as possible depending on - * system capacity. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence generation_cadence = 3; - * @return \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence|null - */ - public function getGenerationCadence() - { - return $this->readOneof(3); - } - - public function hasGenerationCadence() - { - return $this->hasOneof(3); - } - - /** - * How often and when to update profiles. New tables that match both the - * filter and conditions are scanned as quickly as possible depending on - * system capacity. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence generation_cadence = 3; - * @param \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence $var - * @return $this - */ - public function setGenerationCadence($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Disable profiling for database resources that match this filter. - * - * Generated from protobuf field .google.privacy.dlp.v2.Disabled disabled = 4; - * @return \Google\Cloud\Dlp\V2\Disabled|null - */ - public function getDisabled() - { - return $this->readOneof(4); - } - - public function hasDisabled() - { - return $this->hasOneof(4); - } - - /** - * Disable profiling for database resources that match this filter. - * - * Generated from protobuf field .google.privacy.dlp.v2.Disabled disabled = 4; - * @param \Google\Cloud\Dlp\V2\Disabled $var - * @return $this - */ - public function setDisabled($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Disabled::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getCadence() - { - return $this->whichOneof("cadence"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlIamCredential.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlIamCredential.php deleted file mode 100644 index bd753580e0b9..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlIamCredential.php +++ /dev/null @@ -1,36 +0,0 @@ -google.privacy.dlp.v2.CloudSqlIamCredential - */ -class CloudSqlIamCredential extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties.php deleted file mode 100644 index f14189ddced5..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties.php +++ /dev/null @@ -1,250 +0,0 @@ -google.privacy.dlp.v2.CloudSqlProperties - */ -class CloudSqlProperties extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Immutable. The Cloud SQL instance for which the connection is - * defined. Only one connection per instance is allowed. This can only be set - * at creation time, and cannot be updated. - * It is an error to use a connection_name from different project or region - * than the one that holds the connection. - * For example, a Connection resource for Cloud SQL connection_name - * `project-id:us-central1:sql-instance` - * must be created under the parent - * `projects/project-id/locations/us-central1` - * - * Generated from protobuf field string connection_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; - */ - protected $connection_name = ''; - /** - * Required. DLP will limit its connections to max_connections. - * Must be 2 or greater. - * - * Generated from protobuf field int32 max_connections = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $max_connections = 0; - /** - * Required. The database engine used by the Cloud SQL instance that this - * connection configures. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlProperties.DatabaseEngine database_engine = 7 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $database_engine = 0; - protected $credential; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $connection_name - * Optional. Immutable. The Cloud SQL instance for which the connection is - * defined. Only one connection per instance is allowed. This can only be set - * at creation time, and cannot be updated. - * It is an error to use a connection_name from different project or region - * than the one that holds the connection. - * For example, a Connection resource for Cloud SQL connection_name - * `project-id:us-central1:sql-instance` - * must be created under the parent - * `projects/project-id/locations/us-central1` - * @type \Google\Cloud\Dlp\V2\SecretManagerCredential $username_password - * A username and password stored in Secret Manager. - * @type \Google\Cloud\Dlp\V2\CloudSqlIamCredential $cloud_sql_iam - * Built-in IAM authentication (must be configured in Cloud SQL). - * @type int $max_connections - * Required. DLP will limit its connections to max_connections. - * Must be 2 or greater. - * @type int $database_engine - * Required. The database engine used by the Cloud SQL instance that this - * connection configures. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Immutable. The Cloud SQL instance for which the connection is - * defined. Only one connection per instance is allowed. This can only be set - * at creation time, and cannot be updated. - * It is an error to use a connection_name from different project or region - * than the one that holds the connection. - * For example, a Connection resource for Cloud SQL connection_name - * `project-id:us-central1:sql-instance` - * must be created under the parent - * `projects/project-id/locations/us-central1` - * - * Generated from protobuf field string connection_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getConnectionName() - { - return $this->connection_name; - } - - /** - * Optional. Immutable. The Cloud SQL instance for which the connection is - * defined. Only one connection per instance is allowed. This can only be set - * at creation time, and cannot be updated. - * It is an error to use a connection_name from different project or region - * than the one that holds the connection. - * For example, a Connection resource for Cloud SQL connection_name - * `project-id:us-central1:sql-instance` - * must be created under the parent - * `projects/project-id/locations/us-central1` - * - * Generated from protobuf field string connection_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setConnectionName($var) - { - GPBUtil::checkString($var, True); - $this->connection_name = $var; - - return $this; - } - - /** - * A username and password stored in Secret Manager. - * - * Generated from protobuf field .google.privacy.dlp.v2.SecretManagerCredential username_password = 2; - * @return \Google\Cloud\Dlp\V2\SecretManagerCredential|null - */ - public function getUsernamePassword() - { - return $this->readOneof(2); - } - - public function hasUsernamePassword() - { - return $this->hasOneof(2); - } - - /** - * A username and password stored in Secret Manager. - * - * Generated from protobuf field .google.privacy.dlp.v2.SecretManagerCredential username_password = 2; - * @param \Google\Cloud\Dlp\V2\SecretManagerCredential $var - * @return $this - */ - public function setUsernamePassword($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SecretManagerCredential::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Built-in IAM authentication (must be configured in Cloud SQL). - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlIamCredential cloud_sql_iam = 3; - * @return \Google\Cloud\Dlp\V2\CloudSqlIamCredential|null - */ - public function getCloudSqlIam() - { - return $this->readOneof(3); - } - - public function hasCloudSqlIam() - { - return $this->hasOneof(3); - } - - /** - * Built-in IAM authentication (must be configured in Cloud SQL). - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlIamCredential cloud_sql_iam = 3; - * @param \Google\Cloud\Dlp\V2\CloudSqlIamCredential $var - * @return $this - */ - public function setCloudSqlIam($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudSqlIamCredential::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Required. DLP will limit its connections to max_connections. - * Must be 2 or greater. - * - * Generated from protobuf field int32 max_connections = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getMaxConnections() - { - return $this->max_connections; - } - - /** - * Required. DLP will limit its connections to max_connections. - * Must be 2 or greater. - * - * Generated from protobuf field int32 max_connections = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setMaxConnections($var) - { - GPBUtil::checkInt32($var); - $this->max_connections = $var; - - return $this; - } - - /** - * Required. The database engine used by the Cloud SQL instance that this - * connection configures. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlProperties.DatabaseEngine database_engine = 7 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getDatabaseEngine() - { - return $this->database_engine; - } - - /** - * Required. The database engine used by the Cloud SQL instance that this - * connection configures. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlProperties.DatabaseEngine database_engine = 7 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setDatabaseEngine($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\CloudSqlProperties\DatabaseEngine::class); - $this->database_engine = $var; - - return $this; - } - - /** - * @return string - */ - public function getCredential() - { - return $this->whichOneof("credential"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties/DatabaseEngine.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties/DatabaseEngine.php deleted file mode 100644 index c21e1f3d23c8..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudSqlProperties/DatabaseEngine.php +++ /dev/null @@ -1,65 +0,0 @@ -google.privacy.dlp.v2.CloudSqlProperties.DatabaseEngine - */ -class DatabaseEngine -{ - /** - * An engine that is not currently supported by Sensitive Data Protection. - * - * Generated from protobuf enum DATABASE_ENGINE_UNKNOWN = 0; - */ - const DATABASE_ENGINE_UNKNOWN = 0; - /** - * Cloud SQL for MySQL instance. - * - * Generated from protobuf enum DATABASE_ENGINE_MYSQL = 1; - */ - const DATABASE_ENGINE_MYSQL = 1; - /** - * Cloud SQL for PostgreSQL instance. - * - * Generated from protobuf enum DATABASE_ENGINE_POSTGRES = 2; - */ - const DATABASE_ENGINE_POSTGRES = 2; - - private static $valueToName = [ - self::DATABASE_ENGINE_UNKNOWN => 'DATABASE_ENGINE_UNKNOWN', - self::DATABASE_ENGINE_MYSQL => 'DATABASE_ENGINE_MYSQL', - self::DATABASE_ENGINE_POSTGRES => 'DATABASE_ENGINE_POSTGRES', - ]; - - 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(DatabaseEngine::class, \Google\Cloud\Dlp\V2\CloudSqlProperties_DatabaseEngine::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageFileSet.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageFileSet.php deleted file mode 100644 index 39377fbb5684..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageFileSet.php +++ /dev/null @@ -1,71 +0,0 @@ -google.privacy.dlp.v2.CloudStorageFileSet - */ -class CloudStorageFileSet extends \Google\Protobuf\Internal\Message -{ - /** - * The url, in the format `gs:///`. Trailing wildcard in the - * path is allowed. - * - * Generated from protobuf field string url = 1; - */ - protected $url = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $url - * The url, in the format `gs:///`. Trailing wildcard in the - * path is allowed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * The url, in the format `gs:///`. Trailing wildcard in the - * path is allowed. - * - * Generated from protobuf field string url = 1; - * @return string - */ - public function getUrl() - { - return $this->url; - } - - /** - * The url, in the format `gs:///`. Trailing wildcard in the - * path is allowed. - * - * 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; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions.php deleted file mode 100644 index b68860969e30..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions.php +++ /dev/null @@ -1,332 +0,0 @@ -google.privacy.dlp.v2.CloudStorageOptions - */ -class CloudStorageOptions extends \Google\Protobuf\Internal\Message -{ - /** - * The set of one or more files to scan. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions.FileSet file_set = 1; - */ - protected $file_set = null; - /** - * Max number of bytes to scan from a file. If a scanned file's size is bigger - * than this value then the rest of the bytes are omitted. Only one of - * `bytes_limit_per_file` and `bytes_limit_per_file_percent` can be specified. - * This field can't be set if de-identification is requested. For certain file - * types, setting this field has no effect. For more information, see [Limits - * on bytes scanned per - * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). - * - * Generated from protobuf field int64 bytes_limit_per_file = 4; - */ - protected $bytes_limit_per_file = 0; - /** - * Max percentage of bytes to scan from a file. The rest are omitted. The - * number of bytes scanned is rounded down. Must be between 0 and 100, - * inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of - * bytes_limit_per_file and bytes_limit_per_file_percent can be specified. - * This field can't be set if de-identification is requested. For certain file - * types, setting this field has no effect. For more information, see [Limits - * on bytes scanned per - * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). - * - * Generated from protobuf field int32 bytes_limit_per_file_percent = 8; - */ - protected $bytes_limit_per_file_percent = 0; - /** - * List of file type groups to include in the scan. - * If empty, all files are scanned and available data format processors - * are applied. In addition, the binary content of the selected files - * is always scanned as well. - * Images are scanned only as binary if the specified region - * does not support image inspection and no file_types were specified. - * Image inspection is restricted to 'global', 'us', 'asia', and 'europe'. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FileType file_types = 5; - */ - private $file_types; - /** - * How to sample the data. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions.SampleMethod sample_method = 6; - */ - protected $sample_method = 0; - /** - * Limits the number of files to scan to this percentage of the input FileSet. - * Number of files scanned is rounded down. Must be between 0 and 100, - * inclusively. Both 0 and 100 means no limit. Defaults to 0. - * - * Generated from protobuf field int32 files_limit_percent = 7; - */ - protected $files_limit_percent = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\CloudStorageOptions\FileSet $file_set - * The set of one or more files to scan. - * @type int|string $bytes_limit_per_file - * Max number of bytes to scan from a file. If a scanned file's size is bigger - * than this value then the rest of the bytes are omitted. Only one of - * `bytes_limit_per_file` and `bytes_limit_per_file_percent` can be specified. - * This field can't be set if de-identification is requested. For certain file - * types, setting this field has no effect. For more information, see [Limits - * on bytes scanned per - * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). - * @type int $bytes_limit_per_file_percent - * Max percentage of bytes to scan from a file. The rest are omitted. The - * number of bytes scanned is rounded down. Must be between 0 and 100, - * inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of - * bytes_limit_per_file and bytes_limit_per_file_percent can be specified. - * This field can't be set if de-identification is requested. For certain file - * types, setting this field has no effect. For more information, see [Limits - * on bytes scanned per - * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). - * @type array|\Google\Protobuf\Internal\RepeatedField $file_types - * List of file type groups to include in the scan. - * If empty, all files are scanned and available data format processors - * are applied. In addition, the binary content of the selected files - * is always scanned as well. - * Images are scanned only as binary if the specified region - * does not support image inspection and no file_types were specified. - * Image inspection is restricted to 'global', 'us', 'asia', and 'europe'. - * @type int $sample_method - * How to sample the data. - * @type int $files_limit_percent - * Limits the number of files to scan to this percentage of the input FileSet. - * Number of files scanned is rounded down. Must be between 0 and 100, - * inclusively. Both 0 and 100 means no limit. Defaults to 0. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * The set of one or more files to scan. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions.FileSet file_set = 1; - * @return \Google\Cloud\Dlp\V2\CloudStorageOptions\FileSet|null - */ - public function getFileSet() - { - return $this->file_set; - } - - public function hasFileSet() - { - return isset($this->file_set); - } - - public function clearFileSet() - { - unset($this->file_set); - } - - /** - * The set of one or more files to scan. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions.FileSet file_set = 1; - * @param \Google\Cloud\Dlp\V2\CloudStorageOptions\FileSet $var - * @return $this - */ - public function setFileSet($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudStorageOptions\FileSet::class); - $this->file_set = $var; - - return $this; - } - - /** - * Max number of bytes to scan from a file. If a scanned file's size is bigger - * than this value then the rest of the bytes are omitted. Only one of - * `bytes_limit_per_file` and `bytes_limit_per_file_percent` can be specified. - * This field can't be set if de-identification is requested. For certain file - * types, setting this field has no effect. For more information, see [Limits - * on bytes scanned per - * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). - * - * Generated from protobuf field int64 bytes_limit_per_file = 4; - * @return int|string - */ - public function getBytesLimitPerFile() - { - return $this->bytes_limit_per_file; - } - - /** - * Max number of bytes to scan from a file. If a scanned file's size is bigger - * than this value then the rest of the bytes are omitted. Only one of - * `bytes_limit_per_file` and `bytes_limit_per_file_percent` can be specified. - * This field can't be set if de-identification is requested. For certain file - * types, setting this field has no effect. For more information, see [Limits - * on bytes scanned per - * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). - * - * Generated from protobuf field int64 bytes_limit_per_file = 4; - * @param int|string $var - * @return $this - */ - public function setBytesLimitPerFile($var) - { - GPBUtil::checkInt64($var); - $this->bytes_limit_per_file = $var; - - return $this; - } - - /** - * Max percentage of bytes to scan from a file. The rest are omitted. The - * number of bytes scanned is rounded down. Must be between 0 and 100, - * inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of - * bytes_limit_per_file and bytes_limit_per_file_percent can be specified. - * This field can't be set if de-identification is requested. For certain file - * types, setting this field has no effect. For more information, see [Limits - * on bytes scanned per - * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). - * - * Generated from protobuf field int32 bytes_limit_per_file_percent = 8; - * @return int - */ - public function getBytesLimitPerFilePercent() - { - return $this->bytes_limit_per_file_percent; - } - - /** - * Max percentage of bytes to scan from a file. The rest are omitted. The - * number of bytes scanned is rounded down. Must be between 0 and 100, - * inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of - * bytes_limit_per_file and bytes_limit_per_file_percent can be specified. - * This field can't be set if de-identification is requested. For certain file - * types, setting this field has no effect. For more information, see [Limits - * on bytes scanned per - * file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). - * - * Generated from protobuf field int32 bytes_limit_per_file_percent = 8; - * @param int $var - * @return $this - */ - public function setBytesLimitPerFilePercent($var) - { - GPBUtil::checkInt32($var); - $this->bytes_limit_per_file_percent = $var; - - return $this; - } - - /** - * List of file type groups to include in the scan. - * If empty, all files are scanned and available data format processors - * are applied. In addition, the binary content of the selected files - * is always scanned as well. - * Images are scanned only as binary if the specified region - * does not support image inspection and no file_types were specified. - * Image inspection is restricted to 'global', 'us', 'asia', and 'europe'. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FileType file_types = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFileTypes() - { - return $this->file_types; - } - - /** - * List of file type groups to include in the scan. - * If empty, all files are scanned and available data format processors - * are applied. In addition, the binary content of the selected files - * is always scanned as well. - * Images are scanned only as binary if the specified region - * does not support image inspection and no file_types were specified. - * Image inspection is restricted to 'global', 'us', 'asia', and 'europe'. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FileType file_types = 5; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFileTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\FileType::class); - $this->file_types = $arr; - - return $this; - } - - /** - * How to sample the data. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions.SampleMethod sample_method = 6; - * @return int - */ - public function getSampleMethod() - { - return $this->sample_method; - } - - /** - * How to sample the data. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions.SampleMethod sample_method = 6; - * @param int $var - * @return $this - */ - public function setSampleMethod($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\CloudStorageOptions\SampleMethod::class); - $this->sample_method = $var; - - return $this; - } - - /** - * Limits the number of files to scan to this percentage of the input FileSet. - * Number of files scanned is rounded down. Must be between 0 and 100, - * inclusively. Both 0 and 100 means no limit. Defaults to 0. - * - * Generated from protobuf field int32 files_limit_percent = 7; - * @return int - */ - public function getFilesLimitPercent() - { - return $this->files_limit_percent; - } - - /** - * Limits the number of files to scan to this percentage of the input FileSet. - * Number of files scanned is rounded down. Must be between 0 and 100, - * inclusively. Both 0 and 100 means no limit. Defaults to 0. - * - * Generated from protobuf field int32 files_limit_percent = 7; - * @param int $var - * @return $this - */ - public function setFilesLimitPercent($var) - { - GPBUtil::checkInt32($var); - $this->files_limit_percent = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/FileSet.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/FileSet.php deleted file mode 100644 index ac18796373e3..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/FileSet.php +++ /dev/null @@ -1,146 +0,0 @@ -google.privacy.dlp.v2.CloudStorageOptions.FileSet - */ -class FileSet extends \Google\Protobuf\Internal\Message -{ - /** - * The Cloud Storage url of the file(s) to scan, in the format - * `gs:///`. Trailing wildcard in the path is allowed. - * If the url ends in a trailing slash, the bucket or directory represented - * by the url will be scanned non-recursively (content in sub-directories - * will not be scanned). This means that `gs://mybucket/` is equivalent to - * `gs://mybucket/*`, and `gs://mybucket/directory/` is equivalent to - * `gs://mybucket/directory/*`. - * Exactly one of `url` or `regex_file_set` must be set. - * - * Generated from protobuf field string url = 1; - */ - protected $url = ''; - /** - * The regex-filtered set of files to scan. Exactly one of `url` or - * `regex_file_set` must be set. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageRegexFileSet regex_file_set = 2; - */ - protected $regex_file_set = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $url - * The Cloud Storage url of the file(s) to scan, in the format - * `gs:///`. Trailing wildcard in the path is allowed. - * If the url ends in a trailing slash, the bucket or directory represented - * by the url will be scanned non-recursively (content in sub-directories - * will not be scanned). This means that `gs://mybucket/` is equivalent to - * `gs://mybucket/*`, and `gs://mybucket/directory/` is equivalent to - * `gs://mybucket/directory/*`. - * Exactly one of `url` or `regex_file_set` must be set. - * @type \Google\Cloud\Dlp\V2\CloudStorageRegexFileSet $regex_file_set - * The regex-filtered set of files to scan. Exactly one of `url` or - * `regex_file_set` must be set. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * The Cloud Storage url of the file(s) to scan, in the format - * `gs:///`. Trailing wildcard in the path is allowed. - * If the url ends in a trailing slash, the bucket or directory represented - * by the url will be scanned non-recursively (content in sub-directories - * will not be scanned). This means that `gs://mybucket/` is equivalent to - * `gs://mybucket/*`, and `gs://mybucket/directory/` is equivalent to - * `gs://mybucket/directory/*`. - * Exactly one of `url` or `regex_file_set` must be set. - * - * Generated from protobuf field string url = 1; - * @return string - */ - public function getUrl() - { - return $this->url; - } - - /** - * The Cloud Storage url of the file(s) to scan, in the format - * `gs:///`. Trailing wildcard in the path is allowed. - * If the url ends in a trailing slash, the bucket or directory represented - * by the url will be scanned non-recursively (content in sub-directories - * will not be scanned). This means that `gs://mybucket/` is equivalent to - * `gs://mybucket/*`, and `gs://mybucket/directory/` is equivalent to - * `gs://mybucket/directory/*`. - * Exactly one of `url` or `regex_file_set` must be set. - * - * 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; - } - - /** - * The regex-filtered set of files to scan. Exactly one of `url` or - * `regex_file_set` must be set. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageRegexFileSet regex_file_set = 2; - * @return \Google\Cloud\Dlp\V2\CloudStorageRegexFileSet|null - */ - public function getRegexFileSet() - { - return $this->regex_file_set; - } - - public function hasRegexFileSet() - { - return isset($this->regex_file_set); - } - - public function clearRegexFileSet() - { - unset($this->regex_file_set); - } - - /** - * The regex-filtered set of files to scan. Exactly one of `url` or - * `regex_file_set` must be set. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageRegexFileSet regex_file_set = 2; - * @param \Google\Cloud\Dlp\V2\CloudStorageRegexFileSet $var - * @return $this - */ - public function setRegexFileSet($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudStorageRegexFileSet::class); - $this->regex_file_set = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(FileSet::class, \Google\Cloud\Dlp\V2\CloudStorageOptions_FileSet::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/SampleMethod.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/SampleMethod.php deleted file mode 100644 index ea69dd317b55..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageOptions/SampleMethod.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.CloudStorageOptions.SampleMethod - */ -class SampleMethod -{ - /** - * No sampling. - * - * Generated from protobuf enum SAMPLE_METHOD_UNSPECIFIED = 0; - */ - const SAMPLE_METHOD_UNSPECIFIED = 0; - /** - * Scan from the top (default). - * - * Generated from protobuf enum TOP = 1; - */ - const TOP = 1; - /** - * For each file larger than bytes_limit_per_file, randomly pick the offset - * to start scanning. The scanned bytes are contiguous. - * - * Generated from protobuf enum RANDOM_START = 2; - */ - const RANDOM_START = 2; - - private static $valueToName = [ - self::SAMPLE_METHOD_UNSPECIFIED => 'SAMPLE_METHOD_UNSPECIFIED', - self::TOP => 'TOP', - self::RANDOM_START => 'RANDOM_START', - ]; - - 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(SampleMethod::class, \Google\Cloud\Dlp\V2\CloudStorageOptions_SampleMethod::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStoragePath.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStoragePath.php deleted file mode 100644 index af52b7c78587..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStoragePath.php +++ /dev/null @@ -1,71 +0,0 @@ -google.privacy.dlp.v2.CloudStoragePath - */ -class CloudStoragePath extends \Google\Protobuf\Internal\Message -{ - /** - * A URL representing a file or path (no wildcards) in Cloud Storage. - * Example: `gs://[BUCKET_NAME]/dictionary.txt` - * - * Generated from protobuf field string path = 1; - */ - protected $path = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $path - * A URL representing a file or path (no wildcards) in Cloud Storage. - * Example: `gs://[BUCKET_NAME]/dictionary.txt` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * A URL representing a file or path (no wildcards) in Cloud Storage. - * Example: `gs://[BUCKET_NAME]/dictionary.txt` - * - * Generated from protobuf field string path = 1; - * @return string - */ - public function getPath() - { - return $this->path; - } - - /** - * A URL representing a file or path (no wildcards) in Cloud Storage. - * Example: `gs://[BUCKET_NAME]/dictionary.txt` - * - * 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; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageRegexFileSet.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageRegexFileSet.php deleted file mode 100644 index 73325c4e9ca7..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CloudStorageRegexFileSet.php +++ /dev/null @@ -1,208 +0,0 @@ -google.privacy.dlp.v2.CloudStorageRegexFileSet - */ -class CloudStorageRegexFileSet extends \Google\Protobuf\Internal\Message -{ - /** - * The name of a Cloud Storage bucket. Required. - * - * Generated from protobuf field string bucket_name = 1; - */ - protected $bucket_name = ''; - /** - * A list of regular expressions matching file paths to include. All files in - * the bucket that match at least one of these regular expressions will be - * included in the set of files, except for those that also match an item in - * `exclude_regex`. Leaving this field empty will match all files by default - * (this is equivalent to including `.*` in the list). - * Regular expressions use RE2 - * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found - * under the google/re2 repository on GitHub. - * - * Generated from protobuf field repeated string include_regex = 2; - */ - private $include_regex; - /** - * A list of regular expressions matching file paths to exclude. All files in - * the bucket that match at least one of these regular expressions will be - * excluded from the scan. - * Regular expressions use RE2 - * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found - * under the google/re2 repository on GitHub. - * - * Generated from protobuf field repeated string exclude_regex = 3; - */ - private $exclude_regex; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $bucket_name - * The name of a Cloud Storage bucket. Required. - * @type array|\Google\Protobuf\Internal\RepeatedField $include_regex - * A list of regular expressions matching file paths to include. All files in - * the bucket that match at least one of these regular expressions will be - * included in the set of files, except for those that also match an item in - * `exclude_regex`. Leaving this field empty will match all files by default - * (this is equivalent to including `.*` in the list). - * Regular expressions use RE2 - * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found - * under the google/re2 repository on GitHub. - * @type array|\Google\Protobuf\Internal\RepeatedField $exclude_regex - * A list of regular expressions matching file paths to exclude. All files in - * the bucket that match at least one of these regular expressions will be - * excluded from the scan. - * Regular expressions use RE2 - * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found - * under the google/re2 repository on GitHub. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * The name of a Cloud Storage bucket. Required. - * - * Generated from protobuf field string bucket_name = 1; - * @return string - */ - public function getBucketName() - { - return $this->bucket_name; - } - - /** - * The name of a Cloud Storage bucket. Required. - * - * Generated from protobuf field string bucket_name = 1; - * @param string $var - * @return $this - */ - public function setBucketName($var) - { - GPBUtil::checkString($var, True); - $this->bucket_name = $var; - - return $this; - } - - /** - * A list of regular expressions matching file paths to include. All files in - * the bucket that match at least one of these regular expressions will be - * included in the set of files, except for those that also match an item in - * `exclude_regex`. Leaving this field empty will match all files by default - * (this is equivalent to including `.*` in the list). - * Regular expressions use RE2 - * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found - * under the google/re2 repository on GitHub. - * - * Generated from protobuf field repeated string include_regex = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIncludeRegex() - { - return $this->include_regex; - } - - /** - * A list of regular expressions matching file paths to include. All files in - * the bucket that match at least one of these regular expressions will be - * included in the set of files, except for those that also match an item in - * `exclude_regex`. Leaving this field empty will match all files by default - * (this is equivalent to including `.*` in the list). - * Regular expressions use RE2 - * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found - * under the google/re2 repository on GitHub. - * - * Generated from protobuf field repeated string include_regex = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIncludeRegex($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->include_regex = $arr; - - return $this; - } - - /** - * A list of regular expressions matching file paths to exclude. All files in - * the bucket that match at least one of these regular expressions will be - * excluded from the scan. - * Regular expressions use RE2 - * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found - * under the google/re2 repository on GitHub. - * - * Generated from protobuf field repeated string exclude_regex = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExcludeRegex() - { - return $this->exclude_regex; - } - - /** - * A list of regular expressions matching file paths to exclude. All files in - * the bucket that match at least one of these regular expressions will be - * excluded from the scan. - * Regular expressions use RE2 - * [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found - * under the google/re2 repository on GitHub. - * - * Generated from protobuf field repeated string exclude_regex = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExcludeRegex($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->exclude_regex = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Color.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Color.php deleted file mode 100644 index 4685448260e1..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Color.php +++ /dev/null @@ -1,135 +0,0 @@ -google.privacy.dlp.v2.Color - */ -class Color extends \Google\Protobuf\Internal\Message -{ - /** - * The amount of red in the color as a value in the interval [0, 1]. - * - * Generated from protobuf field float red = 1; - */ - protected $red = 0.0; - /** - * The amount of green in the color as a value in the interval [0, 1]. - * - * Generated from protobuf field float green = 2; - */ - protected $green = 0.0; - /** - * The amount of blue in the color as a value in the interval [0, 1]. - * - * Generated from protobuf field float blue = 3; - */ - protected $blue = 0.0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $red - * The amount of red in the color as a value in the interval [0, 1]. - * @type float $green - * The amount of green in the color as a value in the interval [0, 1]. - * @type float $blue - * The amount of blue in the color as a value in the interval [0, 1]. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The amount of red in the color as a value in the interval [0, 1]. - * - * Generated from protobuf field float red = 1; - * @return float - */ - public function getRed() - { - return $this->red; - } - - /** - * The amount of red in the color as a value in the interval [0, 1]. - * - * Generated from protobuf field float red = 1; - * @param float $var - * @return $this - */ - public function setRed($var) - { - GPBUtil::checkFloat($var); - $this->red = $var; - - return $this; - } - - /** - * The amount of green in the color as a value in the interval [0, 1]. - * - * Generated from protobuf field float green = 2; - * @return float - */ - public function getGreen() - { - return $this->green; - } - - /** - * The amount of green in the color as a value in the interval [0, 1]. - * - * Generated from protobuf field float green = 2; - * @param float $var - * @return $this - */ - public function setGreen($var) - { - GPBUtil::checkFloat($var); - $this->green = $var; - - return $this; - } - - /** - * The amount of blue in the color as a value in the interval [0, 1]. - * - * Generated from protobuf field float blue = 3; - * @return float - */ - public function getBlue() - { - return $this->blue; - } - - /** - * The amount of blue in the color as a value in the interval [0, 1]. - * - * Generated from protobuf field float blue = 3; - * @param float $var - * @return $this - */ - public function setBlue($var) - { - GPBUtil::checkFloat($var); - $this->blue = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile.php deleted file mode 100644 index 6afebd01c479..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile.php +++ /dev/null @@ -1,795 +0,0 @@ -google.privacy.dlp.v2.ColumnDataProfile - */ -class ColumnDataProfile extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the profile. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Success or error status from the most recent profile generation attempt. - * May be empty if the profile is still being generated. - * - * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 17; - */ - protected $profile_status = null; - /** - * State of a profile. - * - * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.State state = 18; - */ - protected $state = 0; - /** - * The last time the profile was generated. - * - * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 3; - */ - protected $profile_last_generated = null; - /** - * The resource name of the table data profile. - * - * Generated from protobuf field string table_data_profile = 4; - */ - protected $table_data_profile = ''; - /** - * The resource name of the resource this column is within. - * - * Generated from protobuf field string table_full_resource = 5; - */ - protected $table_full_resource = ''; - /** - * The Google Cloud project ID that owns the profiled resource. - * - * Generated from protobuf field string dataset_project_id = 19; - */ - protected $dataset_project_id = ''; - /** - * The BigQuery location where the dataset's data is stored. - * See https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * - * Generated from protobuf field string dataset_location = 20; - */ - protected $dataset_location = ''; - /** - * The BigQuery dataset ID. - * - * Generated from protobuf field string dataset_id = 21; - */ - protected $dataset_id = ''; - /** - * The BigQuery table ID. - * - * Generated from protobuf field string table_id = 22; - */ - protected $table_id = ''; - /** - * The name of the column. - * - * Generated from protobuf field string column = 6; - */ - protected $column = ''; - /** - * The sensitivity of this column. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 7; - */ - protected $sensitivity_score = null; - /** - * The data risk level for this column. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 8; - */ - protected $data_risk_level = null; - /** - * If it's been determined this column can be identified as a single type, - * this will be set. Otherwise the column either has unidentifiable content - * or mixed types. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeSummary column_info_type = 9; - */ - protected $column_info_type = null; - /** - * Other types found within this column. List will be unordered. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.OtherInfoTypeSummary other_matches = 10; - */ - private $other_matches; - /** - * Approximate percentage of entries being null in the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.NullPercentageLevel estimated_null_percentage = 23; - */ - protected $estimated_null_percentage = 0; - /** - * Approximate uniqueness of the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.UniquenessScoreLevel estimated_uniqueness_score = 24; - */ - protected $estimated_uniqueness_score = 0; - /** - * The likelihood that this column contains free-form text. - * A value close to 1 may indicate the column is likely to contain - * free-form or natural language text. - * Range in 0-1. - * - * Generated from protobuf field double free_text_score = 13; - */ - protected $free_text_score = 0.0; - /** - * The data type of a given column. - * - * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.ColumnDataType column_type = 14; - */ - protected $column_type = 0; - /** - * Indicates if a policy tag has been applied to the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.ColumnPolicyState policy_state = 15; - */ - protected $policy_state = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the profile. - * @type \Google\Cloud\Dlp\V2\ProfileStatus $profile_status - * Success or error status from the most recent profile generation attempt. - * May be empty if the profile is still being generated. - * @type int $state - * State of a profile. - * @type \Google\Protobuf\Timestamp $profile_last_generated - * The last time the profile was generated. - * @type string $table_data_profile - * The resource name of the table data profile. - * @type string $table_full_resource - * The resource name of the resource this column is within. - * @type string $dataset_project_id - * The Google Cloud project ID that owns the profiled resource. - * @type string $dataset_location - * The BigQuery location where the dataset's data is stored. - * See https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * @type string $dataset_id - * The BigQuery dataset ID. - * @type string $table_id - * The BigQuery table ID. - * @type string $column - * The name of the column. - * @type \Google\Cloud\Dlp\V2\SensitivityScore $sensitivity_score - * The sensitivity of this column. - * @type \Google\Cloud\Dlp\V2\DataRiskLevel $data_risk_level - * The data risk level for this column. - * @type \Google\Cloud\Dlp\V2\InfoTypeSummary $column_info_type - * If it's been determined this column can be identified as a single type, - * this will be set. Otherwise the column either has unidentifiable content - * or mixed types. - * @type array<\Google\Cloud\Dlp\V2\OtherInfoTypeSummary>|\Google\Protobuf\Internal\RepeatedField $other_matches - * Other types found within this column. List will be unordered. - * @type int $estimated_null_percentage - * Approximate percentage of entries being null in the column. - * @type int $estimated_uniqueness_score - * Approximate uniqueness of the column. - * @type float $free_text_score - * The likelihood that this column contains free-form text. - * A value close to 1 may indicate the column is likely to contain - * free-form or natural language text. - * Range in 0-1. - * @type int $column_type - * The data type of a given column. - * @type int $policy_state - * Indicates if a policy tag has been applied to the column. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The name of the profile. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the profile. - * - * 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; - } - - /** - * Success or error status from the most recent profile generation attempt. - * May be empty if the profile is still being generated. - * - * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 17; - * @return \Google\Cloud\Dlp\V2\ProfileStatus|null - */ - public function getProfileStatus() - { - return $this->profile_status; - } - - public function hasProfileStatus() - { - return isset($this->profile_status); - } - - public function clearProfileStatus() - { - unset($this->profile_status); - } - - /** - * Success or error status from the most recent profile generation attempt. - * May be empty if the profile is still being generated. - * - * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 17; - * @param \Google\Cloud\Dlp\V2\ProfileStatus $var - * @return $this - */ - public function setProfileStatus($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ProfileStatus::class); - $this->profile_status = $var; - - return $this; - } - - /** - * State of a profile. - * - * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.State state = 18; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * State of a profile. - * - * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.State state = 18; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\ColumnDataProfile\State::class); - $this->state = $var; - - return $this; - } - - /** - * The last time the profile was generated. - * - * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getProfileLastGenerated() - { - return $this->profile_last_generated; - } - - public function hasProfileLastGenerated() - { - return isset($this->profile_last_generated); - } - - public function clearProfileLastGenerated() - { - unset($this->profile_last_generated); - } - - /** - * The last time the profile was generated. - * - * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setProfileLastGenerated($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->profile_last_generated = $var; - - return $this; - } - - /** - * The resource name of the table data profile. - * - * Generated from protobuf field string table_data_profile = 4; - * @return string - */ - public function getTableDataProfile() - { - return $this->table_data_profile; - } - - /** - * The resource name of the table data profile. - * - * Generated from protobuf field string table_data_profile = 4; - * @param string $var - * @return $this - */ - public function setTableDataProfile($var) - { - GPBUtil::checkString($var, True); - $this->table_data_profile = $var; - - return $this; - } - - /** - * The resource name of the resource this column is within. - * - * Generated from protobuf field string table_full_resource = 5; - * @return string - */ - public function getTableFullResource() - { - return $this->table_full_resource; - } - - /** - * The resource name of the resource this column is within. - * - * Generated from protobuf field string table_full_resource = 5; - * @param string $var - * @return $this - */ - public function setTableFullResource($var) - { - GPBUtil::checkString($var, True); - $this->table_full_resource = $var; - - return $this; - } - - /** - * The Google Cloud project ID that owns the profiled resource. - * - * Generated from protobuf field string dataset_project_id = 19; - * @return string - */ - public function getDatasetProjectId() - { - return $this->dataset_project_id; - } - - /** - * The Google Cloud project ID that owns the profiled resource. - * - * Generated from protobuf field string dataset_project_id = 19; - * @param string $var - * @return $this - */ - public function setDatasetProjectId($var) - { - GPBUtil::checkString($var, True); - $this->dataset_project_id = $var; - - return $this; - } - - /** - * The BigQuery location where the dataset's data is stored. - * See https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * - * Generated from protobuf field string dataset_location = 20; - * @return string - */ - public function getDatasetLocation() - { - return $this->dataset_location; - } - - /** - * The BigQuery location where the dataset's data is stored. - * See https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * - * Generated from protobuf field string dataset_location = 20; - * @param string $var - * @return $this - */ - public function setDatasetLocation($var) - { - GPBUtil::checkString($var, True); - $this->dataset_location = $var; - - return $this; - } - - /** - * The BigQuery dataset ID. - * - * Generated from protobuf field string dataset_id = 21; - * @return string - */ - public function getDatasetId() - { - return $this->dataset_id; - } - - /** - * The BigQuery dataset ID. - * - * Generated from protobuf field string dataset_id = 21; - * @param string $var - * @return $this - */ - public function setDatasetId($var) - { - GPBUtil::checkString($var, True); - $this->dataset_id = $var; - - return $this; - } - - /** - * The BigQuery table ID. - * - * Generated from protobuf field string table_id = 22; - * @return string - */ - public function getTableId() - { - return $this->table_id; - } - - /** - * The BigQuery table ID. - * - * Generated from protobuf field string table_id = 22; - * @param string $var - * @return $this - */ - public function setTableId($var) - { - GPBUtil::checkString($var, True); - $this->table_id = $var; - - return $this; - } - - /** - * The name of the column. - * - * Generated from protobuf field string column = 6; - * @return string - */ - public function getColumn() - { - return $this->column; - } - - /** - * The name of the column. - * - * Generated from protobuf field string column = 6; - * @param string $var - * @return $this - */ - public function setColumn($var) - { - GPBUtil::checkString($var, True); - $this->column = $var; - - return $this; - } - - /** - * The sensitivity of this column. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 7; - * @return \Google\Cloud\Dlp\V2\SensitivityScore|null - */ - public function getSensitivityScore() - { - return $this->sensitivity_score; - } - - public function hasSensitivityScore() - { - return isset($this->sensitivity_score); - } - - public function clearSensitivityScore() - { - unset($this->sensitivity_score); - } - - /** - * The sensitivity of this column. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 7; - * @param \Google\Cloud\Dlp\V2\SensitivityScore $var - * @return $this - */ - public function setSensitivityScore($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SensitivityScore::class); - $this->sensitivity_score = $var; - - return $this; - } - - /** - * The data risk level for this column. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 8; - * @return \Google\Cloud\Dlp\V2\DataRiskLevel|null - */ - public function getDataRiskLevel() - { - return $this->data_risk_level; - } - - public function hasDataRiskLevel() - { - return isset($this->data_risk_level); - } - - public function clearDataRiskLevel() - { - unset($this->data_risk_level); - } - - /** - * The data risk level for this column. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 8; - * @param \Google\Cloud\Dlp\V2\DataRiskLevel $var - * @return $this - */ - public function setDataRiskLevel($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataRiskLevel::class); - $this->data_risk_level = $var; - - return $this; - } - - /** - * If it's been determined this column can be identified as a single type, - * this will be set. Otherwise the column either has unidentifiable content - * or mixed types. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeSummary column_info_type = 9; - * @return \Google\Cloud\Dlp\V2\InfoTypeSummary|null - */ - public function getColumnInfoType() - { - return $this->column_info_type; - } - - public function hasColumnInfoType() - { - return isset($this->column_info_type); - } - - public function clearColumnInfoType() - { - unset($this->column_info_type); - } - - /** - * If it's been determined this column can be identified as a single type, - * this will be set. Otherwise the column either has unidentifiable content - * or mixed types. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeSummary column_info_type = 9; - * @param \Google\Cloud\Dlp\V2\InfoTypeSummary $var - * @return $this - */ - public function setColumnInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoTypeSummary::class); - $this->column_info_type = $var; - - return $this; - } - - /** - * Other types found within this column. List will be unordered. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.OtherInfoTypeSummary other_matches = 10; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getOtherMatches() - { - return $this->other_matches; - } - - /** - * Other types found within this column. List will be unordered. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.OtherInfoTypeSummary other_matches = 10; - * @param array<\Google\Cloud\Dlp\V2\OtherInfoTypeSummary>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setOtherMatches($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\OtherInfoTypeSummary::class); - $this->other_matches = $arr; - - return $this; - } - - /** - * Approximate percentage of entries being null in the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.NullPercentageLevel estimated_null_percentage = 23; - * @return int - */ - public function getEstimatedNullPercentage() - { - return $this->estimated_null_percentage; - } - - /** - * Approximate percentage of entries being null in the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.NullPercentageLevel estimated_null_percentage = 23; - * @param int $var - * @return $this - */ - public function setEstimatedNullPercentage($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\NullPercentageLevel::class); - $this->estimated_null_percentage = $var; - - return $this; - } - - /** - * Approximate uniqueness of the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.UniquenessScoreLevel estimated_uniqueness_score = 24; - * @return int - */ - public function getEstimatedUniquenessScore() - { - return $this->estimated_uniqueness_score; - } - - /** - * Approximate uniqueness of the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.UniquenessScoreLevel estimated_uniqueness_score = 24; - * @param int $var - * @return $this - */ - public function setEstimatedUniquenessScore($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\UniquenessScoreLevel::class); - $this->estimated_uniqueness_score = $var; - - return $this; - } - - /** - * The likelihood that this column contains free-form text. - * A value close to 1 may indicate the column is likely to contain - * free-form or natural language text. - * Range in 0-1. - * - * Generated from protobuf field double free_text_score = 13; - * @return float - */ - public function getFreeTextScore() - { - return $this->free_text_score; - } - - /** - * The likelihood that this column contains free-form text. - * A value close to 1 may indicate the column is likely to contain - * free-form or natural language text. - * Range in 0-1. - * - * Generated from protobuf field double free_text_score = 13; - * @param float $var - * @return $this - */ - public function setFreeTextScore($var) - { - GPBUtil::checkDouble($var); - $this->free_text_score = $var; - - return $this; - } - - /** - * The data type of a given column. - * - * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.ColumnDataType column_type = 14; - * @return int - */ - public function getColumnType() - { - return $this->column_type; - } - - /** - * The data type of a given column. - * - * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.ColumnDataType column_type = 14; - * @param int $var - * @return $this - */ - public function setColumnType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\ColumnDataProfile\ColumnDataType::class); - $this->column_type = $var; - - return $this; - } - - /** - * Indicates if a policy tag has been applied to the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.ColumnPolicyState policy_state = 15; - * @return int - */ - public function getPolicyState() - { - return $this->policy_state; - } - - /** - * Indicates if a policy tag has been applied to the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile.ColumnPolicyState policy_state = 15; - * @param int $var - * @return $this - */ - public function setPolicyState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\ColumnDataProfile\ColumnPolicyState::class); - $this->policy_state = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnDataType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnDataType.php deleted file mode 100644 index 83faea00b595..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnDataType.php +++ /dev/null @@ -1,177 +0,0 @@ -google.privacy.dlp.v2.ColumnDataProfile.ColumnDataType - */ -class ColumnDataType -{ - /** - * Invalid type. - * - * Generated from protobuf enum COLUMN_DATA_TYPE_UNSPECIFIED = 0; - */ - const COLUMN_DATA_TYPE_UNSPECIFIED = 0; - /** - * Encoded as a string in decimal format. - * - * Generated from protobuf enum TYPE_INT64 = 1; - */ - const TYPE_INT64 = 1; - /** - * Encoded as a boolean "false" or "true". - * - * Generated from protobuf enum TYPE_BOOL = 2; - */ - const TYPE_BOOL = 2; - /** - * Encoded as a number, or string "NaN", "Infinity" or "-Infinity". - * - * Generated from protobuf enum TYPE_FLOAT64 = 3; - */ - const TYPE_FLOAT64 = 3; - /** - * Encoded as a string value. - * - * Generated from protobuf enum TYPE_STRING = 4; - */ - const TYPE_STRING = 4; - /** - * Encoded as a base64 string per RFC 4648, section 4. - * - * Generated from protobuf enum TYPE_BYTES = 5; - */ - const TYPE_BYTES = 5; - /** - * Encoded as an RFC 3339 timestamp with mandatory "Z" time zone string: - * 1985-04-12T23:20:50.52Z - * - * Generated from protobuf enum TYPE_TIMESTAMP = 6; - */ - const TYPE_TIMESTAMP = 6; - /** - * Encoded as RFC 3339 full-date format string: 1985-04-12 - * - * Generated from protobuf enum TYPE_DATE = 7; - */ - const TYPE_DATE = 7; - /** - * Encoded as RFC 3339 partial-time format string: 23:20:50.52 - * - * Generated from protobuf enum TYPE_TIME = 8; - */ - const TYPE_TIME = 8; - /** - * Encoded as RFC 3339 full-date "T" partial-time: 1985-04-12T23:20:50.52 - * - * Generated from protobuf enum TYPE_DATETIME = 9; - */ - const TYPE_DATETIME = 9; - /** - * Encoded as WKT - * - * Generated from protobuf enum TYPE_GEOGRAPHY = 10; - */ - const TYPE_GEOGRAPHY = 10; - /** - * Encoded as a decimal string. - * - * Generated from protobuf enum TYPE_NUMERIC = 11; - */ - const TYPE_NUMERIC = 11; - /** - * Container of ordered fields, each with a type and field name. - * - * Generated from protobuf enum TYPE_RECORD = 12; - */ - const TYPE_RECORD = 12; - /** - * Decimal type. - * - * Generated from protobuf enum TYPE_BIGNUMERIC = 13; - */ - const TYPE_BIGNUMERIC = 13; - /** - * Json type. - * - * Generated from protobuf enum TYPE_JSON = 14; - */ - const TYPE_JSON = 14; - /** - * Interval type. - * - * Generated from protobuf enum TYPE_INTERVAL = 15; - */ - const TYPE_INTERVAL = 15; - /** - * `Range` type. - * - * Generated from protobuf enum TYPE_RANGE_DATE = 16; - */ - const TYPE_RANGE_DATE = 16; - /** - * `Range` type. - * - * Generated from protobuf enum TYPE_RANGE_DATETIME = 17; - */ - const TYPE_RANGE_DATETIME = 17; - /** - * `Range` type. - * - * Generated from protobuf enum TYPE_RANGE_TIMESTAMP = 18; - */ - const TYPE_RANGE_TIMESTAMP = 18; - - private static $valueToName = [ - self::COLUMN_DATA_TYPE_UNSPECIFIED => 'COLUMN_DATA_TYPE_UNSPECIFIED', - self::TYPE_INT64 => 'TYPE_INT64', - self::TYPE_BOOL => 'TYPE_BOOL', - self::TYPE_FLOAT64 => 'TYPE_FLOAT64', - self::TYPE_STRING => 'TYPE_STRING', - self::TYPE_BYTES => 'TYPE_BYTES', - self::TYPE_TIMESTAMP => 'TYPE_TIMESTAMP', - self::TYPE_DATE => 'TYPE_DATE', - self::TYPE_TIME => 'TYPE_TIME', - self::TYPE_DATETIME => 'TYPE_DATETIME', - self::TYPE_GEOGRAPHY => 'TYPE_GEOGRAPHY', - self::TYPE_NUMERIC => 'TYPE_NUMERIC', - self::TYPE_RECORD => 'TYPE_RECORD', - self::TYPE_BIGNUMERIC => 'TYPE_BIGNUMERIC', - self::TYPE_JSON => 'TYPE_JSON', - self::TYPE_INTERVAL => 'TYPE_INTERVAL', - self::TYPE_RANGE_DATE => 'TYPE_RANGE_DATE', - self::TYPE_RANGE_DATETIME => 'TYPE_RANGE_DATETIME', - self::TYPE_RANGE_TIMESTAMP => 'TYPE_RANGE_TIMESTAMP', - ]; - - 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(ColumnDataType::class, \Google\Cloud\Dlp\V2\ColumnDataProfile_ColumnDataType::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnPolicyState.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnPolicyState.php deleted file mode 100644 index b00c7d7e26b9..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/ColumnPolicyState.php +++ /dev/null @@ -1,57 +0,0 @@ -google.privacy.dlp.v2.ColumnDataProfile.ColumnPolicyState - */ -class ColumnPolicyState -{ - /** - * No policy tags. - * - * Generated from protobuf enum COLUMN_POLICY_STATE_UNSPECIFIED = 0; - */ - const COLUMN_POLICY_STATE_UNSPECIFIED = 0; - /** - * Column has policy tag applied. - * - * Generated from protobuf enum COLUMN_POLICY_TAGGED = 1; - */ - const COLUMN_POLICY_TAGGED = 1; - - private static $valueToName = [ - self::COLUMN_POLICY_STATE_UNSPECIFIED => 'COLUMN_POLICY_STATE_UNSPECIFIED', - self::COLUMN_POLICY_TAGGED => 'COLUMN_POLICY_TAGGED', - ]; - - 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(ColumnPolicyState::class, \Google\Cloud\Dlp\V2\ColumnDataProfile_ColumnPolicyState::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/State.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/State.php deleted file mode 100644 index a8698a1945a3..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ColumnDataProfile/State.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.ColumnDataProfile.State - */ -class State -{ - /** - * Unused. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The profile is currently running. Once a profile has finished it will - * transition to DONE. - * - * Generated from protobuf enum RUNNING = 1; - */ - const RUNNING = 1; - /** - * The profile is no longer generating. - * If profile_status.status.code is 0, the profile succeeded, otherwise, it - * failed. - * - * Generated from protobuf enum DONE = 2; - */ - const DONE = 2; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::RUNNING => 'RUNNING', - self::DONE => 'DONE', - ]; - - 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, \Google\Cloud\Dlp\V2\ColumnDataProfile_State::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Connection.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Connection.php deleted file mode 100644 index 911eb5b4d87d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Connection.php +++ /dev/null @@ -1,186 +0,0 @@ -google.privacy.dlp.v2.Connection - */ -class Connection extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Name of the connection: - * `projects/{project}/locations/{location}/connections/{name}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Required. The connection's state in its lifecycle. - * - * Generated from protobuf field .google.privacy.dlp.v2.ConnectionState state = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $state = 0; - /** - * Output only. Set if status == ERROR, to provide additional details. Will - * store the last 10 errors sorted with the most recent first. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $errors; - protected $properties; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Name of the connection: - * `projects/{project}/locations/{location}/connections/{name}`. - * @type int $state - * Required. The connection's state in its lifecycle. - * @type array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $errors - * Output only. Set if status == ERROR, to provide additional details. Will - * store the last 10 errors sorted with the most recent first. - * @type \Google\Cloud\Dlp\V2\CloudSqlProperties $cloud_sql - * Connect to a Cloud SQL instance. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Name of the connection: - * `projects/{project}/locations/{location}/connections/{name}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Name of the connection: - * `projects/{project}/locations/{location}/connections/{name}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The connection's state in its lifecycle. - * - * Generated from protobuf field .google.privacy.dlp.v2.ConnectionState state = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Required. The connection's state in its lifecycle. - * - * Generated from protobuf field .google.privacy.dlp.v2.ConnectionState state = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\ConnectionState::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. Set if status == ERROR, to provide additional details. Will - * store the last 10 errors sorted with the most recent first. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getErrors() - { - return $this->errors; - } - - /** - * Output only. Set if status == ERROR, to provide additional details. Will - * store the last 10 errors sorted with the most recent first. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setErrors($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Error::class); - $this->errors = $arr; - - return $this; - } - - /** - * Connect to a Cloud SQL instance. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlProperties cloud_sql = 4; - * @return \Google\Cloud\Dlp\V2\CloudSqlProperties|null - */ - public function getCloudSql() - { - return $this->readOneof(4); - } - - public function hasCloudSql() - { - return $this->hasOneof(4); - } - - /** - * Connect to a Cloud SQL instance. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlProperties cloud_sql = 4; - * @param \Google\Cloud\Dlp\V2\CloudSqlProperties $var - * @return $this - */ - public function setCloudSql($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudSqlProperties::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getProperties() - { - return $this->whichOneof("properties"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ConnectionState.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ConnectionState.php deleted file mode 100644 index 84cec3815510..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ConnectionState.php +++ /dev/null @@ -1,75 +0,0 @@ -google.privacy.dlp.v2.ConnectionState - */ -class ConnectionState -{ - /** - * Unused - * - * Generated from protobuf enum CONNECTION_STATE_UNSPECIFIED = 0; - */ - const CONNECTION_STATE_UNSPECIFIED = 0; - /** - * DLP automatically created this connection during an initial scan, and it is - * awaiting full configuration by a user. - * - * Generated from protobuf enum MISSING_CREDENTIALS = 1; - */ - const MISSING_CREDENTIALS = 1; - /** - * A configured connection that has not encountered any errors. - * - * Generated from protobuf enum AVAILABLE = 2; - */ - const AVAILABLE = 2; - /** - * A configured connection that encountered errors during its last use. It - * will not be used again until it is set to AVAILABLE. - * If the resolution requires external action, then the client must send a - * request to set the status to AVAILABLE when the connection is ready for - * use. If the resolution doesn't require external action, then any changes to - * the connection properties will automatically mark it as AVAILABLE. - * - * Generated from protobuf enum ERROR = 3; - */ - const ERROR = 3; - - private static $valueToName = [ - self::CONNECTION_STATE_UNSPECIFIED => 'CONNECTION_STATE_UNSPECIFIED', - self::MISSING_CREDENTIALS => 'MISSING_CREDENTIALS', - self::AVAILABLE => 'AVAILABLE', - self::ERROR => 'ERROR', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Container.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Container.php deleted file mode 100644 index 2c70c94a5360..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Container.php +++ /dev/null @@ -1,354 +0,0 @@ -google.privacy.dlp.v2.Container - */ -class Container extends \Google\Protobuf\Internal\Message -{ - /** - * Container type, for example BigQuery or Cloud Storage. - * - * Generated from protobuf field string type = 1; - */ - protected $type = ''; - /** - * Project where the finding was found. - * Can be different from the project that owns the finding. - * - * Generated from protobuf field string project_id = 2; - */ - protected $project_id = ''; - /** - * A string representation of the full container name. - * Examples: - * - BigQuery: 'Project:DataSetId.TableId' - * - Cloud Storage: 'gs://Bucket/folders/filename.txt' - * - * Generated from protobuf field string full_path = 3; - */ - protected $full_path = ''; - /** - * The root of the container. - * Examples: - * - For BigQuery table `project_id:dataset_id.table_id`, the root is - * `dataset_id` - * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the root - * is `gs://bucket` - * - * Generated from protobuf field string root_path = 4; - */ - protected $root_path = ''; - /** - * The rest of the path after the root. - * Examples: - * - For BigQuery table `project_id:dataset_id.table_id`, the relative path is - * `table_id` - * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the relative - * path is `folder/filename.txt` - * - * Generated from protobuf field string relative_path = 5; - */ - protected $relative_path = ''; - /** - * Findings container modification timestamp, if applicable. For Cloud - * Storage, this field contains the last file modification timestamp. For a - * BigQuery table, this field contains the last_modified_time property. For - * Datastore, this field isn't populated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; - */ - protected $update_time = null; - /** - * Findings container version, if available - * ("generation" for Cloud Storage). - * - * Generated from protobuf field string version = 7; - */ - protected $version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $type - * Container type, for example BigQuery or Cloud Storage. - * @type string $project_id - * Project where the finding was found. - * Can be different from the project that owns the finding. - * @type string $full_path - * A string representation of the full container name. - * Examples: - * - BigQuery: 'Project:DataSetId.TableId' - * - Cloud Storage: 'gs://Bucket/folders/filename.txt' - * @type string $root_path - * The root of the container. - * Examples: - * - For BigQuery table `project_id:dataset_id.table_id`, the root is - * `dataset_id` - * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the root - * is `gs://bucket` - * @type string $relative_path - * The rest of the path after the root. - * Examples: - * - For BigQuery table `project_id:dataset_id.table_id`, the relative path is - * `table_id` - * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the relative - * path is `folder/filename.txt` - * @type \Google\Protobuf\Timestamp $update_time - * Findings container modification timestamp, if applicable. For Cloud - * Storage, this field contains the last file modification timestamp. For a - * BigQuery table, this field contains the last_modified_time property. For - * Datastore, this field isn't populated. - * @type string $version - * Findings container version, if available - * ("generation" for Cloud Storage). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Container type, for example BigQuery or Cloud Storage. - * - * Generated from protobuf field string type = 1; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * Container type, for example BigQuery or Cloud Storage. - * - * 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; - } - - /** - * Project where the finding was found. - * Can be different from the project that owns the finding. - * - * Generated from protobuf field string project_id = 2; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Project where the finding was found. - * Can be different from the project that owns the finding. - * - * 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; - } - - /** - * A string representation of the full container name. - * Examples: - * - BigQuery: 'Project:DataSetId.TableId' - * - Cloud Storage: 'gs://Bucket/folders/filename.txt' - * - * Generated from protobuf field string full_path = 3; - * @return string - */ - public function getFullPath() - { - return $this->full_path; - } - - /** - * A string representation of the full container name. - * Examples: - * - BigQuery: 'Project:DataSetId.TableId' - * - Cloud Storage: 'gs://Bucket/folders/filename.txt' - * - * Generated from protobuf field string full_path = 3; - * @param string $var - * @return $this - */ - public function setFullPath($var) - { - GPBUtil::checkString($var, True); - $this->full_path = $var; - - return $this; - } - - /** - * The root of the container. - * Examples: - * - For BigQuery table `project_id:dataset_id.table_id`, the root is - * `dataset_id` - * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the root - * is `gs://bucket` - * - * Generated from protobuf field string root_path = 4; - * @return string - */ - public function getRootPath() - { - return $this->root_path; - } - - /** - * The root of the container. - * Examples: - * - For BigQuery table `project_id:dataset_id.table_id`, the root is - * `dataset_id` - * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the root - * is `gs://bucket` - * - * Generated from protobuf field string root_path = 4; - * @param string $var - * @return $this - */ - public function setRootPath($var) - { - GPBUtil::checkString($var, True); - $this->root_path = $var; - - return $this; - } - - /** - * The rest of the path after the root. - * Examples: - * - For BigQuery table `project_id:dataset_id.table_id`, the relative path is - * `table_id` - * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the relative - * path is `folder/filename.txt` - * - * Generated from protobuf field string relative_path = 5; - * @return string - */ - public function getRelativePath() - { - return $this->relative_path; - } - - /** - * The rest of the path after the root. - * Examples: - * - For BigQuery table `project_id:dataset_id.table_id`, the relative path is - * `table_id` - * - For Cloud Storage file `gs://bucket/folder/filename.txt`, the relative - * path is `folder/filename.txt` - * - * Generated from protobuf field string relative_path = 5; - * @param string $var - * @return $this - */ - public function setRelativePath($var) - { - GPBUtil::checkString($var, True); - $this->relative_path = $var; - - return $this; - } - - /** - * Findings container modification timestamp, if applicable. For Cloud - * Storage, this field contains the last file modification timestamp. For a - * BigQuery table, this field contains the last_modified_time property. For - * Datastore, this field isn't populated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; - * @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); - } - - /** - * Findings container modification timestamp, if applicable. For Cloud - * Storage, this field contains the last file modification timestamp. For a - * BigQuery table, this field contains the last_modified_time property. For - * Datastore, this field isn't populated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Findings container version, if available - * ("generation" for Cloud Storage). - * - * Generated from protobuf field string version = 7; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * Findings container version, if available - * ("generation" for Cloud Storage). - * - * Generated from protobuf field string version = 7; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentItem.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentItem.php deleted file mode 100644 index 272e11b07211..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentItem.php +++ /dev/null @@ -1,147 +0,0 @@ -google.privacy.dlp.v2.ContentItem - */ -class ContentItem extends \Google\Protobuf\Internal\Message -{ - protected $data_item; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $value - * String data to inspect or redact. - * @type \Google\Cloud\Dlp\V2\Table $table - * Structured content for inspection. See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-text#inspecting_a_table - * to learn more. - * @type \Google\Cloud\Dlp\V2\ByteContentItem $byte_item - * Content data to inspect or redact. Replaces `type` and `data`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * String data to inspect or redact. - * - * Generated from protobuf field string value = 3; - * @return string - */ - public function getValue() - { - return $this->readOneof(3); - } - - public function hasValue() - { - return $this->hasOneof(3); - } - - /** - * String data to inspect or redact. - * - * Generated from protobuf field string value = 3; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Structured content for inspection. See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-text#inspecting_a_table - * to learn more. - * - * Generated from protobuf field .google.privacy.dlp.v2.Table table = 4; - * @return \Google\Cloud\Dlp\V2\Table|null - */ - public function getTable() - { - return $this->readOneof(4); - } - - public function hasTable() - { - return $this->hasOneof(4); - } - - /** - * Structured content for inspection. See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-text#inspecting_a_table - * to learn more. - * - * Generated from protobuf field .google.privacy.dlp.v2.Table table = 4; - * @param \Google\Cloud\Dlp\V2\Table $var - * @return $this - */ - public function setTable($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Table::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Content data to inspect or redact. Replaces `type` and `data`. - * - * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem byte_item = 5; - * @return \Google\Cloud\Dlp\V2\ByteContentItem|null - */ - public function getByteItem() - { - return $this->readOneof(5); - } - - public function hasByteItem() - { - return $this->hasOneof(5); - } - - /** - * Content data to inspect or redact. Replaces `type` and `data`. - * - * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem byte_item = 5; - * @param \Google\Cloud\Dlp\V2\ByteContentItem $var - * @return $this - */ - public function setByteItem($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ByteContentItem::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * @return string - */ - public function getDataItem() - { - return $this->whichOneof("data_item"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentLocation.php deleted file mode 100644 index 24ecf1d49145..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentLocation.php +++ /dev/null @@ -1,331 +0,0 @@ -google.privacy.dlp.v2.ContentLocation - */ -class ContentLocation extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the container where the finding is located. - * The top level name is the source file name or table name. Names of some - * common storage containers are formatted as follows: - * * BigQuery tables: `{project_id}:{dataset_id}.{table_id}` - * * Cloud Storage files: `gs://{bucket}/{path}` - * * Datastore namespace: {namespace} - * Nested names could be absent if the embedded object has no string - * identifier (for example, an image contained within a document). - * - * Generated from protobuf field string container_name = 1; - */ - protected $container_name = ''; - /** - * Finding container modification timestamp, if applicable. For Cloud Storage, - * this field contains the last file modification timestamp. For a BigQuery - * table, this field contains the last_modified_time property. For Datastore, - * this field isn't populated. - * - * Generated from protobuf field .google.protobuf.Timestamp container_timestamp = 6; - */ - protected $container_timestamp = null; - /** - * Finding container version, if available - * ("generation" for Cloud Storage). - * - * Generated from protobuf field string container_version = 7; - */ - protected $container_version = ''; - protected $location; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $container_name - * Name of the container where the finding is located. - * The top level name is the source file name or table name. Names of some - * common storage containers are formatted as follows: - * * BigQuery tables: `{project_id}:{dataset_id}.{table_id}` - * * Cloud Storage files: `gs://{bucket}/{path}` - * * Datastore namespace: {namespace} - * Nested names could be absent if the embedded object has no string - * identifier (for example, an image contained within a document). - * @type \Google\Cloud\Dlp\V2\RecordLocation $record_location - * Location within a row or record of a database table. - * @type \Google\Cloud\Dlp\V2\ImageLocation $image_location - * Location within an image's pixels. - * @type \Google\Cloud\Dlp\V2\DocumentLocation $document_location - * Location data for document files. - * @type \Google\Cloud\Dlp\V2\MetadataLocation $metadata_location - * Location within the metadata for inspected content. - * @type \Google\Protobuf\Timestamp $container_timestamp - * Finding container modification timestamp, if applicable. For Cloud Storage, - * this field contains the last file modification timestamp. For a BigQuery - * table, this field contains the last_modified_time property. For Datastore, - * this field isn't populated. - * @type string $container_version - * Finding container version, if available - * ("generation" for Cloud Storage). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Name of the container where the finding is located. - * The top level name is the source file name or table name. Names of some - * common storage containers are formatted as follows: - * * BigQuery tables: `{project_id}:{dataset_id}.{table_id}` - * * Cloud Storage files: `gs://{bucket}/{path}` - * * Datastore namespace: {namespace} - * Nested names could be absent if the embedded object has no string - * identifier (for example, an image contained within a document). - * - * Generated from protobuf field string container_name = 1; - * @return string - */ - public function getContainerName() - { - return $this->container_name; - } - - /** - * Name of the container where the finding is located. - * The top level name is the source file name or table name. Names of some - * common storage containers are formatted as follows: - * * BigQuery tables: `{project_id}:{dataset_id}.{table_id}` - * * Cloud Storage files: `gs://{bucket}/{path}` - * * Datastore namespace: {namespace} - * Nested names could be absent if the embedded object has no string - * identifier (for example, an image contained within a document). - * - * Generated from protobuf field string container_name = 1; - * @param string $var - * @return $this - */ - public function setContainerName($var) - { - GPBUtil::checkString($var, True); - $this->container_name = $var; - - return $this; - } - - /** - * Location within a row or record of a database table. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordLocation record_location = 2; - * @return \Google\Cloud\Dlp\V2\RecordLocation|null - */ - public function getRecordLocation() - { - return $this->readOneof(2); - } - - public function hasRecordLocation() - { - return $this->hasOneof(2); - } - - /** - * Location within a row or record of a database table. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordLocation record_location = 2; - * @param \Google\Cloud\Dlp\V2\RecordLocation $var - * @return $this - */ - public function setRecordLocation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordLocation::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Location within an image's pixels. - * - * Generated from protobuf field .google.privacy.dlp.v2.ImageLocation image_location = 3; - * @return \Google\Cloud\Dlp\V2\ImageLocation|null - */ - public function getImageLocation() - { - return $this->readOneof(3); - } - - public function hasImageLocation() - { - return $this->hasOneof(3); - } - - /** - * Location within an image's pixels. - * - * Generated from protobuf field .google.privacy.dlp.v2.ImageLocation image_location = 3; - * @param \Google\Cloud\Dlp\V2\ImageLocation $var - * @return $this - */ - public function setImageLocation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ImageLocation::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Location data for document files. - * - * Generated from protobuf field .google.privacy.dlp.v2.DocumentLocation document_location = 5; - * @return \Google\Cloud\Dlp\V2\DocumentLocation|null - */ - public function getDocumentLocation() - { - return $this->readOneof(5); - } - - public function hasDocumentLocation() - { - return $this->hasOneof(5); - } - - /** - * Location data for document files. - * - * Generated from protobuf field .google.privacy.dlp.v2.DocumentLocation document_location = 5; - * @param \Google\Cloud\Dlp\V2\DocumentLocation $var - * @return $this - */ - public function setDocumentLocation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DocumentLocation::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Location within the metadata for inspected content. - * - * Generated from protobuf field .google.privacy.dlp.v2.MetadataLocation metadata_location = 8; - * @return \Google\Cloud\Dlp\V2\MetadataLocation|null - */ - public function getMetadataLocation() - { - return $this->readOneof(8); - } - - public function hasMetadataLocation() - { - return $this->hasOneof(8); - } - - /** - * Location within the metadata for inspected content. - * - * Generated from protobuf field .google.privacy.dlp.v2.MetadataLocation metadata_location = 8; - * @param \Google\Cloud\Dlp\V2\MetadataLocation $var - * @return $this - */ - public function setMetadataLocation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\MetadataLocation::class); - $this->writeOneof(8, $var); - - return $this; - } - - /** - * Finding container modification timestamp, if applicable. For Cloud Storage, - * this field contains the last file modification timestamp. For a BigQuery - * table, this field contains the last_modified_time property. For Datastore, - * this field isn't populated. - * - * Generated from protobuf field .google.protobuf.Timestamp container_timestamp = 6; - * @return \Google\Protobuf\Timestamp|null - */ - public function getContainerTimestamp() - { - return $this->container_timestamp; - } - - public function hasContainerTimestamp() - { - return isset($this->container_timestamp); - } - - public function clearContainerTimestamp() - { - unset($this->container_timestamp); - } - - /** - * Finding container modification timestamp, if applicable. For Cloud Storage, - * this field contains the last file modification timestamp. For a BigQuery - * table, this field contains the last_modified_time property. For Datastore, - * this field isn't populated. - * - * Generated from protobuf field .google.protobuf.Timestamp container_timestamp = 6; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setContainerTimestamp($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->container_timestamp = $var; - - return $this; - } - - /** - * Finding container version, if available - * ("generation" for Cloud Storage). - * - * Generated from protobuf field string container_version = 7; - * @return string - */ - public function getContainerVersion() - { - return $this->container_version; - } - - /** - * Finding container version, if available - * ("generation" for Cloud Storage). - * - * Generated from protobuf field string container_version = 7; - * @param string $var - * @return $this - */ - public function setContainerVersion($var) - { - GPBUtil::checkString($var, True); - $this->container_version = $var; - - return $this; - } - - /** - * @return string - */ - public function getLocation() - { - return $this->whichOneof("location"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentOption.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentOption.php deleted file mode 100644 index 69a85fe92312..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ContentOption.php +++ /dev/null @@ -1,61 +0,0 @@ -google.privacy.dlp.v2.ContentOption - */ -class ContentOption -{ - /** - * Includes entire content of a file or a data stream. - * - * Generated from protobuf enum CONTENT_UNSPECIFIED = 0; - */ - const CONTENT_UNSPECIFIED = 0; - /** - * Text content within the data, excluding any metadata. - * - * Generated from protobuf enum CONTENT_TEXT = 1; - */ - const CONTENT_TEXT = 1; - /** - * Images found in the data. - * - * Generated from protobuf enum CONTENT_IMAGE = 2; - */ - const CONTENT_IMAGE = 2; - - private static $valueToName = [ - self::CONTENT_UNSPECIFIED => 'CONTENT_UNSPECIFIED', - self::CONTENT_TEXT => 'CONTENT_TEXT', - self::CONTENT_IMAGE => 'CONTENT_IMAGE', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateConnectionRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateConnectionRequest.php deleted file mode 100644 index 1632c9f8e190..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateConnectionRequest.php +++ /dev/null @@ -1,132 +0,0 @@ -google.privacy.dlp.v2.CreateConnectionRequest - */ -class CreateConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name in the format: - * `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The connection resource. - * - * Generated from protobuf field .google.privacy.dlp.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $connection = null; - - /** - * @param string $parent Required. Parent resource name in the format: - * `projects/{project}/locations/{location}`. Please see - * {@see DlpServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\Connection $connection Required. The connection resource. - * - * @return \Google\Cloud\Dlp\V2\CreateConnectionRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Dlp\V2\Connection $connection): self - { - return (new self()) - ->setParent($parent) - ->setConnection($connection); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name in the format: - * `projects/{project}/locations/{location}`. - * @type \Google\Cloud\Dlp\V2\Connection $connection - * Required. The connection resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name in the format: - * `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name in the format: - * `projects/{project}/locations/{location}`. - * - * 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; - } - - /** - * Required. The connection resource. - * - * Generated from protobuf field .google.privacy.dlp.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\Connection|null - */ - public function getConnection() - { - return $this->connection; - } - - public function hasConnection() - { - return isset($this->connection); - } - - public function clearConnection() - { - unset($this->connection); - } - - /** - * Required. The connection resource. - * - * Generated from protobuf field .google.privacy.dlp.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\Connection $var - * @return $this - */ - public function setConnection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Connection::class); - $this->connection = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDeidentifyTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDeidentifyTemplateRequest.php deleted file mode 100644 index 37044c2cf4b7..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDeidentifyTemplateRequest.php +++ /dev/null @@ -1,286 +0,0 @@ -google.privacy.dlp.v2.CreateDeidentifyTemplateRequest - */ -class CreateDeidentifyTemplateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The DeidentifyTemplate to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate deidentify_template = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $deidentify_template = null; - /** - * The template id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string template_id = 3; - */ - protected $template_id = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 4; - */ - protected $location_id = ''; - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $deidentifyTemplate Required. The DeidentifyTemplate to create. - * - * @return \Google\Cloud\Dlp\V2\CreateDeidentifyTemplateRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Dlp\V2\DeidentifyTemplate $deidentifyTemplate): self - { - return (new self()) - ->setParent($parent) - ->setDeidentifyTemplate($deidentifyTemplate); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type \Google\Cloud\Dlp\V2\DeidentifyTemplate $deidentify_template - * Required. The DeidentifyTemplate to create. - * @type string $template_id - * The template id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * 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; - } - - /** - * Required. The DeidentifyTemplate to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate deidentify_template = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\DeidentifyTemplate|null - */ - public function getDeidentifyTemplate() - { - return $this->deidentify_template; - } - - public function hasDeidentifyTemplate() - { - return isset($this->deidentify_template); - } - - public function clearDeidentifyTemplate() - { - unset($this->deidentify_template); - } - - /** - * Required. The DeidentifyTemplate to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate deidentify_template = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $var - * @return $this - */ - public function setDeidentifyTemplate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyTemplate::class); - $this->deidentify_template = $var; - - return $this; - } - - /** - * The template id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string template_id = 3; - * @return string - */ - public function getTemplateId() - { - return $this->template_id; - } - - /** - * The template id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string template_id = 3; - * @param string $var - * @return $this - */ - public function setTemplateId($var) - { - GPBUtil::checkString($var, True); - $this->template_id = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 4; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 4; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDiscoveryConfigRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDiscoveryConfigRequest.php deleted file mode 100644 index 4d0d65696f58..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDiscoveryConfigRequest.php +++ /dev/null @@ -1,206 +0,0 @@ -google.privacy.dlp.v2.CreateDiscoveryConfigRequest - */ -class CreateDiscoveryConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value is as follows: - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The DiscoveryConfig to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $discovery_config = null; - /** - * The config ID can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string config_id = 3; - */ - protected $config_id = ''; - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value is as follows: - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\DiscoveryConfig $discoveryConfig Required. The DiscoveryConfig to create. - * - * @return \Google\Cloud\Dlp\V2\CreateDiscoveryConfigRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Dlp\V2\DiscoveryConfig $discoveryConfig): self - { - return (new self()) - ->setParent($parent) - ->setDiscoveryConfig($discoveryConfig); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value is as follows: - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type \Google\Cloud\Dlp\V2\DiscoveryConfig $discovery_config - * Required. The DiscoveryConfig to create. - * @type string $config_id - * The config ID can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value is as follows: - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value is as follows: - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * 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; - } - - /** - * Required. The DiscoveryConfig to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\DiscoveryConfig|null - */ - public function getDiscoveryConfig() - { - return $this->discovery_config; - } - - public function hasDiscoveryConfig() - { - return isset($this->discovery_config); - } - - public function clearDiscoveryConfig() - { - unset($this->discovery_config); - } - - /** - * Required. The DiscoveryConfig to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\DiscoveryConfig $var - * @return $this - */ - public function setDiscoveryConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryConfig::class); - $this->discovery_config = $var; - - return $this; - } - - /** - * The config ID can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string config_id = 3; - * @return string - */ - public function getConfigId() - { - return $this->config_id; - } - - /** - * The config ID can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string config_id = 3; - * @param string $var - * @return $this - */ - public function setConfigId($var) - { - GPBUtil::checkString($var, True); - $this->config_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDlpJobRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDlpJobRequest.php deleted file mode 100644 index b38ffc88310a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateDlpJobRequest.php +++ /dev/null @@ -1,334 +0,0 @@ -google.privacy.dlp.v2.CreateDlpJobRequest - */ -class CreateDlpJobRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The job id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string job_id = 4; - */ - protected $job_id = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - */ - protected $location_id = ''; - protected $job; - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::projectName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\InspectJobConfig $inspectJob An inspection job scans a storage repository for InfoTypes. - * - * @return \Google\Cloud\Dlp\V2\CreateDlpJobRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Dlp\V2\InspectJobConfig $inspectJob): self - { - return (new self()) - ->setParent($parent) - ->setInspectJob($inspectJob); - } - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::projectName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig $riskJob A risk analysis job calculates re-identification risk metrics for a - * BigQuery table. - * - * @return \Google\Cloud\Dlp\V2\CreateDlpJobRequest - * - * @experimental - */ - public static function buildFromParentRiskJob(string $parent, \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig $riskJob): self - { - return (new self()) - ->setParent($parent) - ->setRiskJob($riskJob); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type \Google\Cloud\Dlp\V2\InspectJobConfig $inspect_job - * An inspection job scans a storage repository for InfoTypes. - * @type \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig $risk_job - * A risk analysis job calculates re-identification risk metrics for a - * BigQuery table. - * @type string $job_id - * The job id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * 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; - } - - /** - * An inspection job scans a storage repository for InfoTypes. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig inspect_job = 2; - * @return \Google\Cloud\Dlp\V2\InspectJobConfig|null - */ - public function getInspectJob() - { - return $this->readOneof(2); - } - - public function hasInspectJob() - { - return $this->hasOneof(2); - } - - /** - * An inspection job scans a storage repository for InfoTypes. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig inspect_job = 2; - * @param \Google\Cloud\Dlp\V2\InspectJobConfig $var - * @return $this - */ - public function setInspectJob($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectJobConfig::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * A risk analysis job calculates re-identification risk metrics for a - * BigQuery table. - * - * Generated from protobuf field .google.privacy.dlp.v2.RiskAnalysisJobConfig risk_job = 3; - * @return \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig|null - */ - public function getRiskJob() - { - return $this->readOneof(3); - } - - public function hasRiskJob() - { - return $this->hasOneof(3); - } - - /** - * A risk analysis job calculates re-identification risk metrics for a - * BigQuery table. - * - * Generated from protobuf field .google.privacy.dlp.v2.RiskAnalysisJobConfig risk_job = 3; - * @param \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig $var - * @return $this - */ - public function setRiskJob($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RiskAnalysisJobConfig::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * The job id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string job_id = 4; - * @return string - */ - public function getJobId() - { - return $this->job_id; - } - - /** - * The job id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string job_id = 4; - * @param string $var - * @return $this - */ - public function setJobId($var) - { - GPBUtil::checkString($var, True); - $this->job_id = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - - /** - * @return string - */ - public function getJob() - { - return $this->whichOneof("job"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateInspectTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateInspectTemplateRequest.php deleted file mode 100644 index 6919c3c0f689..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateInspectTemplateRequest.php +++ /dev/null @@ -1,286 +0,0 @@ -google.privacy.dlp.v2.CreateInspectTemplateRequest - */ -class CreateInspectTemplateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The InspectTemplate to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate inspect_template = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $inspect_template = null; - /** - * The template id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string template_id = 3; - */ - protected $template_id = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 4; - */ - protected $location_id = ''; - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\InspectTemplate $inspectTemplate Required. The InspectTemplate to create. - * - * @return \Google\Cloud\Dlp\V2\CreateInspectTemplateRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Dlp\V2\InspectTemplate $inspectTemplate): self - { - return (new self()) - ->setParent($parent) - ->setInspectTemplate($inspectTemplate); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type \Google\Cloud\Dlp\V2\InspectTemplate $inspect_template - * Required. The InspectTemplate to create. - * @type string $template_id - * The template id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * 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; - } - - /** - * Required. The InspectTemplate to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate inspect_template = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\InspectTemplate|null - */ - public function getInspectTemplate() - { - return $this->inspect_template; - } - - public function hasInspectTemplate() - { - return isset($this->inspect_template); - } - - public function clearInspectTemplate() - { - unset($this->inspect_template); - } - - /** - * Required. The InspectTemplate to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate inspect_template = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\InspectTemplate $var - * @return $this - */ - public function setInspectTemplate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectTemplate::class); - $this->inspect_template = $var; - - return $this; - } - - /** - * The template id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string template_id = 3; - * @return string - */ - public function getTemplateId() - { - return $this->template_id; - } - - /** - * The template id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string template_id = 3; - * @param string $var - * @return $this - */ - public function setTemplateId($var) - { - GPBUtil::checkString($var, True); - $this->template_id = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 4; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 4; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateJobTriggerRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateJobTriggerRequest.php deleted file mode 100644 index ca2b09d9a86d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateJobTriggerRequest.php +++ /dev/null @@ -1,266 +0,0 @@ -google.privacy.dlp.v2.CreateJobTriggerRequest - */ -class CreateJobTriggerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The JobTrigger to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger job_trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $job_trigger = null; - /** - * The trigger id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string trigger_id = 3; - */ - protected $trigger_id = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 4; - */ - protected $location_id = ''; - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::projectName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\JobTrigger $jobTrigger Required. The JobTrigger to create. - * - * @return \Google\Cloud\Dlp\V2\CreateJobTriggerRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Dlp\V2\JobTrigger $jobTrigger): self - { - return (new self()) - ->setParent($parent) - ->setJobTrigger($jobTrigger); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type \Google\Cloud\Dlp\V2\JobTrigger $job_trigger - * Required. The JobTrigger to create. - * @type string $trigger_id - * The trigger id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * 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; - } - - /** - * Required. The JobTrigger to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger job_trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\JobTrigger|null - */ - public function getJobTrigger() - { - return $this->job_trigger; - } - - public function hasJobTrigger() - { - return isset($this->job_trigger); - } - - public function clearJobTrigger() - { - unset($this->job_trigger); - } - - /** - * Required. The JobTrigger to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger job_trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\JobTrigger $var - * @return $this - */ - public function setJobTrigger($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\JobTrigger::class); - $this->job_trigger = $var; - - return $this; - } - - /** - * The trigger id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string trigger_id = 3; - * @return string - */ - public function getTriggerId() - { - return $this->trigger_id; - } - - /** - * The trigger id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string trigger_id = 3; - * @param string $var - * @return $this - */ - public function setTriggerId($var) - { - GPBUtil::checkString($var, True); - $this->trigger_id = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 4; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 4; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateStoredInfoTypeRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateStoredInfoTypeRequest.php deleted file mode 100644 index 62d8fa46a8e9..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CreateStoredInfoTypeRequest.php +++ /dev/null @@ -1,286 +0,0 @@ -google.privacy.dlp.v2.CreateStoredInfoTypeRequest - */ -class CreateStoredInfoTypeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Configuration of the storedInfoType to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $config = null; - /** - * The storedInfoType ID can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string stored_info_type_id = 3; - */ - protected $stored_info_type_id = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 4; - */ - protected $location_id = ''; - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config Required. Configuration of the storedInfoType to create. - * - * @return \Google\Cloud\Dlp\V2\CreateStoredInfoTypeRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config): self - { - return (new self()) - ->setParent($parent) - ->setConfig($config); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config - * Required. Configuration of the storedInfoType to create. - * @type string $stored_info_type_id - * The storedInfoType ID can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * 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; - } - - /** - * Required. Configuration of the storedInfoType to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\StoredInfoTypeConfig|null - */ - public function getConfig() - { - return $this->config; - } - - public function hasConfig() - { - return isset($this->config); - } - - public function clearConfig() - { - unset($this->config); - } - - /** - * Required. Configuration of the storedInfoType to create. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StoredInfoTypeConfig::class); - $this->config = $var; - - return $this; - } - - /** - * The storedInfoType ID can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string stored_info_type_id = 3; - * @return string - */ - public function getStoredInfoTypeId() - { - return $this->stored_info_type_id; - } - - /** - * The storedInfoType ID can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * - * Generated from protobuf field string stored_info_type_id = 3; - * @param string $var - * @return $this - */ - public function setStoredInfoTypeId($var) - { - GPBUtil::checkString($var, True); - $this->stored_info_type_id = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 4; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 4; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoDeterministicConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoDeterministicConfig.php deleted file mode 100644 index fc425a4a7ee1..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoDeterministicConfig.php +++ /dev/null @@ -1,327 +0,0 @@ -google.privacy.dlp.v2.CryptoDeterministicConfig - */ -class CryptoDeterministicConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The key used by the encryption function. For deterministic encryption - * using AES-SIV, the provided key is internally expanded to 64 bytes prior to - * use. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1; - */ - protected $crypto_key = null; - /** - * The custom info type to annotate the surrogate with. - * This annotation will be applied to the surrogate by prefixing it with - * the name of the custom info type followed by the number of - * characters comprising the surrogate. The following scheme defines the - * format: {info type name}({surrogate character count}):{surrogate} - * For example, if the name of custom info type is 'MY_TOKEN_INFO_TYPE' and - * the surrogate is 'abc', the full replacement value - * will be: 'MY_TOKEN_INFO_TYPE(3):abc' - * This annotation identifies the surrogate when inspecting content using the - * custom info type 'Surrogate'. This facilitates reversal of the - * surrogate when it occurs in free text. - * Note: For record transformations where the entire cell in a table is being - * transformed, surrogates are not mandatory. Surrogates are used to denote - * the location of the token and are necessary for re-identification in free - * form text. - * In order for inspection to work properly, the name of this info type must - * not occur naturally anywhere in your data; otherwise, inspection may either - * - reverse a surrogate that does not correspond to an actual identifier - * - be unable to parse the surrogate and result in an error - * Therefore, choose your custom info type name carefully after considering - * what your data looks like. One way to select a name that has a high chance - * of yielding reliable detection is to include one or more unicode characters - * that are highly improbable to exist in your data. - * For example, assuming your data is entered from a regular ASCII keyboard, - * the symbol with the hex code point 29DD might be used like so: - * ⧝MY_TOKEN_TYPE. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType surrogate_info_type = 2; - */ - protected $surrogate_info_type = null; - /** - * A context may be used for higher security and maintaining - * referential integrity such that the same identifier in two different - * contexts will be given a distinct surrogate. The context is appended to - * plaintext value being encrypted. On decryption the provided context is - * validated against the value used during encryption. If a context was - * provided during encryption, same context must be provided during decryption - * as well. - * If the context is not set, plaintext would be used as is for encryption. - * If the context is set but: - * 1. there is no record present when transforming a given value or - * 2. the field is not present when transforming a given value, - * plaintext would be used as is for encryption. - * Note that case (1) is expected when an `InfoTypeTransformation` is - * applied to both structured and unstructured `ContentItem`s. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 3; - */ - protected $context = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\CryptoKey $crypto_key - * The key used by the encryption function. For deterministic encryption - * using AES-SIV, the provided key is internally expanded to 64 bytes prior to - * use. - * @type \Google\Cloud\Dlp\V2\InfoType $surrogate_info_type - * The custom info type to annotate the surrogate with. - * This annotation will be applied to the surrogate by prefixing it with - * the name of the custom info type followed by the number of - * characters comprising the surrogate. The following scheme defines the - * format: {info type name}({surrogate character count}):{surrogate} - * For example, if the name of custom info type is 'MY_TOKEN_INFO_TYPE' and - * the surrogate is 'abc', the full replacement value - * will be: 'MY_TOKEN_INFO_TYPE(3):abc' - * This annotation identifies the surrogate when inspecting content using the - * custom info type 'Surrogate'. This facilitates reversal of the - * surrogate when it occurs in free text. - * Note: For record transformations where the entire cell in a table is being - * transformed, surrogates are not mandatory. Surrogates are used to denote - * the location of the token and are necessary for re-identification in free - * form text. - * In order for inspection to work properly, the name of this info type must - * not occur naturally anywhere in your data; otherwise, inspection may either - * - reverse a surrogate that does not correspond to an actual identifier - * - be unable to parse the surrogate and result in an error - * Therefore, choose your custom info type name carefully after considering - * what your data looks like. One way to select a name that has a high chance - * of yielding reliable detection is to include one or more unicode characters - * that are highly improbable to exist in your data. - * For example, assuming your data is entered from a regular ASCII keyboard, - * the symbol with the hex code point 29DD might be used like so: - * ⧝MY_TOKEN_TYPE. - * @type \Google\Cloud\Dlp\V2\FieldId $context - * A context may be used for higher security and maintaining - * referential integrity such that the same identifier in two different - * contexts will be given a distinct surrogate. The context is appended to - * plaintext value being encrypted. On decryption the provided context is - * validated against the value used during encryption. If a context was - * provided during encryption, same context must be provided during decryption - * as well. - * If the context is not set, plaintext would be used as is for encryption. - * If the context is set but: - * 1. there is no record present when transforming a given value or - * 2. the field is not present when transforming a given value, - * plaintext would be used as is for encryption. - * Note that case (1) is expected when an `InfoTypeTransformation` is - * applied to both structured and unstructured `ContentItem`s. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The key used by the encryption function. For deterministic encryption - * using AES-SIV, the provided key is internally expanded to 64 bytes prior to - * use. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1; - * @return \Google\Cloud\Dlp\V2\CryptoKey|null - */ - public function getCryptoKey() - { - return $this->crypto_key; - } - - public function hasCryptoKey() - { - return isset($this->crypto_key); - } - - public function clearCryptoKey() - { - unset($this->crypto_key); - } - - /** - * The key used by the encryption function. For deterministic encryption - * using AES-SIV, the provided key is internally expanded to 64 bytes prior to - * use. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1; - * @param \Google\Cloud\Dlp\V2\CryptoKey $var - * @return $this - */ - public function setCryptoKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoKey::class); - $this->crypto_key = $var; - - return $this; - } - - /** - * The custom info type to annotate the surrogate with. - * This annotation will be applied to the surrogate by prefixing it with - * the name of the custom info type followed by the number of - * characters comprising the surrogate. The following scheme defines the - * format: {info type name}({surrogate character count}):{surrogate} - * For example, if the name of custom info type is 'MY_TOKEN_INFO_TYPE' and - * the surrogate is 'abc', the full replacement value - * will be: 'MY_TOKEN_INFO_TYPE(3):abc' - * This annotation identifies the surrogate when inspecting content using the - * custom info type 'Surrogate'. This facilitates reversal of the - * surrogate when it occurs in free text. - * Note: For record transformations where the entire cell in a table is being - * transformed, surrogates are not mandatory. Surrogates are used to denote - * the location of the token and are necessary for re-identification in free - * form text. - * In order for inspection to work properly, the name of this info type must - * not occur naturally anywhere in your data; otherwise, inspection may either - * - reverse a surrogate that does not correspond to an actual identifier - * - be unable to parse the surrogate and result in an error - * Therefore, choose your custom info type name carefully after considering - * what your data looks like. One way to select a name that has a high chance - * of yielding reliable detection is to include one or more unicode characters - * that are highly improbable to exist in your data. - * For example, assuming your data is entered from a regular ASCII keyboard, - * the symbol with the hex code point 29DD might be used like so: - * ⧝MY_TOKEN_TYPE. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType surrogate_info_type = 2; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getSurrogateInfoType() - { - return $this->surrogate_info_type; - } - - public function hasSurrogateInfoType() - { - return isset($this->surrogate_info_type); - } - - public function clearSurrogateInfoType() - { - unset($this->surrogate_info_type); - } - - /** - * The custom info type to annotate the surrogate with. - * This annotation will be applied to the surrogate by prefixing it with - * the name of the custom info type followed by the number of - * characters comprising the surrogate. The following scheme defines the - * format: {info type name}({surrogate character count}):{surrogate} - * For example, if the name of custom info type is 'MY_TOKEN_INFO_TYPE' and - * the surrogate is 'abc', the full replacement value - * will be: 'MY_TOKEN_INFO_TYPE(3):abc' - * This annotation identifies the surrogate when inspecting content using the - * custom info type 'Surrogate'. This facilitates reversal of the - * surrogate when it occurs in free text. - * Note: For record transformations where the entire cell in a table is being - * transformed, surrogates are not mandatory. Surrogates are used to denote - * the location of the token and are necessary for re-identification in free - * form text. - * In order for inspection to work properly, the name of this info type must - * not occur naturally anywhere in your data; otherwise, inspection may either - * - reverse a surrogate that does not correspond to an actual identifier - * - be unable to parse the surrogate and result in an error - * Therefore, choose your custom info type name carefully after considering - * what your data looks like. One way to select a name that has a high chance - * of yielding reliable detection is to include one or more unicode characters - * that are highly improbable to exist in your data. - * For example, assuming your data is entered from a regular ASCII keyboard, - * the symbol with the hex code point 29DD might be used like so: - * ⧝MY_TOKEN_TYPE. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType surrogate_info_type = 2; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setSurrogateInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->surrogate_info_type = $var; - - return $this; - } - - /** - * A context may be used for higher security and maintaining - * referential integrity such that the same identifier in two different - * contexts will be given a distinct surrogate. The context is appended to - * plaintext value being encrypted. On decryption the provided context is - * validated against the value used during encryption. If a context was - * provided during encryption, same context must be provided during decryption - * as well. - * If the context is not set, plaintext would be used as is for encryption. - * If the context is set but: - * 1. there is no record present when transforming a given value or - * 2. the field is not present when transforming a given value, - * plaintext would be used as is for encryption. - * Note that case (1) is expected when an `InfoTypeTransformation` is - * applied to both structured and unstructured `ContentItem`s. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 3; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getContext() - { - return $this->context; - } - - public function hasContext() - { - return isset($this->context); - } - - public function clearContext() - { - unset($this->context); - } - - /** - * A context may be used for higher security and maintaining - * referential integrity such that the same identifier in two different - * contexts will be given a distinct surrogate. The context is appended to - * plaintext value being encrypted. On decryption the provided context is - * validated against the value used during encryption. If a context was - * provided during encryption, same context must be provided during decryption - * as well. - * If the context is not set, plaintext would be used as is for encryption. - * If the context is set but: - * 1. there is no record present when transforming a given value or - * 2. the field is not present when transforming a given value, - * plaintext would be used as is for encryption. - * Note that case (1) is expected when an `InfoTypeTransformation` is - * applied to both structured and unstructured `ContentItem`s. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 3; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setContext($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->context = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoHashConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoHashConfig.php deleted file mode 100644 index 3b749b878b35..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoHashConfig.php +++ /dev/null @@ -1,84 +0,0 @@ -google.privacy.dlp.v2.CryptoHashConfig - */ -class CryptoHashConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The key used by the hash function. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1; - */ - protected $crypto_key = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\CryptoKey $crypto_key - * The key used by the hash function. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The key used by the hash function. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1; - * @return \Google\Cloud\Dlp\V2\CryptoKey|null - */ - public function getCryptoKey() - { - return $this->crypto_key; - } - - public function hasCryptoKey() - { - return isset($this->crypto_key); - } - - public function clearCryptoKey() - { - unset($this->crypto_key); - } - - /** - * The key used by the hash function. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1; - * @param \Google\Cloud\Dlp\V2\CryptoKey $var - * @return $this - */ - public function setCryptoKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoKey::class); - $this->crypto_key = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoKey.php deleted file mode 100644 index 403e1b4170a0..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoKey.php +++ /dev/null @@ -1,146 +0,0 @@ -google.privacy.dlp.v2.CryptoKey - */ -class CryptoKey extends \Google\Protobuf\Internal\Message -{ - protected $source; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\TransientCryptoKey $transient - * Transient crypto key - * @type \Google\Cloud\Dlp\V2\UnwrappedCryptoKey $unwrapped - * Unwrapped crypto key - * @type \Google\Cloud\Dlp\V2\KmsWrappedCryptoKey $kms_wrapped - * Key wrapped using Cloud KMS - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Transient crypto key - * - * Generated from protobuf field .google.privacy.dlp.v2.TransientCryptoKey transient = 1; - * @return \Google\Cloud\Dlp\V2\TransientCryptoKey|null - */ - public function getTransient() - { - return $this->readOneof(1); - } - - public function hasTransient() - { - return $this->hasOneof(1); - } - - /** - * Transient crypto key - * - * Generated from protobuf field .google.privacy.dlp.v2.TransientCryptoKey transient = 1; - * @param \Google\Cloud\Dlp\V2\TransientCryptoKey $var - * @return $this - */ - public function setTransient($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransientCryptoKey::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Unwrapped crypto key - * - * Generated from protobuf field .google.privacy.dlp.v2.UnwrappedCryptoKey unwrapped = 2; - * @return \Google\Cloud\Dlp\V2\UnwrappedCryptoKey|null - */ - public function getUnwrapped() - { - return $this->readOneof(2); - } - - public function hasUnwrapped() - { - return $this->hasOneof(2); - } - - /** - * Unwrapped crypto key - * - * Generated from protobuf field .google.privacy.dlp.v2.UnwrappedCryptoKey unwrapped = 2; - * @param \Google\Cloud\Dlp\V2\UnwrappedCryptoKey $var - * @return $this - */ - public function setUnwrapped($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\UnwrappedCryptoKey::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Key wrapped using Cloud KMS - * - * Generated from protobuf field .google.privacy.dlp.v2.KmsWrappedCryptoKey kms_wrapped = 3; - * @return \Google\Cloud\Dlp\V2\KmsWrappedCryptoKey|null - */ - public function getKmsWrapped() - { - return $this->readOneof(3); - } - - public function hasKmsWrapped() - { - return $this->hasOneof(3); - } - - /** - * Key wrapped using Cloud KMS - * - * Generated from protobuf field .google.privacy.dlp.v2.KmsWrappedCryptoKey kms_wrapped = 3; - * @param \Google\Cloud\Dlp\V2\KmsWrappedCryptoKey $var - * @return $this - */ - public function setKmsWrapped($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\KmsWrappedCryptoKey::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getSource() - { - return $this->whichOneof("source"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig.php deleted file mode 100644 index 78a1f0ce9324..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig.php +++ /dev/null @@ -1,448 +0,0 @@ -google.privacy.dlp.v2.CryptoReplaceFfxFpeConfig - */ -class CryptoReplaceFfxFpeConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The key used by the encryption algorithm. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $crypto_key = null; - /** - * The 'tweak', a context may be used for higher security since the same - * identifier in two different contexts won't be given the same surrogate. If - * the context is not set, a default tweak will be used. - * If the context is set but: - * 1. there is no record present when transforming a given value or - * 1. the field is not present when transforming a given value, - * a default tweak will be used. - * Note that case (1) is expected when an `InfoTypeTransformation` is - * applied to both structured and unstructured `ContentItem`s. - * Currently, the referenced field may be of value type integer or string. - * The tweak is constructed as a sequence of bytes in big endian byte order - * such that: - * - a 64 bit integer is encoded followed by a single byte of value 1 - * - a string is encoded in UTF-8 format followed by a single byte of value 2 - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 2; - */ - protected $context = null; - /** - * The custom infoType to annotate the surrogate with. - * This annotation will be applied to the surrogate by prefixing it with - * the name of the custom infoType followed by the number of - * characters comprising the surrogate. The following scheme defines the - * format: info_type_name(surrogate_character_count):surrogate - * For example, if the name of custom infoType is 'MY_TOKEN_INFO_TYPE' and - * the surrogate is 'abc', the full replacement value - * will be: 'MY_TOKEN_INFO_TYPE(3):abc' - * This annotation identifies the surrogate when inspecting content using the - * custom infoType - * [`SurrogateType`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/InspectConfig#surrogatetype). - * This facilitates reversal of the surrogate when it occurs in free text. - * In order for inspection to work properly, the name of this infoType must - * not occur naturally anywhere in your data; otherwise, inspection may - * find a surrogate that does not correspond to an actual identifier. - * Therefore, choose your custom infoType name carefully after considering - * what your data looks like. One way to select a name that has a high chance - * of yielding reliable detection is to include one or more unicode characters - * that are highly improbable to exist in your data. - * For example, assuming your data is entered from a regular ASCII keyboard, - * the symbol with the hex code point 29DD might be used like so: - * ⧝MY_TOKEN_TYPE - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType surrogate_info_type = 8; - */ - protected $surrogate_info_type = null; - protected $alphabet; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\CryptoKey $crypto_key - * Required. The key used by the encryption algorithm. - * @type \Google\Cloud\Dlp\V2\FieldId $context - * The 'tweak', a context may be used for higher security since the same - * identifier in two different contexts won't be given the same surrogate. If - * the context is not set, a default tweak will be used. - * If the context is set but: - * 1. there is no record present when transforming a given value or - * 1. the field is not present when transforming a given value, - * a default tweak will be used. - * Note that case (1) is expected when an `InfoTypeTransformation` is - * applied to both structured and unstructured `ContentItem`s. - * Currently, the referenced field may be of value type integer or string. - * The tweak is constructed as a sequence of bytes in big endian byte order - * such that: - * - a 64 bit integer is encoded followed by a single byte of value 1 - * - a string is encoded in UTF-8 format followed by a single byte of value 2 - * @type int $common_alphabet - * Common alphabets. - * @type string $custom_alphabet - * This is supported by mapping these to the alphanumeric characters - * that the FFX mode natively supports. This happens before/after - * encryption/decryption. - * Each character listed must appear only once. - * Number of characters must be in the range [2, 95]. - * This must be encoded as ASCII. - * The order of characters does not matter. - * The full list of allowed characters is: - * 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz - * ~`!@#$%^&*()_-+={[}]|\:;"'<,>.?/ - * @type int $radix - * The native way to select the alphabet. Must be in the range [2, 95]. - * @type \Google\Cloud\Dlp\V2\InfoType $surrogate_info_type - * The custom infoType to annotate the surrogate with. - * This annotation will be applied to the surrogate by prefixing it with - * the name of the custom infoType followed by the number of - * characters comprising the surrogate. The following scheme defines the - * format: info_type_name(surrogate_character_count):surrogate - * For example, if the name of custom infoType is 'MY_TOKEN_INFO_TYPE' and - * the surrogate is 'abc', the full replacement value - * will be: 'MY_TOKEN_INFO_TYPE(3):abc' - * This annotation identifies the surrogate when inspecting content using the - * custom infoType - * [`SurrogateType`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/InspectConfig#surrogatetype). - * This facilitates reversal of the surrogate when it occurs in free text. - * In order for inspection to work properly, the name of this infoType must - * not occur naturally anywhere in your data; otherwise, inspection may - * find a surrogate that does not correspond to an actual identifier. - * Therefore, choose your custom infoType name carefully after considering - * what your data looks like. One way to select a name that has a high chance - * of yielding reliable detection is to include one or more unicode characters - * that are highly improbable to exist in your data. - * For example, assuming your data is entered from a regular ASCII keyboard, - * the symbol with the hex code point 29DD might be used like so: - * ⧝MY_TOKEN_TYPE - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. The key used by the encryption algorithm. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\CryptoKey|null - */ - public function getCryptoKey() - { - return $this->crypto_key; - } - - public function hasCryptoKey() - { - return isset($this->crypto_key); - } - - public function clearCryptoKey() - { - unset($this->crypto_key); - } - - /** - * Required. The key used by the encryption algorithm. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\CryptoKey $var - * @return $this - */ - public function setCryptoKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoKey::class); - $this->crypto_key = $var; - - return $this; - } - - /** - * The 'tweak', a context may be used for higher security since the same - * identifier in two different contexts won't be given the same surrogate. If - * the context is not set, a default tweak will be used. - * If the context is set but: - * 1. there is no record present when transforming a given value or - * 1. the field is not present when transforming a given value, - * a default tweak will be used. - * Note that case (1) is expected when an `InfoTypeTransformation` is - * applied to both structured and unstructured `ContentItem`s. - * Currently, the referenced field may be of value type integer or string. - * The tweak is constructed as a sequence of bytes in big endian byte order - * such that: - * - a 64 bit integer is encoded followed by a single byte of value 1 - * - a string is encoded in UTF-8 format followed by a single byte of value 2 - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 2; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getContext() - { - return $this->context; - } - - public function hasContext() - { - return isset($this->context); - } - - public function clearContext() - { - unset($this->context); - } - - /** - * The 'tweak', a context may be used for higher security since the same - * identifier in two different contexts won't be given the same surrogate. If - * the context is not set, a default tweak will be used. - * If the context is set but: - * 1. there is no record present when transforming a given value or - * 1. the field is not present when transforming a given value, - * a default tweak will be used. - * Note that case (1) is expected when an `InfoTypeTransformation` is - * applied to both structured and unstructured `ContentItem`s. - * Currently, the referenced field may be of value type integer or string. - * The tweak is constructed as a sequence of bytes in big endian byte order - * such that: - * - a 64 bit integer is encoded followed by a single byte of value 1 - * - a string is encoded in UTF-8 format followed by a single byte of value 2 - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 2; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setContext($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->context = $var; - - return $this; - } - - /** - * Common alphabets. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; - * @return int - */ - public function getCommonAlphabet() - { - return $this->readOneof(4); - } - - public function hasCommonAlphabet() - { - return $this->hasOneof(4); - } - - /** - * Common alphabets. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; - * @param int $var - * @return $this - */ - public function setCommonAlphabet($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\CryptoReplaceFfxFpeConfig\FfxCommonNativeAlphabet::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * This is supported by mapping these to the alphanumeric characters - * that the FFX mode natively supports. This happens before/after - * encryption/decryption. - * Each character listed must appear only once. - * Number of characters must be in the range [2, 95]. - * This must be encoded as ASCII. - * The order of characters does not matter. - * The full list of allowed characters is: - * 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz - * ~`!@#$%^&*()_-+={[}]|\:;"'<,>.?/ - * - * Generated from protobuf field string custom_alphabet = 5; - * @return string - */ - public function getCustomAlphabet() - { - return $this->readOneof(5); - } - - public function hasCustomAlphabet() - { - return $this->hasOneof(5); - } - - /** - * This is supported by mapping these to the alphanumeric characters - * that the FFX mode natively supports. This happens before/after - * encryption/decryption. - * Each character listed must appear only once. - * Number of characters must be in the range [2, 95]. - * This must be encoded as ASCII. - * The order of characters does not matter. - * The full list of allowed characters is: - * 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz - * ~`!@#$%^&*()_-+={[}]|\:;"'<,>.?/ - * - * Generated from protobuf field string custom_alphabet = 5; - * @param string $var - * @return $this - */ - public function setCustomAlphabet($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * The native way to select the alphabet. Must be in the range [2, 95]. - * - * Generated from protobuf field int32 radix = 6; - * @return int - */ - public function getRadix() - { - return $this->readOneof(6); - } - - public function hasRadix() - { - return $this->hasOneof(6); - } - - /** - * The native way to select the alphabet. Must be in the range [2, 95]. - * - * Generated from protobuf field int32 radix = 6; - * @param int $var - * @return $this - */ - public function setRadix($var) - { - GPBUtil::checkInt32($var); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * The custom infoType to annotate the surrogate with. - * This annotation will be applied to the surrogate by prefixing it with - * the name of the custom infoType followed by the number of - * characters comprising the surrogate. The following scheme defines the - * format: info_type_name(surrogate_character_count):surrogate - * For example, if the name of custom infoType is 'MY_TOKEN_INFO_TYPE' and - * the surrogate is 'abc', the full replacement value - * will be: 'MY_TOKEN_INFO_TYPE(3):abc' - * This annotation identifies the surrogate when inspecting content using the - * custom infoType - * [`SurrogateType`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/InspectConfig#surrogatetype). - * This facilitates reversal of the surrogate when it occurs in free text. - * In order for inspection to work properly, the name of this infoType must - * not occur naturally anywhere in your data; otherwise, inspection may - * find a surrogate that does not correspond to an actual identifier. - * Therefore, choose your custom infoType name carefully after considering - * what your data looks like. One way to select a name that has a high chance - * of yielding reliable detection is to include one or more unicode characters - * that are highly improbable to exist in your data. - * For example, assuming your data is entered from a regular ASCII keyboard, - * the symbol with the hex code point 29DD might be used like so: - * ⧝MY_TOKEN_TYPE - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType surrogate_info_type = 8; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getSurrogateInfoType() - { - return $this->surrogate_info_type; - } - - public function hasSurrogateInfoType() - { - return isset($this->surrogate_info_type); - } - - public function clearSurrogateInfoType() - { - unset($this->surrogate_info_type); - } - - /** - * The custom infoType to annotate the surrogate with. - * This annotation will be applied to the surrogate by prefixing it with - * the name of the custom infoType followed by the number of - * characters comprising the surrogate. The following scheme defines the - * format: info_type_name(surrogate_character_count):surrogate - * For example, if the name of custom infoType is 'MY_TOKEN_INFO_TYPE' and - * the surrogate is 'abc', the full replacement value - * will be: 'MY_TOKEN_INFO_TYPE(3):abc' - * This annotation identifies the surrogate when inspecting content using the - * custom infoType - * [`SurrogateType`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/InspectConfig#surrogatetype). - * This facilitates reversal of the surrogate when it occurs in free text. - * In order for inspection to work properly, the name of this infoType must - * not occur naturally anywhere in your data; otherwise, inspection may - * find a surrogate that does not correspond to an actual identifier. - * Therefore, choose your custom infoType name carefully after considering - * what your data looks like. One way to select a name that has a high chance - * of yielding reliable detection is to include one or more unicode characters - * that are highly improbable to exist in your data. - * For example, assuming your data is entered from a regular ASCII keyboard, - * the symbol with the hex code point 29DD might be used like so: - * ⧝MY_TOKEN_TYPE - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType surrogate_info_type = 8; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setSurrogateInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->surrogate_info_type = $var; - - return $this; - } - - /** - * @return string - */ - public function getAlphabet() - { - return $this->whichOneof("alphabet"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig/FfxCommonNativeAlphabet.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig/FfxCommonNativeAlphabet.php deleted file mode 100644 index c08c85b4dd25..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CryptoReplaceFfxFpeConfig/FfxCommonNativeAlphabet.php +++ /dev/null @@ -1,80 +0,0 @@ -google.privacy.dlp.v2.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet - */ -class FfxCommonNativeAlphabet -{ - /** - * Unused. - * - * Generated from protobuf enum FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED = 0; - */ - const FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED = 0; - /** - * `[0-9]` (radix of 10) - * - * Generated from protobuf enum NUMERIC = 1; - */ - const NUMERIC = 1; - /** - * `[0-9A-F]` (radix of 16) - * - * Generated from protobuf enum HEXADECIMAL = 2; - */ - const HEXADECIMAL = 2; - /** - * `[0-9A-Z]` (radix of 36) - * - * Generated from protobuf enum UPPER_CASE_ALPHA_NUMERIC = 3; - */ - const UPPER_CASE_ALPHA_NUMERIC = 3; - /** - * `[0-9A-Za-z]` (radix of 62) - * - * Generated from protobuf enum ALPHA_NUMERIC = 4; - */ - const ALPHA_NUMERIC = 4; - - private static $valueToName = [ - self::FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED => 'FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED', - self::NUMERIC => 'NUMERIC', - self::HEXADECIMAL => 'HEXADECIMAL', - self::UPPER_CASE_ALPHA_NUMERIC => 'UPPER_CASE_ALPHA_NUMERIC', - self::ALPHA_NUMERIC => 'ALPHA_NUMERIC', - ]; - - 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(FfxCommonNativeAlphabet::class, \Google\Cloud\Dlp\V2\CryptoReplaceFfxFpeConfig_FfxCommonNativeAlphabet::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType.php deleted file mode 100644 index 741a2b367937..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType.php +++ /dev/null @@ -1,427 +0,0 @@ -google.privacy.dlp.v2.CustomInfoType - */ -class CustomInfoType extends \Google\Protobuf\Internal\Message -{ - /** - * CustomInfoType can either be a new infoType, or an extension of built-in - * infoType, when the name matches one of existing infoTypes and that infoType - * is specified in `InspectContent.info_types` field. Specifying the latter - * adds findings to the one detected by the system. If built-in info type is - * not specified in `InspectContent.info_types` list then the name is treated - * as a custom info type. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - */ - protected $info_type = null; - /** - * Likelihood to return for this CustomInfoType. This base value can be - * altered by a detection rule if the finding meets the criteria specified by - * the rule. Defaults to `VERY_LIKELY` if not specified. - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood likelihood = 6; - */ - protected $likelihood = 0; - /** - * Set of detection rules to apply to all findings of this CustomInfoType. - * Rules are applied in order that they are specified. Not supported for the - * `surrogate_type` CustomInfoType. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.CustomInfoType.DetectionRule detection_rules = 7; - */ - private $detection_rules; - /** - * If set to EXCLUSION_TYPE_EXCLUDE this infoType will not cause a finding - * to be returned. It still can be used for rules matching. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.ExclusionType exclusion_type = 8; - */ - protected $exclusion_type = 0; - /** - * Sensitivity for this CustomInfoType. If this CustomInfoType extends an - * existing InfoType, the sensitivity here will take precedence over that of - * the original InfoType. If unset for a CustomInfoType, it will default to - * HIGH. - * This only applies to data profiling. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 9; - */ - protected $sensitivity_score = null; - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InfoType $info_type - * CustomInfoType can either be a new infoType, or an extension of built-in - * infoType, when the name matches one of existing infoTypes and that infoType - * is specified in `InspectContent.info_types` field. Specifying the latter - * adds findings to the one detected by the system. If built-in info type is - * not specified in `InspectContent.info_types` list then the name is treated - * as a custom info type. - * @type int $likelihood - * Likelihood to return for this CustomInfoType. This base value can be - * altered by a detection rule if the finding meets the criteria specified by - * the rule. Defaults to `VERY_LIKELY` if not specified. - * @type \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary $dictionary - * A list of phrases to detect as a CustomInfoType. - * @type \Google\Cloud\Dlp\V2\CustomInfoType\Regex $regex - * Regular expression based CustomInfoType. - * @type \Google\Cloud\Dlp\V2\CustomInfoType\SurrogateType $surrogate_type - * Message for detecting output from deidentification transformations that - * support reversing. - * @type \Google\Cloud\Dlp\V2\StoredType $stored_type - * Load an existing `StoredInfoType` resource for use in - * `InspectDataSource`. Not currently supported in `InspectContent`. - * @type array<\Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule>|\Google\Protobuf\Internal\RepeatedField $detection_rules - * Set of detection rules to apply to all findings of this CustomInfoType. - * Rules are applied in order that they are specified. Not supported for the - * `surrogate_type` CustomInfoType. - * @type int $exclusion_type - * If set to EXCLUSION_TYPE_EXCLUDE this infoType will not cause a finding - * to be returned. It still can be used for rules matching. - * @type \Google\Cloud\Dlp\V2\SensitivityScore $sensitivity_score - * Sensitivity for this CustomInfoType. If this CustomInfoType extends an - * existing InfoType, the sensitivity here will take precedence over that of - * the original InfoType. If unset for a CustomInfoType, it will default to - * HIGH. - * This only applies to data profiling. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * CustomInfoType can either be a new infoType, or an extension of built-in - * infoType, when the name matches one of existing infoTypes and that infoType - * is specified in `InspectContent.info_types` field. Specifying the latter - * adds findings to the one detected by the system. If built-in info type is - * not specified in `InspectContent.info_types` list then the name is treated - * as a custom info type. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getInfoType() - { - return $this->info_type; - } - - public function hasInfoType() - { - return isset($this->info_type); - } - - public function clearInfoType() - { - unset($this->info_type); - } - - /** - * CustomInfoType can either be a new infoType, or an extension of built-in - * infoType, when the name matches one of existing infoTypes and that infoType - * is specified in `InspectContent.info_types` field. Specifying the latter - * adds findings to the one detected by the system. If built-in info type is - * not specified in `InspectContent.info_types` list then the name is treated - * as a custom info type. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_type = $var; - - return $this; - } - - /** - * Likelihood to return for this CustomInfoType. This base value can be - * altered by a detection rule if the finding meets the criteria specified by - * the rule. Defaults to `VERY_LIKELY` if not specified. - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood likelihood = 6; - * @return int - */ - public function getLikelihood() - { - return $this->likelihood; - } - - /** - * Likelihood to return for this CustomInfoType. This base value can be - * altered by a detection rule if the finding meets the criteria specified by - * the rule. Defaults to `VERY_LIKELY` if not specified. - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood likelihood = 6; - * @param int $var - * @return $this - */ - public function setLikelihood($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\Likelihood::class); - $this->likelihood = $var; - - return $this; - } - - /** - * A list of phrases to detect as a CustomInfoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary dictionary = 2; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary|null - */ - public function getDictionary() - { - return $this->readOneof(2); - } - - public function hasDictionary() - { - return $this->hasOneof(2); - } - - /** - * A list of phrases to detect as a CustomInfoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary dictionary = 2; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary $var - * @return $this - */ - public function setDictionary($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Regular expression based CustomInfoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex regex = 3; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\Regex|null - */ - public function getRegex() - { - return $this->readOneof(3); - } - - public function hasRegex() - { - return $this->hasOneof(3); - } - - /** - * Regular expression based CustomInfoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex regex = 3; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\Regex $var - * @return $this - */ - public function setRegex($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Regex::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Message for detecting output from deidentification transformations that - * support reversing. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.SurrogateType surrogate_type = 4; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\SurrogateType|null - */ - public function getSurrogateType() - { - return $this->readOneof(4); - } - - public function hasSurrogateType() - { - return $this->hasOneof(4); - } - - /** - * Message for detecting output from deidentification transformations that - * support reversing. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.SurrogateType surrogate_type = 4; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\SurrogateType $var - * @return $this - */ - public function setSurrogateType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\SurrogateType::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Load an existing `StoredInfoType` resource for use in - * `InspectDataSource`. Not currently supported in `InspectContent`. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredType stored_type = 5; - * @return \Google\Cloud\Dlp\V2\StoredType|null - */ - public function getStoredType() - { - return $this->readOneof(5); - } - - public function hasStoredType() - { - return $this->hasOneof(5); - } - - /** - * Load an existing `StoredInfoType` resource for use in - * `InspectDataSource`. Not currently supported in `InspectContent`. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredType stored_type = 5; - * @param \Google\Cloud\Dlp\V2\StoredType $var - * @return $this - */ - public function setStoredType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StoredType::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Set of detection rules to apply to all findings of this CustomInfoType. - * Rules are applied in order that they are specified. Not supported for the - * `surrogate_type` CustomInfoType. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.CustomInfoType.DetectionRule detection_rules = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDetectionRules() - { - return $this->detection_rules; - } - - /** - * Set of detection rules to apply to all findings of this CustomInfoType. - * Rules are applied in order that they are specified. Not supported for the - * `surrogate_type` CustomInfoType. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.CustomInfoType.DetectionRule detection_rules = 7; - * @param array<\Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDetectionRules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule::class); - $this->detection_rules = $arr; - - return $this; - } - - /** - * If set to EXCLUSION_TYPE_EXCLUDE this infoType will not cause a finding - * to be returned. It still can be used for rules matching. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.ExclusionType exclusion_type = 8; - * @return int - */ - public function getExclusionType() - { - return $this->exclusion_type; - } - - /** - * If set to EXCLUSION_TYPE_EXCLUDE this infoType will not cause a finding - * to be returned. It still can be used for rules matching. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.ExclusionType exclusion_type = 8; - * @param int $var - * @return $this - */ - public function setExclusionType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\CustomInfoType\ExclusionType::class); - $this->exclusion_type = $var; - - return $this; - } - - /** - * Sensitivity for this CustomInfoType. If this CustomInfoType extends an - * existing InfoType, the sensitivity here will take precedence over that of - * the original InfoType. If unset for a CustomInfoType, it will default to - * HIGH. - * This only applies to data profiling. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 9; - * @return \Google\Cloud\Dlp\V2\SensitivityScore|null - */ - public function getSensitivityScore() - { - return $this->sensitivity_score; - } - - public function hasSensitivityScore() - { - return isset($this->sensitivity_score); - } - - public function clearSensitivityScore() - { - unset($this->sensitivity_score); - } - - /** - * Sensitivity for this CustomInfoType. If this CustomInfoType extends an - * existing InfoType, the sensitivity here will take precedence over that of - * the original InfoType. If unset for a CustomInfoType, it will default to - * HIGH. - * This only applies to data profiling. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 9; - * @param \Google\Cloud\Dlp\V2\SensitivityScore $var - * @return $this - */ - public function setSensitivityScore($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SensitivityScore::class); - $this->sensitivity_score = $var; - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule.php deleted file mode 100644 index 88b6f48d1a0d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule.php +++ /dev/null @@ -1,81 +0,0 @@ -google.privacy.dlp.v2.CustomInfoType.DetectionRule - */ -class DetectionRule extends \Google\Protobuf\Internal\Message -{ - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule $hotword_rule - * Hotword-based detection rule. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Hotword-based detection rule. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.HotwordRule hotword_rule = 1; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule|null - */ - public function getHotwordRule() - { - return $this->readOneof(1); - } - - public function hasHotwordRule() - { - return $this->hasOneof(1); - } - - /** - * Hotword-based detection rule. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.HotwordRule hotword_rule = 1; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule $var - * @return $this - */ - public function setHotwordRule($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DetectionRule::class, \Google\Cloud\Dlp\V2\CustomInfoType_DetectionRule::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/HotwordRule.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/HotwordRule.php deleted file mode 100644 index 55e0494d670f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/HotwordRule.php +++ /dev/null @@ -1,213 +0,0 @@ -google.privacy.dlp.v2.CustomInfoType.DetectionRule.HotwordRule - */ -class HotwordRule extends \Google\Protobuf\Internal\Message -{ - /** - * Regular expression pattern defining what qualifies as a hotword. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex hotword_regex = 1; - */ - protected $hotword_regex = null; - /** - * Range of characters within which the entire hotword must reside. - * The total length of the window cannot exceed 1000 characters. - * The finding itself will be included in the window, so that hotwords can - * be used to match substrings of the finding itself. Suppose you - * want Cloud DLP to promote the likelihood of the phone number - * regex "\(\d{3}\) \d{3}-\d{4}" if the area code is known to be the - * area code of a company's office. In this case, use the hotword regex - * "\(xxx\)", where "xxx" is the area code in question. - * For tabular data, if you want to modify the likelihood of an entire - * column of findngs, see - * [Hotword example: Set the match likelihood of a table column] - * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity proximity = 2; - */ - protected $proximity = null; - /** - * Likelihood adjustment to apply to all matching findings. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.LikelihoodAdjustment likelihood_adjustment = 3; - */ - protected $likelihood_adjustment = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\CustomInfoType\Regex $hotword_regex - * Regular expression pattern defining what qualifies as a hotword. - * @type \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity $proximity - * Range of characters within which the entire hotword must reside. - * The total length of the window cannot exceed 1000 characters. - * The finding itself will be included in the window, so that hotwords can - * be used to match substrings of the finding itself. Suppose you - * want Cloud DLP to promote the likelihood of the phone number - * regex "\(\d{3}\) \d{3}-\d{4}" if the area code is known to be the - * area code of a company's office. In this case, use the hotword regex - * "\(xxx\)", where "xxx" is the area code in question. - * For tabular data, if you want to modify the likelihood of an entire - * column of findngs, see - * [Hotword example: Set the match likelihood of a table column] - * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). - * @type \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\LikelihoodAdjustment $likelihood_adjustment - * Likelihood adjustment to apply to all matching findings. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Regular expression pattern defining what qualifies as a hotword. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex hotword_regex = 1; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\Regex|null - */ - public function getHotwordRegex() - { - return $this->hotword_regex; - } - - public function hasHotwordRegex() - { - return isset($this->hotword_regex); - } - - public function clearHotwordRegex() - { - unset($this->hotword_regex); - } - - /** - * Regular expression pattern defining what qualifies as a hotword. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex hotword_regex = 1; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\Regex $var - * @return $this - */ - public function setHotwordRegex($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Regex::class); - $this->hotword_regex = $var; - - return $this; - } - - /** - * Range of characters within which the entire hotword must reside. - * The total length of the window cannot exceed 1000 characters. - * The finding itself will be included in the window, so that hotwords can - * be used to match substrings of the finding itself. Suppose you - * want Cloud DLP to promote the likelihood of the phone number - * regex "\(\d{3}\) \d{3}-\d{4}" if the area code is known to be the - * area code of a company's office. In this case, use the hotword regex - * "\(xxx\)", where "xxx" is the area code in question. - * For tabular data, if you want to modify the likelihood of an entire - * column of findngs, see - * [Hotword example: Set the match likelihood of a table column] - * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity proximity = 2; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity|null - */ - public function getProximity() - { - return $this->proximity; - } - - public function hasProximity() - { - return isset($this->proximity); - } - - public function clearProximity() - { - unset($this->proximity); - } - - /** - * Range of characters within which the entire hotword must reside. - * The total length of the window cannot exceed 1000 characters. - * The finding itself will be included in the window, so that hotwords can - * be used to match substrings of the finding itself. Suppose you - * want Cloud DLP to promote the likelihood of the phone number - * regex "\(\d{3}\) \d{3}-\d{4}" if the area code is known to be the - * area code of a company's office. In this case, use the hotword regex - * "\(xxx\)", where "xxx" is the area code in question. - * For tabular data, if you want to modify the likelihood of an entire - * column of findngs, see - * [Hotword example: Set the match likelihood of a table column] - * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity proximity = 2; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity $var - * @return $this - */ - public function setProximity($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity::class); - $this->proximity = $var; - - return $this; - } - - /** - * Likelihood adjustment to apply to all matching findings. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.LikelihoodAdjustment likelihood_adjustment = 3; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\LikelihoodAdjustment|null - */ - public function getLikelihoodAdjustment() - { - return $this->likelihood_adjustment; - } - - public function hasLikelihoodAdjustment() - { - return isset($this->likelihood_adjustment); - } - - public function clearLikelihoodAdjustment() - { - unset($this->likelihood_adjustment); - } - - /** - * Likelihood adjustment to apply to all matching findings. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.LikelihoodAdjustment likelihood_adjustment = 3; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\LikelihoodAdjustment $var - * @return $this - */ - public function setLikelihoodAdjustment($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\LikelihoodAdjustment::class); - $this->likelihood_adjustment = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(HotwordRule::class, \Google\Cloud\Dlp\V2\CustomInfoType_DetectionRule_HotwordRule::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/LikelihoodAdjustment.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/LikelihoodAdjustment.php deleted file mode 100644 index 9532708c58cf..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/LikelihoodAdjustment.php +++ /dev/null @@ -1,133 +0,0 @@ -google.privacy.dlp.v2.CustomInfoType.DetectionRule.LikelihoodAdjustment - */ -class LikelihoodAdjustment extends \Google\Protobuf\Internal\Message -{ - protected $adjustment; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $fixed_likelihood - * Set the likelihood of a finding to a fixed value. - * @type int $relative_likelihood - * Increase or decrease the likelihood by the specified number of - * levels. For example, if a finding would be `POSSIBLE` without the - * detection rule and `relative_likelihood` is 1, then it is upgraded to - * `LIKELY`, while a value of -1 would downgrade it to `UNLIKELY`. - * Likelihood may never drop below `VERY_UNLIKELY` or exceed - * `VERY_LIKELY`, so applying an adjustment of 1 followed by an - * adjustment of -1 when base likelihood is `VERY_LIKELY` will result in - * a final likelihood of `LIKELY`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Set the likelihood of a finding to a fixed value. - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood fixed_likelihood = 1; - * @return int - */ - public function getFixedLikelihood() - { - return $this->readOneof(1); - } - - public function hasFixedLikelihood() - { - return $this->hasOneof(1); - } - - /** - * Set the likelihood of a finding to a fixed value. - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood fixed_likelihood = 1; - * @param int $var - * @return $this - */ - public function setFixedLikelihood($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\Likelihood::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Increase or decrease the likelihood by the specified number of - * levels. For example, if a finding would be `POSSIBLE` without the - * detection rule and `relative_likelihood` is 1, then it is upgraded to - * `LIKELY`, while a value of -1 would downgrade it to `UNLIKELY`. - * Likelihood may never drop below `VERY_UNLIKELY` or exceed - * `VERY_LIKELY`, so applying an adjustment of 1 followed by an - * adjustment of -1 when base likelihood is `VERY_LIKELY` will result in - * a final likelihood of `LIKELY`. - * - * Generated from protobuf field int32 relative_likelihood = 2; - * @return int - */ - public function getRelativeLikelihood() - { - return $this->readOneof(2); - } - - public function hasRelativeLikelihood() - { - return $this->hasOneof(2); - } - - /** - * Increase or decrease the likelihood by the specified number of - * levels. For example, if a finding would be `POSSIBLE` without the - * detection rule and `relative_likelihood` is 1, then it is upgraded to - * `LIKELY`, while a value of -1 would downgrade it to `UNLIKELY`. - * Likelihood may never drop below `VERY_UNLIKELY` or exceed - * `VERY_LIKELY`, so applying an adjustment of 1 followed by an - * adjustment of -1 when base likelihood is `VERY_LIKELY` will result in - * a final likelihood of `LIKELY`. - * - * Generated from protobuf field int32 relative_likelihood = 2; - * @param int $var - * @return $this - */ - public function setRelativeLikelihood($var) - { - GPBUtil::checkInt32($var); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getAdjustment() - { - return $this->whichOneof("adjustment"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LikelihoodAdjustment::class, \Google\Cloud\Dlp\V2\CustomInfoType_DetectionRule_LikelihoodAdjustment::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/Proximity.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/Proximity.php deleted file mode 100644 index 65e1f624e4f7..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/DetectionRule/Proximity.php +++ /dev/null @@ -1,121 +0,0 @@ -google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity - */ -class Proximity extends \Google\Protobuf\Internal\Message -{ - /** - * Number of characters before the finding to consider. For tabular data, - * if you want to modify the likelihood of an entire column of findngs, - * set this to 1. For more information, see - * [Hotword example: Set the match likelihood of a table column] - * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). - * - * Generated from protobuf field int32 window_before = 1; - */ - protected $window_before = 0; - /** - * Number of characters after the finding to consider. - * - * Generated from protobuf field int32 window_after = 2; - */ - protected $window_after = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $window_before - * Number of characters before the finding to consider. For tabular data, - * if you want to modify the likelihood of an entire column of findngs, - * set this to 1. For more information, see - * [Hotword example: Set the match likelihood of a table column] - * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). - * @type int $window_after - * Number of characters after the finding to consider. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Number of characters before the finding to consider. For tabular data, - * if you want to modify the likelihood of an entire column of findngs, - * set this to 1. For more information, see - * [Hotword example: Set the match likelihood of a table column] - * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). - * - * Generated from protobuf field int32 window_before = 1; - * @return int - */ - public function getWindowBefore() - { - return $this->window_before; - } - - /** - * Number of characters before the finding to consider. For tabular data, - * if you want to modify the likelihood of an entire column of findngs, - * set this to 1. For more information, see - * [Hotword example: Set the match likelihood of a table column] - * (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). - * - * Generated from protobuf field int32 window_before = 1; - * @param int $var - * @return $this - */ - public function setWindowBefore($var) - { - GPBUtil::checkInt32($var); - $this->window_before = $var; - - return $this; - } - - /** - * Number of characters after the finding to consider. - * - * Generated from protobuf field int32 window_after = 2; - * @return int - */ - public function getWindowAfter() - { - return $this->window_after; - } - - /** - * Number of characters after the finding to consider. - * - * Generated from protobuf field int32 window_after = 2; - * @param int $var - * @return $this - */ - public function setWindowAfter($var) - { - GPBUtil::checkInt32($var); - $this->window_after = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Proximity::class, \Google\Cloud\Dlp\V2\CustomInfoType_DetectionRule_Proximity::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary.php deleted file mode 100644 index 049f1f42dff4..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary.php +++ /dev/null @@ -1,134 +0,0 @@ -google.privacy.dlp.v2.CustomInfoType.Dictionary - */ -class Dictionary extends \Google\Protobuf\Internal\Message -{ - protected $source; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList $word_list - * List of words or phrases to search for. - * @type \Google\Cloud\Dlp\V2\CloudStoragePath $cloud_storage_path - * Newline-delimited file of words in Cloud Storage. Only a single file - * is accepted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * List of words or phrases to search for. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary.WordList word_list = 1; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList|null - */ - public function getWordList() - { - return $this->readOneof(1); - } - - public function hasWordList() - { - return $this->hasOneof(1); - } - - /** - * List of words or phrases to search for. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary.WordList word_list = 1; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList $var - * @return $this - */ - public function setWordList($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Newline-delimited file of words in Cloud Storage. Only a single file - * is accepted. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStoragePath cloud_storage_path = 3; - * @return \Google\Cloud\Dlp\V2\CloudStoragePath|null - */ - public function getCloudStoragePath() - { - return $this->readOneof(3); - } - - public function hasCloudStoragePath() - { - return $this->hasOneof(3); - } - - /** - * Newline-delimited file of words in Cloud Storage. Only a single file - * is accepted. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStoragePath cloud_storage_path = 3; - * @param \Google\Cloud\Dlp\V2\CloudStoragePath $var - * @return $this - */ - public function setCloudStoragePath($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudStoragePath::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getSource() - { - return $this->whichOneof("source"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Dictionary::class, \Google\Cloud\Dlp\V2\CustomInfoType_Dictionary::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary/WordList.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary/WordList.php deleted file mode 100644 index 2b8f09b8a095..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Dictionary/WordList.php +++ /dev/null @@ -1,78 +0,0 @@ -google.privacy.dlp.v2.CustomInfoType.Dictionary.WordList - */ -class WordList extends \Google\Protobuf\Internal\Message -{ - /** - * Words or phrases defining the dictionary. The dictionary must contain - * at least one phrase and every phrase must contain at least 2 characters - * that are letters or digits. [required] - * - * Generated from protobuf field repeated string words = 1; - */ - private $words; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $words - * Words or phrases defining the dictionary. The dictionary must contain - * at least one phrase and every phrase must contain at least 2 characters - * that are letters or digits. [required] - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Words or phrases defining the dictionary. The dictionary must contain - * at least one phrase and every phrase must contain at least 2 characters - * that are letters or digits. [required] - * - * Generated from protobuf field repeated string words = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getWords() - { - return $this->words; - } - - /** - * Words or phrases defining the dictionary. The dictionary must contain - * at least one phrase and every phrase must contain at least 2 characters - * that are letters or digits. [required] - * - * Generated from protobuf field repeated string words = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setWords($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->words = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(WordList::class, \Google\Cloud\Dlp\V2\CustomInfoType_Dictionary_WordList::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/ExclusionType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/ExclusionType.php deleted file mode 100644 index 7c0cee8c1898..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/ExclusionType.php +++ /dev/null @@ -1,58 +0,0 @@ -google.privacy.dlp.v2.CustomInfoType.ExclusionType - */ -class ExclusionType -{ - /** - * A finding of this custom info type will not be excluded from results. - * - * Generated from protobuf enum EXCLUSION_TYPE_UNSPECIFIED = 0; - */ - const EXCLUSION_TYPE_UNSPECIFIED = 0; - /** - * A finding of this custom info type will be excluded from final results, - * but can still affect rule execution. - * - * Generated from protobuf enum EXCLUSION_TYPE_EXCLUDE = 1; - */ - const EXCLUSION_TYPE_EXCLUDE = 1; - - private static $valueToName = [ - self::EXCLUSION_TYPE_UNSPECIFIED => 'EXCLUSION_TYPE_UNSPECIFIED', - self::EXCLUSION_TYPE_EXCLUDE => 'EXCLUSION_TYPE_EXCLUDE', - ]; - - 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(ExclusionType::class, \Google\Cloud\Dlp\V2\CustomInfoType_ExclusionType::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Regex.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Regex.php deleted file mode 100644 index b54260ff0a67..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/Regex.php +++ /dev/null @@ -1,116 +0,0 @@ -google.privacy.dlp.v2.CustomInfoType.Regex - */ -class Regex extends \Google\Protobuf\Internal\Message -{ - /** - * Pattern defining the regular expression. Its syntax - * (https://github.com/google/re2/wiki/Syntax) can be found under the - * google/re2 repository on GitHub. - * - * Generated from protobuf field string pattern = 1; - */ - protected $pattern = ''; - /** - * The index of the submatch to extract as findings. When not - * specified, the entire match is returned. No more than 3 may be included. - * - * Generated from protobuf field repeated int32 group_indexes = 2; - */ - private $group_indexes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $pattern - * Pattern defining the regular expression. Its syntax - * (https://github.com/google/re2/wiki/Syntax) can be found under the - * google/re2 repository on GitHub. - * @type array|\Google\Protobuf\Internal\RepeatedField $group_indexes - * The index of the submatch to extract as findings. When not - * specified, the entire match is returned. No more than 3 may be included. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Pattern defining the regular expression. Its syntax - * (https://github.com/google/re2/wiki/Syntax) can be found under the - * google/re2 repository on GitHub. - * - * Generated from protobuf field string pattern = 1; - * @return string - */ - public function getPattern() - { - return $this->pattern; - } - - /** - * Pattern defining the regular expression. Its syntax - * (https://github.com/google/re2/wiki/Syntax) can be found under the - * google/re2 repository on GitHub. - * - * Generated from protobuf field string pattern = 1; - * @param string $var - * @return $this - */ - public function setPattern($var) - { - GPBUtil::checkString($var, True); - $this->pattern = $var; - - return $this; - } - - /** - * The index of the submatch to extract as findings. When not - * specified, the entire match is returned. No more than 3 may be included. - * - * Generated from protobuf field repeated int32 group_indexes = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGroupIndexes() - { - return $this->group_indexes; - } - - /** - * The index of the submatch to extract as findings. When not - * specified, the entire match is returned. No more than 3 may be included. - * - * Generated from protobuf field repeated int32 group_indexes = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGroupIndexes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); - $this->group_indexes = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Regex::class, \Google\Cloud\Dlp\V2\CustomInfoType_Regex::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/SurrogateType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/SurrogateType.php deleted file mode 100644 index 688c5e044728..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/CustomInfoType/SurrogateType.php +++ /dev/null @@ -1,43 +0,0 @@ -google.privacy.dlp.v2.CustomInfoType.SurrogateType - */ -class SurrogateType extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SurrogateType::class, \Google\Cloud\Dlp\V2\CustomInfoType_SurrogateType::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction.php deleted file mode 100644 index 250af007bcf6..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction.php +++ /dev/null @@ -1,108 +0,0 @@ -google.privacy.dlp.v2.DataProfileAction - */ -class DataProfileAction extends \Google\Protobuf\Internal\Message -{ - protected $action; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DataProfileAction\Export $export_data - * Export data profiles into a provided location. - * @type \Google\Cloud\Dlp\V2\DataProfileAction\PubSubNotification $pub_sub_notification - * Publish a message into the Pub/Sub topic. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Export data profiles into a provided location. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.Export export_data = 1; - * @return \Google\Cloud\Dlp\V2\DataProfileAction\Export|null - */ - public function getExportData() - { - return $this->readOneof(1); - } - - public function hasExportData() - { - return $this->hasOneof(1); - } - - /** - * Export data profiles into a provided location. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.Export export_data = 1; - * @param \Google\Cloud\Dlp\V2\DataProfileAction\Export $var - * @return $this - */ - public function setExportData($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfileAction\Export::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Publish a message into the Pub/Sub topic. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.PubSubNotification pub_sub_notification = 2; - * @return \Google\Cloud\Dlp\V2\DataProfileAction\PubSubNotification|null - */ - public function getPubSubNotification() - { - return $this->readOneof(2); - } - - public function hasPubSubNotification() - { - return $this->hasOneof(2); - } - - /** - * Publish a message into the Pub/Sub topic. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.PubSubNotification pub_sub_notification = 2; - * @param \Google\Cloud\Dlp\V2\DataProfileAction\PubSubNotification $var - * @return $this - */ - public function setPubSubNotification($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfileAction\PubSubNotification::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getAction() - { - return $this->whichOneof("action"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/EventType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/EventType.php deleted file mode 100644 index 0c49c9ad18c9..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/EventType.php +++ /dev/null @@ -1,80 +0,0 @@ -google.privacy.dlp.v2.DataProfileAction.EventType - */ -class EventType -{ - /** - * Unused. - * - * Generated from protobuf enum EVENT_TYPE_UNSPECIFIED = 0; - */ - const EVENT_TYPE_UNSPECIFIED = 0; - /** - * New profile (not a re-profile). - * - * Generated from protobuf enum NEW_PROFILE = 1; - */ - const NEW_PROFILE = 1; - /** - * One of the following profile metrics changed: Data risk score, - * Sensitivity score, Resource visibility, Encryption type, Predicted - * infoTypes, Other infoTypes - * - * Generated from protobuf enum CHANGED_PROFILE = 2; - */ - const CHANGED_PROFILE = 2; - /** - * Table data risk score or sensitivity score increased. - * - * Generated from protobuf enum SCORE_INCREASED = 3; - */ - const SCORE_INCREASED = 3; - /** - * A user (non-internal) error occurred. - * - * Generated from protobuf enum ERROR_CHANGED = 4; - */ - const ERROR_CHANGED = 4; - - private static $valueToName = [ - self::EVENT_TYPE_UNSPECIFIED => 'EVENT_TYPE_UNSPECIFIED', - self::NEW_PROFILE => 'NEW_PROFILE', - self::CHANGED_PROFILE => 'CHANGED_PROFILE', - self::SCORE_INCREASED => 'SCORE_INCREASED', - self::ERROR_CHANGED => 'ERROR_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(EventType::class, \Google\Cloud\Dlp\V2\DataProfileAction_EventType::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/Export.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/Export.php deleted file mode 100644 index f406b2dec6cf..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/Export.php +++ /dev/null @@ -1,113 +0,0 @@ -google.privacy.dlp.v2.DataProfileAction.Export - */ -class Export extends \Google\Protobuf\Internal\Message -{ - /** - * Store all table and column profiles in an existing table or a new table - * in an existing dataset. Each re-generation will result in new rows in - * BigQuery. Data is inserted using [streaming - * insert](https://cloud.google.com/blog/products/bigquery/life-of-a-bigquery-streaming-insert) - * and so data may be in the buffer for a period of time after the profile - * has finished. The Pub/Sub notification is sent before the streaming - * buffer is guaranteed to be written, so data may not be instantly - * visible to queries by the time your topic receives the Pub/Sub - * notification. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable profile_table = 1; - */ - protected $profile_table = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\BigQueryTable $profile_table - * Store all table and column profiles in an existing table or a new table - * in an existing dataset. Each re-generation will result in new rows in - * BigQuery. Data is inserted using [streaming - * insert](https://cloud.google.com/blog/products/bigquery/life-of-a-bigquery-streaming-insert) - * and so data may be in the buffer for a period of time after the profile - * has finished. The Pub/Sub notification is sent before the streaming - * buffer is guaranteed to be written, so data may not be instantly - * visible to queries by the time your topic receives the Pub/Sub - * notification. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Store all table and column profiles in an existing table or a new table - * in an existing dataset. Each re-generation will result in new rows in - * BigQuery. Data is inserted using [streaming - * insert](https://cloud.google.com/blog/products/bigquery/life-of-a-bigquery-streaming-insert) - * and so data may be in the buffer for a period of time after the profile - * has finished. The Pub/Sub notification is sent before the streaming - * buffer is guaranteed to be written, so data may not be instantly - * visible to queries by the time your topic receives the Pub/Sub - * notification. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable profile_table = 1; - * @return \Google\Cloud\Dlp\V2\BigQueryTable|null - */ - public function getProfileTable() - { - return $this->profile_table; - } - - public function hasProfileTable() - { - return isset($this->profile_table); - } - - public function clearProfileTable() - { - unset($this->profile_table); - } - - /** - * Store all table and column profiles in an existing table or a new table - * in an existing dataset. Each re-generation will result in new rows in - * BigQuery. Data is inserted using [streaming - * insert](https://cloud.google.com/blog/products/bigquery/life-of-a-bigquery-streaming-insert) - * and so data may be in the buffer for a period of time after the profile - * has finished. The Pub/Sub notification is sent before the streaming - * buffer is guaranteed to be written, so data may not be instantly - * visible to queries by the time your topic receives the Pub/Sub - * notification. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable profile_table = 1; - * @param \Google\Cloud\Dlp\V2\BigQueryTable $var - * @return $this - */ - public function setProfileTable($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); - $this->profile_table = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Export::class, \Google\Cloud\Dlp\V2\DataProfileAction_Export::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification.php deleted file mode 100644 index 57a33ee43c26..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification.php +++ /dev/null @@ -1,204 +0,0 @@ -google.privacy.dlp.v2.DataProfileAction.PubSubNotification - */ -class PubSubNotification extends \Google\Protobuf\Internal\Message -{ - /** - * Cloud Pub/Sub topic to send notifications to. - * Format is projects/{project}/topics/{topic}. - * - * Generated from protobuf field string topic = 1; - */ - protected $topic = ''; - /** - * The type of event that triggers a Pub/Sub. At most one - * `PubSubNotification` per EventType is permitted. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.EventType event = 2; - */ - protected $event = 0; - /** - * Conditions (e.g., data risk or sensitivity level) for triggering a - * Pub/Sub. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition pubsub_condition = 3; - */ - protected $pubsub_condition = null; - /** - * How much data to include in the Pub/Sub message. If the user wishes to - * limit the size of the message, they can use resource_name and fetch the - * profile fields they wish to. Per table profile (not per column). - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.PubSubNotification.DetailLevel detail_of_message = 4; - */ - protected $detail_of_message = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $topic - * Cloud Pub/Sub topic to send notifications to. - * Format is projects/{project}/topics/{topic}. - * @type int $event - * The type of event that triggers a Pub/Sub. At most one - * `PubSubNotification` per EventType is permitted. - * @type \Google\Cloud\Dlp\V2\DataProfilePubSubCondition $pubsub_condition - * Conditions (e.g., data risk or sensitivity level) for triggering a - * Pub/Sub. - * @type int $detail_of_message - * How much data to include in the Pub/Sub message. If the user wishes to - * limit the size of the message, they can use resource_name and fetch the - * profile fields they wish to. Per table profile (not per column). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Cloud Pub/Sub topic to send notifications to. - * Format is projects/{project}/topics/{topic}. - * - * Generated from protobuf field string topic = 1; - * @return string - */ - public function getTopic() - { - return $this->topic; - } - - /** - * Cloud Pub/Sub topic to send notifications to. - * Format is projects/{project}/topics/{topic}. - * - * Generated from protobuf field string topic = 1; - * @param string $var - * @return $this - */ - public function setTopic($var) - { - GPBUtil::checkString($var, True); - $this->topic = $var; - - return $this; - } - - /** - * The type of event that triggers a Pub/Sub. At most one - * `PubSubNotification` per EventType is permitted. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.EventType event = 2; - * @return int - */ - public function getEvent() - { - return $this->event; - } - - /** - * The type of event that triggers a Pub/Sub. At most one - * `PubSubNotification` per EventType is permitted. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.EventType event = 2; - * @param int $var - * @return $this - */ - public function setEvent($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileAction\EventType::class); - $this->event = $var; - - return $this; - } - - /** - * Conditions (e.g., data risk or sensitivity level) for triggering a - * Pub/Sub. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition pubsub_condition = 3; - * @return \Google\Cloud\Dlp\V2\DataProfilePubSubCondition|null - */ - public function getPubsubCondition() - { - return $this->pubsub_condition; - } - - public function hasPubsubCondition() - { - return isset($this->pubsub_condition); - } - - public function clearPubsubCondition() - { - unset($this->pubsub_condition); - } - - /** - * Conditions (e.g., data risk or sensitivity level) for triggering a - * Pub/Sub. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition pubsub_condition = 3; - * @param \Google\Cloud\Dlp\V2\DataProfilePubSubCondition $var - * @return $this - */ - public function setPubsubCondition($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition::class); - $this->pubsub_condition = $var; - - return $this; - } - - /** - * How much data to include in the Pub/Sub message. If the user wishes to - * limit the size of the message, they can use resource_name and fetch the - * profile fields they wish to. Per table profile (not per column). - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.PubSubNotification.DetailLevel detail_of_message = 4; - * @return int - */ - public function getDetailOfMessage() - { - return $this->detail_of_message; - } - - /** - * How much data to include in the Pub/Sub message. If the user wishes to - * limit the size of the message, they can use resource_name and fetch the - * profile fields they wish to. Per table profile (not per column). - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.PubSubNotification.DetailLevel detail_of_message = 4; - * @param int $var - * @return $this - */ - public function setDetailOfMessage($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileAction\PubSubNotification\DetailLevel::class); - $this->detail_of_message = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PubSubNotification::class, \Google\Cloud\Dlp\V2\DataProfileAction_PubSubNotification::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification/DetailLevel.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification/DetailLevel.php deleted file mode 100644 index 3367ba04d4e6..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileAction/PubSubNotification/DetailLevel.php +++ /dev/null @@ -1,64 +0,0 @@ -google.privacy.dlp.v2.DataProfileAction.PubSubNotification.DetailLevel - */ -class DetailLevel -{ - /** - * Unused. - * - * Generated from protobuf enum DETAIL_LEVEL_UNSPECIFIED = 0; - */ - const DETAIL_LEVEL_UNSPECIFIED = 0; - /** - * The full table data profile. - * - * Generated from protobuf enum TABLE_PROFILE = 1; - */ - const TABLE_PROFILE = 1; - /** - * The name of the profiled resource. - * - * Generated from protobuf enum RESOURCE_NAME = 2; - */ - const RESOURCE_NAME = 2; - - private static $valueToName = [ - self::DETAIL_LEVEL_UNSPECIFIED => 'DETAIL_LEVEL_UNSPECIFIED', - self::TABLE_PROFILE => 'TABLE_PROFILE', - self::RESOURCE_NAME => 'RESOURCE_NAME', - ]; - - 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(DetailLevel::class, \Google\Cloud\Dlp\V2\DataProfileAction_PubSubNotification_DetailLevel::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileBigQueryRowSchema.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileBigQueryRowSchema.php deleted file mode 100644 index c2460dbf4913..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileBigQueryRowSchema.php +++ /dev/null @@ -1,109 +0,0 @@ -google.privacy.dlp.v2.DataProfileBigQueryRowSchema - */ -class DataProfileBigQueryRowSchema extends \Google\Protobuf\Internal\Message -{ - protected $data_profile; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\TableDataProfile $table_profile - * Table data profile column - * @type \Google\Cloud\Dlp\V2\ColumnDataProfile $column_profile - * Column data profile column - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Table data profile column - * - * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile table_profile = 1; - * @return \Google\Cloud\Dlp\V2\TableDataProfile|null - */ - public function getTableProfile() - { - return $this->readOneof(1); - } - - public function hasTableProfile() - { - return $this->hasOneof(1); - } - - /** - * Table data profile column - * - * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile table_profile = 1; - * @param \Google\Cloud\Dlp\V2\TableDataProfile $var - * @return $this - */ - public function setTableProfile($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableDataProfile::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Column data profile column - * - * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile column_profile = 2; - * @return \Google\Cloud\Dlp\V2\ColumnDataProfile|null - */ - public function getColumnProfile() - { - return $this->readOneof(2); - } - - public function hasColumnProfile() - { - return $this->hasOneof(2); - } - - /** - * Column data profile column - * - * Generated from protobuf field .google.privacy.dlp.v2.ColumnDataProfile column_profile = 2; - * @param \Google\Cloud\Dlp\V2\ColumnDataProfile $var - * @return $this - */ - public function setColumnProfile($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ColumnDataProfile::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getDataProfile() - { - return $this->whichOneof("data_profile"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileConfigSnapshot.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileConfigSnapshot.php deleted file mode 100644 index 77e66e42ffe8..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileConfigSnapshot.php +++ /dev/null @@ -1,270 +0,0 @@ -google.privacy.dlp.v2.DataProfileConfigSnapshot - */ -class DataProfileConfigSnapshot extends \Google\Protobuf\Internal\Message -{ - /** - * A copy of the inspection config used to generate this profile. This - * is a copy of the inspect_template specified in `DataProfileJobConfig`. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; - */ - protected $inspect_config = null; - /** - * A copy of the configuration used to generate this profile. This is - * deprecated, and the DiscoveryConfig field is preferred moving forward. - * DataProfileJobConfig will still be written here for Discovery in BigQuery - * for backwards compatibility, but will not be updated with new fields, while - * DiscoveryConfig will. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileJobConfig data_profile_job = 3 [deprecated = true]; - * @deprecated - */ - protected $data_profile_job = null; - /** - * A copy of the configuration used to generate this profile. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 4; - */ - protected $discovery_config = null; - /** - * Name of the inspection template used to generate this profile - * - * Generated from protobuf field string inspect_template_name = 5; - */ - protected $inspect_template_name = ''; - /** - * Timestamp when the template was modified - * - * Generated from protobuf field .google.protobuf.Timestamp inspect_template_modified_time = 6; - */ - protected $inspect_template_modified_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config - * A copy of the inspection config used to generate this profile. This - * is a copy of the inspect_template specified in `DataProfileJobConfig`. - * @type \Google\Cloud\Dlp\V2\DataProfileJobConfig $data_profile_job - * A copy of the configuration used to generate this profile. This is - * deprecated, and the DiscoveryConfig field is preferred moving forward. - * DataProfileJobConfig will still be written here for Discovery in BigQuery - * for backwards compatibility, but will not be updated with new fields, while - * DiscoveryConfig will. - * @type \Google\Cloud\Dlp\V2\DiscoveryConfig $discovery_config - * A copy of the configuration used to generate this profile. - * @type string $inspect_template_name - * Name of the inspection template used to generate this profile - * @type \Google\Protobuf\Timestamp $inspect_template_modified_time - * Timestamp when the template was modified - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A copy of the inspection config used to generate this profile. This - * is a copy of the inspect_template specified in `DataProfileJobConfig`. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; - * @return \Google\Cloud\Dlp\V2\InspectConfig|null - */ - public function getInspectConfig() - { - return $this->inspect_config; - } - - public function hasInspectConfig() - { - return isset($this->inspect_config); - } - - public function clearInspectConfig() - { - unset($this->inspect_config); - } - - /** - * A copy of the inspection config used to generate this profile. This - * is a copy of the inspect_template specified in `DataProfileJobConfig`. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; - * @param \Google\Cloud\Dlp\V2\InspectConfig $var - * @return $this - */ - public function setInspectConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); - $this->inspect_config = $var; - - return $this; - } - - /** - * A copy of the configuration used to generate this profile. This is - * deprecated, and the DiscoveryConfig field is preferred moving forward. - * DataProfileJobConfig will still be written here for Discovery in BigQuery - * for backwards compatibility, but will not be updated with new fields, while - * DiscoveryConfig will. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileJobConfig data_profile_job = 3 [deprecated = true]; - * @return \Google\Cloud\Dlp\V2\DataProfileJobConfig|null - * @deprecated - */ - public function getDataProfileJob() - { - @trigger_error('data_profile_job is deprecated.', E_USER_DEPRECATED); - return $this->data_profile_job; - } - - public function hasDataProfileJob() - { - @trigger_error('data_profile_job is deprecated.', E_USER_DEPRECATED); - return isset($this->data_profile_job); - } - - public function clearDataProfileJob() - { - @trigger_error('data_profile_job is deprecated.', E_USER_DEPRECATED); - unset($this->data_profile_job); - } - - /** - * A copy of the configuration used to generate this profile. This is - * deprecated, and the DiscoveryConfig field is preferred moving forward. - * DataProfileJobConfig will still be written here for Discovery in BigQuery - * for backwards compatibility, but will not be updated with new fields, while - * DiscoveryConfig will. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileJobConfig data_profile_job = 3 [deprecated = true]; - * @param \Google\Cloud\Dlp\V2\DataProfileJobConfig $var - * @return $this - * @deprecated - */ - public function setDataProfileJob($var) - { - @trigger_error('data_profile_job is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfileJobConfig::class); - $this->data_profile_job = $var; - - return $this; - } - - /** - * A copy of the configuration used to generate this profile. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 4; - * @return \Google\Cloud\Dlp\V2\DiscoveryConfig|null - */ - public function getDiscoveryConfig() - { - return $this->discovery_config; - } - - public function hasDiscoveryConfig() - { - return isset($this->discovery_config); - } - - public function clearDiscoveryConfig() - { - unset($this->discovery_config); - } - - /** - * A copy of the configuration used to generate this profile. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 4; - * @param \Google\Cloud\Dlp\V2\DiscoveryConfig $var - * @return $this - */ - public function setDiscoveryConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryConfig::class); - $this->discovery_config = $var; - - return $this; - } - - /** - * Name of the inspection template used to generate this profile - * - * Generated from protobuf field string inspect_template_name = 5; - * @return string - */ - public function getInspectTemplateName() - { - return $this->inspect_template_name; - } - - /** - * Name of the inspection template used to generate this profile - * - * Generated from protobuf field string inspect_template_name = 5; - * @param string $var - * @return $this - */ - public function setInspectTemplateName($var) - { - GPBUtil::checkString($var, True); - $this->inspect_template_name = $var; - - return $this; - } - - /** - * Timestamp when the template was modified - * - * Generated from protobuf field .google.protobuf.Timestamp inspect_template_modified_time = 6; - * @return \Google\Protobuf\Timestamp|null - */ - public function getInspectTemplateModifiedTime() - { - return $this->inspect_template_modified_time; - } - - public function hasInspectTemplateModifiedTime() - { - return isset($this->inspect_template_modified_time); - } - - public function clearInspectTemplateModifiedTime() - { - unset($this->inspect_template_modified_time); - } - - /** - * Timestamp when the template was modified - * - * Generated from protobuf field .google.protobuf.Timestamp inspect_template_modified_time = 6; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setInspectTemplateModifiedTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->inspect_template_modified_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileJobConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileJobConfig.php deleted file mode 100644 index d65e517fa702..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileJobConfig.php +++ /dev/null @@ -1,240 +0,0 @@ -google.privacy.dlp.v2.DataProfileJobConfig - */ -class DataProfileJobConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The data to scan. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileLocation location = 1; - */ - protected $location = null; - /** - * The project that will run the scan. The DLP service - * account that exists within this project must have access to all resources - * that are profiled, and the Cloud DLP API must be enabled. - * - * Generated from protobuf field string project_id = 5; - */ - protected $project_id = ''; - /** - * Detection logic for profile generation. - * Not all template features are used by profiles. FindingLimits, - * include_quote and exclude_info_types have no impact on - * data profiling. - * Multiple templates may be provided if there is data in multiple regions. - * At most one template must be specified per-region (including "global"). - * Each region is scanned using the applicable template. If no region-specific - * template is specified, but a "global" template is specified, it will be - * copied to that region and used instead. If no global or region-specific - * template is provided for a region with data, that region's data will not be - * scanned. - * For more information, see - * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. - * - * Generated from protobuf field repeated string inspect_templates = 7; - */ - private $inspect_templates; - /** - * Actions to execute at the completion of the job. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfileAction data_profile_actions = 6; - */ - private $data_profile_actions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DataProfileLocation $location - * The data to scan. - * @type string $project_id - * The project that will run the scan. The DLP service - * account that exists within this project must have access to all resources - * that are profiled, and the Cloud DLP API must be enabled. - * @type array|\Google\Protobuf\Internal\RepeatedField $inspect_templates - * Detection logic for profile generation. - * Not all template features are used by profiles. FindingLimits, - * include_quote and exclude_info_types have no impact on - * data profiling. - * Multiple templates may be provided if there is data in multiple regions. - * At most one template must be specified per-region (including "global"). - * Each region is scanned using the applicable template. If no region-specific - * template is specified, but a "global" template is specified, it will be - * copied to that region and used instead. If no global or region-specific - * template is provided for a region with data, that region's data will not be - * scanned. - * For more information, see - * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. - * @type array<\Google\Cloud\Dlp\V2\DataProfileAction>|\Google\Protobuf\Internal\RepeatedField $data_profile_actions - * Actions to execute at the completion of the job. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The data to scan. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileLocation location = 1; - * @return \Google\Cloud\Dlp\V2\DataProfileLocation|null - */ - public function getLocation() - { - return $this->location; - } - - public function hasLocation() - { - return isset($this->location); - } - - public function clearLocation() - { - unset($this->location); - } - - /** - * The data to scan. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileLocation location = 1; - * @param \Google\Cloud\Dlp\V2\DataProfileLocation $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfileLocation::class); - $this->location = $var; - - return $this; - } - - /** - * The project that will run the scan. The DLP service - * account that exists within this project must have access to all resources - * that are profiled, and the Cloud DLP API must be enabled. - * - * Generated from protobuf field string project_id = 5; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * The project that will run the scan. The DLP service - * account that exists within this project must have access to all resources - * that are profiled, and the Cloud DLP API must be enabled. - * - * Generated from protobuf field string project_id = 5; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Detection logic for profile generation. - * Not all template features are used by profiles. FindingLimits, - * include_quote and exclude_info_types have no impact on - * data profiling. - * Multiple templates may be provided if there is data in multiple regions. - * At most one template must be specified per-region (including "global"). - * Each region is scanned using the applicable template. If no region-specific - * template is specified, but a "global" template is specified, it will be - * copied to that region and used instead. If no global or region-specific - * template is provided for a region with data, that region's data will not be - * scanned. - * For more information, see - * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. - * - * Generated from protobuf field repeated string inspect_templates = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInspectTemplates() - { - return $this->inspect_templates; - } - - /** - * Detection logic for profile generation. - * Not all template features are used by profiles. FindingLimits, - * include_quote and exclude_info_types have no impact on - * data profiling. - * Multiple templates may be provided if there is data in multiple regions. - * At most one template must be specified per-region (including "global"). - * Each region is scanned using the applicable template. If no region-specific - * template is specified, but a "global" template is specified, it will be - * copied to that region and used instead. If no global or region-specific - * template is provided for a region with data, that region's data will not be - * scanned. - * For more information, see - * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. - * - * Generated from protobuf field repeated string inspect_templates = 7; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInspectTemplates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->inspect_templates = $arr; - - return $this; - } - - /** - * Actions to execute at the completion of the job. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfileAction data_profile_actions = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDataProfileActions() - { - return $this->data_profile_actions; - } - - /** - * Actions to execute at the completion of the job. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfileAction data_profile_actions = 6; - * @param array<\Google\Cloud\Dlp\V2\DataProfileAction>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDataProfileActions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DataProfileAction::class); - $this->data_profile_actions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileLocation.php deleted file mode 100644 index 926bce69a79e..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileLocation.php +++ /dev/null @@ -1,108 +0,0 @@ -google.privacy.dlp.v2.DataProfileLocation - */ -class DataProfileLocation extends \Google\Protobuf\Internal\Message -{ - protected $location; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $organization_id - * The ID of an organization to scan. - * @type int|string $folder_id - * The ID of the Folder within an organization to scan. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The ID of an organization to scan. - * - * Generated from protobuf field int64 organization_id = 1; - * @return int|string - */ - public function getOrganizationId() - { - return $this->readOneof(1); - } - - public function hasOrganizationId() - { - return $this->hasOneof(1); - } - - /** - * The ID of an organization to scan. - * - * Generated from protobuf field int64 organization_id = 1; - * @param int|string $var - * @return $this - */ - public function setOrganizationId($var) - { - GPBUtil::checkInt64($var); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The ID of the Folder within an organization to scan. - * - * Generated from protobuf field int64 folder_id = 2; - * @return int|string - */ - public function getFolderId() - { - return $this->readOneof(2); - } - - public function hasFolderId() - { - return $this->hasOneof(2); - } - - /** - * The ID of the Folder within an organization to scan. - * - * Generated from protobuf field int64 folder_id = 2; - * @param int|string $var - * @return $this - */ - public function setFolderId($var) - { - GPBUtil::checkInt64($var); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getLocation() - { - return $this->whichOneof("location"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition.php deleted file mode 100644 index c5858b4bb75d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition.php +++ /dev/null @@ -1,77 +0,0 @@ -google.privacy.dlp.v2.DataProfilePubSubCondition - */ -class DataProfilePubSubCondition extends \Google\Protobuf\Internal\Message -{ - /** - * An expression. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions expressions = 1; - */ - protected $expressions = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubExpressions $expressions - * An expression. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * An expression. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions expressions = 1; - * @return \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubExpressions|null - */ - public function getExpressions() - { - return $this->expressions; - } - - public function hasExpressions() - { - return isset($this->expressions); - } - - public function clearExpressions() - { - unset($this->expressions); - } - - /** - * An expression. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions expressions = 1; - * @param \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubExpressions $var - * @return $this - */ - public function setExpressions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubExpressions::class); - $this->expressions = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/ProfileScoreBucket.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/ProfileScoreBucket.php deleted file mode 100644 index 3badf79759e1..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/ProfileScoreBucket.php +++ /dev/null @@ -1,64 +0,0 @@ -google.privacy.dlp.v2.DataProfilePubSubCondition.ProfileScoreBucket - */ -class ProfileScoreBucket -{ - /** - * Unused. - * - * Generated from protobuf enum PROFILE_SCORE_BUCKET_UNSPECIFIED = 0; - */ - const PROFILE_SCORE_BUCKET_UNSPECIFIED = 0; - /** - * High risk/sensitivity detected. - * - * Generated from protobuf enum HIGH = 1; - */ - const HIGH = 1; - /** - * Medium or high risk/sensitivity detected. - * - * Generated from protobuf enum MEDIUM_OR_HIGH = 2; - */ - const MEDIUM_OR_HIGH = 2; - - private static $valueToName = [ - self::PROFILE_SCORE_BUCKET_UNSPECIFIED => 'PROFILE_SCORE_BUCKET_UNSPECIFIED', - self::HIGH => 'HIGH', - self::MEDIUM_OR_HIGH => 'MEDIUM_OR_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(ProfileScoreBucket::class, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition_ProfileScoreBucket::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubCondition.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubCondition.php deleted file mode 100644 index 5cff0909ffa3..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubCondition.php +++ /dev/null @@ -1,111 +0,0 @@ -google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubCondition - */ -class PubSubCondition extends \Google\Protobuf\Internal\Message -{ - protected $value; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $minimum_risk_score - * The minimum data risk score that triggers the condition. - * @type int $minimum_sensitivity_score - * The minimum sensitivity level that triggers the condition. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The minimum data risk score that triggers the condition. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.ProfileScoreBucket minimum_risk_score = 1; - * @return int - */ - public function getMinimumRiskScore() - { - return $this->readOneof(1); - } - - public function hasMinimumRiskScore() - { - return $this->hasOneof(1); - } - - /** - * The minimum data risk score that triggers the condition. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.ProfileScoreBucket minimum_risk_score = 1; - * @param int $var - * @return $this - */ - public function setMinimumRiskScore($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\ProfileScoreBucket::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The minimum sensitivity level that triggers the condition. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.ProfileScoreBucket minimum_sensitivity_score = 2; - * @return int - */ - public function getMinimumSensitivityScore() - { - return $this->readOneof(2); - } - - public function hasMinimumSensitivityScore() - { - return $this->hasOneof(2); - } - - /** - * The minimum sensitivity level that triggers the condition. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.ProfileScoreBucket minimum_sensitivity_score = 2; - * @param int $var - * @return $this - */ - public function setMinimumSensitivityScore($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\ProfileScoreBucket::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getValue() - { - return $this->whichOneof("value"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PubSubCondition::class, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition_PubSubCondition::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions.php deleted file mode 100644 index 5db8a91afd83..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions.php +++ /dev/null @@ -1,104 +0,0 @@ -google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions - */ -class PubSubExpressions extends \Google\Protobuf\Internal\Message -{ - /** - * The operator to apply to the collection of conditions. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions.PubSubLogicalOperator logical_operator = 1; - */ - protected $logical_operator = 0; - /** - * Conditions to apply to the expression. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubCondition conditions = 2; - */ - private $conditions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $logical_operator - * The operator to apply to the collection of conditions. - * @type array<\Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubCondition>|\Google\Protobuf\Internal\RepeatedField $conditions - * Conditions to apply to the expression. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The operator to apply to the collection of conditions. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions.PubSubLogicalOperator logical_operator = 1; - * @return int - */ - public function getLogicalOperator() - { - return $this->logical_operator; - } - - /** - * The operator to apply to the collection of conditions. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions.PubSubLogicalOperator logical_operator = 1; - * @param int $var - * @return $this - */ - public function setLogicalOperator($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubExpressions\PubSubLogicalOperator::class); - $this->logical_operator = $var; - - return $this; - } - - /** - * Conditions to apply to the expression. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubCondition conditions = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getConditions() - { - return $this->conditions; - } - - /** - * Conditions to apply to the expression. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubCondition conditions = 2; - * @param array<\Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubCondition>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setConditions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition\PubSubCondition::class); - $this->conditions = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PubSubExpressions::class, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition_PubSubExpressions::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions/PubSubLogicalOperator.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions/PubSubLogicalOperator.php deleted file mode 100644 index 47586059b5bf..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubCondition/PubSubExpressions/PubSubLogicalOperator.php +++ /dev/null @@ -1,68 +0,0 @@ -google.privacy.dlp.v2.DataProfilePubSubCondition.PubSubExpressions.PubSubLogicalOperator - */ -class PubSubLogicalOperator -{ - /** - * Unused. - * - * Generated from protobuf enum LOGICAL_OPERATOR_UNSPECIFIED = 0; - */ - const LOGICAL_OPERATOR_UNSPECIFIED = 0; - /** - * Conditional OR. - * - * Generated from protobuf enum OR = 1; - */ - const PBOR = 1; - /** - * Conditional AND. - * - * Generated from protobuf enum AND = 2; - */ - const PBAND = 2; - - private static $valueToName = [ - self::LOGICAL_OPERATOR_UNSPECIFIED => 'LOGICAL_OPERATOR_UNSPECIFIED', - self::PBOR => 'OR', - self::PBAND => 'AND', - ]; - - 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)) { - $pbconst = __CLASS__. '::PB' . strtoupper($name); - if (!defined($pbconst)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($pbconst); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PubSubLogicalOperator::class, \Google\Cloud\Dlp\V2\DataProfilePubSubCondition_PubSubExpressions_PubSubLogicalOperator::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubMessage.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubMessage.php deleted file mode 100644 index 1117f6b2b513..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfilePubSubMessage.php +++ /dev/null @@ -1,121 +0,0 @@ -google.privacy.dlp.v2.DataProfilePubSubMessage - */ -class DataProfilePubSubMessage extends \Google\Protobuf\Internal\Message -{ - /** - * If `DetailLevel` is `TABLE_PROFILE` this will be fully populated. - * Otherwise, if `DetailLevel` is `RESOURCE_NAME`, then only `name` and - * `full_resource` will be populated. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile profile = 1; - */ - protected $profile = null; - /** - * The event that caused the Pub/Sub message to be sent. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.EventType event = 2; - */ - protected $event = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\TableDataProfile $profile - * If `DetailLevel` is `TABLE_PROFILE` this will be fully populated. - * Otherwise, if `DetailLevel` is `RESOURCE_NAME`, then only `name` and - * `full_resource` will be populated. - * @type int $event - * The event that caused the Pub/Sub message to be sent. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * If `DetailLevel` is `TABLE_PROFILE` this will be fully populated. - * Otherwise, if `DetailLevel` is `RESOURCE_NAME`, then only `name` and - * `full_resource` will be populated. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile profile = 1; - * @return \Google\Cloud\Dlp\V2\TableDataProfile|null - */ - public function getProfile() - { - return $this->profile; - } - - public function hasProfile() - { - return isset($this->profile); - } - - public function clearProfile() - { - unset($this->profile); - } - - /** - * If `DetailLevel` is `TABLE_PROFILE` this will be fully populated. - * Otherwise, if `DetailLevel` is `RESOURCE_NAME`, then only `name` and - * `full_resource` will be populated. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile profile = 1; - * @param \Google\Cloud\Dlp\V2\TableDataProfile $var - * @return $this - */ - public function setProfile($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableDataProfile::class); - $this->profile = $var; - - return $this; - } - - /** - * The event that caused the Pub/Sub message to be sent. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.EventType event = 2; - * @return int - */ - public function getEvent() - { - return $this->event; - } - - /** - * The event that caused the Pub/Sub message to be sent. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileAction.EventType event = 2; - * @param int $var - * @return $this - */ - public function setEvent($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileAction\EventType::class); - $this->event = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileUpdateFrequency.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileUpdateFrequency.php deleted file mode 100644 index 4b4fc355a7b8..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataProfileUpdateFrequency.php +++ /dev/null @@ -1,69 +0,0 @@ -google.privacy.dlp.v2.DataProfileUpdateFrequency - */ -class DataProfileUpdateFrequency -{ - /** - * Unspecified. - * - * Generated from protobuf enum UPDATE_FREQUENCY_UNSPECIFIED = 0; - */ - const UPDATE_FREQUENCY_UNSPECIFIED = 0; - /** - * After the data profile is created, it will never be updated. - * - * Generated from protobuf enum UPDATE_FREQUENCY_NEVER = 1; - */ - const UPDATE_FREQUENCY_NEVER = 1; - /** - * The data profile can be updated up to once every 24 hours. - * - * Generated from protobuf enum UPDATE_FREQUENCY_DAILY = 2; - */ - const UPDATE_FREQUENCY_DAILY = 2; - /** - * The data profile can be updated up to once every 30 days. Default. - * - * Generated from protobuf enum UPDATE_FREQUENCY_MONTHLY = 4; - */ - const UPDATE_FREQUENCY_MONTHLY = 4; - - private static $valueToName = [ - self::UPDATE_FREQUENCY_UNSPECIFIED => 'UPDATE_FREQUENCY_UNSPECIFIED', - self::UPDATE_FREQUENCY_NEVER => 'UPDATE_FREQUENCY_NEVER', - self::UPDATE_FREQUENCY_DAILY => 'UPDATE_FREQUENCY_DAILY', - self::UPDATE_FREQUENCY_MONTHLY => 'UPDATE_FREQUENCY_MONTHLY', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel.php deleted file mode 100644 index 5736ca6f76a3..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel.php +++ /dev/null @@ -1,68 +0,0 @@ -google.privacy.dlp.v2.DataRiskLevel - */ -class DataRiskLevel extends \Google\Protobuf\Internal\Message -{ - /** - * The score applied to the resource. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel.DataRiskLevelScore score = 1; - */ - protected $score = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $score - * The score applied to the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The score applied to the resource. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel.DataRiskLevelScore score = 1; - * @return int - */ - public function getScore() - { - return $this->score; - } - - /** - * The score applied to the resource. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel.DataRiskLevelScore score = 1; - * @param int $var - * @return $this - */ - public function setScore($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataRiskLevel\DataRiskLevelScore::class); - $this->score = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel/DataRiskLevelScore.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel/DataRiskLevelScore.php deleted file mode 100644 index e5b2081ddb95..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataRiskLevel/DataRiskLevelScore.php +++ /dev/null @@ -1,77 +0,0 @@ -google.privacy.dlp.v2.DataRiskLevel.DataRiskLevelScore - */ -class DataRiskLevelScore -{ - /** - * Unused. - * - * Generated from protobuf enum RISK_SCORE_UNSPECIFIED = 0; - */ - const RISK_SCORE_UNSPECIFIED = 0; - /** - * Low risk - Lower indication of sensitive data that appears to have - * additional access restrictions in place or no indication of sensitive - * data found. - * - * Generated from protobuf enum RISK_LOW = 10; - */ - const RISK_LOW = 10; - /** - * Medium risk - Sensitive data may be present but additional access or fine - * grain access restrictions appear to be present. Consider limiting - * access even further or transform data to mask. - * - * Generated from protobuf enum RISK_MODERATE = 20; - */ - const RISK_MODERATE = 20; - /** - * High risk – SPII may be present. Access controls may include public - * ACLs. Exfiltration of data may lead to user data loss. Re-identification - * of users may be possible. Consider limiting usage and or removing SPII. - * - * Generated from protobuf enum RISK_HIGH = 30; - */ - const RISK_HIGH = 30; - - private static $valueToName = [ - self::RISK_SCORE_UNSPECIFIED => 'RISK_SCORE_UNSPECIFIED', - self::RISK_LOW => 'RISK_LOW', - self::RISK_MODERATE => 'RISK_MODERATE', - self::RISK_HIGH => 'RISK_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(DataRiskLevelScore::class, \Google\Cloud\Dlp\V2\DataRiskLevel_DataRiskLevelScore::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataSourceType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataSourceType.php deleted file mode 100644 index 6b4531da05df..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DataSourceType.php +++ /dev/null @@ -1,71 +0,0 @@ -google.privacy.dlp.v2.DataSourceType - */ -class DataSourceType extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. An identifying string to the type of resource being profiled. - * Current values: google/bigquery/table, google/project - * - * Generated from protobuf field string data_source = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $data_source = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $data_source - * Output only. An identifying string to the type of resource being profiled. - * Current values: google/bigquery/table, google/project - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Output only. An identifying string to the type of resource being profiled. - * Current values: google/bigquery/table, google/project - * - * Generated from protobuf field string data_source = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getDataSource() - { - return $this->data_source; - } - - /** - * Output only. An identifying string to the type of resource being profiled. - * Current values: google/bigquery/table, google/project - * - * Generated from protobuf field string data_source = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setDataSource($var) - { - GPBUtil::checkString($var, True); - $this->data_source = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceCollection.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceCollection.php deleted file mode 100644 index 61a1ce7130dd..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceCollection.php +++ /dev/null @@ -1,76 +0,0 @@ -google.privacy.dlp.v2.DatabaseResourceCollection - */ -class DatabaseResourceCollection extends \Google\Protobuf\Internal\Message -{ - protected $pattern; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DatabaseResourceRegexes $include_regexes - * A collection of regular expressions to match a database resource against. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A collection of regular expressions to match a database resource against. - * - * Generated from protobuf field .google.privacy.dlp.v2.DatabaseResourceRegexes include_regexes = 1; - * @return \Google\Cloud\Dlp\V2\DatabaseResourceRegexes|null - */ - public function getIncludeRegexes() - { - return $this->readOneof(1); - } - - public function hasIncludeRegexes() - { - return $this->hasOneof(1); - } - - /** - * A collection of regular expressions to match a database resource against. - * - * Generated from protobuf field .google.privacy.dlp.v2.DatabaseResourceRegexes include_regexes = 1; - * @param \Google\Cloud\Dlp\V2\DatabaseResourceRegexes $var - * @return $this - */ - public function setIncludeRegexes($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DatabaseResourceRegexes::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getPattern() - { - return $this->whichOneof("pattern"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceReference.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceReference.php deleted file mode 100644 index e04211fa322d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceReference.php +++ /dev/null @@ -1,181 +0,0 @@ -google.privacy.dlp.v2.DatabaseResourceReference - */ -class DatabaseResourceReference extends \Google\Protobuf\Internal\Message -{ - /** - * Required. If within a project-level config, then this must match the - * config's project ID. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - /** - * Required. The instance where this resource is located. For example: Cloud - * SQL instance ID. - * - * Generated from protobuf field string instance = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $instance = ''; - /** - * Required. Name of a database within the instance. - * - * Generated from protobuf field string database = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $database = ''; - /** - * Required. Name of a database resource, for example, a table within the - * database. - * - * Generated from protobuf field string database_resource = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $database_resource = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $project_id - * Required. If within a project-level config, then this must match the - * config's project ID. - * @type string $instance - * Required. The instance where this resource is located. For example: Cloud - * SQL instance ID. - * @type string $database - * Required. Name of a database within the instance. - * @type string $database_resource - * Required. Name of a database resource, for example, a table within the - * database. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. If within a project-level config, then this must match the - * config's project ID. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. If within a project-level config, then this must match the - * config's project ID. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Required. The instance where this resource is located. For example: Cloud - * SQL instance ID. - * - * Generated from protobuf field string instance = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getInstance() - { - return $this->instance; - } - - /** - * Required. The instance where this resource is located. For example: Cloud - * SQL instance ID. - * - * Generated from protobuf field string instance = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setInstance($var) - { - GPBUtil::checkString($var, True); - $this->instance = $var; - - return $this; - } - - /** - * Required. Name of a database within the instance. - * - * Generated from protobuf field string database = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDatabase() - { - return $this->database; - } - - /** - * Required. Name of a database within the instance. - * - * Generated from protobuf field string database = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDatabase($var) - { - GPBUtil::checkString($var, True); - $this->database = $var; - - return $this; - } - - /** - * Required. Name of a database resource, for example, a table within the - * database. - * - * Generated from protobuf field string database_resource = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDatabaseResource() - { - return $this->database_resource; - } - - /** - * Required. Name of a database resource, for example, a table within the - * database. - * - * Generated from protobuf field string database_resource = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDatabaseResource($var) - { - GPBUtil::checkString($var, True); - $this->database_resource = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegex.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegex.php deleted file mode 100644 index 87663fec9fd7..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegex.php +++ /dev/null @@ -1,188 +0,0 @@ -google.privacy.dlp.v2.DatabaseResourceRegex - */ -class DatabaseResourceRegex extends \Google\Protobuf\Internal\Message -{ - /** - * For organizations, if unset, will match all projects. Has no effect - * for configurations created within a project. - * - * Generated from protobuf field string project_id_regex = 1; - */ - protected $project_id_regex = ''; - /** - * Regex to test the instance name against. If empty, all instances match. - * - * Generated from protobuf field string instance_regex = 2; - */ - protected $instance_regex = ''; - /** - * Regex to test the database name against. If empty, all databases match. - * - * Generated from protobuf field string database_regex = 3; - */ - protected $database_regex = ''; - /** - * Regex to test the database resource's name against. An example of a - * database resource name is a table's name. Other database resource names - * like view names could be included in the future. If empty, all database - * resources match. - * - * Generated from protobuf field string database_resource_name_regex = 4; - */ - protected $database_resource_name_regex = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $project_id_regex - * For organizations, if unset, will match all projects. Has no effect - * for configurations created within a project. - * @type string $instance_regex - * Regex to test the instance name against. If empty, all instances match. - * @type string $database_regex - * Regex to test the database name against. If empty, all databases match. - * @type string $database_resource_name_regex - * Regex to test the database resource's name against. An example of a - * database resource name is a table's name. Other database resource names - * like view names could be included in the future. If empty, all database - * resources match. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * For organizations, if unset, will match all projects. Has no effect - * for configurations created within a project. - * - * Generated from protobuf field string project_id_regex = 1; - * @return string - */ - public function getProjectIdRegex() - { - return $this->project_id_regex; - } - - /** - * For organizations, if unset, will match all projects. Has no effect - * for configurations created within a project. - * - * Generated from protobuf field string project_id_regex = 1; - * @param string $var - * @return $this - */ - public function setProjectIdRegex($var) - { - GPBUtil::checkString($var, True); - $this->project_id_regex = $var; - - return $this; - } - - /** - * Regex to test the instance name against. If empty, all instances match. - * - * Generated from protobuf field string instance_regex = 2; - * @return string - */ - public function getInstanceRegex() - { - return $this->instance_regex; - } - - /** - * Regex to test the instance name against. If empty, all instances match. - * - * Generated from protobuf field string instance_regex = 2; - * @param string $var - * @return $this - */ - public function setInstanceRegex($var) - { - GPBUtil::checkString($var, True); - $this->instance_regex = $var; - - return $this; - } - - /** - * Regex to test the database name against. If empty, all databases match. - * - * Generated from protobuf field string database_regex = 3; - * @return string - */ - public function getDatabaseRegex() - { - return $this->database_regex; - } - - /** - * Regex to test the database name against. If empty, all databases match. - * - * Generated from protobuf field string database_regex = 3; - * @param string $var - * @return $this - */ - public function setDatabaseRegex($var) - { - GPBUtil::checkString($var, True); - $this->database_regex = $var; - - return $this; - } - - /** - * Regex to test the database resource's name against. An example of a - * database resource name is a table's name. Other database resource names - * like view names could be included in the future. If empty, all database - * resources match. - * - * Generated from protobuf field string database_resource_name_regex = 4; - * @return string - */ - public function getDatabaseResourceNameRegex() - { - return $this->database_resource_name_regex; - } - - /** - * Regex to test the database resource's name against. An example of a - * database resource name is a table's name. Other database resource names - * like view names could be included in the future. If empty, all database - * resources match. - * - * Generated from protobuf field string database_resource_name_regex = 4; - * @param string $var - * @return $this - */ - public function setDatabaseResourceNameRegex($var) - { - GPBUtil::checkString($var, True); - $this->database_resource_name_regex = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegexes.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegexes.php deleted file mode 100644 index c9a5d6122541..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatabaseResourceRegexes.php +++ /dev/null @@ -1,80 +0,0 @@ -google.privacy.dlp.v2.DatabaseResourceRegexes - */ -class DatabaseResourceRegexes extends \Google\Protobuf\Internal\Message -{ - /** - * A group of regular expression patterns to match against one or more - * database resources. - * Maximum of 100 entries. The sum of all regular expression's length can't - * exceed 10 KiB. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DatabaseResourceRegex patterns = 1; - */ - private $patterns; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\DatabaseResourceRegex>|\Google\Protobuf\Internal\RepeatedField $patterns - * A group of regular expression patterns to match against one or more - * database resources. - * Maximum of 100 entries. The sum of all regular expression's length can't - * exceed 10 KiB. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A group of regular expression patterns to match against one or more - * database resources. - * Maximum of 100 entries. The sum of all regular expression's length can't - * exceed 10 KiB. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DatabaseResourceRegex patterns = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPatterns() - { - return $this->patterns; - } - - /** - * A group of regular expression patterns to match against one or more - * database resources. - * Maximum of 100 entries. The sum of all regular expression's length can't - * exceed 10 KiB. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DatabaseResourceRegex patterns = 1; - * @param array<\Google\Cloud\Dlp\V2\DatabaseResourceRegex>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPatterns($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DatabaseResourceRegex::class); - $this->patterns = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreKey.php deleted file mode 100644 index a4eec6118bf7..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreKey.php +++ /dev/null @@ -1,77 +0,0 @@ -google.privacy.dlp.v2.DatastoreKey - */ -class DatastoreKey extends \Google\Protobuf\Internal\Message -{ - /** - * Datastore entity key. - * - * Generated from protobuf field .google.privacy.dlp.v2.Key entity_key = 1; - */ - protected $entity_key = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\Key $entity_key - * Datastore entity key. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Datastore entity key. - * - * Generated from protobuf field .google.privacy.dlp.v2.Key entity_key = 1; - * @return \Google\Cloud\Dlp\V2\Key|null - */ - public function getEntityKey() - { - return $this->entity_key; - } - - public function hasEntityKey() - { - return isset($this->entity_key); - } - - public function clearEntityKey() - { - unset($this->entity_key); - } - - /** - * Datastore entity key. - * - * Generated from protobuf field .google.privacy.dlp.v2.Key entity_key = 1; - * @param \Google\Cloud\Dlp\V2\Key $var - * @return $this - */ - public function setEntityKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Key::class); - $this->entity_key = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreOptions.php deleted file mode 100644 index 2bcb48315e54..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DatastoreOptions.php +++ /dev/null @@ -1,125 +0,0 @@ -google.privacy.dlp.v2.DatastoreOptions - */ -class DatastoreOptions extends \Google\Protobuf\Internal\Message -{ - /** - * A partition ID identifies a grouping of entities. The grouping is always - * by project and namespace, however the namespace ID may be empty. - * - * Generated from protobuf field .google.privacy.dlp.v2.PartitionId partition_id = 1; - */ - protected $partition_id = null; - /** - * The kind to process. - * - * Generated from protobuf field .google.privacy.dlp.v2.KindExpression kind = 2; - */ - protected $kind = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\PartitionId $partition_id - * A partition ID identifies a grouping of entities. The grouping is always - * by project and namespace, however the namespace ID may be empty. - * @type \Google\Cloud\Dlp\V2\KindExpression $kind - * The kind to process. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * A partition ID identifies a grouping of entities. The grouping is always - * by project and namespace, however the namespace ID may be empty. - * - * Generated from protobuf field .google.privacy.dlp.v2.PartitionId partition_id = 1; - * @return \Google\Cloud\Dlp\V2\PartitionId|null - */ - public function getPartitionId() - { - return $this->partition_id; - } - - public function hasPartitionId() - { - return isset($this->partition_id); - } - - public function clearPartitionId() - { - unset($this->partition_id); - } - - /** - * A partition ID identifies a grouping of entities. The grouping is always - * by project and namespace, however the namespace ID may be empty. - * - * Generated from protobuf field .google.privacy.dlp.v2.PartitionId partition_id = 1; - * @param \Google\Cloud\Dlp\V2\PartitionId $var - * @return $this - */ - public function setPartitionId($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PartitionId::class); - $this->partition_id = $var; - - return $this; - } - - /** - * The kind to process. - * - * Generated from protobuf field .google.privacy.dlp.v2.KindExpression kind = 2; - * @return \Google\Cloud\Dlp\V2\KindExpression|null - */ - public function getKind() - { - return $this->kind; - } - - public function hasKind() - { - return isset($this->kind); - } - - public function clearKind() - { - unset($this->kind); - } - - /** - * The kind to process. - * - * Generated from protobuf field .google.privacy.dlp.v2.KindExpression kind = 2; - * @param \Google\Cloud\Dlp\V2\KindExpression $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\KindExpression::class); - $this->kind = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateShiftConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateShiftConfig.php deleted file mode 100644 index 710be7fdb1a7..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateShiftConfig.php +++ /dev/null @@ -1,220 +0,0 @@ -google.privacy.dlp.v2.DateShiftConfig - */ -class DateShiftConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Range of shift in days. Actual shift will be selected at random - * within this range (inclusive ends). Negative means shift to earlier in - * time. Must not be more than 365250 days (1000 years) each direction. - * For example, 3 means shift date to at most 3 days into the future. - * - * Generated from protobuf field int32 upper_bound_days = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $upper_bound_days = 0; - /** - * Required. For example, -5 means shift date to at most 5 days back in the - * past. - * - * Generated from protobuf field int32 lower_bound_days = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $lower_bound_days = 0; - /** - * Points to the field that contains the context, for example, an entity id. - * If set, must also set cryptoKey. If set, shift will be consistent for the - * given context. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 3; - */ - protected $context = null; - protected $method; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $upper_bound_days - * Required. Range of shift in days. Actual shift will be selected at random - * within this range (inclusive ends). Negative means shift to earlier in - * time. Must not be more than 365250 days (1000 years) each direction. - * For example, 3 means shift date to at most 3 days into the future. - * @type int $lower_bound_days - * Required. For example, -5 means shift date to at most 5 days back in the - * past. - * @type \Google\Cloud\Dlp\V2\FieldId $context - * Points to the field that contains the context, for example, an entity id. - * If set, must also set cryptoKey. If set, shift will be consistent for the - * given context. - * @type \Google\Cloud\Dlp\V2\CryptoKey $crypto_key - * Causes the shift to be computed based on this key and the context. This - * results in the same shift for the same context and crypto_key. If - * set, must also set context. Can only be applied to table items. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Range of shift in days. Actual shift will be selected at random - * within this range (inclusive ends). Negative means shift to earlier in - * time. Must not be more than 365250 days (1000 years) each direction. - * For example, 3 means shift date to at most 3 days into the future. - * - * Generated from protobuf field int32 upper_bound_days = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getUpperBoundDays() - { - return $this->upper_bound_days; - } - - /** - * Required. Range of shift in days. Actual shift will be selected at random - * within this range (inclusive ends). Negative means shift to earlier in - * time. Must not be more than 365250 days (1000 years) each direction. - * For example, 3 means shift date to at most 3 days into the future. - * - * Generated from protobuf field int32 upper_bound_days = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setUpperBoundDays($var) - { - GPBUtil::checkInt32($var); - $this->upper_bound_days = $var; - - return $this; - } - - /** - * Required. For example, -5 means shift date to at most 5 days back in the - * past. - * - * Generated from protobuf field int32 lower_bound_days = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getLowerBoundDays() - { - return $this->lower_bound_days; - } - - /** - * Required. For example, -5 means shift date to at most 5 days back in the - * past. - * - * Generated from protobuf field int32 lower_bound_days = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setLowerBoundDays($var) - { - GPBUtil::checkInt32($var); - $this->lower_bound_days = $var; - - return $this; - } - - /** - * Points to the field that contains the context, for example, an entity id. - * If set, must also set cryptoKey. If set, shift will be consistent for the - * given context. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 3; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getContext() - { - return $this->context; - } - - public function hasContext() - { - return isset($this->context); - } - - public function clearContext() - { - unset($this->context); - } - - /** - * Points to the field that contains the context, for example, an entity id. - * If set, must also set cryptoKey. If set, shift will be consistent for the - * given context. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId context = 3; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setContext($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->context = $var; - - return $this; - } - - /** - * Causes the shift to be computed based on this key and the context. This - * results in the same shift for the same context and crypto_key. If - * set, must also set context. Can only be applied to table items. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 4; - * @return \Google\Cloud\Dlp\V2\CryptoKey|null - */ - public function getCryptoKey() - { - return $this->readOneof(4); - } - - public function hasCryptoKey() - { - return $this->hasOneof(4); - } - - /** - * Causes the shift to be computed based on this key and the context. This - * results in the same shift for the same context and crypto_key. If - * set, must also set context. Can only be applied to table items. - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoKey crypto_key = 4; - * @param \Google\Cloud\Dlp\V2\CryptoKey $var - * @return $this - */ - public function setCryptoKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoKey::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getMethod() - { - return $this->whichOneof("method"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime.php deleted file mode 100644 index da1a586cf1a2..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime.php +++ /dev/null @@ -1,204 +0,0 @@ -google.privacy.dlp.v2.DateTime - */ -class DateTime extends \Google\Protobuf\Internal\Message -{ - /** - * One or more of the following must be set. - * Must be a valid date or time value. - * - * Generated from protobuf field .google.type.Date date = 1; - */ - protected $date = null; - /** - * Day of week - * - * Generated from protobuf field .google.type.DayOfWeek day_of_week = 2; - */ - protected $day_of_week = 0; - /** - * Time of day - * - * Generated from protobuf field .google.type.TimeOfDay time = 3; - */ - protected $time = null; - /** - * Time zone - * - * Generated from protobuf field .google.privacy.dlp.v2.DateTime.TimeZone time_zone = 4; - */ - protected $time_zone = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Type\Date $date - * One or more of the following must be set. - * Must be a valid date or time value. - * @type int $day_of_week - * Day of week - * @type \Google\Type\TimeOfDay $time - * Time of day - * @type \Google\Cloud\Dlp\V2\DateTime\TimeZone $time_zone - * Time zone - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * One or more of the following must be set. - * Must be a valid date or time value. - * - * Generated from protobuf field .google.type.Date date = 1; - * @return \Google\Type\Date|null - */ - public function getDate() - { - return $this->date; - } - - public function hasDate() - { - return isset($this->date); - } - - public function clearDate() - { - unset($this->date); - } - - /** - * One or more of the following must be set. - * Must be a valid date or time value. - * - * Generated from protobuf field .google.type.Date date = 1; - * @param \Google\Type\Date $var - * @return $this - */ - public function setDate($var) - { - GPBUtil::checkMessage($var, \Google\Type\Date::class); - $this->date = $var; - - return $this; - } - - /** - * Day of week - * - * Generated from protobuf field .google.type.DayOfWeek day_of_week = 2; - * @return int - */ - public function getDayOfWeek() - { - return $this->day_of_week; - } - - /** - * Day of week - * - * Generated from protobuf field .google.type.DayOfWeek day_of_week = 2; - * @param int $var - * @return $this - */ - public function setDayOfWeek($var) - { - GPBUtil::checkEnum($var, \Google\Type\DayOfWeek::class); - $this->day_of_week = $var; - - return $this; - } - - /** - * Time of day - * - * Generated from protobuf field .google.type.TimeOfDay time = 3; - * @return \Google\Type\TimeOfDay|null - */ - public function getTime() - { - return $this->time; - } - - public function hasTime() - { - return isset($this->time); - } - - public function clearTime() - { - unset($this->time); - } - - /** - * Time of day - * - * Generated from protobuf field .google.type.TimeOfDay time = 3; - * @param \Google\Type\TimeOfDay $var - * @return $this - */ - public function setTime($var) - { - GPBUtil::checkMessage($var, \Google\Type\TimeOfDay::class); - $this->time = $var; - - return $this; - } - - /** - * Time zone - * - * Generated from protobuf field .google.privacy.dlp.v2.DateTime.TimeZone time_zone = 4; - * @return \Google\Cloud\Dlp\V2\DateTime\TimeZone|null - */ - public function getTimeZone() - { - return $this->time_zone; - } - - public function hasTimeZone() - { - return isset($this->time_zone); - } - - public function clearTimeZone() - { - unset($this->time_zone); - } - - /** - * Time zone - * - * Generated from protobuf field .google.privacy.dlp.v2.DateTime.TimeZone time_zone = 4; - * @param \Google\Cloud\Dlp\V2\DateTime\TimeZone $var - * @return $this - */ - public function setTimeZone($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DateTime\TimeZone::class); - $this->time_zone = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime/TimeZone.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime/TimeZone.php deleted file mode 100644 index e371a018541a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DateTime/TimeZone.php +++ /dev/null @@ -1,74 +0,0 @@ -google.privacy.dlp.v2.DateTime.TimeZone - */ -class TimeZone extends \Google\Protobuf\Internal\Message -{ - /** - * Set only if the offset can be determined. Positive for time ahead of UTC. - * E.g. For "UTC-9", this value is -540. - * - * Generated from protobuf field int32 offset_minutes = 1; - */ - protected $offset_minutes = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $offset_minutes - * Set only if the offset can be determined. Positive for time ahead of UTC. - * E.g. For "UTC-9", this value is -540. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Set only if the offset can be determined. Positive for time ahead of UTC. - * E.g. For "UTC-9", this value is -540. - * - * Generated from protobuf field int32 offset_minutes = 1; - * @return int - */ - public function getOffsetMinutes() - { - return $this->offset_minutes; - } - - /** - * Set only if the offset can be determined. Positive for time ahead of UTC. - * E.g. For "UTC-9", this value is -540. - * - * Generated from protobuf field int32 offset_minutes = 1; - * @param int $var - * @return $this - */ - public function setOffsetMinutes($var) - { - GPBUtil::checkInt32($var); - $this->offset_minutes = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(TimeZone::class, \Google\Cloud\Dlp\V2\DateTime_TimeZone::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyConfig.php deleted file mode 100644 index 0ffdb2d9697d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyConfig.php +++ /dev/null @@ -1,198 +0,0 @@ -google.privacy.dlp.v2.DeidentifyConfig - */ -class DeidentifyConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Mode for handling transformation errors. If left unspecified, the default - * mode is `TransformationErrorHandling.ThrowError`. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling transformation_error_handling = 3; - */ - protected $transformation_error_handling = null; - protected $transformation; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InfoTypeTransformations $info_type_transformations - * Treat the dataset as free-form text and apply the same free text - * transformation everywhere. - * @type \Google\Cloud\Dlp\V2\RecordTransformations $record_transformations - * Treat the dataset as structured. Transformations can be applied to - * specific locations within structured datasets, such as transforming - * a column within a table. - * @type \Google\Cloud\Dlp\V2\ImageTransformations $image_transformations - * Treat the dataset as an image and redact. - * @type \Google\Cloud\Dlp\V2\TransformationErrorHandling $transformation_error_handling - * Mode for handling transformation errors. If left unspecified, the default - * mode is `TransformationErrorHandling.ThrowError`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Treat the dataset as free-form text and apply the same free text - * transformation everywhere. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeTransformations info_type_transformations = 1; - * @return \Google\Cloud\Dlp\V2\InfoTypeTransformations|null - */ - public function getInfoTypeTransformations() - { - return $this->readOneof(1); - } - - public function hasInfoTypeTransformations() - { - return $this->hasOneof(1); - } - - /** - * Treat the dataset as free-form text and apply the same free text - * transformation everywhere. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeTransformations info_type_transformations = 1; - * @param \Google\Cloud\Dlp\V2\InfoTypeTransformations $var - * @return $this - */ - public function setInfoTypeTransformations($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoTypeTransformations::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Treat the dataset as structured. Transformations can be applied to - * specific locations within structured datasets, such as transforming - * a column within a table. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordTransformations record_transformations = 2; - * @return \Google\Cloud\Dlp\V2\RecordTransformations|null - */ - public function getRecordTransformations() - { - return $this->readOneof(2); - } - - public function hasRecordTransformations() - { - return $this->hasOneof(2); - } - - /** - * Treat the dataset as structured. Transformations can be applied to - * specific locations within structured datasets, such as transforming - * a column within a table. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordTransformations record_transformations = 2; - * @param \Google\Cloud\Dlp\V2\RecordTransformations $var - * @return $this - */ - public function setRecordTransformations($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordTransformations::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Treat the dataset as an image and redact. - * - * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations image_transformations = 4; - * @return \Google\Cloud\Dlp\V2\ImageTransformations|null - */ - public function getImageTransformations() - { - return $this->readOneof(4); - } - - public function hasImageTransformations() - { - return $this->hasOneof(4); - } - - /** - * Treat the dataset as an image and redact. - * - * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations image_transformations = 4; - * @param \Google\Cloud\Dlp\V2\ImageTransformations $var - * @return $this - */ - public function setImageTransformations($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ImageTransformations::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Mode for handling transformation errors. If left unspecified, the default - * mode is `TransformationErrorHandling.ThrowError`. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling transformation_error_handling = 3; - * @return \Google\Cloud\Dlp\V2\TransformationErrorHandling|null - */ - public function getTransformationErrorHandling() - { - return $this->transformation_error_handling; - } - - public function hasTransformationErrorHandling() - { - return isset($this->transformation_error_handling); - } - - public function clearTransformationErrorHandling() - { - unset($this->transformation_error_handling); - } - - /** - * Mode for handling transformation errors. If left unspecified, the default - * mode is `TransformationErrorHandling.ThrowError`. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling transformation_error_handling = 3; - * @param \Google\Cloud\Dlp\V2\TransformationErrorHandling $var - * @return $this - */ - public function setTransformationErrorHandling($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationErrorHandling::class); - $this->transformation_error_handling = $var; - - return $this; - } - - /** - * @return string - */ - public function getTransformation() - { - return $this->whichOneof("transformation"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentRequest.php deleted file mode 100644 index 220d50dd05cf..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentRequest.php +++ /dev/null @@ -1,417 +0,0 @@ -google.privacy.dlp.v2.DeidentifyContentRequest - */ -class DeidentifyContentRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Configuration for the de-identification of the content item. - * Items specified here will override the template referenced by the - * deidentify_template_name argument. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig deidentify_config = 2; - */ - protected $deidentify_config = null; - /** - * Configuration for the inspector. - * Items specified here will override the template referenced by the - * inspect_template_name argument. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 3; - */ - protected $inspect_config = null; - /** - * The item to de-identify. Will be treated as text. - * This value must be of type - * [Table][google.privacy.dlp.v2.Table] if your - * [deidentify_config][google.privacy.dlp.v2.DeidentifyContentRequest.deidentify_config] - * is a - * [RecordTransformations][google.privacy.dlp.v2.RecordTransformations] - * object. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 4; - */ - protected $item = null; - /** - * Template to use. Any configuration directly specified in - * inspect_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * - * Generated from protobuf field string inspect_template_name = 5; - */ - protected $inspect_template_name = ''; - /** - * Template to use. Any configuration directly specified in - * deidentify_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * - * Generated from protobuf field string deidentify_template_name = 6; - */ - protected $deidentify_template_name = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 7; - */ - protected $location_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type \Google\Cloud\Dlp\V2\DeidentifyConfig $deidentify_config - * Configuration for the de-identification of the content item. - * Items specified here will override the template referenced by the - * deidentify_template_name argument. - * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config - * Configuration for the inspector. - * Items specified here will override the template referenced by the - * inspect_template_name argument. - * @type \Google\Cloud\Dlp\V2\ContentItem $item - * The item to de-identify. Will be treated as text. - * This value must be of type - * [Table][google.privacy.dlp.v2.Table] if your - * [deidentify_config][google.privacy.dlp.v2.DeidentifyContentRequest.deidentify_config] - * is a - * [RecordTransformations][google.privacy.dlp.v2.RecordTransformations] - * object. - * @type string $inspect_template_name - * Template to use. Any configuration directly specified in - * inspect_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * @type string $deidentify_template_name - * Template to use. Any configuration directly specified in - * deidentify_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Configuration for the de-identification of the content item. - * Items specified here will override the template referenced by the - * deidentify_template_name argument. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig deidentify_config = 2; - * @return \Google\Cloud\Dlp\V2\DeidentifyConfig|null - */ - public function getDeidentifyConfig() - { - return $this->deidentify_config; - } - - public function hasDeidentifyConfig() - { - return isset($this->deidentify_config); - } - - public function clearDeidentifyConfig() - { - unset($this->deidentify_config); - } - - /** - * Configuration for the de-identification of the content item. - * Items specified here will override the template referenced by the - * deidentify_template_name argument. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig deidentify_config = 2; - * @param \Google\Cloud\Dlp\V2\DeidentifyConfig $var - * @return $this - */ - public function setDeidentifyConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyConfig::class); - $this->deidentify_config = $var; - - return $this; - } - - /** - * Configuration for the inspector. - * Items specified here will override the template referenced by the - * inspect_template_name argument. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 3; - * @return \Google\Cloud\Dlp\V2\InspectConfig|null - */ - public function getInspectConfig() - { - return $this->inspect_config; - } - - public function hasInspectConfig() - { - return isset($this->inspect_config); - } - - public function clearInspectConfig() - { - unset($this->inspect_config); - } - - /** - * Configuration for the inspector. - * Items specified here will override the template referenced by the - * inspect_template_name argument. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 3; - * @param \Google\Cloud\Dlp\V2\InspectConfig $var - * @return $this - */ - public function setInspectConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); - $this->inspect_config = $var; - - return $this; - } - - /** - * The item to de-identify. Will be treated as text. - * This value must be of type - * [Table][google.privacy.dlp.v2.Table] if your - * [deidentify_config][google.privacy.dlp.v2.DeidentifyContentRequest.deidentify_config] - * is a - * [RecordTransformations][google.privacy.dlp.v2.RecordTransformations] - * object. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 4; - * @return \Google\Cloud\Dlp\V2\ContentItem|null - */ - public function getItem() - { - return $this->item; - } - - public function hasItem() - { - return isset($this->item); - } - - public function clearItem() - { - unset($this->item); - } - - /** - * The item to de-identify. Will be treated as text. - * This value must be of type - * [Table][google.privacy.dlp.v2.Table] if your - * [deidentify_config][google.privacy.dlp.v2.DeidentifyContentRequest.deidentify_config] - * is a - * [RecordTransformations][google.privacy.dlp.v2.RecordTransformations] - * object. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 4; - * @param \Google\Cloud\Dlp\V2\ContentItem $var - * @return $this - */ - public function setItem($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ContentItem::class); - $this->item = $var; - - return $this; - } - - /** - * Template to use. Any configuration directly specified in - * inspect_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * - * Generated from protobuf field string inspect_template_name = 5; - * @return string - */ - public function getInspectTemplateName() - { - return $this->inspect_template_name; - } - - /** - * Template to use. Any configuration directly specified in - * inspect_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * - * Generated from protobuf field string inspect_template_name = 5; - * @param string $var - * @return $this - */ - public function setInspectTemplateName($var) - { - GPBUtil::checkString($var, True); - $this->inspect_template_name = $var; - - return $this; - } - - /** - * Template to use. Any configuration directly specified in - * deidentify_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * - * Generated from protobuf field string deidentify_template_name = 6; - * @return string - */ - public function getDeidentifyTemplateName() - { - return $this->deidentify_template_name; - } - - /** - * Template to use. Any configuration directly specified in - * deidentify_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * - * Generated from protobuf field string deidentify_template_name = 6; - * @param string $var - * @return $this - */ - public function setDeidentifyTemplateName($var) - { - GPBUtil::checkString($var, True); - $this->deidentify_template_name = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 7; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 7; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentResponse.php deleted file mode 100644 index dd41fd9c0f4d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyContentResponse.php +++ /dev/null @@ -1,121 +0,0 @@ -google.privacy.dlp.v2.DeidentifyContentResponse - */ -class DeidentifyContentResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The de-identified item. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; - */ - protected $item = null; - /** - * An overview of the changes that were made on the `item`. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationOverview overview = 2; - */ - protected $overview = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\ContentItem $item - * The de-identified item. - * @type \Google\Cloud\Dlp\V2\TransformationOverview $overview - * An overview of the changes that were made on the `item`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The de-identified item. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; - * @return \Google\Cloud\Dlp\V2\ContentItem|null - */ - public function getItem() - { - return $this->item; - } - - public function hasItem() - { - return isset($this->item); - } - - public function clearItem() - { - unset($this->item); - } - - /** - * The de-identified item. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; - * @param \Google\Cloud\Dlp\V2\ContentItem $var - * @return $this - */ - public function setItem($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ContentItem::class); - $this->item = $var; - - return $this; - } - - /** - * An overview of the changes that were made on the `item`. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationOverview overview = 2; - * @return \Google\Cloud\Dlp\V2\TransformationOverview|null - */ - public function getOverview() - { - return $this->overview; - } - - public function hasOverview() - { - return isset($this->overview); - } - - public function clearOverview() - { - unset($this->overview); - } - - /** - * An overview of the changes that were made on the `item`. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationOverview overview = 2; - * @param \Google\Cloud\Dlp\V2\TransformationOverview $var - * @return $this - */ - public function setOverview($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationOverview::class); - $this->overview = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails.php deleted file mode 100644 index 7df95b625939..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails.php +++ /dev/null @@ -1,122 +0,0 @@ -google.privacy.dlp.v2.DeidentifyDataSourceDetails - */ -class DeidentifyDataSourceDetails extends \Google\Protobuf\Internal\Message -{ - /** - * De-identification config used for the request. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceDetails.RequestedDeidentifyOptions requested_options = 1; - */ - protected $requested_options = null; - /** - * Stats about the de-identification operation. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceStats deidentify_stats = 2; - */ - protected $deidentify_stats = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails\RequestedDeidentifyOptions $requested_options - * De-identification config used for the request. - * @type \Google\Cloud\Dlp\V2\DeidentifyDataSourceStats $deidentify_stats - * Stats about the de-identification operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * De-identification config used for the request. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceDetails.RequestedDeidentifyOptions requested_options = 1; - * @return \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails\RequestedDeidentifyOptions|null - */ - public function getRequestedOptions() - { - return $this->requested_options; - } - - public function hasRequestedOptions() - { - return isset($this->requested_options); - } - - public function clearRequestedOptions() - { - unset($this->requested_options); - } - - /** - * De-identification config used for the request. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceDetails.RequestedDeidentifyOptions requested_options = 1; - * @param \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails\RequestedDeidentifyOptions $var - * @return $this - */ - public function setRequestedOptions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails\RequestedDeidentifyOptions::class); - $this->requested_options = $var; - - return $this; - } - - /** - * Stats about the de-identification operation. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceStats deidentify_stats = 2; - * @return \Google\Cloud\Dlp\V2\DeidentifyDataSourceStats|null - */ - public function getDeidentifyStats() - { - return $this->deidentify_stats; - } - - public function hasDeidentifyStats() - { - return isset($this->deidentify_stats); - } - - public function clearDeidentifyStats() - { - unset($this->deidentify_stats); - } - - /** - * Stats about the de-identification operation. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyDataSourceStats deidentify_stats = 2; - * @param \Google\Cloud\Dlp\V2\DeidentifyDataSourceStats $var - * @return $this - */ - public function setDeidentifyStats($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyDataSourceStats::class); - $this->deidentify_stats = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails/RequestedDeidentifyOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails/RequestedDeidentifyOptions.php deleted file mode 100644 index e19b4098468f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceDetails/RequestedDeidentifyOptions.php +++ /dev/null @@ -1,184 +0,0 @@ -google.privacy.dlp.v2.DeidentifyDataSourceDetails.RequestedDeidentifyOptions - */ -class RequestedDeidentifyOptions extends \Google\Protobuf\Internal\Message -{ - /** - * Snapshot of the state of the `DeidentifyTemplate` from the - * [Deidentify][google.privacy.dlp.v2.Action.Deidentify] action at the time - * this job was run. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_deidentify_template = 1; - */ - protected $snapshot_deidentify_template = null; - /** - * Snapshot of the state of the structured `DeidentifyTemplate` from the - * `Deidentify` action at the time this job was run. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_structured_deidentify_template = 2; - */ - protected $snapshot_structured_deidentify_template = null; - /** - * Snapshot of the state of the image transformation `DeidentifyTemplate` - * from the `Deidentify` action at the time this job was run. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_image_redact_template = 3; - */ - protected $snapshot_image_redact_template = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DeidentifyTemplate $snapshot_deidentify_template - * Snapshot of the state of the `DeidentifyTemplate` from the - * [Deidentify][google.privacy.dlp.v2.Action.Deidentify] action at the time - * this job was run. - * @type \Google\Cloud\Dlp\V2\DeidentifyTemplate $snapshot_structured_deidentify_template - * Snapshot of the state of the structured `DeidentifyTemplate` from the - * `Deidentify` action at the time this job was run. - * @type \Google\Cloud\Dlp\V2\DeidentifyTemplate $snapshot_image_redact_template - * Snapshot of the state of the image transformation `DeidentifyTemplate` - * from the `Deidentify` action at the time this job was run. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Snapshot of the state of the `DeidentifyTemplate` from the - * [Deidentify][google.privacy.dlp.v2.Action.Deidentify] action at the time - * this job was run. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_deidentify_template = 1; - * @return \Google\Cloud\Dlp\V2\DeidentifyTemplate|null - */ - public function getSnapshotDeidentifyTemplate() - { - return $this->snapshot_deidentify_template; - } - - public function hasSnapshotDeidentifyTemplate() - { - return isset($this->snapshot_deidentify_template); - } - - public function clearSnapshotDeidentifyTemplate() - { - unset($this->snapshot_deidentify_template); - } - - /** - * Snapshot of the state of the `DeidentifyTemplate` from the - * [Deidentify][google.privacy.dlp.v2.Action.Deidentify] action at the time - * this job was run. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_deidentify_template = 1; - * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $var - * @return $this - */ - public function setSnapshotDeidentifyTemplate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyTemplate::class); - $this->snapshot_deidentify_template = $var; - - return $this; - } - - /** - * Snapshot of the state of the structured `DeidentifyTemplate` from the - * `Deidentify` action at the time this job was run. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_structured_deidentify_template = 2; - * @return \Google\Cloud\Dlp\V2\DeidentifyTemplate|null - */ - public function getSnapshotStructuredDeidentifyTemplate() - { - return $this->snapshot_structured_deidentify_template; - } - - public function hasSnapshotStructuredDeidentifyTemplate() - { - return isset($this->snapshot_structured_deidentify_template); - } - - public function clearSnapshotStructuredDeidentifyTemplate() - { - unset($this->snapshot_structured_deidentify_template); - } - - /** - * Snapshot of the state of the structured `DeidentifyTemplate` from the - * `Deidentify` action at the time this job was run. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_structured_deidentify_template = 2; - * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $var - * @return $this - */ - public function setSnapshotStructuredDeidentifyTemplate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyTemplate::class); - $this->snapshot_structured_deidentify_template = $var; - - return $this; - } - - /** - * Snapshot of the state of the image transformation `DeidentifyTemplate` - * from the `Deidentify` action at the time this job was run. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_image_redact_template = 3; - * @return \Google\Cloud\Dlp\V2\DeidentifyTemplate|null - */ - public function getSnapshotImageRedactTemplate() - { - return $this->snapshot_image_redact_template; - } - - public function hasSnapshotImageRedactTemplate() - { - return isset($this->snapshot_image_redact_template); - } - - public function clearSnapshotImageRedactTemplate() - { - unset($this->snapshot_image_redact_template); - } - - /** - * Snapshot of the state of the image transformation `DeidentifyTemplate` - * from the `Deidentify` action at the time this job was run. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate snapshot_image_redact_template = 3; - * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $var - * @return $this - */ - public function setSnapshotImageRedactTemplate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyTemplate::class); - $this->snapshot_image_redact_template = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RequestedDeidentifyOptions::class, \Google\Cloud\Dlp\V2\DeidentifyDataSourceDetails_RequestedDeidentifyOptions::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceStats.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceStats.php deleted file mode 100644 index 59a55b5aa27b..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyDataSourceStats.php +++ /dev/null @@ -1,135 +0,0 @@ -google.privacy.dlp.v2.DeidentifyDataSourceStats - */ -class DeidentifyDataSourceStats extends \Google\Protobuf\Internal\Message -{ - /** - * Total size in bytes that were transformed in some way. - * - * Generated from protobuf field int64 transformed_bytes = 1; - */ - protected $transformed_bytes = 0; - /** - * Number of successfully applied transformations. - * - * Generated from protobuf field int64 transformation_count = 2; - */ - protected $transformation_count = 0; - /** - * Number of errors encountered while trying to apply transformations. - * - * Generated from protobuf field int64 transformation_error_count = 3; - */ - protected $transformation_error_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $transformed_bytes - * Total size in bytes that were transformed in some way. - * @type int|string $transformation_count - * Number of successfully applied transformations. - * @type int|string $transformation_error_count - * Number of errors encountered while trying to apply transformations. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Total size in bytes that were transformed in some way. - * - * Generated from protobuf field int64 transformed_bytes = 1; - * @return int|string - */ - public function getTransformedBytes() - { - return $this->transformed_bytes; - } - - /** - * Total size in bytes that were transformed in some way. - * - * Generated from protobuf field int64 transformed_bytes = 1; - * @param int|string $var - * @return $this - */ - public function setTransformedBytes($var) - { - GPBUtil::checkInt64($var); - $this->transformed_bytes = $var; - - return $this; - } - - /** - * Number of successfully applied transformations. - * - * Generated from protobuf field int64 transformation_count = 2; - * @return int|string - */ - public function getTransformationCount() - { - return $this->transformation_count; - } - - /** - * Number of successfully applied transformations. - * - * Generated from protobuf field int64 transformation_count = 2; - * @param int|string $var - * @return $this - */ - public function setTransformationCount($var) - { - GPBUtil::checkInt64($var); - $this->transformation_count = $var; - - return $this; - } - - /** - * Number of errors encountered while trying to apply transformations. - * - * Generated from protobuf field int64 transformation_error_count = 3; - * @return int|string - */ - public function getTransformationErrorCount() - { - return $this->transformation_error_count; - } - - /** - * Number of errors encountered while trying to apply transformations. - * - * Generated from protobuf field int64 transformation_error_count = 3; - * @param int|string $var - * @return $this - */ - public function setTransformationErrorCount($var) - { - GPBUtil::checkInt64($var); - $this->transformation_error_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyTemplate.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyTemplate.php deleted file mode 100644 index ed0862cbcb2b..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeidentifyTemplate.php +++ /dev/null @@ -1,282 +0,0 @@ -google.privacy.dlp.v2.DeidentifyTemplate - */ -class DeidentifyTemplate extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The template name. - * The template will have one of the following formats: - * `projects/PROJECT_ID/deidentifyTemplates/TEMPLATE_ID` OR - * `organizations/ORGANIZATION_ID/deidentifyTemplates/TEMPLATE_ID` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Display name (max 256 chars). - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * Short description (max 256 chars). - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * Output only. The creation timestamp of an inspectTemplate. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The last update timestamp of an inspectTemplate. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * The core content of the template. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig deidentify_config = 6; - */ - protected $deidentify_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The template name. - * The template will have one of the following formats: - * `projects/PROJECT_ID/deidentifyTemplates/TEMPLATE_ID` OR - * `organizations/ORGANIZATION_ID/deidentifyTemplates/TEMPLATE_ID` - * @type string $display_name - * Display name (max 256 chars). - * @type string $description - * Short description (max 256 chars). - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The creation timestamp of an inspectTemplate. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The last update timestamp of an inspectTemplate. - * @type \Google\Cloud\Dlp\V2\DeidentifyConfig $deidentify_config - * The core content of the template. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The template name. - * The template will have one of the following formats: - * `projects/PROJECT_ID/deidentifyTemplates/TEMPLATE_ID` OR - * `organizations/ORGANIZATION_ID/deidentifyTemplates/TEMPLATE_ID` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The template name. - * The template will have one of the following formats: - * `projects/PROJECT_ID/deidentifyTemplates/TEMPLATE_ID` OR - * `organizations/ORGANIZATION_ID/deidentifyTemplates/TEMPLATE_ID` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Display name (max 256 chars). - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Display name (max 256 chars). - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Short description (max 256 chars). - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Short description (max 256 chars). - * - * 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; - } - - /** - * Output only. The creation timestamp of an inspectTemplate. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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 creation timestamp of an inspectTemplate. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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 last update timestamp of an inspectTemplate. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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 last update timestamp of an inspectTemplate. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * The core content of the template. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig deidentify_config = 6; - * @return \Google\Cloud\Dlp\V2\DeidentifyConfig|null - */ - public function getDeidentifyConfig() - { - return $this->deidentify_config; - } - - public function hasDeidentifyConfig() - { - return isset($this->deidentify_config); - } - - public function clearDeidentifyConfig() - { - unset($this->deidentify_config); - } - - /** - * The core content of the template. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig deidentify_config = 6; - * @param \Google\Cloud\Dlp\V2\DeidentifyConfig $var - * @return $this - */ - public function setDeidentifyConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyConfig::class); - $this->deidentify_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteConnectionRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteConnectionRequest.php deleted file mode 100644 index bb91b2b567db..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteConnectionRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.privacy.dlp.v2.DeleteConnectionRequest - */ -class DeleteConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the Connection to be deleted, in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the Connection to be deleted, in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. Please see - * {@see DlpServiceClient::connectionName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\DeleteConnectionRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the Connection to be deleted, in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the Connection to be deleted, in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the Connection to be deleted, in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDeidentifyTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDeidentifyTemplateRequest.php deleted file mode 100644 index 0b3e5e031c0a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDeidentifyTemplateRequest.php +++ /dev/null @@ -1,96 +0,0 @@ -google.privacy.dlp.v2.DeleteDeidentifyTemplateRequest - */ -class DeleteDeidentifyTemplateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the organization and deidentify template to be - * deleted, for example - * `organizations/433245324/deidentifyTemplates/432452342` or - * projects/project-id/deidentifyTemplates/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the organization and deidentify template to be - * deleted, for example - * `organizations/433245324/deidentifyTemplates/432452342` or - * projects/project-id/deidentifyTemplates/432452342. Please see - * {@see DlpServiceClient::deidentifyTemplateName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\DeleteDeidentifyTemplateRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the organization and deidentify template to be - * deleted, for example - * `organizations/433245324/deidentifyTemplates/432452342` or - * projects/project-id/deidentifyTemplates/432452342. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the organization and deidentify template to be - * deleted, for example - * `organizations/433245324/deidentifyTemplates/432452342` or - * projects/project-id/deidentifyTemplates/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the organization and deidentify template to be - * deleted, for example - * `organizations/433245324/deidentifyTemplates/432452342` or - * projects/project-id/deidentifyTemplates/432452342. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDiscoveryConfigRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDiscoveryConfigRequest.php deleted file mode 100644 index 6a20b7235350..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDiscoveryConfigRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.privacy.dlp.v2.DeleteDiscoveryConfigRequest - */ -class DeleteDiscoveryConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the project and the config, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the project and the config, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. Please see - * {@see DlpServiceClient::discoveryConfigName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\DeleteDiscoveryConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the project and the config, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the project and the config, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the project and the config, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDlpJobRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDlpJobRequest.php deleted file mode 100644 index 973c1c27b837..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteDlpJobRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.privacy.dlp.v2.DeleteDlpJobRequest - */ -class DeleteDlpJobRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the DlpJob resource to be deleted. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the DlpJob resource to be deleted. Please see - * {@see DlpServiceClient::dlpJobName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\DeleteDlpJobRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the DlpJob resource to be deleted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the DlpJob resource to be deleted. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the DlpJob resource to be deleted. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteInspectTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteInspectTemplateRequest.php deleted file mode 100644 index 247a31ff2442..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteInspectTemplateRequest.php +++ /dev/null @@ -1,91 +0,0 @@ -google.privacy.dlp.v2.DeleteInspectTemplateRequest - */ -class DeleteInspectTemplateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the organization and inspectTemplate to be - * deleted, for example `organizations/433245324/inspectTemplates/432452342` - * or projects/project-id/inspectTemplates/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the organization and inspectTemplate to be - * deleted, for example `organizations/433245324/inspectTemplates/432452342` - * or projects/project-id/inspectTemplates/432452342. Please see - * {@see DlpServiceClient::inspectTemplateName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\DeleteInspectTemplateRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the organization and inspectTemplate to be - * deleted, for example `organizations/433245324/inspectTemplates/432452342` - * or projects/project-id/inspectTemplates/432452342. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the organization and inspectTemplate to be - * deleted, for example `organizations/433245324/inspectTemplates/432452342` - * or projects/project-id/inspectTemplates/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the organization and inspectTemplate to be - * deleted, for example `organizations/433245324/inspectTemplates/432452342` - * or projects/project-id/inspectTemplates/432452342. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteJobTriggerRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteJobTriggerRequest.php deleted file mode 100644 index a5b16ef7a905..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteJobTriggerRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.privacy.dlp.v2.DeleteJobTriggerRequest - */ -class DeleteJobTriggerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. Please see - * {@see DlpServiceClient::jobTriggerName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\DeleteJobTriggerRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteStoredInfoTypeRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteStoredInfoTypeRequest.php deleted file mode 100644 index d8d4c68e7530..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteStoredInfoTypeRequest.php +++ /dev/null @@ -1,91 +0,0 @@ -google.privacy.dlp.v2.DeleteStoredInfoTypeRequest - */ -class DeleteStoredInfoTypeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the organization and storedInfoType to be - * deleted, for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the organization and storedInfoType to be - * deleted, for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. Please see - * {@see DlpServiceClient::storedInfoTypeName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\DeleteStoredInfoTypeRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the organization and storedInfoType to be - * deleted, for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the organization and storedInfoType to be - * deleted, for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the organization and storedInfoType to be - * deleted, for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteTableDataProfileRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteTableDataProfileRequest.php deleted file mode 100644 index e270dbd6466f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DeleteTableDataProfileRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.privacy.dlp.v2.DeleteTableDataProfileRequest - */ -class DeleteTableDataProfileRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the table data profile. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the table data profile. Please see - * {@see DlpServiceClient::tableDataProfileName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\DeleteTableDataProfileRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the table data profile. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the table data profile. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the table data profile. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Disabled.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Disabled.php deleted file mode 100644 index 41edd890b7f6..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Disabled.php +++ /dev/null @@ -1,33 +0,0 @@ -google.privacy.dlp.v2.Disabled - */ -class Disabled extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions.php deleted file mode 100644 index 79aa5b244deb..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions.php +++ /dev/null @@ -1,204 +0,0 @@ -google.privacy.dlp.v2.DiscoveryBigQueryConditions - */ -class DiscoveryBigQueryConditions extends \Google\Protobuf\Internal\Message -{ - /** - * BigQuery table must have been created after this date. Used to avoid - * backfilling. - * - * Generated from protobuf field .google.protobuf.Timestamp created_after = 1; - */ - protected $created_after = null; - /** - * At least one of the conditions must be true for a table to be scanned. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryConditions.OrConditions or_conditions = 4; - */ - protected $or_conditions = null; - protected $included_types; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $created_after - * BigQuery table must have been created after this date. Used to avoid - * backfilling. - * @type \Google\Cloud\Dlp\V2\BigQueryTableTypes $types - * Restrict discovery to specific table types. - * @type int $type_collection - * Restrict discovery to categories of table types. - * @type \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions\OrConditions $or_conditions - * At least one of the conditions must be true for a table to be scanned. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * BigQuery table must have been created after this date. Used to avoid - * backfilling. - * - * Generated from protobuf field .google.protobuf.Timestamp created_after = 1; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreatedAfter() - { - return $this->created_after; - } - - public function hasCreatedAfter() - { - return isset($this->created_after); - } - - public function clearCreatedAfter() - { - unset($this->created_after); - } - - /** - * BigQuery table must have been created after this date. Used to avoid - * backfilling. - * - * Generated from protobuf field .google.protobuf.Timestamp created_after = 1; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreatedAfter($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->created_after = $var; - - return $this; - } - - /** - * Restrict discovery to specific table types. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTableTypes types = 2; - * @return \Google\Cloud\Dlp\V2\BigQueryTableTypes|null - */ - public function getTypes() - { - return $this->readOneof(2); - } - - public function hasTypes() - { - return $this->hasOneof(2); - } - - /** - * Restrict discovery to specific table types. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTableTypes types = 2; - * @param \Google\Cloud\Dlp\V2\BigQueryTableTypes $var - * @return $this - */ - public function setTypes($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTableTypes::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Restrict discovery to categories of table types. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTableTypeCollection type_collection = 3; - * @return int - */ - public function getTypeCollection() - { - return $this->readOneof(3); - } - - public function hasTypeCollection() - { - return $this->hasOneof(3); - } - - /** - * Restrict discovery to categories of table types. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTableTypeCollection type_collection = 3; - * @param int $var - * @return $this - */ - public function setTypeCollection($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\BigQueryTableTypeCollection::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * At least one of the conditions must be true for a table to be scanned. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryConditions.OrConditions or_conditions = 4; - * @return \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions\OrConditions|null - */ - public function getOrConditions() - { - return $this->or_conditions; - } - - public function hasOrConditions() - { - return isset($this->or_conditions); - } - - public function clearOrConditions() - { - unset($this->or_conditions); - } - - /** - * At least one of the conditions must be true for a table to be scanned. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryConditions.OrConditions or_conditions = 4; - * @param \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions\OrConditions $var - * @return $this - */ - public function setOrConditions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions\OrConditions::class); - $this->or_conditions = $var; - - return $this; - } - - /** - * @return string - */ - public function getIncludedTypes() - { - return $this->whichOneof("included_types"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions/OrConditions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions/OrConditions.php deleted file mode 100644 index be485bc77246..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryConditions/OrConditions.php +++ /dev/null @@ -1,123 +0,0 @@ -google.privacy.dlp.v2.DiscoveryBigQueryConditions.OrConditions - */ -class OrConditions extends \Google\Protobuf\Internal\Message -{ - /** - * Minimum number of rows that should be present before Cloud DLP - * profiles a table - * - * Generated from protobuf field int32 min_row_count = 1; - */ - protected $min_row_count = 0; - /** - * Minimum age a table must have before Cloud DLP can profile it. Value must - * be 1 hour or greater. - * - * Generated from protobuf field .google.protobuf.Duration min_age = 2; - */ - protected $min_age = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $min_row_count - * Minimum number of rows that should be present before Cloud DLP - * profiles a table - * @type \Google\Protobuf\Duration $min_age - * Minimum age a table must have before Cloud DLP can profile it. Value must - * be 1 hour or greater. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Minimum number of rows that should be present before Cloud DLP - * profiles a table - * - * Generated from protobuf field int32 min_row_count = 1; - * @return int - */ - public function getMinRowCount() - { - return $this->min_row_count; - } - - /** - * Minimum number of rows that should be present before Cloud DLP - * profiles a table - * - * Generated from protobuf field int32 min_row_count = 1; - * @param int $var - * @return $this - */ - public function setMinRowCount($var) - { - GPBUtil::checkInt32($var); - $this->min_row_count = $var; - - return $this; - } - - /** - * Minimum age a table must have before Cloud DLP can profile it. Value must - * be 1 hour or greater. - * - * Generated from protobuf field .google.protobuf.Duration min_age = 2; - * @return \Google\Protobuf\Duration|null - */ - public function getMinAge() - { - return $this->min_age; - } - - public function hasMinAge() - { - return isset($this->min_age); - } - - public function clearMinAge() - { - unset($this->min_age); - } - - /** - * Minimum age a table must have before Cloud DLP can profile it. Value must - * be 1 hour or greater. - * - * Generated from protobuf field .google.protobuf.Duration min_age = 2; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setMinAge($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->min_age = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(OrConditions::class, \Google\Cloud\Dlp\V2\DiscoveryBigQueryConditions_OrConditions::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter.php deleted file mode 100644 index a87ee0ec1d3b..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter.php +++ /dev/null @@ -1,167 +0,0 @@ -google.privacy.dlp.v2.DiscoveryBigQueryFilter - */ -class DiscoveryBigQueryFilter extends \Google\Protobuf\Internal\Message -{ - protected $filter; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\BigQueryTableCollection $tables - * A specific set of tables for this filter to apply to. A table collection - * must be specified in only one filter per config. - * If a table id or dataset is empty, Cloud DLP assumes all tables in that - * collection must be profiled. Must specify a project ID. - * @type \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter\AllOtherBigQueryTables $other_tables - * Catch-all. This should always be the last filter in the list because - * anything above it will apply first. Should only appear once in a - * configuration. If none is specified, a default one will be added - * automatically. - * @type \Google\Cloud\Dlp\V2\TableReference $table_reference - * The table to scan. Discovery configurations including this can only - * include one DiscoveryTarget (the DiscoveryTarget with this - * TableReference). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A specific set of tables for this filter to apply to. A table collection - * must be specified in only one filter per config. - * If a table id or dataset is empty, Cloud DLP assumes all tables in that - * collection must be profiled. Must specify a project ID. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTableCollection tables = 1; - * @return \Google\Cloud\Dlp\V2\BigQueryTableCollection|null - */ - public function getTables() - { - return $this->readOneof(1); - } - - public function hasTables() - { - return $this->hasOneof(1); - } - - /** - * A specific set of tables for this filter to apply to. A table collection - * must be specified in only one filter per config. - * If a table id or dataset is empty, Cloud DLP assumes all tables in that - * collection must be profiled. Must specify a project ID. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTableCollection tables = 1; - * @param \Google\Cloud\Dlp\V2\BigQueryTableCollection $var - * @return $this - */ - public function setTables($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTableCollection::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Catch-all. This should always be the last filter in the list because - * anything above it will apply first. Should only appear once in a - * configuration. If none is specified, a default one will be added - * automatically. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryFilter.AllOtherBigQueryTables other_tables = 2; - * @return \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter\AllOtherBigQueryTables|null - */ - public function getOtherTables() - { - return $this->readOneof(2); - } - - public function hasOtherTables() - { - return $this->hasOneof(2); - } - - /** - * Catch-all. This should always be the last filter in the list because - * anything above it will apply first. Should only appear once in a - * configuration. If none is specified, a default one will be added - * automatically. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryBigQueryFilter.AllOtherBigQueryTables other_tables = 2; - * @param \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter\AllOtherBigQueryTables $var - * @return $this - */ - public function setOtherTables($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter\AllOtherBigQueryTables::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The table to scan. Discovery configurations including this can only - * include one DiscoveryTarget (the DiscoveryTarget with this - * TableReference). - * - * Generated from protobuf field .google.privacy.dlp.v2.TableReference table_reference = 3; - * @return \Google\Cloud\Dlp\V2\TableReference|null - */ - public function getTableReference() - { - return $this->readOneof(3); - } - - public function hasTableReference() - { - return $this->hasOneof(3); - } - - /** - * The table to scan. Discovery configurations including this can only - * include one DiscoveryTarget (the DiscoveryTarget with this - * TableReference). - * - * Generated from protobuf field .google.privacy.dlp.v2.TableReference table_reference = 3; - * @param \Google\Cloud\Dlp\V2\TableReference $var - * @return $this - */ - public function setTableReference($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableReference::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getFilter() - { - return $this->whichOneof("filter"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter/AllOtherBigQueryTables.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter/AllOtherBigQueryTables.php deleted file mode 100644 index 10dc3a6a889a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryBigQueryFilter/AllOtherBigQueryTables.php +++ /dev/null @@ -1,38 +0,0 @@ -google.privacy.dlp.v2.DiscoveryBigQueryFilter.AllOtherBigQueryTables - */ -class AllOtherBigQueryTables extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AllOtherBigQueryTables::class, \Google\Cloud\Dlp\V2\DiscoveryBigQueryFilter_AllOtherBigQueryTables::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions.php deleted file mode 100644 index 0697e79227ac..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions.php +++ /dev/null @@ -1,114 +0,0 @@ -google.privacy.dlp.v2.DiscoveryCloudSqlConditions - */ -class DiscoveryCloudSqlConditions extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Database engines that should be profiled. - * Optional. Defaults to ALL_SUPPORTED_DATABASE_ENGINES if unspecified. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseEngine database_engines = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $database_engines; - /** - * Data profiles will only be generated for the database resource types - * specified in this field. - * If not specified, defaults to [DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES]. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseResourceType types = 3; - */ - private $types; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $database_engines - * Optional. Database engines that should be profiled. - * Optional. Defaults to ALL_SUPPORTED_DATABASE_ENGINES if unspecified. - * @type array|\Google\Protobuf\Internal\RepeatedField $types - * Data profiles will only be generated for the database resource types - * specified in this field. - * If not specified, defaults to [DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES]. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Database engines that should be profiled. - * Optional. Defaults to ALL_SUPPORTED_DATABASE_ENGINES if unspecified. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseEngine database_engines = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDatabaseEngines() - { - return $this->database_engines; - } - - /** - * Optional. Database engines that should be profiled. - * Optional. Defaults to ALL_SUPPORTED_DATABASE_ENGINES if unspecified. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseEngine database_engines = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDatabaseEngines($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions\DatabaseEngine::class); - $this->database_engines = $arr; - - return $this; - } - - /** - * Data profiles will only be generated for the database resource types - * specified in this field. - * If not specified, defaults to [DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES]. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseResourceType types = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTypes() - { - return $this->types; - } - - /** - * Data profiles will only be generated for the database resource types - * specified in this field. - * If not specified, defaults to [DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES]. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseResourceType types = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions\DatabaseResourceType::class); - $this->types = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseEngine.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseEngine.php deleted file mode 100644 index 8438c6877e4a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseEngine.php +++ /dev/null @@ -1,71 +0,0 @@ -google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseEngine - */ -class DatabaseEngine -{ - /** - * Unused. - * - * Generated from protobuf enum DATABASE_ENGINE_UNSPECIFIED = 0; - */ - const DATABASE_ENGINE_UNSPECIFIED = 0; - /** - * Include all supported database engines. - * - * Generated from protobuf enum ALL_SUPPORTED_DATABASE_ENGINES = 1; - */ - const ALL_SUPPORTED_DATABASE_ENGINES = 1; - /** - * MySQL database. - * - * Generated from protobuf enum MYSQL = 2; - */ - const MYSQL = 2; - /** - * PostgreSQL database. - * - * Generated from protobuf enum POSTGRES = 3; - */ - const POSTGRES = 3; - - private static $valueToName = [ - self::DATABASE_ENGINE_UNSPECIFIED => 'DATABASE_ENGINE_UNSPECIFIED', - self::ALL_SUPPORTED_DATABASE_ENGINES => 'ALL_SUPPORTED_DATABASE_ENGINES', - self::MYSQL => 'MYSQL', - self::POSTGRES => 'POSTGRES', - ]; - - 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(DatabaseEngine::class, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions_DatabaseEngine::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseResourceType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseResourceType.php deleted file mode 100644 index 50969361416d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlConditions/DatabaseResourceType.php +++ /dev/null @@ -1,64 +0,0 @@ -google.privacy.dlp.v2.DiscoveryCloudSqlConditions.DatabaseResourceType - */ -class DatabaseResourceType -{ - /** - * Unused. - * - * Generated from protobuf enum DATABASE_RESOURCE_TYPE_UNSPECIFIED = 0; - */ - const DATABASE_RESOURCE_TYPE_UNSPECIFIED = 0; - /** - * Includes database resource types that become supported at a later time. - * - * Generated from protobuf enum DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES = 1; - */ - const DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES = 1; - /** - * Tables. - * - * Generated from protobuf enum DATABASE_RESOURCE_TYPE_TABLE = 2; - */ - const DATABASE_RESOURCE_TYPE_TABLE = 2; - - private static $valueToName = [ - self::DATABASE_RESOURCE_TYPE_UNSPECIFIED => 'DATABASE_RESOURCE_TYPE_UNSPECIFIED', - self::DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES => 'DATABASE_RESOURCE_TYPE_ALL_SUPPORTED_TYPES', - self::DATABASE_RESOURCE_TYPE_TABLE => 'DATABASE_RESOURCE_TYPE_TABLE', - ]; - - 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(DatabaseResourceType::class, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlConditions_DatabaseResourceType::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlFilter.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlFilter.php deleted file mode 100644 index c2d34c2f8649..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlFilter.php +++ /dev/null @@ -1,155 +0,0 @@ -google.privacy.dlp.v2.DiscoveryCloudSqlFilter - */ -class DiscoveryCloudSqlFilter extends \Google\Protobuf\Internal\Message -{ - protected $filter; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DatabaseResourceCollection $collection - * A specific set of database resources for this filter to apply to. - * @type \Google\Cloud\Dlp\V2\AllOtherDatabaseResources $others - * Catch-all. This should always be the last target in the list because - * anything above it will apply first. Should only appear once in a - * configuration. If none is specified, a default one will be added - * automatically. - * @type \Google\Cloud\Dlp\V2\DatabaseResourceReference $database_resource_reference - * The database resource to scan. Targets including this can only include - * one target (the target with this database resource reference). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A specific set of database resources for this filter to apply to. - * - * Generated from protobuf field .google.privacy.dlp.v2.DatabaseResourceCollection collection = 1; - * @return \Google\Cloud\Dlp\V2\DatabaseResourceCollection|null - */ - public function getCollection() - { - return $this->readOneof(1); - } - - public function hasCollection() - { - return $this->hasOneof(1); - } - - /** - * A specific set of database resources for this filter to apply to. - * - * Generated from protobuf field .google.privacy.dlp.v2.DatabaseResourceCollection collection = 1; - * @param \Google\Cloud\Dlp\V2\DatabaseResourceCollection $var - * @return $this - */ - public function setCollection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DatabaseResourceCollection::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Catch-all. This should always be the last target in the list because - * anything above it will apply first. Should only appear once in a - * configuration. If none is specified, a default one will be added - * automatically. - * - * Generated from protobuf field .google.privacy.dlp.v2.AllOtherDatabaseResources others = 2; - * @return \Google\Cloud\Dlp\V2\AllOtherDatabaseResources|null - */ - public function getOthers() - { - return $this->readOneof(2); - } - - public function hasOthers() - { - return $this->hasOneof(2); - } - - /** - * Catch-all. This should always be the last target in the list because - * anything above it will apply first. Should only appear once in a - * configuration. If none is specified, a default one will be added - * automatically. - * - * Generated from protobuf field .google.privacy.dlp.v2.AllOtherDatabaseResources others = 2; - * @param \Google\Cloud\Dlp\V2\AllOtherDatabaseResources $var - * @return $this - */ - public function setOthers($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AllOtherDatabaseResources::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The database resource to scan. Targets including this can only include - * one target (the target with this database resource reference). - * - * Generated from protobuf field .google.privacy.dlp.v2.DatabaseResourceReference database_resource_reference = 3; - * @return \Google\Cloud\Dlp\V2\DatabaseResourceReference|null - */ - public function getDatabaseResourceReference() - { - return $this->readOneof(3); - } - - public function hasDatabaseResourceReference() - { - return $this->hasOneof(3); - } - - /** - * The database resource to scan. Targets including this can only include - * one target (the target with this database resource reference). - * - * Generated from protobuf field .google.privacy.dlp.v2.DatabaseResourceReference database_resource_reference = 3; - * @param \Google\Cloud\Dlp\V2\DatabaseResourceReference $var - * @return $this - */ - public function setDatabaseResourceReference($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DatabaseResourceReference::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getFilter() - { - return $this->whichOneof("filter"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence.php deleted file mode 100644 index dd3a9545fe18..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence.php +++ /dev/null @@ -1,125 +0,0 @@ -google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence - */ -class DiscoveryCloudSqlGenerationCadence extends \Google\Protobuf\Internal\Message -{ - /** - * When to reprofile if the schema has changed. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence schema_modified_cadence = 1; - */ - protected $schema_modified_cadence = null; - /** - * Data changes (non-schema changes) in Cloud SQL tables can't trigger - * reprofiling. If you set this field, profiles are refreshed at this - * frequency regardless of whether the underlying tables have changed. - * Defaults to never. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency refresh_frequency = 2; - */ - protected $refresh_frequency = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence\SchemaModifiedCadence $schema_modified_cadence - * When to reprofile if the schema has changed. - * @type int $refresh_frequency - * Data changes (non-schema changes) in Cloud SQL tables can't trigger - * reprofiling. If you set this field, profiles are refreshed at this - * frequency regardless of whether the underlying tables have changed. - * Defaults to never. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * When to reprofile if the schema has changed. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence schema_modified_cadence = 1; - * @return \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence\SchemaModifiedCadence|null - */ - public function getSchemaModifiedCadence() - { - return $this->schema_modified_cadence; - } - - public function hasSchemaModifiedCadence() - { - return isset($this->schema_modified_cadence); - } - - public function clearSchemaModifiedCadence() - { - unset($this->schema_modified_cadence); - } - - /** - * When to reprofile if the schema has changed. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence schema_modified_cadence = 1; - * @param \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence\SchemaModifiedCadence $var - * @return $this - */ - public function setSchemaModifiedCadence($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence\SchemaModifiedCadence::class); - $this->schema_modified_cadence = $var; - - return $this; - } - - /** - * Data changes (non-schema changes) in Cloud SQL tables can't trigger - * reprofiling. If you set this field, profiles are refreshed at this - * frequency regardless of whether the underlying tables have changed. - * Defaults to never. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency refresh_frequency = 2; - * @return int - */ - public function getRefreshFrequency() - { - return $this->refresh_frequency; - } - - /** - * Data changes (non-schema changes) in Cloud SQL tables can't trigger - * reprofiling. If you set this field, profiles are refreshed at this - * frequency regardless of whether the underlying tables have changed. - * Defaults to never. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency refresh_frequency = 2; - * @param int $var - * @return $this - */ - public function setRefreshFrequency($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileUpdateFrequency::class); - $this->refresh_frequency = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence.php deleted file mode 100644 index 60ebef96f635..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence.php +++ /dev/null @@ -1,112 +0,0 @@ -google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence - */ -class SchemaModifiedCadence extends \Google\Protobuf\Internal\Message -{ - /** - * The types of schema modifications to consider. - * Defaults to NEW_COLUMNS. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence.CloudSqlSchemaModification types = 1; - */ - private $types; - /** - * Frequency to regenerate data profiles when the schema is modified. - * Defaults to monthly. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; - */ - protected $frequency = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $types - * The types of schema modifications to consider. - * Defaults to NEW_COLUMNS. - * @type int $frequency - * Frequency to regenerate data profiles when the schema is modified. - * Defaults to monthly. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The types of schema modifications to consider. - * Defaults to NEW_COLUMNS. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence.CloudSqlSchemaModification types = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTypes() - { - return $this->types; - } - - /** - * The types of schema modifications to consider. - * Defaults to NEW_COLUMNS. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence.CloudSqlSchemaModification types = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence\SchemaModifiedCadence\CloudSqlSchemaModification::class); - $this->types = $arr; - - return $this; - } - - /** - * Frequency to regenerate data profiles when the schema is modified. - * Defaults to monthly. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; - * @return int - */ - public function getFrequency() - { - return $this->frequency; - } - - /** - * Frequency to regenerate data profiles when the schema is modified. - * Defaults to monthly. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; - * @param int $var - * @return $this - */ - public function setFrequency($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileUpdateFrequency::class); - $this->frequency = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SchemaModifiedCadence::class, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence_SchemaModifiedCadence::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence/CloudSqlSchemaModification.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence/CloudSqlSchemaModification.php deleted file mode 100644 index 38682145dfb2..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryCloudSqlGenerationCadence/SchemaModifiedCadence/CloudSqlSchemaModification.php +++ /dev/null @@ -1,64 +0,0 @@ -google.privacy.dlp.v2.DiscoveryCloudSqlGenerationCadence.SchemaModifiedCadence.CloudSqlSchemaModification - */ -class CloudSqlSchemaModification -{ - /** - * Unused. - * - * Generated from protobuf enum SQL_SCHEMA_MODIFICATION_UNSPECIFIED = 0; - */ - const SQL_SCHEMA_MODIFICATION_UNSPECIFIED = 0; - /** - * New columns have appeared. - * - * Generated from protobuf enum NEW_COLUMNS = 1; - */ - const NEW_COLUMNS = 1; - /** - * Columns have been removed from the table. - * - * Generated from protobuf enum REMOVED_COLUMNS = 2; - */ - const REMOVED_COLUMNS = 2; - - private static $valueToName = [ - self::SQL_SCHEMA_MODIFICATION_UNSPECIFIED => 'SQL_SCHEMA_MODIFICATION_UNSPECIFIED', - self::NEW_COLUMNS => 'NEW_COLUMNS', - self::REMOVED_COLUMNS => 'REMOVED_COLUMNS', - ]; - - 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(CloudSqlSchemaModification::class, \Google\Cloud\Dlp\V2\DiscoveryCloudSqlGenerationCadence_SchemaModifiedCadence_CloudSqlSchemaModification::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig.php deleted file mode 100644 index c78a915b00dd..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig.php +++ /dev/null @@ -1,520 +0,0 @@ -google.privacy.dlp.v2.DiscoveryConfig - */ -class DiscoveryConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Unique resource name for the DiscoveryConfig, assigned by the service when - * the DiscoveryConfig is created, for example - * `projects/dlp-test-project/locations/global/discoveryConfigs/53234423`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Display name (max 100 chars) - * - * Generated from protobuf field string display_name = 11; - */ - protected $display_name = ''; - /** - * Only set when the parent is an org. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig.OrgConfig org_config = 2; - */ - protected $org_config = null; - /** - * Detection logic for profile generation. - * Not all template features are used by Discovery. FindingLimits, - * include_quote and exclude_info_types have no impact on - * Discovery. - * Multiple templates may be provided if there is data in multiple regions. - * At most one template must be specified per-region (including "global"). - * Each region is scanned using the applicable template. If no region-specific - * template is specified, but a "global" template is specified, it will be - * copied to that region and used instead. If no global or region-specific - * template is provided for a region with data, that region's data will not be - * scanned. - * For more information, see - * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. - * - * Generated from protobuf field repeated string inspect_templates = 3; - */ - private $inspect_templates; - /** - * Actions to execute at the completion of scanning. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfileAction actions = 4; - */ - private $actions; - /** - * Target to match against for determining what to scan and how frequently. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryTarget targets = 5; - */ - private $targets; - /** - * Output only. A stream of errors encountered when the config was activated. - * Repeated errors may result in the config automatically being paused. Output - * only field. Will return the last 100 errors. Whenever the config is - * modified this list will be cleared. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $errors; - /** - * Output only. The creation timestamp of a DiscoveryConfig. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The last update timestamp of a DiscoveryConfig. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. The timestamp of the last time this config was executed. - * - * Generated from protobuf field .google.protobuf.Timestamp last_run_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $last_run_time = null; - /** - * Required. A status for this configuration. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig.Status status = 10 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $status = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Unique resource name for the DiscoveryConfig, assigned by the service when - * the DiscoveryConfig is created, for example - * `projects/dlp-test-project/locations/global/discoveryConfigs/53234423`. - * @type string $display_name - * Display name (max 100 chars) - * @type \Google\Cloud\Dlp\V2\DiscoveryConfig\OrgConfig $org_config - * Only set when the parent is an org. - * @type array|\Google\Protobuf\Internal\RepeatedField $inspect_templates - * Detection logic for profile generation. - * Not all template features are used by Discovery. FindingLimits, - * include_quote and exclude_info_types have no impact on - * Discovery. - * Multiple templates may be provided if there is data in multiple regions. - * At most one template must be specified per-region (including "global"). - * Each region is scanned using the applicable template. If no region-specific - * template is specified, but a "global" template is specified, it will be - * copied to that region and used instead. If no global or region-specific - * template is provided for a region with data, that region's data will not be - * scanned. - * For more information, see - * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. - * @type array<\Google\Cloud\Dlp\V2\DataProfileAction>|\Google\Protobuf\Internal\RepeatedField $actions - * Actions to execute at the completion of scanning. - * @type array<\Google\Cloud\Dlp\V2\DiscoveryTarget>|\Google\Protobuf\Internal\RepeatedField $targets - * Target to match against for determining what to scan and how frequently. - * @type array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $errors - * Output only. A stream of errors encountered when the config was activated. - * Repeated errors may result in the config automatically being paused. Output - * only field. Will return the last 100 errors. Whenever the config is - * modified this list will be cleared. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The creation timestamp of a DiscoveryConfig. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The last update timestamp of a DiscoveryConfig. - * @type \Google\Protobuf\Timestamp $last_run_time - * Output only. The timestamp of the last time this config was executed. - * @type int $status - * Required. A status for this configuration. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Unique resource name for the DiscoveryConfig, assigned by the service when - * the DiscoveryConfig is created, for example - * `projects/dlp-test-project/locations/global/discoveryConfigs/53234423`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Unique resource name for the DiscoveryConfig, assigned by the service when - * the DiscoveryConfig is created, for example - * `projects/dlp-test-project/locations/global/discoveryConfigs/53234423`. - * - * 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; - } - - /** - * Display name (max 100 chars) - * - * Generated from protobuf field string display_name = 11; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Display name (max 100 chars) - * - * Generated from protobuf field string display_name = 11; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Only set when the parent is an org. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig.OrgConfig org_config = 2; - * @return \Google\Cloud\Dlp\V2\DiscoveryConfig\OrgConfig|null - */ - public function getOrgConfig() - { - return $this->org_config; - } - - public function hasOrgConfig() - { - return isset($this->org_config); - } - - public function clearOrgConfig() - { - unset($this->org_config); - } - - /** - * Only set when the parent is an org. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig.OrgConfig org_config = 2; - * @param \Google\Cloud\Dlp\V2\DiscoveryConfig\OrgConfig $var - * @return $this - */ - public function setOrgConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryConfig\OrgConfig::class); - $this->org_config = $var; - - return $this; - } - - /** - * Detection logic for profile generation. - * Not all template features are used by Discovery. FindingLimits, - * include_quote and exclude_info_types have no impact on - * Discovery. - * Multiple templates may be provided if there is data in multiple regions. - * At most one template must be specified per-region (including "global"). - * Each region is scanned using the applicable template. If no region-specific - * template is specified, but a "global" template is specified, it will be - * copied to that region and used instead. If no global or region-specific - * template is provided for a region with data, that region's data will not be - * scanned. - * For more information, see - * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. - * - * Generated from protobuf field repeated string inspect_templates = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInspectTemplates() - { - return $this->inspect_templates; - } - - /** - * Detection logic for profile generation. - * Not all template features are used by Discovery. FindingLimits, - * include_quote and exclude_info_types have no impact on - * Discovery. - * Multiple templates may be provided if there is data in multiple regions. - * At most one template must be specified per-region (including "global"). - * Each region is scanned using the applicable template. If no region-specific - * template is specified, but a "global" template is specified, it will be - * copied to that region and used instead. If no global or region-specific - * template is provided for a region with data, that region's data will not be - * scanned. - * For more information, see - * https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. - * - * Generated from protobuf field repeated string inspect_templates = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInspectTemplates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->inspect_templates = $arr; - - return $this; - } - - /** - * Actions to execute at the completion of scanning. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfileAction actions = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getActions() - { - return $this->actions; - } - - /** - * Actions to execute at the completion of scanning. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DataProfileAction actions = 4; - * @param array<\Google\Cloud\Dlp\V2\DataProfileAction>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setActions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DataProfileAction::class); - $this->actions = $arr; - - return $this; - } - - /** - * Target to match against for determining what to scan and how frequently. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryTarget targets = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTargets() - { - return $this->targets; - } - - /** - * Target to match against for determining what to scan and how frequently. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryTarget targets = 5; - * @param array<\Google\Cloud\Dlp\V2\DiscoveryTarget>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTargets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DiscoveryTarget::class); - $this->targets = $arr; - - return $this; - } - - /** - * Output only. A stream of errors encountered when the config was activated. - * Repeated errors may result in the config automatically being paused. Output - * only field. Will return the last 100 errors. Whenever the config is - * modified this list will be cleared. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getErrors() - { - return $this->errors; - } - - /** - * Output only. A stream of errors encountered when the config was activated. - * Repeated errors may result in the config automatically being paused. Output - * only field. Will return the last 100 errors. Whenever the config is - * modified this list will be cleared. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setErrors($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Error::class); - $this->errors = $arr; - - return $this; - } - - /** - * Output only. The creation timestamp of a DiscoveryConfig. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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 creation timestamp of a DiscoveryConfig. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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 last update timestamp of a DiscoveryConfig. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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 last update timestamp of a DiscoveryConfig. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Output only. The timestamp of the last time this config was executed. - * - * Generated from protobuf field .google.protobuf.Timestamp last_run_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getLastRunTime() - { - return $this->last_run_time; - } - - public function hasLastRunTime() - { - return isset($this->last_run_time); - } - - public function clearLastRunTime() - { - unset($this->last_run_time); - } - - /** - * Output only. The timestamp of the last time this config was executed. - * - * Generated from protobuf field .google.protobuf.Timestamp last_run_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setLastRunTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->last_run_time = $var; - - return $this; - } - - /** - * Required. A status for this configuration. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig.Status status = 10 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getStatus() - { - return $this->status; - } - - /** - * Required. A status for this configuration. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig.Status status = 10 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DiscoveryConfig\Status::class); - $this->status = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/OrgConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/OrgConfig.php deleted file mode 100644 index f562a26a05a6..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/OrgConfig.php +++ /dev/null @@ -1,122 +0,0 @@ -google.privacy.dlp.v2.DiscoveryConfig.OrgConfig - */ -class OrgConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The data to scan: folder, org, or project - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryStartingLocation location = 1; - */ - protected $location = null; - /** - * The project that will run the scan. The DLP service - * account that exists within this project must have access to all resources - * that are profiled, and the Cloud DLP API must be enabled. - * - * Generated from protobuf field string project_id = 2; - */ - protected $project_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DiscoveryStartingLocation $location - * The data to scan: folder, org, or project - * @type string $project_id - * The project that will run the scan. The DLP service - * account that exists within this project must have access to all resources - * that are profiled, and the Cloud DLP API must be enabled. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The data to scan: folder, org, or project - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryStartingLocation location = 1; - * @return \Google\Cloud\Dlp\V2\DiscoveryStartingLocation|null - */ - public function getLocation() - { - return $this->location; - } - - public function hasLocation() - { - return isset($this->location); - } - - public function clearLocation() - { - unset($this->location); - } - - /** - * The data to scan: folder, org, or project - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryStartingLocation location = 1; - * @param \Google\Cloud\Dlp\V2\DiscoveryStartingLocation $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryStartingLocation::class); - $this->location = $var; - - return $this; - } - - /** - * The project that will run the scan. The DLP service - * account that exists within this project must have access to all resources - * that are profiled, and the Cloud DLP API must be enabled. - * - * Generated from protobuf field string project_id = 2; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * The project that will run the scan. The DLP service - * account that exists within this project must have access to all resources - * that are profiled, and the Cloud DLP API must be enabled. - * - * 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; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(OrgConfig::class, \Google\Cloud\Dlp\V2\DiscoveryConfig_OrgConfig::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/Status.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/Status.php deleted file mode 100644 index 64226233f6e9..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryConfig/Status.php +++ /dev/null @@ -1,65 +0,0 @@ -google.privacy.dlp.v2.DiscoveryConfig.Status - */ -class Status -{ - /** - * Unused - * - * Generated from protobuf enum STATUS_UNSPECIFIED = 0; - */ - const STATUS_UNSPECIFIED = 0; - /** - * The discovery config is currently active. - * - * Generated from protobuf enum RUNNING = 1; - */ - const RUNNING = 1; - /** - * The discovery config is paused temporarily. - * - * Generated from protobuf enum PAUSED = 2; - */ - const PAUSED = 2; - - private static $valueToName = [ - self::STATUS_UNSPECIFIED => 'STATUS_UNSPECIFIED', - self::RUNNING => 'RUNNING', - self::PAUSED => 'PAUSED', - ]; - - 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(Status::class, \Google\Cloud\Dlp\V2\DiscoveryConfig_Status::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryGenerationCadence.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryGenerationCadence.php deleted file mode 100644 index 5e0977e435b4..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryGenerationCadence.php +++ /dev/null @@ -1,124 +0,0 @@ -google.privacy.dlp.v2.DiscoveryGenerationCadence - */ -class DiscoveryGenerationCadence extends \Google\Protobuf\Internal\Message -{ - /** - * Governs when to update data profiles when a schema is modified. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoverySchemaModifiedCadence schema_modified_cadence = 1; - */ - protected $schema_modified_cadence = null; - /** - * Governs when to update data profiles when a table is modified. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryTableModifiedCadence table_modified_cadence = 2; - */ - protected $table_modified_cadence = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DiscoverySchemaModifiedCadence $schema_modified_cadence - * Governs when to update data profiles when a schema is modified. - * @type \Google\Cloud\Dlp\V2\DiscoveryTableModifiedCadence $table_modified_cadence - * Governs when to update data profiles when a table is modified. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Governs when to update data profiles when a schema is modified. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoverySchemaModifiedCadence schema_modified_cadence = 1; - * @return \Google\Cloud\Dlp\V2\DiscoverySchemaModifiedCadence|null - */ - public function getSchemaModifiedCadence() - { - return $this->schema_modified_cadence; - } - - public function hasSchemaModifiedCadence() - { - return isset($this->schema_modified_cadence); - } - - public function clearSchemaModifiedCadence() - { - unset($this->schema_modified_cadence); - } - - /** - * Governs when to update data profiles when a schema is modified. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoverySchemaModifiedCadence schema_modified_cadence = 1; - * @param \Google\Cloud\Dlp\V2\DiscoverySchemaModifiedCadence $var - * @return $this - */ - public function setSchemaModifiedCadence($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoverySchemaModifiedCadence::class); - $this->schema_modified_cadence = $var; - - return $this; - } - - /** - * Governs when to update data profiles when a table is modified. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryTableModifiedCadence table_modified_cadence = 2; - * @return \Google\Cloud\Dlp\V2\DiscoveryTableModifiedCadence|null - */ - public function getTableModifiedCadence() - { - return $this->table_modified_cadence; - } - - public function hasTableModifiedCadence() - { - return isset($this->table_modified_cadence); - } - - public function clearTableModifiedCadence() - { - unset($this->table_modified_cadence); - } - - /** - * Governs when to update data profiles when a table is modified. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryTableModifiedCadence table_modified_cadence = 2; - * @param \Google\Cloud\Dlp\V2\DiscoveryTableModifiedCadence $var - * @return $this - */ - public function setTableModifiedCadence($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryTableModifiedCadence::class); - $this->table_modified_cadence = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoverySchemaModifiedCadence.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoverySchemaModifiedCadence.php deleted file mode 100644 index 0fa1784d3daf..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoverySchemaModifiedCadence.php +++ /dev/null @@ -1,113 +0,0 @@ -google.privacy.dlp.v2.DiscoverySchemaModifiedCadence - */ -class DiscoverySchemaModifiedCadence extends \Google\Protobuf\Internal\Message -{ - /** - * The type of events to consider when deciding if the table's schema - * has been modified and should have the profile updated. Defaults to - * NEW_COLUMNS. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQuerySchemaModification types = 1; - */ - private $types; - /** - * How frequently profiles may be updated when schemas are - * modified. Defaults to monthly. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; - */ - protected $frequency = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $types - * The type of events to consider when deciding if the table's schema - * has been modified and should have the profile updated. Defaults to - * NEW_COLUMNS. - * @type int $frequency - * How frequently profiles may be updated when schemas are - * modified. Defaults to monthly. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The type of events to consider when deciding if the table's schema - * has been modified and should have the profile updated. Defaults to - * NEW_COLUMNS. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQuerySchemaModification types = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTypes() - { - return $this->types; - } - - /** - * The type of events to consider when deciding if the table's schema - * has been modified and should have the profile updated. Defaults to - * NEW_COLUMNS. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQuerySchemaModification types = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\BigQuerySchemaModification::class); - $this->types = $arr; - - return $this; - } - - /** - * How frequently profiles may be updated when schemas are - * modified. Defaults to monthly. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; - * @return int - */ - public function getFrequency() - { - return $this->frequency; - } - - /** - * How frequently profiles may be updated when schemas are - * modified. Defaults to monthly. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; - * @param int $var - * @return $this - */ - public function setFrequency($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileUpdateFrequency::class); - $this->frequency = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryStartingLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryStartingLocation.php deleted file mode 100644 index 702d9f4d5bbc..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryStartingLocation.php +++ /dev/null @@ -1,109 +0,0 @@ -google.privacy.dlp.v2.DiscoveryStartingLocation - */ -class DiscoveryStartingLocation extends \Google\Protobuf\Internal\Message -{ - protected $location; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $organization_id - * The ID of an organization to scan. - * @type int|string $folder_id - * The ID of the Folder within an organization to scan. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The ID of an organization to scan. - * - * Generated from protobuf field int64 organization_id = 1; - * @return int|string - */ - public function getOrganizationId() - { - return $this->readOneof(1); - } - - public function hasOrganizationId() - { - return $this->hasOneof(1); - } - - /** - * The ID of an organization to scan. - * - * Generated from protobuf field int64 organization_id = 1; - * @param int|string $var - * @return $this - */ - public function setOrganizationId($var) - { - GPBUtil::checkInt64($var); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The ID of the Folder within an organization to scan. - * - * Generated from protobuf field int64 folder_id = 2; - * @return int|string - */ - public function getFolderId() - { - return $this->readOneof(2); - } - - public function hasFolderId() - { - return $this->hasOneof(2); - } - - /** - * The ID of the Folder within an organization to scan. - * - * Generated from protobuf field int64 folder_id = 2; - * @param int|string $var - * @return $this - */ - public function setFolderId($var) - { - GPBUtil::checkInt64($var); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getLocation() - { - return $this->whichOneof("location"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTableModifiedCadence.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTableModifiedCadence.php deleted file mode 100644 index 41c4460b6233..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTableModifiedCadence.php +++ /dev/null @@ -1,113 +0,0 @@ -google.privacy.dlp.v2.DiscoveryTableModifiedCadence - */ -class DiscoveryTableModifiedCadence extends \Google\Protobuf\Internal\Message -{ - /** - * The type of events to consider when deciding if the table has been - * modified and should have the profile updated. Defaults to - * MODIFIED_TIMESTAMP. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryTableModification types = 1; - */ - private $types; - /** - * How frequently data profiles can be updated when tables are modified. - * Defaults to never. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; - */ - protected $frequency = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $types - * The type of events to consider when deciding if the table has been - * modified and should have the profile updated. Defaults to - * MODIFIED_TIMESTAMP. - * @type int $frequency - * How frequently data profiles can be updated when tables are modified. - * Defaults to never. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The type of events to consider when deciding if the table has been - * modified and should have the profile updated. Defaults to - * MODIFIED_TIMESTAMP. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryTableModification types = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTypes() - { - return $this->types; - } - - /** - * The type of events to consider when deciding if the table has been - * modified and should have the profile updated. Defaults to - * MODIFIED_TIMESTAMP. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BigQueryTableModification types = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\BigQueryTableModification::class); - $this->types = $arr; - - return $this; - } - - /** - * How frequently data profiles can be updated when tables are modified. - * Defaults to never. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; - * @return int - */ - public function getFrequency() - { - return $this->frequency; - } - - /** - * How frequently data profiles can be updated when tables are modified. - * Defaults to never. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileUpdateFrequency frequency = 2; - * @param int $var - * @return $this - */ - public function setFrequency($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DataProfileUpdateFrequency::class); - $this->frequency = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTarget.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTarget.php deleted file mode 100644 index b9b4cc728e9b..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DiscoveryTarget.php +++ /dev/null @@ -1,153 +0,0 @@ -google.privacy.dlp.v2.DiscoveryTarget - */ -class DiscoveryTarget extends \Google\Protobuf\Internal\Message -{ - protected $target; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\BigQueryDiscoveryTarget $big_query_target - * BigQuery target for Discovery. The first target to match a table will be - * the one applied. - * @type \Google\Cloud\Dlp\V2\CloudSqlDiscoveryTarget $cloud_sql_target - * Cloud SQL target for Discovery. The first target to match a table will be - * the one applied. - * @type \Google\Cloud\Dlp\V2\SecretsDiscoveryTarget $secrets_target - * Discovery target that looks for credentials and secrets stored in cloud - * resource metadata and reports them as vulnerabilities to Security Command - * Center. Only one target of this type is allowed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * BigQuery target for Discovery. The first target to match a table will be - * the one applied. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryDiscoveryTarget big_query_target = 1; - * @return \Google\Cloud\Dlp\V2\BigQueryDiscoveryTarget|null - */ - public function getBigQueryTarget() - { - return $this->readOneof(1); - } - - public function hasBigQueryTarget() - { - return $this->hasOneof(1); - } - - /** - * BigQuery target for Discovery. The first target to match a table will be - * the one applied. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryDiscoveryTarget big_query_target = 1; - * @param \Google\Cloud\Dlp\V2\BigQueryDiscoveryTarget $var - * @return $this - */ - public function setBigQueryTarget($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryDiscoveryTarget::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Cloud SQL target for Discovery. The first target to match a table will be - * the one applied. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlDiscoveryTarget cloud_sql_target = 2; - * @return \Google\Cloud\Dlp\V2\CloudSqlDiscoveryTarget|null - */ - public function getCloudSqlTarget() - { - return $this->readOneof(2); - } - - public function hasCloudSqlTarget() - { - return $this->hasOneof(2); - } - - /** - * Cloud SQL target for Discovery. The first target to match a table will be - * the one applied. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudSqlDiscoveryTarget cloud_sql_target = 2; - * @param \Google\Cloud\Dlp\V2\CloudSqlDiscoveryTarget $var - * @return $this - */ - public function setCloudSqlTarget($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudSqlDiscoveryTarget::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Discovery target that looks for credentials and secrets stored in cloud - * resource metadata and reports them as vulnerabilities to Security Command - * Center. Only one target of this type is allowed. - * - * Generated from protobuf field .google.privacy.dlp.v2.SecretsDiscoveryTarget secrets_target = 3; - * @return \Google\Cloud\Dlp\V2\SecretsDiscoveryTarget|null - */ - public function getSecretsTarget() - { - return $this->readOneof(3); - } - - public function hasSecretsTarget() - { - return $this->hasOneof(3); - } - - /** - * Discovery target that looks for credentials and secrets stored in cloud - * resource metadata and reports them as vulnerabilities to Security Command - * Center. Only one target of this type is allowed. - * - * Generated from protobuf field .google.privacy.dlp.v2.SecretsDiscoveryTarget secrets_target = 3; - * @param \Google\Cloud\Dlp\V2\SecretsDiscoveryTarget $var - * @return $this - */ - public function setSecretsTarget($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SecretsDiscoveryTarget::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getTarget() - { - return $this->whichOneof("target"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob.php deleted file mode 100644 index 9bd92b2beccb..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob.php +++ /dev/null @@ -1,492 +0,0 @@ -google.privacy.dlp.v2.DlpJob - */ -class DlpJob extends \Google\Protobuf\Internal\Message -{ - /** - * The server-assigned name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The type of job. - * - * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 2; - */ - protected $type = 0; - /** - * State of a job. - * - * Generated from protobuf field .google.privacy.dlp.v2.DlpJob.JobState state = 3; - */ - protected $state = 0; - /** - * Time when the job was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; - */ - protected $create_time = null; - /** - * Time when the job started. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 7; - */ - protected $start_time = null; - /** - * Time when the job finished. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 8; - */ - protected $end_time = null; - /** - * Time when the job was last modified by the system. - * - * Generated from protobuf field .google.protobuf.Timestamp last_modified = 15; - */ - protected $last_modified = null; - /** - * If created by a job trigger, the resource name of the trigger that - * instantiated the job. - * - * Generated from protobuf field string job_trigger_name = 10; - */ - protected $job_trigger_name = ''; - /** - * A stream of errors encountered running the job. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 11; - */ - private $errors; - /** - * Events that should occur after the job has completed. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ActionDetails action_details = 12; - */ - private $action_details; - protected $details; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The server-assigned name. - * @type int $type - * The type of job. - * @type int $state - * State of a job. - * @type \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails $risk_details - * Results from analyzing risk of a data source. - * @type \Google\Cloud\Dlp\V2\InspectDataSourceDetails $inspect_details - * Results from inspecting a data source. - * @type \Google\Protobuf\Timestamp $create_time - * Time when the job was created. - * @type \Google\Protobuf\Timestamp $start_time - * Time when the job started. - * @type \Google\Protobuf\Timestamp $end_time - * Time when the job finished. - * @type \Google\Protobuf\Timestamp $last_modified - * Time when the job was last modified by the system. - * @type string $job_trigger_name - * If created by a job trigger, the resource name of the trigger that - * instantiated the job. - * @type array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $errors - * A stream of errors encountered running the job. - * @type array<\Google\Cloud\Dlp\V2\ActionDetails>|\Google\Protobuf\Internal\RepeatedField $action_details - * Events that should occur after the job has completed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The server-assigned name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The server-assigned 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; - } - - /** - * The type of job. - * - * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 2; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The type of job. - * - * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 2; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DlpJobType::class); - $this->type = $var; - - return $this; - } - - /** - * State of a job. - * - * Generated from protobuf field .google.privacy.dlp.v2.DlpJob.JobState state = 3; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * State of a job. - * - * Generated from protobuf field .google.privacy.dlp.v2.DlpJob.JobState state = 3; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DlpJob\JobState::class); - $this->state = $var; - - return $this; - } - - /** - * Results from analyzing risk of a data source. - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails risk_details = 4; - * @return \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails|null - */ - public function getRiskDetails() - { - return $this->readOneof(4); - } - - public function hasRiskDetails() - { - return $this->hasOneof(4); - } - - /** - * Results from analyzing risk of a data source. - * - * Generated from protobuf field .google.privacy.dlp.v2.AnalyzeDataSourceRiskDetails risk_details = 4; - * @param \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails $var - * @return $this - */ - public function setRiskDetails($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Results from inspecting a data source. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails inspect_details = 5; - * @return \Google\Cloud\Dlp\V2\InspectDataSourceDetails|null - */ - public function getInspectDetails() - { - return $this->readOneof(5); - } - - public function hasInspectDetails() - { - return $this->hasOneof(5); - } - - /** - * Results from inspecting a data source. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails inspect_details = 5; - * @param \Google\Cloud\Dlp\V2\InspectDataSourceDetails $var - * @return $this - */ - public function setInspectDetails($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectDataSourceDetails::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Time when the job 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); - } - - /** - * Time when the job 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; - } - - /** - * Time when the job started. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 7; - * @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 when the job started. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 7; - * @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 when the job finished. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 8; - * @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 when the job finished. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 8; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Time when the job was last modified by the system. - * - * Generated from protobuf field .google.protobuf.Timestamp last_modified = 15; - * @return \Google\Protobuf\Timestamp|null - */ - public function getLastModified() - { - return $this->last_modified; - } - - public function hasLastModified() - { - return isset($this->last_modified); - } - - public function clearLastModified() - { - unset($this->last_modified); - } - - /** - * Time when the job was last modified by the system. - * - * Generated from protobuf field .google.protobuf.Timestamp last_modified = 15; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setLastModified($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->last_modified = $var; - - return $this; - } - - /** - * If created by a job trigger, the resource name of the trigger that - * instantiated the job. - * - * Generated from protobuf field string job_trigger_name = 10; - * @return string - */ - public function getJobTriggerName() - { - return $this->job_trigger_name; - } - - /** - * If created by a job trigger, the resource name of the trigger that - * instantiated the job. - * - * Generated from protobuf field string job_trigger_name = 10; - * @param string $var - * @return $this - */ - public function setJobTriggerName($var) - { - GPBUtil::checkString($var, True); - $this->job_trigger_name = $var; - - return $this; - } - - /** - * A stream of errors encountered running the job. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 11; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getErrors() - { - return $this->errors; - } - - /** - * A stream of errors encountered running the job. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 11; - * @param array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setErrors($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Error::class); - $this->errors = $arr; - - return $this; - } - - /** - * Events that should occur after the job has completed. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ActionDetails action_details = 12; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getActionDetails() - { - return $this->action_details; - } - - /** - * Events that should occur after the job has completed. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ActionDetails action_details = 12; - * @param array<\Google\Cloud\Dlp\V2\ActionDetails>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setActionDetails($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ActionDetails::class); - $this->action_details = $arr; - - return $this; - } - - /** - * @return string - */ - public function getDetails() - { - return $this->whichOneof("details"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob/JobState.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob/JobState.php deleted file mode 100644 index 5ba68c696f63..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJob/JobState.php +++ /dev/null @@ -1,96 +0,0 @@ -google.privacy.dlp.v2.DlpJob.JobState - */ -class JobState -{ - /** - * Unused. - * - * Generated from protobuf enum JOB_STATE_UNSPECIFIED = 0; - */ - const JOB_STATE_UNSPECIFIED = 0; - /** - * The job has not yet started. - * - * Generated from protobuf enum PENDING = 1; - */ - const PENDING = 1; - /** - * The job is currently running. Once a job has finished it will transition - * to FAILED or DONE. - * - * Generated from protobuf enum RUNNING = 2; - */ - const RUNNING = 2; - /** - * The job is no longer running. - * - * Generated from protobuf enum DONE = 3; - */ - const DONE = 3; - /** - * The job was canceled before it could be completed. - * - * Generated from protobuf enum CANCELED = 4; - */ - const CANCELED = 4; - /** - * The job had an error and did not complete. - * - * Generated from protobuf enum FAILED = 5; - */ - const FAILED = 5; - /** - * The job is currently accepting findings via hybridInspect. - * A hybrid job in ACTIVE state may continue to have findings added to it - * through the calling of hybridInspect. After the job has finished no more - * calls to hybridInspect may be made. ACTIVE jobs can transition to DONE. - * - * Generated from protobuf enum ACTIVE = 6; - */ - const ACTIVE = 6; - - private static $valueToName = [ - self::JOB_STATE_UNSPECIFIED => 'JOB_STATE_UNSPECIFIED', - self::PENDING => 'PENDING', - self::RUNNING => 'RUNNING', - self::DONE => 'DONE', - self::CANCELED => 'CANCELED', - self::FAILED => 'FAILED', - self::ACTIVE => 'ACTIVE', - ]; - - 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(JobState::class, \Google\Cloud\Dlp\V2\DlpJob_JobState::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJobType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJobType.php deleted file mode 100644 index c34fc91f3d4f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DlpJobType.php +++ /dev/null @@ -1,61 +0,0 @@ -google.privacy.dlp.v2.DlpJobType - */ -class DlpJobType -{ - /** - * Defaults to INSPECT_JOB. - * - * Generated from protobuf enum DLP_JOB_TYPE_UNSPECIFIED = 0; - */ - const DLP_JOB_TYPE_UNSPECIFIED = 0; - /** - * The job inspected Google Cloud for sensitive data. - * - * Generated from protobuf enum INSPECT_JOB = 1; - */ - const INSPECT_JOB = 1; - /** - * The job executed a Risk Analysis computation. - * - * Generated from protobuf enum RISK_ANALYSIS_JOB = 2; - */ - const RISK_ANALYSIS_JOB = 2; - - private static $valueToName = [ - self::DLP_JOB_TYPE_UNSPECIFIED => 'DLP_JOB_TYPE_UNSPECIFIED', - self::INSPECT_JOB => 'INSPECT_JOB', - self::RISK_ANALYSIS_JOB => 'RISK_ANALYSIS_JOB', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DocumentLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DocumentLocation.php deleted file mode 100644 index 1abf21ab6a0b..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/DocumentLocation.php +++ /dev/null @@ -1,71 +0,0 @@ -google.privacy.dlp.v2.DocumentLocation - */ -class DocumentLocation extends \Google\Protobuf\Internal\Message -{ - /** - * Offset of the line, from the beginning of the file, where the finding - * is located. - * - * Generated from protobuf field int64 file_offset = 1; - */ - protected $file_offset = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $file_offset - * Offset of the line, from the beginning of the file, where the finding - * is located. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Offset of the line, from the beginning of the file, where the finding - * is located. - * - * Generated from protobuf field int64 file_offset = 1; - * @return int|string - */ - public function getFileOffset() - { - return $this->file_offset; - } - - /** - * Offset of the line, from the beginning of the file, where the finding - * is located. - * - * Generated from protobuf field int64 file_offset = 1; - * @param int|string $var - * @return $this - */ - public function setFileOffset($var) - { - GPBUtil::checkInt64($var); - $this->file_offset = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EncryptionStatus.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EncryptionStatus.php deleted file mode 100644 index a21080206e59..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EncryptionStatus.php +++ /dev/null @@ -1,61 +0,0 @@ -google.privacy.dlp.v2.EncryptionStatus - */ -class EncryptionStatus -{ - /** - * Unused. - * - * Generated from protobuf enum ENCRYPTION_STATUS_UNSPECIFIED = 0; - */ - const ENCRYPTION_STATUS_UNSPECIFIED = 0; - /** - * Google manages server-side encryption keys on your behalf. - * - * Generated from protobuf enum ENCRYPTION_GOOGLE_MANAGED = 1; - */ - const ENCRYPTION_GOOGLE_MANAGED = 1; - /** - * Customer provides the key. - * - * Generated from protobuf enum ENCRYPTION_CUSTOMER_MANAGED = 2; - */ - const ENCRYPTION_CUSTOMER_MANAGED = 2; - - private static $valueToName = [ - self::ENCRYPTION_STATUS_UNSPECIFIED => 'ENCRYPTION_STATUS_UNSPECIFIED', - self::ENCRYPTION_GOOGLE_MANAGED => 'ENCRYPTION_GOOGLE_MANAGED', - self::ENCRYPTION_CUSTOMER_MANAGED => 'ENCRYPTION_CUSTOMER_MANAGED', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EntityId.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EntityId.php deleted file mode 100644 index 5600e90f2b91..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/EntityId.php +++ /dev/null @@ -1,81 +0,0 @@ -google.privacy.dlp.v2.EntityId - */ -class EntityId extends \Google\Protobuf\Internal\Message -{ - /** - * Composite key indicating which field contains the entity identifier. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - */ - protected $field = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\FieldId $field - * Composite key indicating which field contains the entity identifier. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Composite key indicating which field contains the entity identifier. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getField() - { - return $this->field; - } - - public function hasField() - { - return isset($this->field); - } - - public function clearField() - { - unset($this->field); - } - - /** - * Composite key indicating which field contains the entity identifier. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setField($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->field = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Error.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Error.php deleted file mode 100644 index c05eba7d7098..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Error.php +++ /dev/null @@ -1,116 +0,0 @@ -google.privacy.dlp.v2.Error - */ -class Error extends \Google\Protobuf\Internal\Message -{ - /** - * Detailed error codes and messages. - * - * Generated from protobuf field .google.rpc.Status details = 1; - */ - protected $details = null; - /** - * The times the error occurred. List includes the oldest timestamp and the - * last 9 timestamps. - * - * Generated from protobuf field repeated .google.protobuf.Timestamp timestamps = 2; - */ - private $timestamps; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Rpc\Status $details - * Detailed error codes and messages. - * @type array<\Google\Protobuf\Timestamp>|\Google\Protobuf\Internal\RepeatedField $timestamps - * The times the error occurred. List includes the oldest timestamp and the - * last 9 timestamps. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Detailed error codes and messages. - * - * Generated from protobuf field .google.rpc.Status details = 1; - * @return \Google\Rpc\Status|null - */ - public function getDetails() - { - return $this->details; - } - - public function hasDetails() - { - return isset($this->details); - } - - public function clearDetails() - { - unset($this->details); - } - - /** - * Detailed error codes and messages. - * - * Generated from protobuf field .google.rpc.Status details = 1; - * @param \Google\Rpc\Status $var - * @return $this - */ - public function setDetails($var) - { - GPBUtil::checkMessage($var, \Google\Rpc\Status::class); - $this->details = $var; - - return $this; - } - - /** - * The times the error occurred. List includes the oldest timestamp and the - * last 9 timestamps. - * - * Generated from protobuf field repeated .google.protobuf.Timestamp timestamps = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTimestamps() - { - return $this->timestamps; - } - - /** - * The times the error occurred. List includes the oldest timestamp and the - * last 9 timestamps. - * - * Generated from protobuf field repeated .google.protobuf.Timestamp timestamps = 2; - * @param array<\Google\Protobuf\Timestamp>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTimestamps($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Timestamp::class); - $this->timestamps = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeByHotword.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeByHotword.php deleted file mode 100644 index b36a1ee82195..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeByHotword.php +++ /dev/null @@ -1,136 +0,0 @@ -google.privacy.dlp.v2.ExcludeByHotword - */ -class ExcludeByHotword extends \Google\Protobuf\Internal\Message -{ - /** - * Regular expression pattern defining what qualifies as a hotword. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex hotword_regex = 1; - */ - protected $hotword_regex = null; - /** - * Range of characters within which the entire hotword must reside. - * The total length of the window cannot exceed 1000 characters. - * The windowBefore property in proximity should be set to 1 if the hotword - * needs to be included in a column header. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity proximity = 2; - */ - protected $proximity = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\CustomInfoType\Regex $hotword_regex - * Regular expression pattern defining what qualifies as a hotword. - * @type \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity $proximity - * Range of characters within which the entire hotword must reside. - * The total length of the window cannot exceed 1000 characters. - * The windowBefore property in proximity should be set to 1 if the hotword - * needs to be included in a column header. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Regular expression pattern defining what qualifies as a hotword. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex hotword_regex = 1; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\Regex|null - */ - public function getHotwordRegex() - { - return $this->hotword_regex; - } - - public function hasHotwordRegex() - { - return isset($this->hotword_regex); - } - - public function clearHotwordRegex() - { - unset($this->hotword_regex); - } - - /** - * Regular expression pattern defining what qualifies as a hotword. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex hotword_regex = 1; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\Regex $var - * @return $this - */ - public function setHotwordRegex($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Regex::class); - $this->hotword_regex = $var; - - return $this; - } - - /** - * Range of characters within which the entire hotword must reside. - * The total length of the window cannot exceed 1000 characters. - * The windowBefore property in proximity should be set to 1 if the hotword - * needs to be included in a column header. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity proximity = 2; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity|null - */ - public function getProximity() - { - return $this->proximity; - } - - public function hasProximity() - { - return isset($this->proximity); - } - - public function clearProximity() - { - unset($this->proximity); - } - - /** - * Range of characters within which the entire hotword must reside. - * The total length of the window cannot exceed 1000 characters. - * The windowBefore property in proximity should be set to 1 if the hotword - * needs to be included in a column header. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.Proximity proximity = 2; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity $var - * @return $this - */ - public function setProximity($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\Proximity::class); - $this->proximity = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeInfoTypes.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeInfoTypes.php deleted file mode 100644 index bf9b02b680a5..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExcludeInfoTypes.php +++ /dev/null @@ -1,95 +0,0 @@ -google.privacy.dlp.v2.ExcludeInfoTypes - */ -class ExcludeInfoTypes extends \Google\Protobuf\Internal\Message -{ - /** - * InfoType list in ExclusionRule rule drops a finding when it overlaps or - * contained within with a finding of an infoType from this list. For - * example, for `InspectionRuleSet.info_types` containing "PHONE_NUMBER"` and - * `exclusion_rule` containing `exclude_info_types.info_types` with - * "EMAIL_ADDRESS" the phone number findings are dropped if they overlap - * with EMAIL_ADDRESS finding. - * That leads to "555-222-2222@example.org" to generate only a single - * finding, namely email address. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; - */ - private $info_types; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $info_types - * InfoType list in ExclusionRule rule drops a finding when it overlaps or - * contained within with a finding of an infoType from this list. For - * example, for `InspectionRuleSet.info_types` containing "PHONE_NUMBER"` and - * `exclusion_rule` containing `exclude_info_types.info_types` with - * "EMAIL_ADDRESS" the phone number findings are dropped if they overlap - * with EMAIL_ADDRESS finding. - * That leads to "555-222-2222@example.org" to generate only a single - * finding, namely email address. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * InfoType list in ExclusionRule rule drops a finding when it overlaps or - * contained within with a finding of an infoType from this list. For - * example, for `InspectionRuleSet.info_types` containing "PHONE_NUMBER"` and - * `exclusion_rule` containing `exclude_info_types.info_types` with - * "EMAIL_ADDRESS" the phone number findings are dropped if they overlap - * with EMAIL_ADDRESS finding. - * That leads to "555-222-2222@example.org" to generate only a single - * finding, namely email address. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInfoTypes() - { - return $this->info_types; - } - - /** - * InfoType list in ExclusionRule rule drops a finding when it overlaps or - * contained within with a finding of an infoType from this list. For - * example, for `InspectionRuleSet.info_types` containing "PHONE_NUMBER"` and - * `exclusion_rule` containing `exclude_info_types.info_types` with - * "EMAIL_ADDRESS" the phone number findings are dropped if they overlap - * with EMAIL_ADDRESS finding. - * That leads to "555-222-2222@example.org" to generate only a single - * finding, namely email address. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; - * @param array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInfoTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_types = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExclusionRule.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExclusionRule.php deleted file mode 100644 index c238c2b9417d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ExclusionRule.php +++ /dev/null @@ -1,212 +0,0 @@ -google.privacy.dlp.v2.ExclusionRule - */ -class ExclusionRule extends \Google\Protobuf\Internal\Message -{ - /** - * How the rule is applied, see MatchingType documentation for details. - * - * Generated from protobuf field .google.privacy.dlp.v2.MatchingType matching_type = 4; - */ - protected $matching_type = 0; - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary $dictionary - * Dictionary which defines the rule. - * @type \Google\Cloud\Dlp\V2\CustomInfoType\Regex $regex - * Regular expression which defines the rule. - * @type \Google\Cloud\Dlp\V2\ExcludeInfoTypes $exclude_info_types - * Set of infoTypes for which findings would affect this rule. - * @type \Google\Cloud\Dlp\V2\ExcludeByHotword $exclude_by_hotword - * Drop if the hotword rule is contained in the proximate context. For - * tabular data, the context includes the column name. - * @type int $matching_type - * How the rule is applied, see MatchingType documentation for details. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Dictionary which defines the rule. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary dictionary = 1; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary|null - */ - public function getDictionary() - { - return $this->readOneof(1); - } - - public function hasDictionary() - { - return $this->hasOneof(1); - } - - /** - * Dictionary which defines the rule. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary dictionary = 1; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary $var - * @return $this - */ - public function setDictionary($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Regular expression which defines the rule. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex regex = 2; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\Regex|null - */ - public function getRegex() - { - return $this->readOneof(2); - } - - public function hasRegex() - { - return $this->hasOneof(2); - } - - /** - * Regular expression which defines the rule. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex regex = 2; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\Regex $var - * @return $this - */ - public function setRegex($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Regex::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Set of infoTypes for which findings would affect this rule. - * - * Generated from protobuf field .google.privacy.dlp.v2.ExcludeInfoTypes exclude_info_types = 3; - * @return \Google\Cloud\Dlp\V2\ExcludeInfoTypes|null - */ - public function getExcludeInfoTypes() - { - return $this->readOneof(3); - } - - public function hasExcludeInfoTypes() - { - return $this->hasOneof(3); - } - - /** - * Set of infoTypes for which findings would affect this rule. - * - * Generated from protobuf field .google.privacy.dlp.v2.ExcludeInfoTypes exclude_info_types = 3; - * @param \Google\Cloud\Dlp\V2\ExcludeInfoTypes $var - * @return $this - */ - public function setExcludeInfoTypes($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ExcludeInfoTypes::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Drop if the hotword rule is contained in the proximate context. For - * tabular data, the context includes the column name. - * - * Generated from protobuf field .google.privacy.dlp.v2.ExcludeByHotword exclude_by_hotword = 5; - * @return \Google\Cloud\Dlp\V2\ExcludeByHotword|null - */ - public function getExcludeByHotword() - { - return $this->readOneof(5); - } - - public function hasExcludeByHotword() - { - return $this->hasOneof(5); - } - - /** - * Drop if the hotword rule is contained in the proximate context. For - * tabular data, the context includes the column name. - * - * Generated from protobuf field .google.privacy.dlp.v2.ExcludeByHotword exclude_by_hotword = 5; - * @param \Google\Cloud\Dlp\V2\ExcludeByHotword $var - * @return $this - */ - public function setExcludeByHotword($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ExcludeByHotword::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * How the rule is applied, see MatchingType documentation for details. - * - * Generated from protobuf field .google.privacy.dlp.v2.MatchingType matching_type = 4; - * @return int - */ - public function getMatchingType() - { - return $this->matching_type; - } - - /** - * How the rule is applied, see MatchingType documentation for details. - * - * Generated from protobuf field .google.privacy.dlp.v2.MatchingType matching_type = 4; - * @param int $var - * @return $this - */ - public function setMatchingType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\MatchingType::class); - $this->matching_type = $var; - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldId.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldId.php deleted file mode 100644 index 2cdfe5bc25cf..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldId.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.FieldId - */ -class FieldId extends \Google\Protobuf\Internal\Message -{ - /** - * Name describing the field. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name describing the field. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Name describing the field. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name describing the field. - * - * 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; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldTransformation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldTransformation.php deleted file mode 100644 index 3f7a9a39e9e2..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FieldTransformation.php +++ /dev/null @@ -1,225 +0,0 @@ -google.privacy.dlp.v2.FieldTransformation - */ -class FieldTransformation extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Input field(s) to apply the transformation to. - * When you have columns that reference their position within a list, - * omit the index from the FieldId. FieldId name matching ignores the index. - * For example, instead of "contact.nums[0].type", use "contact.nums.type". - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId fields = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $fields; - /** - * Only apply the transformation if the condition evaluates to true for the - * given `RecordCondition`. The conditions are allowed to reference fields - * that are not used in the actual transformation. - * Example Use Cases: - * - Apply a different bucket transformation to an age column if the zip code - * column for the same record is within a specific range. - * - Redact a field if the date of birth field is greater than 85. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition condition = 3; - */ - protected $condition = null; - protected $transformation; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $fields - * Required. Input field(s) to apply the transformation to. - * When you have columns that reference their position within a list, - * omit the index from the FieldId. FieldId name matching ignores the index. - * For example, instead of "contact.nums[0].type", use "contact.nums.type". - * @type \Google\Cloud\Dlp\V2\RecordCondition $condition - * Only apply the transformation if the condition evaluates to true for the - * given `RecordCondition`. The conditions are allowed to reference fields - * that are not used in the actual transformation. - * Example Use Cases: - * - Apply a different bucket transformation to an age column if the zip code - * column for the same record is within a specific range. - * - Redact a field if the date of birth field is greater than 85. - * @type \Google\Cloud\Dlp\V2\PrimitiveTransformation $primitive_transformation - * Apply the transformation to the entire field. - * @type \Google\Cloud\Dlp\V2\InfoTypeTransformations $info_type_transformations - * Treat the contents of the field as free text, and selectively - * transform content that matches an `InfoType`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Input field(s) to apply the transformation to. - * When you have columns that reference their position within a list, - * omit the index from the FieldId. FieldId name matching ignores the index. - * For example, instead of "contact.nums[0].type", use "contact.nums.type". - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId fields = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFields() - { - return $this->fields; - } - - /** - * Required. Input field(s) to apply the transformation to. - * When you have columns that reference their position within a list, - * omit the index from the FieldId. FieldId name matching ignores the index. - * For example, instead of "contact.nums[0].type", use "contact.nums.type". - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId fields = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFields($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); - $this->fields = $arr; - - return $this; - } - - /** - * Only apply the transformation if the condition evaluates to true for the - * given `RecordCondition`. The conditions are allowed to reference fields - * that are not used in the actual transformation. - * Example Use Cases: - * - Apply a different bucket transformation to an age column if the zip code - * column for the same record is within a specific range. - * - Redact a field if the date of birth field is greater than 85. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition condition = 3; - * @return \Google\Cloud\Dlp\V2\RecordCondition|null - */ - public function getCondition() - { - return $this->condition; - } - - public function hasCondition() - { - return isset($this->condition); - } - - public function clearCondition() - { - unset($this->condition); - } - - /** - * Only apply the transformation if the condition evaluates to true for the - * given `RecordCondition`. The conditions are allowed to reference fields - * that are not used in the actual transformation. - * Example Use Cases: - * - Apply a different bucket transformation to an age column if the zip code - * column for the same record is within a specific range. - * - Redact a field if the date of birth field is greater than 85. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition condition = 3; - * @param \Google\Cloud\Dlp\V2\RecordCondition $var - * @return $this - */ - public function setCondition($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordCondition::class); - $this->condition = $var; - - return $this; - } - - /** - * Apply the transformation to the entire field. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation primitive_transformation = 4; - * @return \Google\Cloud\Dlp\V2\PrimitiveTransformation|null - */ - public function getPrimitiveTransformation() - { - return $this->readOneof(4); - } - - public function hasPrimitiveTransformation() - { - return $this->hasOneof(4); - } - - /** - * Apply the transformation to the entire field. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation primitive_transformation = 4; - * @param \Google\Cloud\Dlp\V2\PrimitiveTransformation $var - * @return $this - */ - public function setPrimitiveTransformation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrimitiveTransformation::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Treat the contents of the field as free text, and selectively - * transform content that matches an `InfoType`. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeTransformations info_type_transformations = 5; - * @return \Google\Cloud\Dlp\V2\InfoTypeTransformations|null - */ - public function getInfoTypeTransformations() - { - return $this->readOneof(5); - } - - public function hasInfoTypeTransformations() - { - return $this->hasOneof(5); - } - - /** - * Treat the contents of the field as free text, and selectively - * transform content that matches an `InfoType`. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeTransformations info_type_transformations = 5; - * @param \Google\Cloud\Dlp\V2\InfoTypeTransformations $var - * @return $this - */ - public function setInfoTypeTransformations($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoTypeTransformations::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * @return string - */ - public function getTransformation() - { - return $this->whichOneof("transformation"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FileType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FileType.php deleted file mode 100644 index 4cf2e8f31733..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FileType.php +++ /dev/null @@ -1,150 +0,0 @@ -google.privacy.dlp.v2.FileType - */ -class FileType -{ - /** - * Includes all files. - * - * Generated from protobuf enum FILE_TYPE_UNSPECIFIED = 0; - */ - const FILE_TYPE_UNSPECIFIED = 0; - /** - * Includes all file extensions not covered by another entry. Binary - * scanning attempts to convert the content of the file to utf_8 to scan - * the file. - * If you wish to avoid this fall back, specify one or more of the other - * file types in your storage scan. - * - * Generated from protobuf enum BINARY_FILE = 1; - */ - const BINARY_FILE = 1; - /** - * Included file extensions: - * asc,asp, aspx, brf, c, cc,cfm, cgi, cpp, csv, cxx, c++, cs, css, dart, - * dat, dot, eml,, epbub, ged, go, h, hh, hpp, hxx, h++, hs, html, htm, - * mkd, markdown, m, ml, mli, perl, pl, plist, pm, php, phtml, pht, - * properties, py, pyw, rb, rbw, rs, rss, rc, scala, sh, sql, swift, tex, - * shtml, shtm, xhtml, lhs, ics, ini, java, js, json, jsonl, kix, kml, - * ocaml, md, txt, text, tsv, vb, vcard, vcs, wml, xcodeproj, xml, xsl, xsd, - * yml, yaml. - * - * Generated from protobuf enum TEXT_FILE = 2; - */ - const TEXT_FILE = 2; - /** - * Included file extensions: - * bmp, gif, jpg, jpeg, jpe, png. Setting - * [bytes_limit_per_file][google.privacy.dlp.v2.CloudStorageOptions.bytes_limit_per_file] - * or - * [bytes_limit_per_file_percent][google.privacy.dlp.v2.CloudStorageOptions.bytes_limit_per_file] - * has no effect on image files. Image inspection is restricted to the - * `global`, `us`, `asia`, and `europe` regions. - * - * Generated from protobuf enum IMAGE = 3; - */ - const IMAGE = 3; - /** - * Microsoft Word files larger than 30 MB will be scanned as binary files. - * Included file extensions: - * docx, dotx, docm, dotm. Setting `bytes_limit_per_file` or - * `bytes_limit_per_file_percent` has no effect on Word files. - * - * Generated from protobuf enum WORD = 5; - */ - const WORD = 5; - /** - * PDF files larger than 30 MB will be scanned as binary files. - * Included file extensions: - * pdf. Setting `bytes_limit_per_file` or `bytes_limit_per_file_percent` - * has no effect on PDF files. - * - * Generated from protobuf enum PDF = 6; - */ - const PDF = 6; - /** - * Included file extensions: - * avro - * - * Generated from protobuf enum AVRO = 7; - */ - const AVRO = 7; - /** - * Included file extensions: - * csv - * - * Generated from protobuf enum CSV = 8; - */ - const CSV = 8; - /** - * Included file extensions: - * tsv - * - * Generated from protobuf enum TSV = 9; - */ - const TSV = 9; - /** - * Microsoft PowerPoint files larger than 30 MB will be scanned as binary - * files. Included file extensions: - * pptx, pptm, potx, potm, pot. Setting `bytes_limit_per_file` or - * `bytes_limit_per_file_percent` has no effect on PowerPoint files. - * - * Generated from protobuf enum POWERPOINT = 11; - */ - const POWERPOINT = 11; - /** - * Microsoft Excel files larger than 30 MB will be scanned as binary files. - * Included file extensions: - * xlsx, xlsm, xltx, xltm. Setting `bytes_limit_per_file` or - * `bytes_limit_per_file_percent` has no effect on Excel files. - * - * Generated from protobuf enum EXCEL = 12; - */ - const EXCEL = 12; - - private static $valueToName = [ - self::FILE_TYPE_UNSPECIFIED => 'FILE_TYPE_UNSPECIFIED', - self::BINARY_FILE => 'BINARY_FILE', - self::TEXT_FILE => 'TEXT_FILE', - self::IMAGE => 'IMAGE', - self::WORD => 'WORD', - self::PDF => 'PDF', - self::AVRO => 'AVRO', - self::CSV => 'CSV', - self::TSV => 'TSV', - self::POWERPOINT => 'POWERPOINT', - self::EXCEL => 'EXCEL', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Finding.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Finding.php deleted file mode 100644 index 96e95ce3b7da..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Finding.php +++ /dev/null @@ -1,593 +0,0 @@ -google.privacy.dlp.v2.Finding - */ -class Finding extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name in format - * projects/{project}/locations/{location}/findings/{finding} Populated only - * when viewing persisted findings. - * - * Generated from protobuf field string name = 14; - */ - protected $name = ''; - /** - * The content that was found. Even if the content is not textual, it - * may be converted to a textual representation here. - * Provided if `include_quote` is true and the finding is - * less than or equal to 4096 bytes long. If the finding exceeds 4096 bytes - * in length, the quote may be omitted. - * - * Generated from protobuf field string quote = 1; - */ - protected $quote = ''; - /** - * The type of content that might have been found. - * Provided if `excluded_types` is false. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; - */ - protected $info_type = null; - /** - * Confidence of how likely it is that the `info_type` is correct. - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood likelihood = 3; - */ - protected $likelihood = 0; - /** - * Where the content was found. - * - * Generated from protobuf field .google.privacy.dlp.v2.Location location = 4; - */ - protected $location = null; - /** - * Timestamp when finding was detected. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; - */ - protected $create_time = null; - /** - * Contains data parsed from quotes. Only populated if include_quote was set - * to true and a supported infoType was requested. Currently supported - * infoTypes: DATE, DATE_OF_BIRTH and TIME. - * - * Generated from protobuf field .google.privacy.dlp.v2.QuoteInfo quote_info = 7; - */ - protected $quote_info = null; - /** - * The job that stored the finding. - * - * Generated from protobuf field string resource_name = 8 [(.google.api.resource_reference) = { - */ - protected $resource_name = ''; - /** - * Job trigger name, if applicable, for this finding. - * - * Generated from protobuf field string trigger_name = 9 [(.google.api.resource_reference) = { - */ - protected $trigger_name = ''; - /** - * The labels associated with this `Finding`. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * Label values must be between 0 and 63 characters long and must conform - * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. - * No more than 10 labels can be associated with a given finding. - * Examples: - * * `"environment" : "production"` - * * `"pipeline" : "etl"` - * - * Generated from protobuf field map labels = 10; - */ - private $labels; - /** - * Time the job started that produced this finding. - * - * Generated from protobuf field .google.protobuf.Timestamp job_create_time = 11; - */ - protected $job_create_time = null; - /** - * The job that stored the finding. - * - * Generated from protobuf field string job_name = 13 [(.google.api.resource_reference) = { - */ - protected $job_name = ''; - /** - * The unique finding id. - * - * Generated from protobuf field string finding_id = 15; - */ - protected $finding_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Resource name in format - * projects/{project}/locations/{location}/findings/{finding} Populated only - * when viewing persisted findings. - * @type string $quote - * The content that was found. Even if the content is not textual, it - * may be converted to a textual representation here. - * Provided if `include_quote` is true and the finding is - * less than or equal to 4096 bytes long. If the finding exceeds 4096 bytes - * in length, the quote may be omitted. - * @type \Google\Cloud\Dlp\V2\InfoType $info_type - * The type of content that might have been found. - * Provided if `excluded_types` is false. - * @type int $likelihood - * Confidence of how likely it is that the `info_type` is correct. - * @type \Google\Cloud\Dlp\V2\Location $location - * Where the content was found. - * @type \Google\Protobuf\Timestamp $create_time - * Timestamp when finding was detected. - * @type \Google\Cloud\Dlp\V2\QuoteInfo $quote_info - * Contains data parsed from quotes. Only populated if include_quote was set - * to true and a supported infoType was requested. Currently supported - * infoTypes: DATE, DATE_OF_BIRTH and TIME. - * @type string $resource_name - * The job that stored the finding. - * @type string $trigger_name - * Job trigger name, if applicable, for this finding. - * @type array|\Google\Protobuf\Internal\MapField $labels - * The labels associated with this `Finding`. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * Label values must be between 0 and 63 characters long and must conform - * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. - * No more than 10 labels can be associated with a given finding. - * Examples: - * * `"environment" : "production"` - * * `"pipeline" : "etl"` - * @type \Google\Protobuf\Timestamp $job_create_time - * Time the job started that produced this finding. - * @type string $job_name - * The job that stored the finding. - * @type string $finding_id - * The unique finding id. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Resource name in format - * projects/{project}/locations/{location}/findings/{finding} Populated only - * when viewing persisted findings. - * - * Generated from protobuf field string name = 14; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Resource name in format - * projects/{project}/locations/{location}/findings/{finding} Populated only - * when viewing persisted findings. - * - * Generated from protobuf field string name = 14; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The content that was found. Even if the content is not textual, it - * may be converted to a textual representation here. - * Provided if `include_quote` is true and the finding is - * less than or equal to 4096 bytes long. If the finding exceeds 4096 bytes - * in length, the quote may be omitted. - * - * Generated from protobuf field string quote = 1; - * @return string - */ - public function getQuote() - { - return $this->quote; - } - - /** - * The content that was found. Even if the content is not textual, it - * may be converted to a textual representation here. - * Provided if `include_quote` is true and the finding is - * less than or equal to 4096 bytes long. If the finding exceeds 4096 bytes - * in length, the quote may be omitted. - * - * Generated from protobuf field string quote = 1; - * @param string $var - * @return $this - */ - public function setQuote($var) - { - GPBUtil::checkString($var, True); - $this->quote = $var; - - return $this; - } - - /** - * The type of content that might have been found. - * Provided if `excluded_types` is false. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getInfoType() - { - return $this->info_type; - } - - public function hasInfoType() - { - return isset($this->info_type); - } - - public function clearInfoType() - { - unset($this->info_type); - } - - /** - * The type of content that might have been found. - * Provided if `excluded_types` is false. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_type = $var; - - return $this; - } - - /** - * Confidence of how likely it is that the `info_type` is correct. - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood likelihood = 3; - * @return int - */ - public function getLikelihood() - { - return $this->likelihood; - } - - /** - * Confidence of how likely it is that the `info_type` is correct. - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood likelihood = 3; - * @param int $var - * @return $this - */ - public function setLikelihood($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\Likelihood::class); - $this->likelihood = $var; - - return $this; - } - - /** - * Where the content was found. - * - * Generated from protobuf field .google.privacy.dlp.v2.Location location = 4; - * @return \Google\Cloud\Dlp\V2\Location|null - */ - public function getLocation() - { - return $this->location; - } - - public function hasLocation() - { - return isset($this->location); - } - - public function clearLocation() - { - unset($this->location); - } - - /** - * Where the content was found. - * - * Generated from protobuf field .google.privacy.dlp.v2.Location location = 4; - * @param \Google\Cloud\Dlp\V2\Location $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Location::class); - $this->location = $var; - - return $this; - } - - /** - * Timestamp when finding was detected. - * - * 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); - } - - /** - * Timestamp when finding was detected. - * - * 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; - } - - /** - * Contains data parsed from quotes. Only populated if include_quote was set - * to true and a supported infoType was requested. Currently supported - * infoTypes: DATE, DATE_OF_BIRTH and TIME. - * - * Generated from protobuf field .google.privacy.dlp.v2.QuoteInfo quote_info = 7; - * @return \Google\Cloud\Dlp\V2\QuoteInfo|null - */ - public function getQuoteInfo() - { - return $this->quote_info; - } - - public function hasQuoteInfo() - { - return isset($this->quote_info); - } - - public function clearQuoteInfo() - { - unset($this->quote_info); - } - - /** - * Contains data parsed from quotes. Only populated if include_quote was set - * to true and a supported infoType was requested. Currently supported - * infoTypes: DATE, DATE_OF_BIRTH and TIME. - * - * Generated from protobuf field .google.privacy.dlp.v2.QuoteInfo quote_info = 7; - * @param \Google\Cloud\Dlp\V2\QuoteInfo $var - * @return $this - */ - public function setQuoteInfo($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\QuoteInfo::class); - $this->quote_info = $var; - - return $this; - } - - /** - * The job that stored the finding. - * - * Generated from protobuf field string resource_name = 8 [(.google.api.resource_reference) = { - * @return string - */ - public function getResourceName() - { - return $this->resource_name; - } - - /** - * The job that stored the finding. - * - * Generated from protobuf field string resource_name = 8 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setResourceName($var) - { - GPBUtil::checkString($var, True); - $this->resource_name = $var; - - return $this; - } - - /** - * Job trigger name, if applicable, for this finding. - * - * Generated from protobuf field string trigger_name = 9 [(.google.api.resource_reference) = { - * @return string - */ - public function getTriggerName() - { - return $this->trigger_name; - } - - /** - * Job trigger name, if applicable, for this finding. - * - * Generated from protobuf field string trigger_name = 9 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setTriggerName($var) - { - GPBUtil::checkString($var, True); - $this->trigger_name = $var; - - return $this; - } - - /** - * The labels associated with this `Finding`. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * Label values must be between 0 and 63 characters long and must conform - * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. - * No more than 10 labels can be associated with a given finding. - * Examples: - * * `"environment" : "production"` - * * `"pipeline" : "etl"` - * - * Generated from protobuf field map labels = 10; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * The labels associated with this `Finding`. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * Label values must be between 0 and 63 characters long and must conform - * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. - * No more than 10 labels can be associated with a given finding. - * Examples: - * * `"environment" : "production"` - * * `"pipeline" : "etl"` - * - * Generated from protobuf field map labels = 10; - * @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; - } - - /** - * Time the job started that produced this finding. - * - * Generated from protobuf field .google.protobuf.Timestamp job_create_time = 11; - * @return \Google\Protobuf\Timestamp|null - */ - public function getJobCreateTime() - { - return $this->job_create_time; - } - - public function hasJobCreateTime() - { - return isset($this->job_create_time); - } - - public function clearJobCreateTime() - { - unset($this->job_create_time); - } - - /** - * Time the job started that produced this finding. - * - * Generated from protobuf field .google.protobuf.Timestamp job_create_time = 11; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setJobCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->job_create_time = $var; - - return $this; - } - - /** - * The job that stored the finding. - * - * Generated from protobuf field string job_name = 13 [(.google.api.resource_reference) = { - * @return string - */ - public function getJobName() - { - return $this->job_name; - } - - /** - * The job that stored the finding. - * - * Generated from protobuf field string job_name = 13 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setJobName($var) - { - GPBUtil::checkString($var, True); - $this->job_name = $var; - - return $this; - } - - /** - * The unique finding id. - * - * Generated from protobuf field string finding_id = 15; - * @return string - */ - public function getFindingId() - { - return $this->finding_id; - } - - /** - * The unique finding id. - * - * Generated from protobuf field string finding_id = 15; - * @param string $var - * @return $this - */ - public function setFindingId($var) - { - GPBUtil::checkString($var, True); - $this->finding_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FinishDlpJobRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FinishDlpJobRequest.php deleted file mode 100644 index 278e8faf1fe8..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FinishDlpJobRequest.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.FinishDlpJobRequest - */ -class FinishDlpJobRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the DlpJob resource to be finished. - * - * 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 - * Required. The name of the DlpJob resource to be finished. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the DlpJob resource to be finished. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the DlpJob resource to be finished. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FixedSizeBucketingConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FixedSizeBucketingConfig.php deleted file mode 100644 index e7b42158b828..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/FixedSizeBucketingConfig.php +++ /dev/null @@ -1,196 +0,0 @@ -google.privacy.dlp.v2.FixedSizeBucketingConfig - */ -class FixedSizeBucketingConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Lower bound value of buckets. All values less than `lower_bound` - * are grouped together into a single bucket; for example if `lower_bound` = - * 10, then all values less than 10 are replaced with the value "-10". - * - * Generated from protobuf field .google.privacy.dlp.v2.Value lower_bound = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $lower_bound = null; - /** - * Required. Upper bound value of buckets. All values greater than upper_bound - * are grouped together into a single bucket; for example if `upper_bound` = - * 89, then all values greater than 89 are replaced with the value "89+". - * - * Generated from protobuf field .google.privacy.dlp.v2.Value upper_bound = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $upper_bound = null; - /** - * Required. Size of each bucket (except for minimum and maximum buckets). So - * if `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the - * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60, - * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. - * - * Generated from protobuf field double bucket_size = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $bucket_size = 0.0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\Value $lower_bound - * Required. Lower bound value of buckets. All values less than `lower_bound` - * are grouped together into a single bucket; for example if `lower_bound` = - * 10, then all values less than 10 are replaced with the value "-10". - * @type \Google\Cloud\Dlp\V2\Value $upper_bound - * Required. Upper bound value of buckets. All values greater than upper_bound - * are grouped together into a single bucket; for example if `upper_bound` = - * 89, then all values greater than 89 are replaced with the value "89+". - * @type float $bucket_size - * Required. Size of each bucket (except for minimum and maximum buckets). So - * if `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the - * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60, - * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Lower bound value of buckets. All values less than `lower_bound` - * are grouped together into a single bucket; for example if `lower_bound` = - * 10, then all values less than 10 are replaced with the value "-10". - * - * Generated from protobuf field .google.privacy.dlp.v2.Value lower_bound = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\Value|null - */ - public function getLowerBound() - { - return $this->lower_bound; - } - - public function hasLowerBound() - { - return isset($this->lower_bound); - } - - public function clearLowerBound() - { - unset($this->lower_bound); - } - - /** - * Required. Lower bound value of buckets. All values less than `lower_bound` - * are grouped together into a single bucket; for example if `lower_bound` = - * 10, then all values less than 10 are replaced with the value "-10". - * - * Generated from protobuf field .google.privacy.dlp.v2.Value lower_bound = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\Value $var - * @return $this - */ - public function setLowerBound($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); - $this->lower_bound = $var; - - return $this; - } - - /** - * Required. Upper bound value of buckets. All values greater than upper_bound - * are grouped together into a single bucket; for example if `upper_bound` = - * 89, then all values greater than 89 are replaced with the value "89+". - * - * Generated from protobuf field .google.privacy.dlp.v2.Value upper_bound = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\Value|null - */ - public function getUpperBound() - { - return $this->upper_bound; - } - - public function hasUpperBound() - { - return isset($this->upper_bound); - } - - public function clearUpperBound() - { - unset($this->upper_bound); - } - - /** - * Required. Upper bound value of buckets. All values greater than upper_bound - * are grouped together into a single bucket; for example if `upper_bound` = - * 89, then all values greater than 89 are replaced with the value "89+". - * - * Generated from protobuf field .google.privacy.dlp.v2.Value upper_bound = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\Value $var - * @return $this - */ - public function setUpperBound($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); - $this->upper_bound = $var; - - return $this; - } - - /** - * Required. Size of each bucket (except for minimum and maximum buckets). So - * if `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the - * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60, - * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. - * - * Generated from protobuf field double bucket_size = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return float - */ - public function getBucketSize() - { - return $this->bucket_size; - } - - /** - * Required. Size of each bucket (except for minimum and maximum buckets). So - * if `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the - * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60, - * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. - * - * Generated from protobuf field double bucket_size = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param float $var - * @return $this - */ - public function setBucketSize($var) - { - GPBUtil::checkDouble($var); - $this->bucket_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetColumnDataProfileRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetColumnDataProfileRequest.php deleted file mode 100644 index 06e176a0c4d7..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetColumnDataProfileRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.privacy.dlp.v2.GetColumnDataProfileRequest - */ -class GetColumnDataProfileRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name, for example - * `organizations/12345/locations/us/columnDataProfiles/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name, for example - * `organizations/12345/locations/us/columnDataProfiles/53234423`. Please see - * {@see DlpServiceClient::columnDataProfileName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\GetColumnDataProfileRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name, for example - * `organizations/12345/locations/us/columnDataProfiles/53234423`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name, for example - * `organizations/12345/locations/us/columnDataProfiles/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name, for example - * `organizations/12345/locations/us/columnDataProfiles/53234423`. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetConnectionRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetConnectionRequest.php deleted file mode 100644 index abceabf3a8bb..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetConnectionRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.privacy.dlp.v2.GetConnectionRequest - */ -class GetConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. Please see - * {@see DlpServiceClient::connectionName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\GetConnectionRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDeidentifyTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDeidentifyTemplateRequest.php deleted file mode 100644 index 33f8f78f48c9..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDeidentifyTemplateRequest.php +++ /dev/null @@ -1,91 +0,0 @@ -google.privacy.dlp.v2.GetDeidentifyTemplateRequest - */ -class GetDeidentifyTemplateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the organization and deidentify template to be - * read, for example `organizations/433245324/deidentifyTemplates/432452342` - * or projects/project-id/deidentifyTemplates/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the organization and deidentify template to be - * read, for example `organizations/433245324/deidentifyTemplates/432452342` - * or projects/project-id/deidentifyTemplates/432452342. Please see - * {@see DlpServiceClient::deidentifyTemplateName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\GetDeidentifyTemplateRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the organization and deidentify template to be - * read, for example `organizations/433245324/deidentifyTemplates/432452342` - * or projects/project-id/deidentifyTemplates/432452342. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the organization and deidentify template to be - * read, for example `organizations/433245324/deidentifyTemplates/432452342` - * or projects/project-id/deidentifyTemplates/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the organization and deidentify template to be - * read, for example `organizations/433245324/deidentifyTemplates/432452342` - * or projects/project-id/deidentifyTemplates/432452342. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDiscoveryConfigRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDiscoveryConfigRequest.php deleted file mode 100644 index 74e5008be7ec..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDiscoveryConfigRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.privacy.dlp.v2.GetDiscoveryConfigRequest - */ -class GetDiscoveryConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the project and the configuration, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the project and the configuration, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. Please see - * {@see DlpServiceClient::discoveryConfigName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\GetDiscoveryConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the project and the configuration, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the project and the configuration, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the project and the configuration, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDlpJobRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDlpJobRequest.php deleted file mode 100644 index 272eaaf940b2..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetDlpJobRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.privacy.dlp.v2.GetDlpJobRequest - */ -class GetDlpJobRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the DlpJob resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the DlpJob resource. Please see - * {@see DlpServiceClient::dlpJobName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\GetDlpJobRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the DlpJob resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the DlpJob resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the DlpJob resource. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetInspectTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetInspectTemplateRequest.php deleted file mode 100644 index 14b95682d6cb..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetInspectTemplateRequest.php +++ /dev/null @@ -1,91 +0,0 @@ -google.privacy.dlp.v2.GetInspectTemplateRequest - */ -class GetInspectTemplateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the organization and inspectTemplate to be read, - * for example `organizations/433245324/inspectTemplates/432452342` or - * projects/project-id/inspectTemplates/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the organization and inspectTemplate to be read, - * for example `organizations/433245324/inspectTemplates/432452342` or - * projects/project-id/inspectTemplates/432452342. Please see - * {@see DlpServiceClient::inspectTemplateName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\GetInspectTemplateRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the organization and inspectTemplate to be read, - * for example `organizations/433245324/inspectTemplates/432452342` or - * projects/project-id/inspectTemplates/432452342. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the organization and inspectTemplate to be read, - * for example `organizations/433245324/inspectTemplates/432452342` or - * projects/project-id/inspectTemplates/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the organization and inspectTemplate to be read, - * for example `organizations/433245324/inspectTemplates/432452342` or - * projects/project-id/inspectTemplates/432452342. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetJobTriggerRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetJobTriggerRequest.php deleted file mode 100644 index 3b8f6fcddf1a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetJobTriggerRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.privacy.dlp.v2.GetJobTriggerRequest - */ -class GetJobTriggerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. Please see - * {@see DlpServiceClient::jobTriggerName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\GetJobTriggerRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetProjectDataProfileRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetProjectDataProfileRequest.php deleted file mode 100644 index 853ec07bdbd7..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetProjectDataProfileRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.privacy.dlp.v2.GetProjectDataProfileRequest - */ -class GetProjectDataProfileRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name, for example - * `organizations/12345/locations/us/projectDataProfiles/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name, for example - * `organizations/12345/locations/us/projectDataProfiles/53234423`. Please see - * {@see DlpServiceClient::projectDataProfileName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\GetProjectDataProfileRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name, for example - * `organizations/12345/locations/us/projectDataProfiles/53234423`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name, for example - * `organizations/12345/locations/us/projectDataProfiles/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name, for example - * `organizations/12345/locations/us/projectDataProfiles/53234423`. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetStoredInfoTypeRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetStoredInfoTypeRequest.php deleted file mode 100644 index c1fc45586b54..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetStoredInfoTypeRequest.php +++ /dev/null @@ -1,91 +0,0 @@ -google.privacy.dlp.v2.GetStoredInfoTypeRequest - */ -class GetStoredInfoTypeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the organization and storedInfoType to be read, - * for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the organization and storedInfoType to be read, - * for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. Please see - * {@see DlpServiceClient::storedInfoTypeName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\GetStoredInfoTypeRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the organization and storedInfoType to be read, - * for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the organization and storedInfoType to be read, - * for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the organization and storedInfoType to be read, - * for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetTableDataProfileRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetTableDataProfileRequest.php deleted file mode 100644 index 60adfcef114a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/GetTableDataProfileRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.privacy.dlp.v2.GetTableDataProfileRequest - */ -class GetTableDataProfileRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name, for example - * `organizations/12345/locations/us/tableDataProfiles/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name, for example - * `organizations/12345/locations/us/tableDataProfiles/53234423`. Please see - * {@see DlpServiceClient::tableDataProfileName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\GetTableDataProfileRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name, for example - * `organizations/12345/locations/us/tableDataProfiles/53234423`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name, for example - * `organizations/12345/locations/us/tableDataProfiles/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name, for example - * `organizations/12345/locations/us/tableDataProfiles/53234423`. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridContentItem.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridContentItem.php deleted file mode 100644 index 9aa65f72ffd7..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridContentItem.php +++ /dev/null @@ -1,122 +0,0 @@ -google.privacy.dlp.v2.HybridContentItem - */ -class HybridContentItem extends \Google\Protobuf\Internal\Message -{ - /** - * The item to inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; - */ - protected $item = null; - /** - * Supplementary information that will be added to each finding. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridFindingDetails finding_details = 2; - */ - protected $finding_details = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\ContentItem $item - * The item to inspect. - * @type \Google\Cloud\Dlp\V2\HybridFindingDetails $finding_details - * Supplementary information that will be added to each finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The item to inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; - * @return \Google\Cloud\Dlp\V2\ContentItem|null - */ - public function getItem() - { - return $this->item; - } - - public function hasItem() - { - return isset($this->item); - } - - public function clearItem() - { - unset($this->item); - } - - /** - * The item to inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; - * @param \Google\Cloud\Dlp\V2\ContentItem $var - * @return $this - */ - public function setItem($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ContentItem::class); - $this->item = $var; - - return $this; - } - - /** - * Supplementary information that will be added to each finding. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridFindingDetails finding_details = 2; - * @return \Google\Cloud\Dlp\V2\HybridFindingDetails|null - */ - public function getFindingDetails() - { - return $this->finding_details; - } - - public function hasFindingDetails() - { - return isset($this->finding_details); - } - - public function clearFindingDetails() - { - unset($this->finding_details); - } - - /** - * Supplementary information that will be added to each finding. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridFindingDetails finding_details = 2; - * @param \Google\Cloud\Dlp\V2\HybridFindingDetails $var - * @return $this - */ - public function setFindingDetails($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\HybridFindingDetails::class); - $this->finding_details = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridFindingDetails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridFindingDetails.php deleted file mode 100644 index e27434622dd3..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridFindingDetails.php +++ /dev/null @@ -1,303 +0,0 @@ -google.privacy.dlp.v2.HybridFindingDetails - */ -class HybridFindingDetails extends \Google\Protobuf\Internal\Message -{ - /** - * Details about the container where the content being inspected is from. - * - * Generated from protobuf field .google.privacy.dlp.v2.Container container_details = 1; - */ - protected $container_details = null; - /** - * Offset in bytes of the line, from the beginning of the file, where the - * finding is located. Populate if the item being scanned is only part of a - * bigger item, such as a shard of a file and you want to track the absolute - * position of the finding. - * - * Generated from protobuf field int64 file_offset = 2; - */ - protected $file_offset = 0; - /** - * Offset of the row for tables. Populate if the row(s) being scanned are - * part of a bigger dataset and you want to keep track of their absolute - * position. - * - * Generated from protobuf field int64 row_offset = 3; - */ - protected $row_offset = 0; - /** - * If the container is a table, additional information to make findings - * meaningful such as the columns that are primary keys. If not known ahead - * of time, can also be set within each inspect hybrid call and the two - * will be merged. Note that identifying_fields will only be stored to - * BigQuery, and only if the BigQuery action has been included. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableOptions table_options = 4; - */ - protected $table_options = null; - /** - * Labels to represent user provided metadata about the data being inspected. - * If configured by the job, some key values may be required. - * The labels associated with `Finding`'s produced by hybrid - * inspection. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * Label values must be between 0 and 63 characters long and must conform - * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. - * No more than 10 labels can be associated with a given finding. - * Examples: - * * `"environment" : "production"` - * * `"pipeline" : "etl"` - * - * Generated from protobuf field map labels = 5; - */ - private $labels; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\Container $container_details - * Details about the container where the content being inspected is from. - * @type int|string $file_offset - * Offset in bytes of the line, from the beginning of the file, where the - * finding is located. Populate if the item being scanned is only part of a - * bigger item, such as a shard of a file and you want to track the absolute - * position of the finding. - * @type int|string $row_offset - * Offset of the row for tables. Populate if the row(s) being scanned are - * part of a bigger dataset and you want to keep track of their absolute - * position. - * @type \Google\Cloud\Dlp\V2\TableOptions $table_options - * If the container is a table, additional information to make findings - * meaningful such as the columns that are primary keys. If not known ahead - * of time, can also be set within each inspect hybrid call and the two - * will be merged. Note that identifying_fields will only be stored to - * BigQuery, and only if the BigQuery action has been included. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels to represent user provided metadata about the data being inspected. - * If configured by the job, some key values may be required. - * The labels associated with `Finding`'s produced by hybrid - * inspection. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * Label values must be between 0 and 63 characters long and must conform - * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. - * No more than 10 labels can be associated with a given finding. - * Examples: - * * `"environment" : "production"` - * * `"pipeline" : "etl"` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Details about the container where the content being inspected is from. - * - * Generated from protobuf field .google.privacy.dlp.v2.Container container_details = 1; - * @return \Google\Cloud\Dlp\V2\Container|null - */ - public function getContainerDetails() - { - return $this->container_details; - } - - public function hasContainerDetails() - { - return isset($this->container_details); - } - - public function clearContainerDetails() - { - unset($this->container_details); - } - - /** - * Details about the container where the content being inspected is from. - * - * Generated from protobuf field .google.privacy.dlp.v2.Container container_details = 1; - * @param \Google\Cloud\Dlp\V2\Container $var - * @return $this - */ - public function setContainerDetails($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Container::class); - $this->container_details = $var; - - return $this; - } - - /** - * Offset in bytes of the line, from the beginning of the file, where the - * finding is located. Populate if the item being scanned is only part of a - * bigger item, such as a shard of a file and you want to track the absolute - * position of the finding. - * - * Generated from protobuf field int64 file_offset = 2; - * @return int|string - */ - public function getFileOffset() - { - return $this->file_offset; - } - - /** - * Offset in bytes of the line, from the beginning of the file, where the - * finding is located. Populate if the item being scanned is only part of a - * bigger item, such as a shard of a file and you want to track the absolute - * position of the finding. - * - * Generated from protobuf field int64 file_offset = 2; - * @param int|string $var - * @return $this - */ - public function setFileOffset($var) - { - GPBUtil::checkInt64($var); - $this->file_offset = $var; - - return $this; - } - - /** - * Offset of the row for tables. Populate if the row(s) being scanned are - * part of a bigger dataset and you want to keep track of their absolute - * position. - * - * Generated from protobuf field int64 row_offset = 3; - * @return int|string - */ - public function getRowOffset() - { - return $this->row_offset; - } - - /** - * Offset of the row for tables. Populate if the row(s) being scanned are - * part of a bigger dataset and you want to keep track of their absolute - * position. - * - * Generated from protobuf field int64 row_offset = 3; - * @param int|string $var - * @return $this - */ - public function setRowOffset($var) - { - GPBUtil::checkInt64($var); - $this->row_offset = $var; - - return $this; - } - - /** - * If the container is a table, additional information to make findings - * meaningful such as the columns that are primary keys. If not known ahead - * of time, can also be set within each inspect hybrid call and the two - * will be merged. Note that identifying_fields will only be stored to - * BigQuery, and only if the BigQuery action has been included. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableOptions table_options = 4; - * @return \Google\Cloud\Dlp\V2\TableOptions|null - */ - public function getTableOptions() - { - return $this->table_options; - } - - public function hasTableOptions() - { - return isset($this->table_options); - } - - public function clearTableOptions() - { - unset($this->table_options); - } - - /** - * If the container is a table, additional information to make findings - * meaningful such as the columns that are primary keys. If not known ahead - * of time, can also be set within each inspect hybrid call and the two - * will be merged. Note that identifying_fields will only be stored to - * BigQuery, and only if the BigQuery action has been included. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableOptions table_options = 4; - * @param \Google\Cloud\Dlp\V2\TableOptions $var - * @return $this - */ - public function setTableOptions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableOptions::class); - $this->table_options = $var; - - return $this; - } - - /** - * Labels to represent user provided metadata about the data being inspected. - * If configured by the job, some key values may be required. - * The labels associated with `Finding`'s produced by hybrid - * inspection. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * Label values must be between 0 and 63 characters long and must conform - * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. - * No more than 10 labels can be associated with a given finding. - * Examples: - * * `"environment" : "production"` - * * `"pipeline" : "etl"` - * - * Generated from protobuf field map labels = 5; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels to represent user provided metadata about the data being inspected. - * If configured by the job, some key values may be required. - * The labels associated with `Finding`'s produced by hybrid - * inspection. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * Label values must be between 0 and 63 characters long and must conform - * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. - * No more than 10 labels can be associated with a given finding. - * Examples: - * * `"environment" : "production"` - * * `"pipeline" : "etl"` - * - * Generated from protobuf field map labels = 5; - * @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; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectDlpJobRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectDlpJobRequest.php deleted file mode 100644 index f1ed062cc4e2..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectDlpJobRequest.php +++ /dev/null @@ -1,130 +0,0 @@ -google.privacy.dlp.v2.HybridInspectDlpJobRequest - */ -class HybridInspectDlpJobRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the job to execute a hybrid inspect on, for - * example `projects/dlp-test-project/dlpJob/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * The item to inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridContentItem hybrid_item = 3; - */ - protected $hybrid_item = null; - - /** - * @param string $name Required. Resource name of the job to execute a hybrid inspect on, for - * example `projects/dlp-test-project/dlpJob/53234423`. Please see - * {@see DlpServiceClient::dlpJobName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\HybridInspectDlpJobRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the job to execute a hybrid inspect on, for - * example `projects/dlp-test-project/dlpJob/53234423`. - * @type \Google\Cloud\Dlp\V2\HybridContentItem $hybrid_item - * The item to inspect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the job to execute a hybrid inspect on, for - * example `projects/dlp-test-project/dlpJob/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the job to execute a hybrid inspect on, for - * example `projects/dlp-test-project/dlpJob/53234423`. - * - * 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 item to inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridContentItem hybrid_item = 3; - * @return \Google\Cloud\Dlp\V2\HybridContentItem|null - */ - public function getHybridItem() - { - return $this->hybrid_item; - } - - public function hasHybridItem() - { - return isset($this->hybrid_item); - } - - public function clearHybridItem() - { - unset($this->hybrid_item); - } - - /** - * The item to inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridContentItem hybrid_item = 3; - * @param \Google\Cloud\Dlp\V2\HybridContentItem $var - * @return $this - */ - public function setHybridItem($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\HybridContentItem::class); - $this->hybrid_item = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectJobTriggerRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectJobTriggerRequest.php deleted file mode 100644 index 4bca83aaf179..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectJobTriggerRequest.php +++ /dev/null @@ -1,130 +0,0 @@ -google.privacy.dlp.v2.HybridInspectJobTriggerRequest - */ -class HybridInspectJobTriggerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the trigger to execute a hybrid inspect on, for - * example `projects/dlp-test-project/jobTriggers/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * The item to inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridContentItem hybrid_item = 3; - */ - protected $hybrid_item = null; - - /** - * @param string $name Required. Resource name of the trigger to execute a hybrid inspect on, for - * example `projects/dlp-test-project/jobTriggers/53234423`. Please see - * {@see DlpServiceClient::jobTriggerName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\HybridInspectJobTriggerRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the trigger to execute a hybrid inspect on, for - * example `projects/dlp-test-project/jobTriggers/53234423`. - * @type \Google\Cloud\Dlp\V2\HybridContentItem $hybrid_item - * The item to inspect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the trigger to execute a hybrid inspect on, for - * example `projects/dlp-test-project/jobTriggers/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the trigger to execute a hybrid inspect on, for - * example `projects/dlp-test-project/jobTriggers/53234423`. - * - * 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 item to inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridContentItem hybrid_item = 3; - * @return \Google\Cloud\Dlp\V2\HybridContentItem|null - */ - public function getHybridItem() - { - return $this->hybrid_item; - } - - public function hasHybridItem() - { - return isset($this->hybrid_item); - } - - public function clearHybridItem() - { - unset($this->hybrid_item); - } - - /** - * The item to inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridContentItem hybrid_item = 3; - * @param \Google\Cloud\Dlp\V2\HybridContentItem $var - * @return $this - */ - public function setHybridItem($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\HybridContentItem::class); - $this->hybrid_item = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectResponse.php deleted file mode 100644 index 0589ade65d3c..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectResponse.php +++ /dev/null @@ -1,33 +0,0 @@ -google.privacy.dlp.v2.HybridInspectResponse - */ -class HybridInspectResponse extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectStatistics.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectStatistics.php deleted file mode 100644 index 9533c8b38f28..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridInspectStatistics.php +++ /dev/null @@ -1,155 +0,0 @@ -google.privacy.dlp.v2.HybridInspectStatistics - */ -class HybridInspectStatistics extends \Google\Protobuf\Internal\Message -{ - /** - * The number of hybrid inspection requests processed within this job. - * - * Generated from protobuf field int64 processed_count = 1; - */ - protected $processed_count = 0; - /** - * The number of hybrid inspection requests aborted because the job ran - * out of quota or was ended before they could be processed. - * - * Generated from protobuf field int64 aborted_count = 2; - */ - protected $aborted_count = 0; - /** - * The number of hybrid requests currently being processed. Only populated - * when called via method `getDlpJob`. - * A burst of traffic may cause hybrid inspect requests to be enqueued. - * Processing will take place as quickly as possible, but resource limitations - * may impact how long a request is enqueued for. - * - * Generated from protobuf field int64 pending_count = 3; - */ - protected $pending_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $processed_count - * The number of hybrid inspection requests processed within this job. - * @type int|string $aborted_count - * The number of hybrid inspection requests aborted because the job ran - * out of quota or was ended before they could be processed. - * @type int|string $pending_count - * The number of hybrid requests currently being processed. Only populated - * when called via method `getDlpJob`. - * A burst of traffic may cause hybrid inspect requests to be enqueued. - * Processing will take place as quickly as possible, but resource limitations - * may impact how long a request is enqueued for. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The number of hybrid inspection requests processed within this job. - * - * Generated from protobuf field int64 processed_count = 1; - * @return int|string - */ - public function getProcessedCount() - { - return $this->processed_count; - } - - /** - * The number of hybrid inspection requests processed within this job. - * - * Generated from protobuf field int64 processed_count = 1; - * @param int|string $var - * @return $this - */ - public function setProcessedCount($var) - { - GPBUtil::checkInt64($var); - $this->processed_count = $var; - - return $this; - } - - /** - * The number of hybrid inspection requests aborted because the job ran - * out of quota or was ended before they could be processed. - * - * Generated from protobuf field int64 aborted_count = 2; - * @return int|string - */ - public function getAbortedCount() - { - return $this->aborted_count; - } - - /** - * The number of hybrid inspection requests aborted because the job ran - * out of quota or was ended before they could be processed. - * - * Generated from protobuf field int64 aborted_count = 2; - * @param int|string $var - * @return $this - */ - public function setAbortedCount($var) - { - GPBUtil::checkInt64($var); - $this->aborted_count = $var; - - return $this; - } - - /** - * The number of hybrid requests currently being processed. Only populated - * when called via method `getDlpJob`. - * A burst of traffic may cause hybrid inspect requests to be enqueued. - * Processing will take place as quickly as possible, but resource limitations - * may impact how long a request is enqueued for. - * - * Generated from protobuf field int64 pending_count = 3; - * @return int|string - */ - public function getPendingCount() - { - return $this->pending_count; - } - - /** - * The number of hybrid requests currently being processed. Only populated - * when called via method `getDlpJob`. - * A burst of traffic may cause hybrid inspect requests to be enqueued. - * Processing will take place as quickly as possible, but resource limitations - * may impact how long a request is enqueued for. - * - * Generated from protobuf field int64 pending_count = 3; - * @param int|string $var - * @return $this - */ - public function setPendingCount($var) - { - GPBUtil::checkInt64($var); - $this->pending_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridOptions.php deleted file mode 100644 index d5167855184a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/HybridOptions.php +++ /dev/null @@ -1,240 +0,0 @@ -google.privacy.dlp.v2.HybridOptions - */ -class HybridOptions extends \Google\Protobuf\Internal\Message -{ - /** - * A short description of where the data is coming from. Will be stored once - * in the job. 256 max length. - * - * Generated from protobuf field string description = 1; - */ - protected $description = ''; - /** - * These are labels that each inspection request must include within their - * 'finding_labels' map. Request may contain others, but any missing one of - * these will be rejected. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * No more than 10 keys can be required. - * - * Generated from protobuf field repeated string required_finding_label_keys = 2; - */ - private $required_finding_label_keys; - /** - * To organize findings, these labels will be added to each finding. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * Label values must be between 0 and 63 characters long and must conform - * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. - * No more than 10 labels can be associated with a given finding. - * Examples: - * * `"environment" : "production"` - * * `"pipeline" : "etl"` - * - * Generated from protobuf field map labels = 3; - */ - private $labels; - /** - * If the container is a table, additional information to make findings - * meaningful such as the columns that are primary keys. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableOptions table_options = 4; - */ - protected $table_options = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $description - * A short description of where the data is coming from. Will be stored once - * in the job. 256 max length. - * @type array|\Google\Protobuf\Internal\RepeatedField $required_finding_label_keys - * These are labels that each inspection request must include within their - * 'finding_labels' map. Request may contain others, but any missing one of - * these will be rejected. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * No more than 10 keys can be required. - * @type array|\Google\Protobuf\Internal\MapField $labels - * To organize findings, these labels will be added to each finding. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * Label values must be between 0 and 63 characters long and must conform - * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. - * No more than 10 labels can be associated with a given finding. - * Examples: - * * `"environment" : "production"` - * * `"pipeline" : "etl"` - * @type \Google\Cloud\Dlp\V2\TableOptions $table_options - * If the container is a table, additional information to make findings - * meaningful such as the columns that are primary keys. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * A short description of where the data is coming from. Will be stored once - * in the job. 256 max length. - * - * Generated from protobuf field string description = 1; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * A short description of where the data is coming from. Will be stored once - * in the job. 256 max length. - * - * Generated from protobuf field string description = 1; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * These are labels that each inspection request must include within their - * 'finding_labels' map. Request may contain others, but any missing one of - * these will be rejected. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * No more than 10 keys can be required. - * - * Generated from protobuf field repeated string required_finding_label_keys = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRequiredFindingLabelKeys() - { - return $this->required_finding_label_keys; - } - - /** - * These are labels that each inspection request must include within their - * 'finding_labels' map. Request may contain others, but any missing one of - * these will be rejected. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * No more than 10 keys can be required. - * - * Generated from protobuf field repeated string required_finding_label_keys = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRequiredFindingLabelKeys($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->required_finding_label_keys = $arr; - - return $this; - } - - /** - * To organize findings, these labels will be added to each finding. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * Label values must be between 0 and 63 characters long and must conform - * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. - * No more than 10 labels can be associated with a given finding. - * Examples: - * * `"environment" : "production"` - * * `"pipeline" : "etl"` - * - * Generated from protobuf field map labels = 3; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * To organize findings, these labels will be added to each finding. - * Label keys must be between 1 and 63 characters long and must conform - * to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. - * Label values must be between 0 and 63 characters long and must conform - * to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. - * No more than 10 labels can be associated with a given finding. - * Examples: - * * `"environment" : "production"` - * * `"pipeline" : "etl"` - * - * Generated from protobuf field map labels = 3; - * @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; - } - - /** - * If the container is a table, additional information to make findings - * meaningful such as the columns that are primary keys. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableOptions table_options = 4; - * @return \Google\Cloud\Dlp\V2\TableOptions|null - */ - public function getTableOptions() - { - return $this->table_options; - } - - public function hasTableOptions() - { - return isset($this->table_options); - } - - public function clearTableOptions() - { - unset($this->table_options); - } - - /** - * If the container is a table, additional information to make findings - * meaningful such as the columns that are primary keys. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableOptions table_options = 4; - * @param \Google\Cloud\Dlp\V2\TableOptions $var - * @return $this - */ - public function setTableOptions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableOptions::class); - $this->table_options = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageLocation.php deleted file mode 100644 index 60678827e0b5..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageLocation.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.ImageLocation - */ -class ImageLocation extends \Google\Protobuf\Internal\Message -{ - /** - * Bounding boxes locating the pixels within the image containing the finding. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BoundingBox bounding_boxes = 1; - */ - private $bounding_boxes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\BoundingBox>|\Google\Protobuf\Internal\RepeatedField $bounding_boxes - * Bounding boxes locating the pixels within the image containing the finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Bounding boxes locating the pixels within the image containing the finding. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BoundingBox bounding_boxes = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBoundingBoxes() - { - return $this->bounding_boxes; - } - - /** - * Bounding boxes locating the pixels within the image containing the finding. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.BoundingBox bounding_boxes = 1; - * @param array<\Google\Cloud\Dlp\V2\BoundingBox>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBoundingBoxes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\BoundingBox::class); - $this->bounding_boxes = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations.php deleted file mode 100644 index 816899665ead..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.ImageTransformations - */ -class ImageTransformations extends \Google\Protobuf\Internal\Message -{ - /** - * List of transforms to make. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ImageTransformations.ImageTransformation transforms = 2; - */ - private $transforms; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation>|\Google\Protobuf\Internal\RepeatedField $transforms - * List of transforms to make. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of transforms to make. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ImageTransformations.ImageTransformation transforms = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTransforms() - { - return $this->transforms; - } - - /** - * List of transforms to make. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ImageTransformations.ImageTransformation transforms = 2; - * @param array<\Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTransforms($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation::class); - $this->transforms = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation.php deleted file mode 100644 index 51539ea89bd7..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation.php +++ /dev/null @@ -1,201 +0,0 @@ -google.privacy.dlp.v2.ImageTransformations.ImageTransformation - */ -class ImageTransformation extends \Google\Protobuf\Internal\Message -{ - /** - * The color to use when redacting content from an image. If not - * specified, the default is black. - * - * Generated from protobuf field .google.privacy.dlp.v2.Color redaction_color = 3; - */ - protected $redaction_color = null; - protected $target; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\SelectedInfoTypes $selected_info_types - * Apply transformation to the selected info_types. - * @type \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllInfoTypes $all_info_types - * Apply transformation to all findings not specified in other - * ImageTransformation's selected_info_types. Only one instance is allowed - * within the ImageTransformations message. - * @type \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllText $all_text - * Apply transformation to all text that doesn't match an infoType. Only - * one instance is allowed within the ImageTransformations message. - * @type \Google\Cloud\Dlp\V2\Color $redaction_color - * The color to use when redacting content from an image. If not - * specified, the default is black. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Apply transformation to the selected info_types. - * - * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations.ImageTransformation.SelectedInfoTypes selected_info_types = 4; - * @return \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\SelectedInfoTypes|null - */ - public function getSelectedInfoTypes() - { - return $this->readOneof(4); - } - - public function hasSelectedInfoTypes() - { - return $this->hasOneof(4); - } - - /** - * Apply transformation to the selected info_types. - * - * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations.ImageTransformation.SelectedInfoTypes selected_info_types = 4; - * @param \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\SelectedInfoTypes $var - * @return $this - */ - public function setSelectedInfoTypes($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\SelectedInfoTypes::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Apply transformation to all findings not specified in other - * ImageTransformation's selected_info_types. Only one instance is allowed - * within the ImageTransformations message. - * - * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations.ImageTransformation.AllInfoTypes all_info_types = 5; - * @return \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllInfoTypes|null - */ - public function getAllInfoTypes() - { - return $this->readOneof(5); - } - - public function hasAllInfoTypes() - { - return $this->hasOneof(5); - } - - /** - * Apply transformation to all findings not specified in other - * ImageTransformation's selected_info_types. Only one instance is allowed - * within the ImageTransformations message. - * - * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations.ImageTransformation.AllInfoTypes all_info_types = 5; - * @param \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllInfoTypes $var - * @return $this - */ - public function setAllInfoTypes($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllInfoTypes::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Apply transformation to all text that doesn't match an infoType. Only - * one instance is allowed within the ImageTransformations message. - * - * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations.ImageTransformation.AllText all_text = 6; - * @return \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllText|null - */ - public function getAllText() - { - return $this->readOneof(6); - } - - public function hasAllText() - { - return $this->hasOneof(6); - } - - /** - * Apply transformation to all text that doesn't match an infoType. Only - * one instance is allowed within the ImageTransformations message. - * - * Generated from protobuf field .google.privacy.dlp.v2.ImageTransformations.ImageTransformation.AllText all_text = 6; - * @param \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllText $var - * @return $this - */ - public function setAllText($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ImageTransformations\ImageTransformation\AllText::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * The color to use when redacting content from an image. If not - * specified, the default is black. - * - * Generated from protobuf field .google.privacy.dlp.v2.Color redaction_color = 3; - * @return \Google\Cloud\Dlp\V2\Color|null - */ - public function getRedactionColor() - { - return $this->redaction_color; - } - - public function hasRedactionColor() - { - return isset($this->redaction_color); - } - - public function clearRedactionColor() - { - unset($this->redaction_color); - } - - /** - * The color to use when redacting content from an image. If not - * specified, the default is black. - * - * Generated from protobuf field .google.privacy.dlp.v2.Color redaction_color = 3; - * @param \Google\Cloud\Dlp\V2\Color $var - * @return $this - */ - public function setRedactionColor($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Color::class); - $this->redaction_color = $var; - - return $this; - } - - /** - * @return string - */ - public function getTarget() - { - return $this->whichOneof("target"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ImageTransformation::class, \Google\Cloud\Dlp\V2\ImageTransformations_ImageTransformation::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllInfoTypes.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllInfoTypes.php deleted file mode 100644 index 67e3f138716d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllInfoTypes.php +++ /dev/null @@ -1,36 +0,0 @@ -google.privacy.dlp.v2.ImageTransformations.ImageTransformation.AllInfoTypes - */ -class AllInfoTypes extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AllInfoTypes::class, \Google\Cloud\Dlp\V2\ImageTransformations_ImageTransformation_AllInfoTypes::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllText.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllText.php deleted file mode 100644 index dc4389a8d1ea..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/AllText.php +++ /dev/null @@ -1,36 +0,0 @@ -google.privacy.dlp.v2.ImageTransformations.ImageTransformation.AllText - */ -class AllText extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AllText::class, \Google\Cloud\Dlp\V2\ImageTransformations_ImageTransformation_AllText::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/SelectedInfoTypes.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/SelectedInfoTypes.php deleted file mode 100644 index 4561d0012782..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ImageTransformations/ImageTransformation/SelectedInfoTypes.php +++ /dev/null @@ -1,74 +0,0 @@ -google.privacy.dlp.v2.ImageTransformations.ImageTransformation.SelectedInfoTypes - */ -class SelectedInfoTypes extends \Google\Protobuf\Internal\Message -{ - /** - * Required. InfoTypes to apply the transformation to. Required. Provided - * InfoType must be unique within the ImageTransformations message. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - private $info_types; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $info_types - * Required. InfoTypes to apply the transformation to. Required. Provided - * InfoType must be unique within the ImageTransformations message. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. InfoTypes to apply the transformation to. Required. Provided - * InfoType must be unique within the ImageTransformations message. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInfoTypes() - { - return $this->info_types; - } - - /** - * Required. InfoTypes to apply the transformation to. Required. Provided - * InfoType must be unique within the ImageTransformations message. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInfoTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_types = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SelectedInfoTypes::class, \Google\Cloud\Dlp\V2\ImageTransformations_ImageTransformation_SelectedInfoTypes::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoType.php deleted file mode 100644 index 7d1307eecacd..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoType.php +++ /dev/null @@ -1,173 +0,0 @@ -google.privacy.dlp.v2.InfoType - */ -class InfoType extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the information type. Either a name of your choosing when - * creating a CustomInfoType, or one of the names listed - * at - * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference - * when specifying a built-in type. When sending Cloud DLP results to Data - * Catalog, infoType names should conform to the pattern - * `[A-Za-z0-9$_-]{1,64}`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Optional version name for this InfoType. - * - * Generated from protobuf field string version = 2; - */ - protected $version = ''; - /** - * Optional custom sensitivity for this InfoType. - * This only applies to data profiling. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 3; - */ - protected $sensitivity_score = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name of the information type. Either a name of your choosing when - * creating a CustomInfoType, or one of the names listed - * at - * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference - * when specifying a built-in type. When sending Cloud DLP results to Data - * Catalog, infoType names should conform to the pattern - * `[A-Za-z0-9$_-]{1,64}`. - * @type string $version - * Optional version name for this InfoType. - * @type \Google\Cloud\Dlp\V2\SensitivityScore $sensitivity_score - * Optional custom sensitivity for this InfoType. - * This only applies to data profiling. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Name of the information type. Either a name of your choosing when - * creating a CustomInfoType, or one of the names listed - * at - * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference - * when specifying a built-in type. When sending Cloud DLP results to Data - * Catalog, infoType names should conform to the pattern - * `[A-Za-z0-9$_-]{1,64}`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name of the information type. Either a name of your choosing when - * creating a CustomInfoType, or one of the names listed - * at - * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference - * when specifying a built-in type. When sending Cloud DLP results to Data - * Catalog, infoType names should conform to the pattern - * `[A-Za-z0-9$_-]{1,64}`. - * - * 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; - } - - /** - * Optional version name for this InfoType. - * - * Generated from protobuf field string version = 2; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * Optional version name for this InfoType. - * - * 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; - } - - /** - * Optional custom sensitivity for this InfoType. - * This only applies to data profiling. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 3; - * @return \Google\Cloud\Dlp\V2\SensitivityScore|null - */ - public function getSensitivityScore() - { - return $this->sensitivity_score; - } - - public function hasSensitivityScore() - { - return isset($this->sensitivity_score); - } - - public function clearSensitivityScore() - { - unset($this->sensitivity_score); - } - - /** - * Optional custom sensitivity for this InfoType. - * This only applies to data profiling. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 3; - * @param \Google\Cloud\Dlp\V2\SensitivityScore $var - * @return $this - */ - public function setSensitivityScore($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SensitivityScore::class); - $this->sensitivity_score = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory.php deleted file mode 100644 index c1579ef0baed..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory.php +++ /dev/null @@ -1,145 +0,0 @@ -google.privacy.dlp.v2.InfoTypeCategory - */ -class InfoTypeCategory extends \Google\Protobuf\Internal\Message -{ - protected $category; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $location_category - * The region or country that issued the ID or document represented by the - * infoType. - * @type int $industry_category - * The group of relevant businesses where this infoType is commonly used - * @type int $type_category - * The class of identifiers where this infoType belongs - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The region or country that issued the ID or document represented by the - * infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeCategory.LocationCategory location_category = 1; - * @return int - */ - public function getLocationCategory() - { - return $this->readOneof(1); - } - - public function hasLocationCategory() - { - return $this->hasOneof(1); - } - - /** - * The region or country that issued the ID or document represented by the - * infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeCategory.LocationCategory location_category = 1; - * @param int $var - * @return $this - */ - public function setLocationCategory($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\InfoTypeCategory\LocationCategory::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The group of relevant businesses where this infoType is commonly used - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeCategory.IndustryCategory industry_category = 2; - * @return int - */ - public function getIndustryCategory() - { - return $this->readOneof(2); - } - - public function hasIndustryCategory() - { - return $this->hasOneof(2); - } - - /** - * The group of relevant businesses where this infoType is commonly used - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeCategory.IndustryCategory industry_category = 2; - * @param int $var - * @return $this - */ - public function setIndustryCategory($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\InfoTypeCategory\IndustryCategory::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The class of identifiers where this infoType belongs - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeCategory.TypeCategory type_category = 3; - * @return int - */ - public function getTypeCategory() - { - return $this->readOneof(3); - } - - public function hasTypeCategory() - { - return $this->hasOneof(3); - } - - /** - * The class of identifiers where this infoType belongs - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoTypeCategory.TypeCategory type_category = 3; - * @param int $var - * @return $this - */ - public function setTypeCategory($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\InfoTypeCategory\TypeCategory::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getCategory() - { - return $this->whichOneof("category"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/IndustryCategory.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/IndustryCategory.php deleted file mode 100644 index 429186610d6f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/IndustryCategory.php +++ /dev/null @@ -1,72 +0,0 @@ -google.privacy.dlp.v2.InfoTypeCategory.IndustryCategory - */ -class IndustryCategory -{ - /** - * Unused industry - * - * Generated from protobuf enum INDUSTRY_UNSPECIFIED = 0; - */ - const INDUSTRY_UNSPECIFIED = 0; - /** - * The infoType is typically used in the finance industry. - * - * Generated from protobuf enum FINANCE = 1; - */ - const FINANCE = 1; - /** - * The infoType is typically used in the health industry. - * - * Generated from protobuf enum HEALTH = 2; - */ - const HEALTH = 2; - /** - * The infoType is typically used in the telecommunications industry. - * - * Generated from protobuf enum TELECOMMUNICATIONS = 3; - */ - const TELECOMMUNICATIONS = 3; - - private static $valueToName = [ - self::INDUSTRY_UNSPECIFIED => 'INDUSTRY_UNSPECIFIED', - self::FINANCE => 'FINANCE', - self::HEALTH => 'HEALTH', - self::TELECOMMUNICATIONS => 'TELECOMMUNICATIONS', - ]; - - 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(IndustryCategory::class, \Google\Cloud\Dlp\V2\InfoTypeCategory_IndustryCategory::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/LocationCategory.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/LocationCategory.php deleted file mode 100644 index 5d6155f21604..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/LocationCategory.php +++ /dev/null @@ -1,392 +0,0 @@ -google.privacy.dlp.v2.InfoTypeCategory.LocationCategory - */ -class LocationCategory -{ - /** - * Unused location - * - * Generated from protobuf enum LOCATION_UNSPECIFIED = 0; - */ - const LOCATION_UNSPECIFIED = 0; - /** - * The infoType is not issued by or tied to a specific region, but is used - * almost everywhere. - * - * Generated from protobuf enum GLOBAL = 1; - */ - const PBGLOBAL = 1; - /** - * The infoType is typically used in Argentina. - * - * Generated from protobuf enum ARGENTINA = 2; - */ - const ARGENTINA = 2; - /** - * The infoType is typically used in Australia. - * - * Generated from protobuf enum AUSTRALIA = 3; - */ - const AUSTRALIA = 3; - /** - * The infoType is typically used in Azerbaijan. - * - * Generated from protobuf enum AZERBAIJAN = 48; - */ - const AZERBAIJAN = 48; - /** - * The infoType is typically used in Belgium. - * - * Generated from protobuf enum BELGIUM = 4; - */ - const BELGIUM = 4; - /** - * The infoType is typically used in Brazil. - * - * Generated from protobuf enum BRAZIL = 5; - */ - const BRAZIL = 5; - /** - * The infoType is typically used in Canada. - * - * Generated from protobuf enum CANADA = 6; - */ - const CANADA = 6; - /** - * The infoType is typically used in Chile. - * - * Generated from protobuf enum CHILE = 7; - */ - const CHILE = 7; - /** - * The infoType is typically used in China. - * - * Generated from protobuf enum CHINA = 8; - */ - const CHINA = 8; - /** - * The infoType is typically used in Colombia. - * - * Generated from protobuf enum COLOMBIA = 9; - */ - const COLOMBIA = 9; - /** - * The infoType is typically used in Croatia. - * - * Generated from protobuf enum CROATIA = 42; - */ - const CROATIA = 42; - /** - * The infoType is typically used in Denmark. - * - * Generated from protobuf enum DENMARK = 10; - */ - const DENMARK = 10; - /** - * The infoType is typically used in France. - * - * Generated from protobuf enum FRANCE = 11; - */ - const FRANCE = 11; - /** - * The infoType is typically used in Finland. - * - * Generated from protobuf enum FINLAND = 12; - */ - const FINLAND = 12; - /** - * The infoType is typically used in Germany. - * - * Generated from protobuf enum GERMANY = 13; - */ - const GERMANY = 13; - /** - * The infoType is typically used in Hong Kong. - * - * Generated from protobuf enum HONG_KONG = 14; - */ - const HONG_KONG = 14; - /** - * The infoType is typically used in India. - * - * Generated from protobuf enum INDIA = 15; - */ - const INDIA = 15; - /** - * The infoType is typically used in Indonesia. - * - * Generated from protobuf enum INDONESIA = 16; - */ - const INDONESIA = 16; - /** - * The infoType is typically used in Ireland. - * - * Generated from protobuf enum IRELAND = 17; - */ - const IRELAND = 17; - /** - * The infoType is typically used in Israel. - * - * Generated from protobuf enum ISRAEL = 18; - */ - const ISRAEL = 18; - /** - * The infoType is typically used in Italy. - * - * Generated from protobuf enum ITALY = 19; - */ - const ITALY = 19; - /** - * The infoType is typically used in Japan. - * - * Generated from protobuf enum JAPAN = 20; - */ - const JAPAN = 20; - /** - * The infoType is typically used in Kazakhstan. - * - * Generated from protobuf enum KAZAKHSTAN = 47; - */ - const KAZAKHSTAN = 47; - /** - * The infoType is typically used in Korea. - * - * Generated from protobuf enum KOREA = 21; - */ - const KOREA = 21; - /** - * The infoType is typically used in Mexico. - * - * Generated from protobuf enum MEXICO = 22; - */ - const MEXICO = 22; - /** - * The infoType is typically used in the Netherlands. - * - * Generated from protobuf enum THE_NETHERLANDS = 23; - */ - const THE_NETHERLANDS = 23; - /** - * The infoType is typically used in New Zealand. - * - * Generated from protobuf enum NEW_ZEALAND = 41; - */ - const NEW_ZEALAND = 41; - /** - * The infoType is typically used in Norway. - * - * Generated from protobuf enum NORWAY = 24; - */ - const NORWAY = 24; - /** - * The infoType is typically used in Paraguay. - * - * Generated from protobuf enum PARAGUAY = 25; - */ - const PARAGUAY = 25; - /** - * The infoType is typically used in Peru. - * - * Generated from protobuf enum PERU = 26; - */ - const PERU = 26; - /** - * The infoType is typically used in Poland. - * - * Generated from protobuf enum POLAND = 27; - */ - const POLAND = 27; - /** - * The infoType is typically used in Portugal. - * - * Generated from protobuf enum PORTUGAL = 28; - */ - const PORTUGAL = 28; - /** - * The infoType is typically used in Russia. - * - * Generated from protobuf enum RUSSIA = 44; - */ - const RUSSIA = 44; - /** - * The infoType is typically used in Singapore. - * - * Generated from protobuf enum SINGAPORE = 29; - */ - const SINGAPORE = 29; - /** - * The infoType is typically used in South Africa. - * - * Generated from protobuf enum SOUTH_AFRICA = 30; - */ - const SOUTH_AFRICA = 30; - /** - * The infoType is typically used in Spain. - * - * Generated from protobuf enum SPAIN = 31; - */ - const SPAIN = 31; - /** - * The infoType is typically used in Sweden. - * - * Generated from protobuf enum SWEDEN = 32; - */ - const SWEDEN = 32; - /** - * The infoType is typically used in Switzerland. - * - * Generated from protobuf enum SWITZERLAND = 43; - */ - const SWITZERLAND = 43; - /** - * The infoType is typically used in Taiwan. - * - * Generated from protobuf enum TAIWAN = 33; - */ - const TAIWAN = 33; - /** - * The infoType is typically used in Thailand. - * - * Generated from protobuf enum THAILAND = 34; - */ - const THAILAND = 34; - /** - * The infoType is typically used in Turkey. - * - * Generated from protobuf enum TURKEY = 35; - */ - const TURKEY = 35; - /** - * The infoType is typically used in Ukraine. - * - * Generated from protobuf enum UKRAINE = 45; - */ - const UKRAINE = 45; - /** - * The infoType is typically used in the United Kingdom. - * - * Generated from protobuf enum UNITED_KINGDOM = 36; - */ - const UNITED_KINGDOM = 36; - /** - * The infoType is typically used in the United States. - * - * Generated from protobuf enum UNITED_STATES = 37; - */ - const UNITED_STATES = 37; - /** - * The infoType is typically used in Uruguay. - * - * Generated from protobuf enum URUGUAY = 38; - */ - const URUGUAY = 38; - /** - * The infoType is typically used in Uzbekistan. - * - * Generated from protobuf enum UZBEKISTAN = 46; - */ - const UZBEKISTAN = 46; - /** - * The infoType is typically used in Venezuela. - * - * Generated from protobuf enum VENEZUELA = 39; - */ - const VENEZUELA = 39; - /** - * The infoType is typically used in Google internally. - * - * Generated from protobuf enum INTERNAL = 40; - */ - const INTERNAL = 40; - - private static $valueToName = [ - self::LOCATION_UNSPECIFIED => 'LOCATION_UNSPECIFIED', - self::PBGLOBAL => 'GLOBAL', - self::ARGENTINA => 'ARGENTINA', - self::AUSTRALIA => 'AUSTRALIA', - self::AZERBAIJAN => 'AZERBAIJAN', - self::BELGIUM => 'BELGIUM', - self::BRAZIL => 'BRAZIL', - self::CANADA => 'CANADA', - self::CHILE => 'CHILE', - self::CHINA => 'CHINA', - self::COLOMBIA => 'COLOMBIA', - self::CROATIA => 'CROATIA', - self::DENMARK => 'DENMARK', - self::FRANCE => 'FRANCE', - self::FINLAND => 'FINLAND', - self::GERMANY => 'GERMANY', - self::HONG_KONG => 'HONG_KONG', - self::INDIA => 'INDIA', - self::INDONESIA => 'INDONESIA', - self::IRELAND => 'IRELAND', - self::ISRAEL => 'ISRAEL', - self::ITALY => 'ITALY', - self::JAPAN => 'JAPAN', - self::KAZAKHSTAN => 'KAZAKHSTAN', - self::KOREA => 'KOREA', - self::MEXICO => 'MEXICO', - self::THE_NETHERLANDS => 'THE_NETHERLANDS', - self::NEW_ZEALAND => 'NEW_ZEALAND', - self::NORWAY => 'NORWAY', - self::PARAGUAY => 'PARAGUAY', - self::PERU => 'PERU', - self::POLAND => 'POLAND', - self::PORTUGAL => 'PORTUGAL', - self::RUSSIA => 'RUSSIA', - self::SINGAPORE => 'SINGAPORE', - self::SOUTH_AFRICA => 'SOUTH_AFRICA', - self::SPAIN => 'SPAIN', - self::SWEDEN => 'SWEDEN', - self::SWITZERLAND => 'SWITZERLAND', - self::TAIWAN => 'TAIWAN', - self::THAILAND => 'THAILAND', - self::TURKEY => 'TURKEY', - self::UKRAINE => 'UKRAINE', - self::UNITED_KINGDOM => 'UNITED_KINGDOM', - self::UNITED_STATES => 'UNITED_STATES', - self::URUGUAY => 'URUGUAY', - self::UZBEKISTAN => 'UZBEKISTAN', - self::VENEZUELA => 'VENEZUELA', - self::INTERNAL => 'INTERNAL', - ]; - - 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)) { - $pbconst = __CLASS__. '::PB' . strtoupper($name); - if (!defined($pbconst)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($pbconst); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LocationCategory::class, \Google\Cloud\Dlp\V2\InfoTypeCategory_LocationCategory::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/TypeCategory.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/TypeCategory.php deleted file mode 100644 index bbc6fd462069..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeCategory/TypeCategory.php +++ /dev/null @@ -1,104 +0,0 @@ -google.privacy.dlp.v2.InfoTypeCategory.TypeCategory - */ -class TypeCategory -{ - /** - * Unused type - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Personally identifiable information, for example, a - * name or phone number - * - * Generated from protobuf enum PII = 1; - */ - const PII = 1; - /** - * Personally identifiable information that is especially sensitive, for - * example, a passport number. - * - * Generated from protobuf enum SPII = 2; - */ - const SPII = 2; - /** - * Attributes that can partially identify someone, especially in - * combination with other attributes, like age, height, and gender. - * - * Generated from protobuf enum DEMOGRAPHIC = 3; - */ - const DEMOGRAPHIC = 3; - /** - * Confidential or secret information, for example, a password. - * - * Generated from protobuf enum CREDENTIAL = 4; - */ - const CREDENTIAL = 4; - /** - * An identification document issued by a government. - * - * Generated from protobuf enum GOVERNMENT_ID = 5; - */ - const GOVERNMENT_ID = 5; - /** - * A document, for example, a resume or source code. - * - * Generated from protobuf enum DOCUMENT = 6; - */ - const DOCUMENT = 6; - /** - * Information that is not sensitive on its own, but provides details about - * the circumstances surrounding an entity or an event. - * - * Generated from protobuf enum CONTEXTUAL_INFORMATION = 7; - */ - const CONTEXTUAL_INFORMATION = 7; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::PII => 'PII', - self::SPII => 'SPII', - self::DEMOGRAPHIC => 'DEMOGRAPHIC', - self::CREDENTIAL => 'CREDENTIAL', - self::GOVERNMENT_ID => 'GOVERNMENT_ID', - self::DOCUMENT => 'DOCUMENT', - self::CONTEXTUAL_INFORMATION => 'CONTEXTUAL_INFORMATION', - ]; - - 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(TypeCategory::class, \Google\Cloud\Dlp\V2\InfoTypeCategory_TypeCategory::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeDescription.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeDescription.php deleted file mode 100644 index 68864fe9391f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeDescription.php +++ /dev/null @@ -1,285 +0,0 @@ -google.privacy.dlp.v2.InfoTypeDescription - */ -class InfoTypeDescription extends \Google\Protobuf\Internal\Message -{ - /** - * Internal name of the infoType. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Human readable form of the infoType name. - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * Which parts of the API supports this InfoType. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeSupportedBy supported_by = 3; - */ - private $supported_by; - /** - * Description of the infotype. Translated when language is provided in the - * request. - * - * Generated from protobuf field string description = 4; - */ - protected $description = ''; - /** - * A list of available versions for the infotype. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.VersionDescription versions = 9; - */ - private $versions; - /** - * The category of the infoType. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeCategory categories = 10; - */ - private $categories; - /** - * The default sensitivity of the infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 11; - */ - protected $sensitivity_score = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Internal name of the infoType. - * @type string $display_name - * Human readable form of the infoType name. - * @type array|\Google\Protobuf\Internal\RepeatedField $supported_by - * Which parts of the API supports this InfoType. - * @type string $description - * Description of the infotype. Translated when language is provided in the - * request. - * @type array<\Google\Cloud\Dlp\V2\VersionDescription>|\Google\Protobuf\Internal\RepeatedField $versions - * A list of available versions for the infotype. - * @type array<\Google\Cloud\Dlp\V2\InfoTypeCategory>|\Google\Protobuf\Internal\RepeatedField $categories - * The category of the infoType. - * @type \Google\Cloud\Dlp\V2\SensitivityScore $sensitivity_score - * The default sensitivity of the infoType. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Internal name of the infoType. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Internal name of the infoType. - * - * 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; - } - - /** - * Human readable form of the infoType name. - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Human readable form of the infoType name. - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Which parts of the API supports this InfoType. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeSupportedBy supported_by = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSupportedBy() - { - return $this->supported_by; - } - - /** - * Which parts of the API supports this InfoType. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeSupportedBy supported_by = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSupportedBy($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\InfoTypeSupportedBy::class); - $this->supported_by = $arr; - - return $this; - } - - /** - * Description of the infotype. Translated when language is provided in the - * request. - * - * Generated from protobuf field string description = 4; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Description of the infotype. Translated when language is provided in the - * request. - * - * Generated from protobuf field string description = 4; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * A list of available versions for the infotype. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.VersionDescription versions = 9; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getVersions() - { - return $this->versions; - } - - /** - * A list of available versions for the infotype. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.VersionDescription versions = 9; - * @param array<\Google\Cloud\Dlp\V2\VersionDescription>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setVersions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\VersionDescription::class); - $this->versions = $arr; - - return $this; - } - - /** - * The category of the infoType. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeCategory categories = 10; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCategories() - { - return $this->categories; - } - - /** - * The category of the infoType. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeCategory categories = 10; - * @param array<\Google\Cloud\Dlp\V2\InfoTypeCategory>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCategories($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoTypeCategory::class); - $this->categories = $arr; - - return $this; - } - - /** - * The default sensitivity of the infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 11; - * @return \Google\Cloud\Dlp\V2\SensitivityScore|null - */ - public function getSensitivityScore() - { - return $this->sensitivity_score; - } - - public function hasSensitivityScore() - { - return isset($this->sensitivity_score); - } - - public function clearSensitivityScore() - { - unset($this->sensitivity_score); - } - - /** - * The default sensitivity of the infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 11; - * @param \Google\Cloud\Dlp\V2\SensitivityScore $var - * @return $this - */ - public function setSensitivityScore($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SensitivityScore::class); - $this->sensitivity_score = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeStats.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeStats.php deleted file mode 100644 index d597096908b4..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeStats.php +++ /dev/null @@ -1,111 +0,0 @@ -google.privacy.dlp.v2.InfoTypeStats - */ -class InfoTypeStats extends \Google\Protobuf\Internal\Message -{ - /** - * The type of finding this stat is for. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - */ - protected $info_type = null; - /** - * Number of findings for this infoType. - * - * Generated from protobuf field int64 count = 2; - */ - protected $count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InfoType $info_type - * The type of finding this stat is for. - * @type int|string $count - * Number of findings for this infoType. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The type of finding this stat is for. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getInfoType() - { - return $this->info_type; - } - - public function hasInfoType() - { - return isset($this->info_type); - } - - public function clearInfoType() - { - unset($this->info_type); - } - - /** - * The type of finding this stat is for. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_type = $var; - - return $this; - } - - /** - * Number of findings for this infoType. - * - * Generated from protobuf field int64 count = 2; - * @return int|string - */ - public function getCount() - { - return $this->count; - } - - /** - * Number of findings for this infoType. - * - * Generated from protobuf field int64 count = 2; - * @param int|string $var - * @return $this - */ - public function setCount($var) - { - GPBUtil::checkInt64($var); - $this->count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSummary.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSummary.php deleted file mode 100644 index e99cc8206155..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSummary.php +++ /dev/null @@ -1,116 +0,0 @@ -google.privacy.dlp.v2.InfoTypeSummary - */ -class InfoTypeSummary extends \Google\Protobuf\Internal\Message -{ - /** - * The infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - */ - protected $info_type = null; - /** - * Not populated for predicted infotypes. - * - * Generated from protobuf field int32 estimated_prevalence = 2 [deprecated = true]; - * @deprecated - */ - protected $estimated_prevalence = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InfoType $info_type - * The infoType. - * @type int $estimated_prevalence - * Not populated for predicted infotypes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getInfoType() - { - return $this->info_type; - } - - public function hasInfoType() - { - return isset($this->info_type); - } - - public function clearInfoType() - { - unset($this->info_type); - } - - /** - * The infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_type = $var; - - return $this; - } - - /** - * Not populated for predicted infotypes. - * - * Generated from protobuf field int32 estimated_prevalence = 2 [deprecated = true]; - * @return int - * @deprecated - */ - public function getEstimatedPrevalence() - { - @trigger_error('estimated_prevalence is deprecated.', E_USER_DEPRECATED); - return $this->estimated_prevalence; - } - - /** - * Not populated for predicted infotypes. - * - * Generated from protobuf field int32 estimated_prevalence = 2 [deprecated = true]; - * @param int $var - * @return $this - * @deprecated - */ - public function setEstimatedPrevalence($var) - { - @trigger_error('estimated_prevalence is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkInt32($var); - $this->estimated_prevalence = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSupportedBy.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSupportedBy.php deleted file mode 100644 index 57ea0fb34dad..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeSupportedBy.php +++ /dev/null @@ -1,61 +0,0 @@ -google.privacy.dlp.v2.InfoTypeSupportedBy - */ -class InfoTypeSupportedBy -{ - /** - * Unused. - * - * Generated from protobuf enum ENUM_TYPE_UNSPECIFIED = 0; - */ - const ENUM_TYPE_UNSPECIFIED = 0; - /** - * Supported by the inspect operations. - * - * Generated from protobuf enum INSPECT = 1; - */ - const INSPECT = 1; - /** - * Supported by the risk analysis operations. - * - * Generated from protobuf enum RISK_ANALYSIS = 2; - */ - const RISK_ANALYSIS = 2; - - private static $valueToName = [ - self::ENUM_TYPE_UNSPECIFIED => 'ENUM_TYPE_UNSPECIFIED', - self::INSPECT => 'INSPECT', - self::RISK_ANALYSIS => 'RISK_ANALYSIS', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations.php deleted file mode 100644 index c35f65c972d4..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations.php +++ /dev/null @@ -1,74 +0,0 @@ -google.privacy.dlp.v2.InfoTypeTransformations - */ -class InfoTypeTransformations extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Transformation for each infoType. Cannot specify more than one - * for a given infoType. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeTransformations.InfoTypeTransformation transformations = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $transformations; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\InfoTypeTransformations\InfoTypeTransformation>|\Google\Protobuf\Internal\RepeatedField $transformations - * Required. Transformation for each infoType. Cannot specify more than one - * for a given infoType. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Transformation for each infoType. Cannot specify more than one - * for a given infoType. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeTransformations.InfoTypeTransformation transformations = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTransformations() - { - return $this->transformations; - } - - /** - * Required. Transformation for each infoType. Cannot specify more than one - * for a given infoType. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeTransformations.InfoTypeTransformation transformations = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\Dlp\V2\InfoTypeTransformations\InfoTypeTransformation>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTransformations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoTypeTransformations\InfoTypeTransformation::class); - $this->transformations = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations/InfoTypeTransformation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations/InfoTypeTransformation.php deleted file mode 100644 index a3d95ca85835..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InfoTypeTransformations/InfoTypeTransformation.php +++ /dev/null @@ -1,123 +0,0 @@ -google.privacy.dlp.v2.InfoTypeTransformations.InfoTypeTransformation - */ -class InfoTypeTransformation extends \Google\Protobuf\Internal\Message -{ - /** - * InfoTypes to apply the transformation to. An empty list will cause - * this transformation to apply to all findings that correspond to - * infoTypes that were requested in `InspectConfig`. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; - */ - private $info_types; - /** - * Required. Primitive transformation to apply to the infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation primitive_transformation = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $primitive_transformation = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $info_types - * InfoTypes to apply the transformation to. An empty list will cause - * this transformation to apply to all findings that correspond to - * infoTypes that were requested in `InspectConfig`. - * @type \Google\Cloud\Dlp\V2\PrimitiveTransformation $primitive_transformation - * Required. Primitive transformation to apply to the infoType. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * InfoTypes to apply the transformation to. An empty list will cause - * this transformation to apply to all findings that correspond to - * infoTypes that were requested in `InspectConfig`. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInfoTypes() - { - return $this->info_types; - } - - /** - * InfoTypes to apply the transformation to. An empty list will cause - * this transformation to apply to all findings that correspond to - * infoTypes that were requested in `InspectConfig`. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; - * @param array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInfoTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_types = $arr; - - return $this; - } - - /** - * Required. Primitive transformation to apply to the infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation primitive_transformation = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\PrimitiveTransformation|null - */ - public function getPrimitiveTransformation() - { - return $this->primitive_transformation; - } - - public function hasPrimitiveTransformation() - { - return isset($this->primitive_transformation); - } - - public function clearPrimitiveTransformation() - { - unset($this->primitive_transformation); - } - - /** - * Required. Primitive transformation to apply to the infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation primitive_transformation = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\PrimitiveTransformation $var - * @return $this - */ - public function setPrimitiveTransformation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrimitiveTransformation::class); - $this->primitive_transformation = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(InfoTypeTransformation::class, \Google\Cloud\Dlp\V2\InfoTypeTransformations_InfoTypeTransformation::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig.php deleted file mode 100644 index a715717d009f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig.php +++ /dev/null @@ -1,495 +0,0 @@ -google.privacy.dlp.v2.InspectConfig - */ -class InspectConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Restricts what info_types to look for. The values must correspond to - * InfoType values returned by ListInfoTypes or listed at - * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference. - * When no InfoTypes or CustomInfoTypes are specified in a request, the - * system may automatically choose a default list of detectors to run, which - * may change over time. - * If you need precise control and predictability as to what detectors are - * run you should specify specific InfoTypes listed in the reference, - * otherwise a default list will be used, which may change over time. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; - */ - private $info_types; - /** - * Only returns findings equal to or above this threshold. The default is - * POSSIBLE. - * In general, the highest likelihood setting yields the fewest findings in - * results and the lowest chance of a false positive. For more information, - * see [Match - * likelihood](https://cloud.google.com/sensitive-data-protection/docs/likelihood). - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood min_likelihood = 2; - */ - protected $min_likelihood = 0; - /** - * Minimum likelihood per infotype. For each infotype, a user can specify a - * minimum likelihood. The system only returns a finding if its likelihood is - * above this threshold. If this field is not set, the system uses the - * InspectConfig min_likelihood. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectConfig.InfoTypeLikelihood min_likelihood_per_info_type = 11; - */ - private $min_likelihood_per_info_type; - /** - * Configuration to control the number of findings returned. - * This is not used for data profiling. - * When redacting sensitive data from images, finding limits don't apply. They - * can cause unexpected or inconsistent results, where only some data is - * redacted. Don't include finding limits in - * [RedactImage][google.privacy.dlp.v2.DlpService.RedactImage] - * requests. Otherwise, Cloud DLP returns an error. - * When set within an - * [InspectJobConfig][google.privacy.dlp.v2.InspectJobConfig], the specified - * maximum values aren't hard limits. If an inspection job reaches these - * limits, the job ends gradually, not abruptly. Therefore, the actual number - * of findings that Cloud DLP returns can be multiple times higher than these - * maximum values. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig.FindingLimits limits = 3; - */ - protected $limits = null; - /** - * When true, a contextual quote from the data that triggered a finding is - * included in the response; see - * [Finding.quote][google.privacy.dlp.v2.Finding.quote]. This is not used for - * data profiling. - * - * Generated from protobuf field bool include_quote = 4; - */ - protected $include_quote = false; - /** - * When true, excludes type information of the findings. - * This is not used for data profiling. - * - * Generated from protobuf field bool exclude_info_types = 5; - */ - protected $exclude_info_types = false; - /** - * CustomInfoTypes provided by the user. See - * https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes - * to learn more. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.CustomInfoType custom_info_types = 6; - */ - private $custom_info_types; - /** - * Deprecated and unused. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ContentOption content_options = 8; - */ - private $content_options; - /** - * Set of rules to apply to the findings for this InspectConfig. - * Exclusion rules, contained in the set are executed in the end, other - * rules are executed in the order they are specified for each info type. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectionRuleSet rule_set = 10; - */ - private $rule_set; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $info_types - * Restricts what info_types to look for. The values must correspond to - * InfoType values returned by ListInfoTypes or listed at - * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference. - * When no InfoTypes or CustomInfoTypes are specified in a request, the - * system may automatically choose a default list of detectors to run, which - * may change over time. - * If you need precise control and predictability as to what detectors are - * run you should specify specific InfoTypes listed in the reference, - * otherwise a default list will be used, which may change over time. - * @type int $min_likelihood - * Only returns findings equal to or above this threshold. The default is - * POSSIBLE. - * In general, the highest likelihood setting yields the fewest findings in - * results and the lowest chance of a false positive. For more information, - * see [Match - * likelihood](https://cloud.google.com/sensitive-data-protection/docs/likelihood). - * @type array<\Google\Cloud\Dlp\V2\InspectConfig\InfoTypeLikelihood>|\Google\Protobuf\Internal\RepeatedField $min_likelihood_per_info_type - * Minimum likelihood per infotype. For each infotype, a user can specify a - * minimum likelihood. The system only returns a finding if its likelihood is - * above this threshold. If this field is not set, the system uses the - * InspectConfig min_likelihood. - * @type \Google\Cloud\Dlp\V2\InspectConfig\FindingLimits $limits - * Configuration to control the number of findings returned. - * This is not used for data profiling. - * When redacting sensitive data from images, finding limits don't apply. They - * can cause unexpected or inconsistent results, where only some data is - * redacted. Don't include finding limits in - * [RedactImage][google.privacy.dlp.v2.DlpService.RedactImage] - * requests. Otherwise, Cloud DLP returns an error. - * When set within an - * [InspectJobConfig][google.privacy.dlp.v2.InspectJobConfig], the specified - * maximum values aren't hard limits. If an inspection job reaches these - * limits, the job ends gradually, not abruptly. Therefore, the actual number - * of findings that Cloud DLP returns can be multiple times higher than these - * maximum values. - * @type bool $include_quote - * When true, a contextual quote from the data that triggered a finding is - * included in the response; see - * [Finding.quote][google.privacy.dlp.v2.Finding.quote]. This is not used for - * data profiling. - * @type bool $exclude_info_types - * When true, excludes type information of the findings. - * This is not used for data profiling. - * @type array<\Google\Cloud\Dlp\V2\CustomInfoType>|\Google\Protobuf\Internal\RepeatedField $custom_info_types - * CustomInfoTypes provided by the user. See - * https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes - * to learn more. - * @type array|\Google\Protobuf\Internal\RepeatedField $content_options - * Deprecated and unused. - * @type array<\Google\Cloud\Dlp\V2\InspectionRuleSet>|\Google\Protobuf\Internal\RepeatedField $rule_set - * Set of rules to apply to the findings for this InspectConfig. - * Exclusion rules, contained in the set are executed in the end, other - * rules are executed in the order they are specified for each info type. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Restricts what info_types to look for. The values must correspond to - * InfoType values returned by ListInfoTypes or listed at - * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference. - * When no InfoTypes or CustomInfoTypes are specified in a request, the - * system may automatically choose a default list of detectors to run, which - * may change over time. - * If you need precise control and predictability as to what detectors are - * run you should specify specific InfoTypes listed in the reference, - * otherwise a default list will be used, which may change over time. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInfoTypes() - { - return $this->info_types; - } - - /** - * Restricts what info_types to look for. The values must correspond to - * InfoType values returned by ListInfoTypes or listed at - * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference. - * When no InfoTypes or CustomInfoTypes are specified in a request, the - * system may automatically choose a default list of detectors to run, which - * may change over time. - * If you need precise control and predictability as to what detectors are - * run you should specify specific InfoTypes listed in the reference, - * otherwise a default list will be used, which may change over time. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; - * @param array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInfoTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_types = $arr; - - return $this; - } - - /** - * Only returns findings equal to or above this threshold. The default is - * POSSIBLE. - * In general, the highest likelihood setting yields the fewest findings in - * results and the lowest chance of a false positive. For more information, - * see [Match - * likelihood](https://cloud.google.com/sensitive-data-protection/docs/likelihood). - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood min_likelihood = 2; - * @return int - */ - public function getMinLikelihood() - { - return $this->min_likelihood; - } - - /** - * Only returns findings equal to or above this threshold. The default is - * POSSIBLE. - * In general, the highest likelihood setting yields the fewest findings in - * results and the lowest chance of a false positive. For more information, - * see [Match - * likelihood](https://cloud.google.com/sensitive-data-protection/docs/likelihood). - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood min_likelihood = 2; - * @param int $var - * @return $this - */ - public function setMinLikelihood($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\Likelihood::class); - $this->min_likelihood = $var; - - return $this; - } - - /** - * Minimum likelihood per infotype. For each infotype, a user can specify a - * minimum likelihood. The system only returns a finding if its likelihood is - * above this threshold. If this field is not set, the system uses the - * InspectConfig min_likelihood. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectConfig.InfoTypeLikelihood min_likelihood_per_info_type = 11; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMinLikelihoodPerInfoType() - { - return $this->min_likelihood_per_info_type; - } - - /** - * Minimum likelihood per infotype. For each infotype, a user can specify a - * minimum likelihood. The system only returns a finding if its likelihood is - * above this threshold. If this field is not set, the system uses the - * InspectConfig min_likelihood. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectConfig.InfoTypeLikelihood min_likelihood_per_info_type = 11; - * @param array<\Google\Cloud\Dlp\V2\InspectConfig\InfoTypeLikelihood>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMinLikelihoodPerInfoType($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InspectConfig\InfoTypeLikelihood::class); - $this->min_likelihood_per_info_type = $arr; - - return $this; - } - - /** - * Configuration to control the number of findings returned. - * This is not used for data profiling. - * When redacting sensitive data from images, finding limits don't apply. They - * can cause unexpected or inconsistent results, where only some data is - * redacted. Don't include finding limits in - * [RedactImage][google.privacy.dlp.v2.DlpService.RedactImage] - * requests. Otherwise, Cloud DLP returns an error. - * When set within an - * [InspectJobConfig][google.privacy.dlp.v2.InspectJobConfig], the specified - * maximum values aren't hard limits. If an inspection job reaches these - * limits, the job ends gradually, not abruptly. Therefore, the actual number - * of findings that Cloud DLP returns can be multiple times higher than these - * maximum values. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig.FindingLimits limits = 3; - * @return \Google\Cloud\Dlp\V2\InspectConfig\FindingLimits|null - */ - public function getLimits() - { - return $this->limits; - } - - public function hasLimits() - { - return isset($this->limits); - } - - public function clearLimits() - { - unset($this->limits); - } - - /** - * Configuration to control the number of findings returned. - * This is not used for data profiling. - * When redacting sensitive data from images, finding limits don't apply. They - * can cause unexpected or inconsistent results, where only some data is - * redacted. Don't include finding limits in - * [RedactImage][google.privacy.dlp.v2.DlpService.RedactImage] - * requests. Otherwise, Cloud DLP returns an error. - * When set within an - * [InspectJobConfig][google.privacy.dlp.v2.InspectJobConfig], the specified - * maximum values aren't hard limits. If an inspection job reaches these - * limits, the job ends gradually, not abruptly. Therefore, the actual number - * of findings that Cloud DLP returns can be multiple times higher than these - * maximum values. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig.FindingLimits limits = 3; - * @param \Google\Cloud\Dlp\V2\InspectConfig\FindingLimits $var - * @return $this - */ - public function setLimits($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig\FindingLimits::class); - $this->limits = $var; - - return $this; - } - - /** - * When true, a contextual quote from the data that triggered a finding is - * included in the response; see - * [Finding.quote][google.privacy.dlp.v2.Finding.quote]. This is not used for - * data profiling. - * - * Generated from protobuf field bool include_quote = 4; - * @return bool - */ - public function getIncludeQuote() - { - return $this->include_quote; - } - - /** - * When true, a contextual quote from the data that triggered a finding is - * included in the response; see - * [Finding.quote][google.privacy.dlp.v2.Finding.quote]. This is not used for - * data profiling. - * - * Generated from protobuf field bool include_quote = 4; - * @param bool $var - * @return $this - */ - public function setIncludeQuote($var) - { - GPBUtil::checkBool($var); - $this->include_quote = $var; - - return $this; - } - - /** - * When true, excludes type information of the findings. - * This is not used for data profiling. - * - * Generated from protobuf field bool exclude_info_types = 5; - * @return bool - */ - public function getExcludeInfoTypes() - { - return $this->exclude_info_types; - } - - /** - * When true, excludes type information of the findings. - * This is not used for data profiling. - * - * Generated from protobuf field bool exclude_info_types = 5; - * @param bool $var - * @return $this - */ - public function setExcludeInfoTypes($var) - { - GPBUtil::checkBool($var); - $this->exclude_info_types = $var; - - return $this; - } - - /** - * CustomInfoTypes provided by the user. See - * https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes - * to learn more. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.CustomInfoType custom_info_types = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCustomInfoTypes() - { - return $this->custom_info_types; - } - - /** - * CustomInfoTypes provided by the user. See - * https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes - * to learn more. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.CustomInfoType custom_info_types = 6; - * @param array<\Google\Cloud\Dlp\V2\CustomInfoType>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCustomInfoTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\CustomInfoType::class); - $this->custom_info_types = $arr; - - return $this; - } - - /** - * Deprecated and unused. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ContentOption content_options = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getContentOptions() - { - return $this->content_options; - } - - /** - * Deprecated and unused. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ContentOption content_options = 8; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setContentOptions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Dlp\V2\ContentOption::class); - $this->content_options = $arr; - - return $this; - } - - /** - * Set of rules to apply to the findings for this InspectConfig. - * Exclusion rules, contained in the set are executed in the end, other - * rules are executed in the order they are specified for each info type. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectionRuleSet rule_set = 10; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRuleSet() - { - return $this->rule_set; - } - - /** - * Set of rules to apply to the findings for this InspectConfig. - * Exclusion rules, contained in the set are executed in the end, other - * rules are executed in the order they are specified for each info type. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectionRuleSet rule_set = 10; - * @param array<\Google\Cloud\Dlp\V2\InspectionRuleSet>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRuleSet($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InspectionRuleSet::class); - $this->rule_set = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits.php deleted file mode 100644 index 6c89c0b17c00..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits.php +++ /dev/null @@ -1,204 +0,0 @@ -google.privacy.dlp.v2.InspectConfig.FindingLimits - */ -class FindingLimits extends \Google\Protobuf\Internal\Message -{ - /** - * Max number of findings that are returned for each item scanned. - * When set within an - * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], - * this field is ignored. - * This value isn't a hard limit. If the number of findings for an item - * reaches this limit, the inspection of that item ends gradually, not - * abruptly. Therefore, the actual number of findings that Cloud DLP returns - * for the item can be multiple times higher than this value. - * - * Generated from protobuf field int32 max_findings_per_item = 1; - */ - protected $max_findings_per_item = 0; - /** - * Max number of findings that are returned per request or job. - * If you set this field in an - * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], the - * resulting maximum value is the value that you set or 3,000, whichever is - * lower. - * This value isn't a hard limit. If an inspection reaches this limit, the - * inspection ends gradually, not abruptly. Therefore, the actual number of - * findings that Cloud DLP returns can be multiple times higher than this - * value. - * - * Generated from protobuf field int32 max_findings_per_request = 2; - */ - protected $max_findings_per_request = 0; - /** - * Configuration of findings limit given for specified infoTypes. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectConfig.FindingLimits.InfoTypeLimit max_findings_per_info_type = 3; - */ - private $max_findings_per_info_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $max_findings_per_item - * Max number of findings that are returned for each item scanned. - * When set within an - * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], - * this field is ignored. - * This value isn't a hard limit. If the number of findings for an item - * reaches this limit, the inspection of that item ends gradually, not - * abruptly. Therefore, the actual number of findings that Cloud DLP returns - * for the item can be multiple times higher than this value. - * @type int $max_findings_per_request - * Max number of findings that are returned per request or job. - * If you set this field in an - * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], the - * resulting maximum value is the value that you set or 3,000, whichever is - * lower. - * This value isn't a hard limit. If an inspection reaches this limit, the - * inspection ends gradually, not abruptly. Therefore, the actual number of - * findings that Cloud DLP returns can be multiple times higher than this - * value. - * @type array<\Google\Cloud\Dlp\V2\InspectConfig\FindingLimits\InfoTypeLimit>|\Google\Protobuf\Internal\RepeatedField $max_findings_per_info_type - * Configuration of findings limit given for specified infoTypes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Max number of findings that are returned for each item scanned. - * When set within an - * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], - * this field is ignored. - * This value isn't a hard limit. If the number of findings for an item - * reaches this limit, the inspection of that item ends gradually, not - * abruptly. Therefore, the actual number of findings that Cloud DLP returns - * for the item can be multiple times higher than this value. - * - * Generated from protobuf field int32 max_findings_per_item = 1; - * @return int - */ - public function getMaxFindingsPerItem() - { - return $this->max_findings_per_item; - } - - /** - * Max number of findings that are returned for each item scanned. - * When set within an - * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], - * this field is ignored. - * This value isn't a hard limit. If the number of findings for an item - * reaches this limit, the inspection of that item ends gradually, not - * abruptly. Therefore, the actual number of findings that Cloud DLP returns - * for the item can be multiple times higher than this value. - * - * Generated from protobuf field int32 max_findings_per_item = 1; - * @param int $var - * @return $this - */ - public function setMaxFindingsPerItem($var) - { - GPBUtil::checkInt32($var); - $this->max_findings_per_item = $var; - - return $this; - } - - /** - * Max number of findings that are returned per request or job. - * If you set this field in an - * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], the - * resulting maximum value is the value that you set or 3,000, whichever is - * lower. - * This value isn't a hard limit. If an inspection reaches this limit, the - * inspection ends gradually, not abruptly. Therefore, the actual number of - * findings that Cloud DLP returns can be multiple times higher than this - * value. - * - * Generated from protobuf field int32 max_findings_per_request = 2; - * @return int - */ - public function getMaxFindingsPerRequest() - { - return $this->max_findings_per_request; - } - - /** - * Max number of findings that are returned per request or job. - * If you set this field in an - * [InspectContentRequest][google.privacy.dlp.v2.InspectContentRequest], the - * resulting maximum value is the value that you set or 3,000, whichever is - * lower. - * This value isn't a hard limit. If an inspection reaches this limit, the - * inspection ends gradually, not abruptly. Therefore, the actual number of - * findings that Cloud DLP returns can be multiple times higher than this - * value. - * - * Generated from protobuf field int32 max_findings_per_request = 2; - * @param int $var - * @return $this - */ - public function setMaxFindingsPerRequest($var) - { - GPBUtil::checkInt32($var); - $this->max_findings_per_request = $var; - - return $this; - } - - /** - * Configuration of findings limit given for specified infoTypes. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectConfig.FindingLimits.InfoTypeLimit max_findings_per_info_type = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMaxFindingsPerInfoType() - { - return $this->max_findings_per_info_type; - } - - /** - * Configuration of findings limit given for specified infoTypes. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectConfig.FindingLimits.InfoTypeLimit max_findings_per_info_type = 3; - * @param array<\Google\Cloud\Dlp\V2\InspectConfig\FindingLimits\InfoTypeLimit>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMaxFindingsPerInfoType($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InspectConfig\FindingLimits\InfoTypeLimit::class); - $this->max_findings_per_info_type = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(FindingLimits::class, \Google\Cloud\Dlp\V2\InspectConfig_FindingLimits::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits/InfoTypeLimit.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits/InfoTypeLimit.php deleted file mode 100644 index cfab8ab3f528..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/FindingLimits/InfoTypeLimit.php +++ /dev/null @@ -1,127 +0,0 @@ -google.privacy.dlp.v2.InspectConfig.FindingLimits.InfoTypeLimit - */ -class InfoTypeLimit extends \Google\Protobuf\Internal\Message -{ - /** - * Type of information the findings limit applies to. Only one limit per - * info_type should be provided. If InfoTypeLimit does not have an - * info_type, the DLP API applies the limit against all info_types that - * are found but not specified in another InfoTypeLimit. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - */ - protected $info_type = null; - /** - * Max findings limit for the given infoType. - * - * Generated from protobuf field int32 max_findings = 2; - */ - protected $max_findings = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InfoType $info_type - * Type of information the findings limit applies to. Only one limit per - * info_type should be provided. If InfoTypeLimit does not have an - * info_type, the DLP API applies the limit against all info_types that - * are found but not specified in another InfoTypeLimit. - * @type int $max_findings - * Max findings limit for the given infoType. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Type of information the findings limit applies to. Only one limit per - * info_type should be provided. If InfoTypeLimit does not have an - * info_type, the DLP API applies the limit against all info_types that - * are found but not specified in another InfoTypeLimit. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getInfoType() - { - return $this->info_type; - } - - public function hasInfoType() - { - return isset($this->info_type); - } - - public function clearInfoType() - { - unset($this->info_type); - } - - /** - * Type of information the findings limit applies to. Only one limit per - * info_type should be provided. If InfoTypeLimit does not have an - * info_type, the DLP API applies the limit against all info_types that - * are found but not specified in another InfoTypeLimit. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_type = $var; - - return $this; - } - - /** - * Max findings limit for the given infoType. - * - * Generated from protobuf field int32 max_findings = 2; - * @return int - */ - public function getMaxFindings() - { - return $this->max_findings; - } - - /** - * Max findings limit for the given infoType. - * - * Generated from protobuf field int32 max_findings = 2; - * @param int $var - * @return $this - */ - public function setMaxFindings($var) - { - GPBUtil::checkInt32($var); - $this->max_findings = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(InfoTypeLimit::class, \Google\Cloud\Dlp\V2\InspectConfig_FindingLimits_InfoTypeLimit::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/InfoTypeLikelihood.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/InfoTypeLikelihood.php deleted file mode 100644 index 2de7fc9c089c..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectConfig/InfoTypeLikelihood.php +++ /dev/null @@ -1,130 +0,0 @@ -google.privacy.dlp.v2.InspectConfig.InfoTypeLikelihood - */ -class InfoTypeLikelihood extends \Google\Protobuf\Internal\Message -{ - /** - * Type of information the likelihood threshold applies to. Only one - * likelihood per info_type should be provided. If InfoTypeLikelihood does - * not have an info_type, the configuration fails. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - */ - protected $info_type = null; - /** - * Only returns findings equal to or above this threshold. This field is - * required or else the configuration fails. - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood min_likelihood = 2; - */ - protected $min_likelihood = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InfoType $info_type - * Type of information the likelihood threshold applies to. Only one - * likelihood per info_type should be provided. If InfoTypeLikelihood does - * not have an info_type, the configuration fails. - * @type int $min_likelihood - * Only returns findings equal to or above this threshold. This field is - * required or else the configuration fails. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Type of information the likelihood threshold applies to. Only one - * likelihood per info_type should be provided. If InfoTypeLikelihood does - * not have an info_type, the configuration fails. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getInfoType() - { - return $this->info_type; - } - - public function hasInfoType() - { - return isset($this->info_type); - } - - public function clearInfoType() - { - unset($this->info_type); - } - - /** - * Type of information the likelihood threshold applies to. Only one - * likelihood per info_type should be provided. If InfoTypeLikelihood does - * not have an info_type, the configuration fails. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_type = $var; - - return $this; - } - - /** - * Only returns findings equal to or above this threshold. This field is - * required or else the configuration fails. - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood min_likelihood = 2; - * @return int - */ - public function getMinLikelihood() - { - return $this->min_likelihood; - } - - /** - * Only returns findings equal to or above this threshold. This field is - * required or else the configuration fails. - * - * Generated from protobuf field .google.privacy.dlp.v2.Likelihood min_likelihood = 2; - * @param int $var - * @return $this - */ - public function setMinLikelihood($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\Likelihood::class); - $this->min_likelihood = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(InfoTypeLikelihood::class, \Google\Cloud\Dlp\V2\InspectConfig_InfoTypeLikelihood::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentRequest.php deleted file mode 100644 index 16159653005f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentRequest.php +++ /dev/null @@ -1,287 +0,0 @@ -google.privacy.dlp.v2.InspectContentRequest - */ -class InspectContentRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Configuration for the inspector. What specified here will override - * the template referenced by the inspect_template_name argument. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; - */ - protected $inspect_config = null; - /** - * The item to inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 3; - */ - protected $item = null; - /** - * Template to use. Any configuration directly specified in - * inspect_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * - * Generated from protobuf field string inspect_template_name = 4; - */ - protected $inspect_template_name = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - */ - protected $location_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config - * Configuration for the inspector. What specified here will override - * the template referenced by the inspect_template_name argument. - * @type \Google\Cloud\Dlp\V2\ContentItem $item - * The item to inspect. - * @type string $inspect_template_name - * Template to use. Any configuration directly specified in - * inspect_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Configuration for the inspector. What specified here will override - * the template referenced by the inspect_template_name argument. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; - * @return \Google\Cloud\Dlp\V2\InspectConfig|null - */ - public function getInspectConfig() - { - return $this->inspect_config; - } - - public function hasInspectConfig() - { - return isset($this->inspect_config); - } - - public function clearInspectConfig() - { - unset($this->inspect_config); - } - - /** - * Configuration for the inspector. What specified here will override - * the template referenced by the inspect_template_name argument. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; - * @param \Google\Cloud\Dlp\V2\InspectConfig $var - * @return $this - */ - public function setInspectConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); - $this->inspect_config = $var; - - return $this; - } - - /** - * The item to inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 3; - * @return \Google\Cloud\Dlp\V2\ContentItem|null - */ - public function getItem() - { - return $this->item; - } - - public function hasItem() - { - return isset($this->item); - } - - public function clearItem() - { - unset($this->item); - } - - /** - * The item to inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 3; - * @param \Google\Cloud\Dlp\V2\ContentItem $var - * @return $this - */ - public function setItem($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ContentItem::class); - $this->item = $var; - - return $this; - } - - /** - * Template to use. Any configuration directly specified in - * inspect_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * - * Generated from protobuf field string inspect_template_name = 4; - * @return string - */ - public function getInspectTemplateName() - { - return $this->inspect_template_name; - } - - /** - * Template to use. Any configuration directly specified in - * inspect_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * - * Generated from protobuf field string inspect_template_name = 4; - * @param string $var - * @return $this - */ - public function setInspectTemplateName($var) - { - GPBUtil::checkString($var, True); - $this->inspect_template_name = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentResponse.php deleted file mode 100644 index 1bb36f9c611f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectContentResponse.php +++ /dev/null @@ -1,77 +0,0 @@ -google.privacy.dlp.v2.InspectContentResponse - */ -class InspectContentResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The findings. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectResult result = 1; - */ - protected $result = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InspectResult $result - * The findings. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The findings. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectResult result = 1; - * @return \Google\Cloud\Dlp\V2\InspectResult|null - */ - public function getResult() - { - return $this->result; - } - - public function hasResult() - { - return isset($this->result); - } - - public function clearResult() - { - unset($this->result); - } - - /** - * The findings. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectResult result = 1; - * @param \Google\Cloud\Dlp\V2\InspectResult $var - * @return $this - */ - public function setResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectResult::class); - $this->result = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails.php deleted file mode 100644 index 4c234301fb6e..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails.php +++ /dev/null @@ -1,121 +0,0 @@ -google.privacy.dlp.v2.InspectDataSourceDetails - */ -class InspectDataSourceDetails extends \Google\Protobuf\Internal\Message -{ - /** - * The configuration used for this job. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails.RequestedOptions requested_options = 2; - */ - protected $requested_options = null; - /** - * A summary of the outcome of this inspection job. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails.Result result = 3; - */ - protected $result = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InspectDataSourceDetails\RequestedOptions $requested_options - * The configuration used for this job. - * @type \Google\Cloud\Dlp\V2\InspectDataSourceDetails\Result $result - * A summary of the outcome of this inspection job. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The configuration used for this job. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails.RequestedOptions requested_options = 2; - * @return \Google\Cloud\Dlp\V2\InspectDataSourceDetails\RequestedOptions|null - */ - public function getRequestedOptions() - { - return $this->requested_options; - } - - public function hasRequestedOptions() - { - return isset($this->requested_options); - } - - public function clearRequestedOptions() - { - unset($this->requested_options); - } - - /** - * The configuration used for this job. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails.RequestedOptions requested_options = 2; - * @param \Google\Cloud\Dlp\V2\InspectDataSourceDetails\RequestedOptions $var - * @return $this - */ - public function setRequestedOptions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectDataSourceDetails\RequestedOptions::class); - $this->requested_options = $var; - - return $this; - } - - /** - * A summary of the outcome of this inspection job. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails.Result result = 3; - * @return \Google\Cloud\Dlp\V2\InspectDataSourceDetails\Result|null - */ - public function getResult() - { - return $this->result; - } - - public function hasResult() - { - return isset($this->result); - } - - public function clearResult() - { - unset($this->result); - } - - /** - * A summary of the outcome of this inspection job. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectDataSourceDetails.Result result = 3; - * @param \Google\Cloud\Dlp\V2\InspectDataSourceDetails\Result $var - * @return $this - */ - public function setResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectDataSourceDetails\Result::class); - $this->result = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/RequestedOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/RequestedOptions.php deleted file mode 100644 index c0e230424154..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/RequestedOptions.php +++ /dev/null @@ -1,128 +0,0 @@ -google.privacy.dlp.v2.InspectDataSourceDetails.RequestedOptions - */ -class RequestedOptions extends \Google\Protobuf\Internal\Message -{ - /** - * If run with an InspectTemplate, a snapshot of its state at the time of - * this run. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate snapshot_inspect_template = 1; - */ - protected $snapshot_inspect_template = null; - /** - * Inspect config. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig job_config = 3; - */ - protected $job_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InspectTemplate $snapshot_inspect_template - * If run with an InspectTemplate, a snapshot of its state at the time of - * this run. - * @type \Google\Cloud\Dlp\V2\InspectJobConfig $job_config - * Inspect config. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * If run with an InspectTemplate, a snapshot of its state at the time of - * this run. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate snapshot_inspect_template = 1; - * @return \Google\Cloud\Dlp\V2\InspectTemplate|null - */ - public function getSnapshotInspectTemplate() - { - return $this->snapshot_inspect_template; - } - - public function hasSnapshotInspectTemplate() - { - return isset($this->snapshot_inspect_template); - } - - public function clearSnapshotInspectTemplate() - { - unset($this->snapshot_inspect_template); - } - - /** - * If run with an InspectTemplate, a snapshot of its state at the time of - * this run. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate snapshot_inspect_template = 1; - * @param \Google\Cloud\Dlp\V2\InspectTemplate $var - * @return $this - */ - public function setSnapshotInspectTemplate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectTemplate::class); - $this->snapshot_inspect_template = $var; - - return $this; - } - - /** - * Inspect config. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig job_config = 3; - * @return \Google\Cloud\Dlp\V2\InspectJobConfig|null - */ - public function getJobConfig() - { - return $this->job_config; - } - - public function hasJobConfig() - { - return isset($this->job_config); - } - - public function clearJobConfig() - { - unset($this->job_config); - } - - /** - * Inspect config. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig job_config = 3; - * @param \Google\Cloud\Dlp\V2\InspectJobConfig $var - * @return $this - */ - public function setJobConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectJobConfig::class); - $this->job_config = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RequestedOptions::class, \Google\Cloud\Dlp\V2\InspectDataSourceDetails_RequestedOptions::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/Result.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/Result.php deleted file mode 100644 index 45e94c9da3c8..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectDataSourceDetails/Result.php +++ /dev/null @@ -1,224 +0,0 @@ -google.privacy.dlp.v2.InspectDataSourceDetails.Result - */ -class Result extends \Google\Protobuf\Internal\Message -{ - /** - * Total size in bytes that were processed. - * - * Generated from protobuf field int64 processed_bytes = 1; - */ - protected $processed_bytes = 0; - /** - * Estimate of the number of bytes to process. - * - * Generated from protobuf field int64 total_estimated_bytes = 2; - */ - protected $total_estimated_bytes = 0; - /** - * Statistics of how many instances of each info type were found during - * inspect job. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeStats info_type_stats = 3; - */ - private $info_type_stats; - /** - * Number of rows scanned after sampling and time filtering (applicable for - * row based stores such as BigQuery). - * - * Generated from protobuf field int64 num_rows_processed = 5; - */ - protected $num_rows_processed = 0; - /** - * Statistics related to the processing of hybrid inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridInspectStatistics hybrid_stats = 7; - */ - protected $hybrid_stats = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $processed_bytes - * Total size in bytes that were processed. - * @type int|string $total_estimated_bytes - * Estimate of the number of bytes to process. - * @type array<\Google\Cloud\Dlp\V2\InfoTypeStats>|\Google\Protobuf\Internal\RepeatedField $info_type_stats - * Statistics of how many instances of each info type were found during - * inspect job. - * @type int|string $num_rows_processed - * Number of rows scanned after sampling and time filtering (applicable for - * row based stores such as BigQuery). - * @type \Google\Cloud\Dlp\V2\HybridInspectStatistics $hybrid_stats - * Statistics related to the processing of hybrid inspect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Total size in bytes that were processed. - * - * Generated from protobuf field int64 processed_bytes = 1; - * @return int|string - */ - public function getProcessedBytes() - { - return $this->processed_bytes; - } - - /** - * Total size in bytes that were processed. - * - * Generated from protobuf field int64 processed_bytes = 1; - * @param int|string $var - * @return $this - */ - public function setProcessedBytes($var) - { - GPBUtil::checkInt64($var); - $this->processed_bytes = $var; - - return $this; - } - - /** - * Estimate of the number of bytes to process. - * - * Generated from protobuf field int64 total_estimated_bytes = 2; - * @return int|string - */ - public function getTotalEstimatedBytes() - { - return $this->total_estimated_bytes; - } - - /** - * Estimate of the number of bytes to process. - * - * Generated from protobuf field int64 total_estimated_bytes = 2; - * @param int|string $var - * @return $this - */ - public function setTotalEstimatedBytes($var) - { - GPBUtil::checkInt64($var); - $this->total_estimated_bytes = $var; - - return $this; - } - - /** - * Statistics of how many instances of each info type were found during - * inspect job. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeStats info_type_stats = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInfoTypeStats() - { - return $this->info_type_stats; - } - - /** - * Statistics of how many instances of each info type were found during - * inspect job. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeStats info_type_stats = 3; - * @param array<\Google\Cloud\Dlp\V2\InfoTypeStats>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInfoTypeStats($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoTypeStats::class); - $this->info_type_stats = $arr; - - return $this; - } - - /** - * Number of rows scanned after sampling and time filtering (applicable for - * row based stores such as BigQuery). - * - * Generated from protobuf field int64 num_rows_processed = 5; - * @return int|string - */ - public function getNumRowsProcessed() - { - return $this->num_rows_processed; - } - - /** - * Number of rows scanned after sampling and time filtering (applicable for - * row based stores such as BigQuery). - * - * Generated from protobuf field int64 num_rows_processed = 5; - * @param int|string $var - * @return $this - */ - public function setNumRowsProcessed($var) - { - GPBUtil::checkInt64($var); - $this->num_rows_processed = $var; - - return $this; - } - - /** - * Statistics related to the processing of hybrid inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridInspectStatistics hybrid_stats = 7; - * @return \Google\Cloud\Dlp\V2\HybridInspectStatistics|null - */ - public function getHybridStats() - { - return $this->hybrid_stats; - } - - public function hasHybridStats() - { - return isset($this->hybrid_stats); - } - - public function clearHybridStats() - { - unset($this->hybrid_stats); - } - - /** - * Statistics related to the processing of hybrid inspect. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridInspectStatistics hybrid_stats = 7; - * @param \Google\Cloud\Dlp\V2\HybridInspectStatistics $var - * @return $this - */ - public function setHybridStats($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\HybridInspectStatistics::class); - $this->hybrid_stats = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Result::class, \Google\Cloud\Dlp\V2\InspectDataSourceDetails_Result::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectJobConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectJobConfig.php deleted file mode 100644 index 3163d015f708..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectJobConfig.php +++ /dev/null @@ -1,197 +0,0 @@ -google.privacy.dlp.v2.InspectJobConfig - */ -class InspectJobConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The data to scan. - * - * Generated from protobuf field .google.privacy.dlp.v2.StorageConfig storage_config = 1; - */ - protected $storage_config = null; - /** - * How and what to scan for. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; - */ - protected $inspect_config = null; - /** - * If provided, will be used as the default for all values in InspectConfig. - * `inspect_config` will be merged into the values persisted as part of the - * template. - * - * Generated from protobuf field string inspect_template_name = 3; - */ - protected $inspect_template_name = ''; - /** - * Actions to execute at the completion of the job. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Action actions = 4; - */ - private $actions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\StorageConfig $storage_config - * The data to scan. - * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config - * How and what to scan for. - * @type string $inspect_template_name - * If provided, will be used as the default for all values in InspectConfig. - * `inspect_config` will be merged into the values persisted as part of the - * template. - * @type array<\Google\Cloud\Dlp\V2\Action>|\Google\Protobuf\Internal\RepeatedField $actions - * Actions to execute at the completion of the job. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The data to scan. - * - * Generated from protobuf field .google.privacy.dlp.v2.StorageConfig storage_config = 1; - * @return \Google\Cloud\Dlp\V2\StorageConfig|null - */ - public function getStorageConfig() - { - return $this->storage_config; - } - - public function hasStorageConfig() - { - return isset($this->storage_config); - } - - public function clearStorageConfig() - { - unset($this->storage_config); - } - - /** - * The data to scan. - * - * Generated from protobuf field .google.privacy.dlp.v2.StorageConfig storage_config = 1; - * @param \Google\Cloud\Dlp\V2\StorageConfig $var - * @return $this - */ - public function setStorageConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StorageConfig::class); - $this->storage_config = $var; - - return $this; - } - - /** - * How and what to scan for. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; - * @return \Google\Cloud\Dlp\V2\InspectConfig|null - */ - public function getInspectConfig() - { - return $this->inspect_config; - } - - public function hasInspectConfig() - { - return isset($this->inspect_config); - } - - public function clearInspectConfig() - { - unset($this->inspect_config); - } - - /** - * How and what to scan for. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; - * @param \Google\Cloud\Dlp\V2\InspectConfig $var - * @return $this - */ - public function setInspectConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); - $this->inspect_config = $var; - - return $this; - } - - /** - * If provided, will be used as the default for all values in InspectConfig. - * `inspect_config` will be merged into the values persisted as part of the - * template. - * - * Generated from protobuf field string inspect_template_name = 3; - * @return string - */ - public function getInspectTemplateName() - { - return $this->inspect_template_name; - } - - /** - * If provided, will be used as the default for all values in InspectConfig. - * `inspect_config` will be merged into the values persisted as part of the - * template. - * - * Generated from protobuf field string inspect_template_name = 3; - * @param string $var - * @return $this - */ - public function setInspectTemplateName($var) - { - GPBUtil::checkString($var, True); - $this->inspect_template_name = $var; - - return $this; - } - - /** - * Actions to execute at the completion of the job. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Action actions = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getActions() - { - return $this->actions; - } - - /** - * Actions to execute at the completion of the job. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Action actions = 4; - * @param array<\Google\Cloud\Dlp\V2\Action>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setActions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Action::class); - $this->actions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectResult.php deleted file mode 100644 index b929d0e4e696..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectResult.php +++ /dev/null @@ -1,121 +0,0 @@ -google.privacy.dlp.v2.InspectResult - */ -class InspectResult extends \Google\Protobuf\Internal\Message -{ - /** - * List of findings for an item. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Finding findings = 1; - */ - private $findings; - /** - * If true, then this item might have more findings than were returned, - * and the findings returned are an arbitrary subset of all findings. - * The findings list might be truncated because the input items were too - * large, or because the server reached the maximum amount of resources - * allowed for a single API call. For best results, divide the input into - * smaller batches. - * - * Generated from protobuf field bool findings_truncated = 2; - */ - protected $findings_truncated = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\Finding>|\Google\Protobuf\Internal\RepeatedField $findings - * List of findings for an item. - * @type bool $findings_truncated - * If true, then this item might have more findings than were returned, - * and the findings returned are an arbitrary subset of all findings. - * The findings list might be truncated because the input items were too - * large, or because the server reached the maximum amount of resources - * allowed for a single API call. For best results, divide the input into - * smaller batches. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of findings for an item. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Finding findings = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFindings() - { - return $this->findings; - } - - /** - * List of findings for an item. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Finding findings = 1; - * @param array<\Google\Cloud\Dlp\V2\Finding>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFindings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Finding::class); - $this->findings = $arr; - - return $this; - } - - /** - * If true, then this item might have more findings than were returned, - * and the findings returned are an arbitrary subset of all findings. - * The findings list might be truncated because the input items were too - * large, or because the server reached the maximum amount of resources - * allowed for a single API call. For best results, divide the input into - * smaller batches. - * - * Generated from protobuf field bool findings_truncated = 2; - * @return bool - */ - public function getFindingsTruncated() - { - return $this->findings_truncated; - } - - /** - * If true, then this item might have more findings than were returned, - * and the findings returned are an arbitrary subset of all findings. - * The findings list might be truncated because the input items were too - * large, or because the server reached the maximum amount of resources - * allowed for a single API call. For best results, divide the input into - * smaller batches. - * - * Generated from protobuf field bool findings_truncated = 2; - * @param bool $var - * @return $this - */ - public function setFindingsTruncated($var) - { - GPBUtil::checkBool($var); - $this->findings_truncated = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectTemplate.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectTemplate.php deleted file mode 100644 index 9dec2b293b5f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectTemplate.php +++ /dev/null @@ -1,283 +0,0 @@ -google.privacy.dlp.v2.InspectTemplate - */ -class InspectTemplate extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The template name. - * The template will have one of the following formats: - * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR - * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`; - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Display name (max 256 chars). - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * Short description (max 256 chars). - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * Output only. The creation timestamp of an inspectTemplate. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The last update timestamp of an inspectTemplate. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * The core content of the template. Configuration of the scanning process. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 6; - */ - protected $inspect_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The template name. - * The template will have one of the following formats: - * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR - * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`; - * @type string $display_name - * Display name (max 256 chars). - * @type string $description - * Short description (max 256 chars). - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The creation timestamp of an inspectTemplate. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The last update timestamp of an inspectTemplate. - * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config - * The core content of the template. Configuration of the scanning process. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The template name. - * The template will have one of the following formats: - * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR - * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`; - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The template name. - * The template will have one of the following formats: - * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR - * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`; - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Display name (max 256 chars). - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Display name (max 256 chars). - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Short description (max 256 chars). - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Short description (max 256 chars). - * - * 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; - } - - /** - * Output only. The creation timestamp of an inspectTemplate. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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 creation timestamp of an inspectTemplate. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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 last update timestamp of an inspectTemplate. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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 last update timestamp of an inspectTemplate. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * The core content of the template. Configuration of the scanning process. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 6; - * @return \Google\Cloud\Dlp\V2\InspectConfig|null - */ - public function getInspectConfig() - { - return $this->inspect_config; - } - - public function hasInspectConfig() - { - return isset($this->inspect_config); - } - - public function clearInspectConfig() - { - unset($this->inspect_config); - } - - /** - * The core content of the template. Configuration of the scanning process. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 6; - * @param \Google\Cloud\Dlp\V2\InspectConfig $var - * @return $this - */ - public function setInspectConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); - $this->inspect_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRule.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRule.php deleted file mode 100644 index a1854d0497c6..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRule.php +++ /dev/null @@ -1,109 +0,0 @@ -google.privacy.dlp.v2.InspectionRule - */ -class InspectionRule extends \Google\Protobuf\Internal\Message -{ - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule $hotword_rule - * Hotword-based detection rule. - * @type \Google\Cloud\Dlp\V2\ExclusionRule $exclusion_rule - * Exclusion rule. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Hotword-based detection rule. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.HotwordRule hotword_rule = 1; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule|null - */ - public function getHotwordRule() - { - return $this->readOneof(1); - } - - public function hasHotwordRule() - { - return $this->hasOneof(1); - } - - /** - * Hotword-based detection rule. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.DetectionRule.HotwordRule hotword_rule = 1; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule $var - * @return $this - */ - public function setHotwordRule($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\DetectionRule\HotwordRule::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Exclusion rule. - * - * Generated from protobuf field .google.privacy.dlp.v2.ExclusionRule exclusion_rule = 2; - * @return \Google\Cloud\Dlp\V2\ExclusionRule|null - */ - public function getExclusionRule() - { - return $this->readOneof(2); - } - - public function hasExclusionRule() - { - return $this->hasOneof(2); - } - - /** - * Exclusion rule. - * - * Generated from protobuf field .google.privacy.dlp.v2.ExclusionRule exclusion_rule = 2; - * @param \Google\Cloud\Dlp\V2\ExclusionRule $var - * @return $this - */ - public function setExclusionRule($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ExclusionRule::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRuleSet.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRuleSet.php deleted file mode 100644 index 5ee0f98dd54b..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/InspectionRuleSet.php +++ /dev/null @@ -1,102 +0,0 @@ -google.privacy.dlp.v2.InspectionRuleSet - */ -class InspectionRuleSet extends \Google\Protobuf\Internal\Message -{ - /** - * List of infoTypes this rule set is applied to. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; - */ - private $info_types; - /** - * Set of rules to be applied to infoTypes. The rules are applied in order. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectionRule rules = 2; - */ - private $rules; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $info_types - * List of infoTypes this rule set is applied to. - * @type array<\Google\Cloud\Dlp\V2\InspectionRule>|\Google\Protobuf\Internal\RepeatedField $rules - * Set of rules to be applied to infoTypes. The rules are applied in order. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of infoTypes this rule set is applied to. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInfoTypes() - { - return $this->info_types; - } - - /** - * List of infoTypes this rule set is applied to. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoType info_types = 1; - * @param array<\Google\Cloud\Dlp\V2\InfoType>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInfoTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_types = $arr; - - return $this; - } - - /** - * Set of rules to be applied to infoTypes. The rules are applied in order. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectionRule rules = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRules() - { - return $this->rules; - } - - /** - * Set of rules to be applied to infoTypes. The rules are applied in order. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectionRule rules = 2; - * @param array<\Google\Cloud\Dlp\V2\InspectionRule>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InspectionRule::class); - $this->rules = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger.php deleted file mode 100644 index d09ba0071108..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger.php +++ /dev/null @@ -1,442 +0,0 @@ -google.privacy.dlp.v2.JobTrigger - */ -class JobTrigger extends \Google\Protobuf\Internal\Message -{ - /** - * Unique resource name for the triggeredJob, assigned by the service when the - * triggeredJob is created, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Display name (max 100 chars) - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * User provided description (max 256 chars) - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * A list of triggers which will be OR'ed together. Only one in the list - * needs to trigger for a job to be started. The list may contain only - * a single Schedule trigger and must have at least one object. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.JobTrigger.Trigger triggers = 5; - */ - private $triggers; - /** - * Output only. A stream of errors encountered when the trigger was activated. - * Repeated errors may result in the JobTrigger automatically being paused. - * Will return the last 100 errors. Whenever the JobTrigger is modified - * this list will be cleared. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $errors; - /** - * Output only. The creation timestamp of a triggeredJob. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The last update timestamp of a triggeredJob. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. The timestamp of the last time this trigger executed. - * - * Generated from protobuf field .google.protobuf.Timestamp last_run_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $last_run_time = null; - /** - * Required. A status for this trigger. - * - * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger.Status status = 10 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $status = 0; - protected $job; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Unique resource name for the triggeredJob, assigned by the service when the - * triggeredJob is created, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * @type string $display_name - * Display name (max 100 chars) - * @type string $description - * User provided description (max 256 chars) - * @type \Google\Cloud\Dlp\V2\InspectJobConfig $inspect_job - * For inspect jobs, a snapshot of the configuration. - * @type array<\Google\Cloud\Dlp\V2\JobTrigger\Trigger>|\Google\Protobuf\Internal\RepeatedField $triggers - * A list of triggers which will be OR'ed together. Only one in the list - * needs to trigger for a job to be started. The list may contain only - * a single Schedule trigger and must have at least one object. - * @type array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $errors - * Output only. A stream of errors encountered when the trigger was activated. - * Repeated errors may result in the JobTrigger automatically being paused. - * Will return the last 100 errors. Whenever the JobTrigger is modified - * this list will be cleared. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The creation timestamp of a triggeredJob. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The last update timestamp of a triggeredJob. - * @type \Google\Protobuf\Timestamp $last_run_time - * Output only. The timestamp of the last time this trigger executed. - * @type int $status - * Required. A status for this trigger. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Unique resource name for the triggeredJob, assigned by the service when the - * triggeredJob is created, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Unique resource name for the triggeredJob, assigned by the service when the - * triggeredJob is created, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * 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; - } - - /** - * Display name (max 100 chars) - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Display name (max 100 chars) - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * User provided description (max 256 chars) - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * User provided description (max 256 chars) - * - * 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; - } - - /** - * For inspect jobs, a snapshot of the configuration. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig inspect_job = 4; - * @return \Google\Cloud\Dlp\V2\InspectJobConfig|null - */ - public function getInspectJob() - { - return $this->readOneof(4); - } - - public function hasInspectJob() - { - return $this->hasOneof(4); - } - - /** - * For inspect jobs, a snapshot of the configuration. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectJobConfig inspect_job = 4; - * @param \Google\Cloud\Dlp\V2\InspectJobConfig $var - * @return $this - */ - public function setInspectJob($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectJobConfig::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * A list of triggers which will be OR'ed together. Only one in the list - * needs to trigger for a job to be started. The list may contain only - * a single Schedule trigger and must have at least one object. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.JobTrigger.Trigger triggers = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTriggers() - { - return $this->triggers; - } - - /** - * A list of triggers which will be OR'ed together. Only one in the list - * needs to trigger for a job to be started. The list may contain only - * a single Schedule trigger and must have at least one object. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.JobTrigger.Trigger triggers = 5; - * @param array<\Google\Cloud\Dlp\V2\JobTrigger\Trigger>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTriggers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\JobTrigger\Trigger::class); - $this->triggers = $arr; - - return $this; - } - - /** - * Output only. A stream of errors encountered when the trigger was activated. - * Repeated errors may result in the JobTrigger automatically being paused. - * Will return the last 100 errors. Whenever the JobTrigger is modified - * this list will be cleared. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getErrors() - { - return $this->errors; - } - - /** - * Output only. A stream of errors encountered when the trigger was activated. - * Repeated errors may result in the JobTrigger automatically being paused. - * Will return the last 100 errors. Whenever the JobTrigger is modified - * this list will be cleared. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setErrors($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Error::class); - $this->errors = $arr; - - return $this; - } - - /** - * Output only. The creation timestamp of a triggeredJob. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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 creation timestamp of a triggeredJob. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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 last update timestamp of a triggeredJob. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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 last update timestamp of a triggeredJob. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Output only. The timestamp of the last time this trigger executed. - * - * Generated from protobuf field .google.protobuf.Timestamp last_run_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getLastRunTime() - { - return $this->last_run_time; - } - - public function hasLastRunTime() - { - return isset($this->last_run_time); - } - - public function clearLastRunTime() - { - unset($this->last_run_time); - } - - /** - * Output only. The timestamp of the last time this trigger executed. - * - * Generated from protobuf field .google.protobuf.Timestamp last_run_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setLastRunTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->last_run_time = $var; - - return $this; - } - - /** - * Required. A status for this trigger. - * - * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger.Status status = 10 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getStatus() - { - return $this->status; - } - - /** - * Required. A status for this trigger. - * - * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger.Status status = 10 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\JobTrigger\Status::class); - $this->status = $var; - - return $this; - } - - /** - * @return string - */ - public function getJob() - { - return $this->whichOneof("job"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Status.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Status.php deleted file mode 100644 index aa040ce1b3a4..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Status.php +++ /dev/null @@ -1,74 +0,0 @@ -google.privacy.dlp.v2.JobTrigger.Status - */ -class Status -{ - /** - * Unused. - * - * Generated from protobuf enum STATUS_UNSPECIFIED = 0; - */ - const STATUS_UNSPECIFIED = 0; - /** - * Trigger is healthy. - * - * Generated from protobuf enum HEALTHY = 1; - */ - const HEALTHY = 1; - /** - * Trigger is temporarily paused. - * - * Generated from protobuf enum PAUSED = 2; - */ - const PAUSED = 2; - /** - * Trigger is cancelled and can not be resumed. - * - * Generated from protobuf enum CANCELLED = 3; - */ - const CANCELLED = 3; - - private static $valueToName = [ - self::STATUS_UNSPECIFIED => 'STATUS_UNSPECIFIED', - self::HEALTHY => 'HEALTHY', - self::PAUSED => 'PAUSED', - self::CANCELLED => 'CANCELLED', - ]; - - 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(Status::class, \Google\Cloud\Dlp\V2\JobTrigger_Status::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Trigger.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Trigger.php deleted file mode 100644 index fc12ffebbe29..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/JobTrigger/Trigger.php +++ /dev/null @@ -1,111 +0,0 @@ -google.privacy.dlp.v2.JobTrigger.Trigger - */ -class Trigger extends \Google\Protobuf\Internal\Message -{ - protected $trigger; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\Schedule $schedule - * Create a job on a repeating basis based on the elapse of time. - * @type \Google\Cloud\Dlp\V2\Manual $manual - * For use with hybrid jobs. Jobs must be manually created and finished. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Create a job on a repeating basis based on the elapse of time. - * - * Generated from protobuf field .google.privacy.dlp.v2.Schedule schedule = 1; - * @return \Google\Cloud\Dlp\V2\Schedule|null - */ - public function getSchedule() - { - return $this->readOneof(1); - } - - public function hasSchedule() - { - return $this->hasOneof(1); - } - - /** - * Create a job on a repeating basis based on the elapse of time. - * - * Generated from protobuf field .google.privacy.dlp.v2.Schedule schedule = 1; - * @param \Google\Cloud\Dlp\V2\Schedule $var - * @return $this - */ - public function setSchedule($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Schedule::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * For use with hybrid jobs. Jobs must be manually created and finished. - * - * Generated from protobuf field .google.privacy.dlp.v2.Manual manual = 2; - * @return \Google\Cloud\Dlp\V2\Manual|null - */ - public function getManual() - { - return $this->readOneof(2); - } - - public function hasManual() - { - return $this->hasOneof(2); - } - - /** - * For use with hybrid jobs. Jobs must be manually created and finished. - * - * Generated from protobuf field .google.privacy.dlp.v2.Manual manual = 2; - * @param \Google\Cloud\Dlp\V2\Manual $var - * @return $this - */ - public function setManual($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Manual::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getTrigger() - { - return $this->whichOneof("trigger"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Trigger::class, \Google\Cloud\Dlp\V2\JobTrigger_Trigger::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key.php deleted file mode 100644 index e21d17e612db..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key.php +++ /dev/null @@ -1,150 +0,0 @@ -google.privacy.dlp.v2.Key - */ -class Key extends \Google\Protobuf\Internal\Message -{ - /** - * Entities are partitioned into subsets, currently identified by a project - * ID and namespace ID. - * Queries are scoped to a single partition. - * - * Generated from protobuf field .google.privacy.dlp.v2.PartitionId partition_id = 1; - */ - protected $partition_id = null; - /** - * The entity path. - * An entity path consists of one or more elements composed of a kind and a - * string or numerical identifier, which identify entities. The first - * element identifies a _root entity_, the second element identifies - * a _child_ of the root entity, the third element identifies a child of the - * second entity, and so forth. The entities identified by all prefixes of - * the path are called the element's _ancestors_. - * A path can never be empty, and a path can have at most 100 elements. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Key.PathElement path = 2; - */ - private $path; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\PartitionId $partition_id - * Entities are partitioned into subsets, currently identified by a project - * ID and namespace ID. - * Queries are scoped to a single partition. - * @type array<\Google\Cloud\Dlp\V2\Key\PathElement>|\Google\Protobuf\Internal\RepeatedField $path - * The entity path. - * An entity path consists of one or more elements composed of a kind and a - * string or numerical identifier, which identify entities. The first - * element identifies a _root entity_, the second element identifies - * a _child_ of the root entity, the third element identifies a child of the - * second entity, and so forth. The entities identified by all prefixes of - * the path are called the element's _ancestors_. - * A path can never be empty, and a path can have at most 100 elements. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Entities are partitioned into subsets, currently identified by a project - * ID and namespace ID. - * Queries are scoped to a single partition. - * - * Generated from protobuf field .google.privacy.dlp.v2.PartitionId partition_id = 1; - * @return \Google\Cloud\Dlp\V2\PartitionId|null - */ - public function getPartitionId() - { - return $this->partition_id; - } - - public function hasPartitionId() - { - return isset($this->partition_id); - } - - public function clearPartitionId() - { - unset($this->partition_id); - } - - /** - * Entities are partitioned into subsets, currently identified by a project - * ID and namespace ID. - * Queries are scoped to a single partition. - * - * Generated from protobuf field .google.privacy.dlp.v2.PartitionId partition_id = 1; - * @param \Google\Cloud\Dlp\V2\PartitionId $var - * @return $this - */ - public function setPartitionId($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PartitionId::class); - $this->partition_id = $var; - - return $this; - } - - /** - * The entity path. - * An entity path consists of one or more elements composed of a kind and a - * string or numerical identifier, which identify entities. The first - * element identifies a _root entity_, the second element identifies - * a _child_ of the root entity, the third element identifies a child of the - * second entity, and so forth. The entities identified by all prefixes of - * the path are called the element's _ancestors_. - * A path can never be empty, and a path can have at most 100 elements. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Key.PathElement path = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPath() - { - return $this->path; - } - - /** - * The entity path. - * An entity path consists of one or more elements composed of a kind and a - * string or numerical identifier, which identify entities. The first - * element identifies a _root entity_, the second element identifies - * a _child_ of the root entity, the third element identifies a child of the - * second entity, and so forth. The entities identified by all prefixes of - * the path are called the element's _ancestors_. - * A path can never be empty, and a path can have at most 100 elements. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Key.PathElement path = 2; - * @param array<\Google\Cloud\Dlp\V2\Key\PathElement>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPath($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Key\PathElement::class); - $this->path = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key/PathElement.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key/PathElement.php deleted file mode 100644 index 6850456e3a22..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Key/PathElement.php +++ /dev/null @@ -1,174 +0,0 @@ -google.privacy.dlp.v2.Key.PathElement - */ -class PathElement extends \Google\Protobuf\Internal\Message -{ - /** - * The kind of the entity. - * A kind matching regex `__.*__` is reserved/read-only. - * A kind must not contain more than 1500 bytes when UTF-8 encoded. - * Cannot be `""`. - * - * Generated from protobuf field string kind = 1; - */ - protected $kind = ''; - protected $id_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $kind - * The kind of the entity. - * A kind matching regex `__.*__` is reserved/read-only. - * A kind must not contain more than 1500 bytes when UTF-8 encoded. - * Cannot be `""`. - * @type int|string $id - * The auto-allocated ID of the entity. - * Never equal to zero. Values less than zero are discouraged and may not - * be supported in the future. - * @type string $name - * The name of the entity. - * A name matching regex `__.*__` is reserved/read-only. - * A name must not be more than 1500 bytes when UTF-8 encoded. - * Cannot be `""`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * The kind of the entity. - * A kind matching regex `__.*__` is reserved/read-only. - * A kind must not contain more than 1500 bytes when UTF-8 encoded. - * Cannot be `""`. - * - * Generated from protobuf field string kind = 1; - * @return string - */ - public function getKind() - { - return $this->kind; - } - - /** - * The kind of the entity. - * A kind matching regex `__.*__` is reserved/read-only. - * A kind must not contain more than 1500 bytes when UTF-8 encoded. - * Cannot be `""`. - * - * Generated from protobuf field string kind = 1; - * @param string $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkString($var, True); - $this->kind = $var; - - return $this; - } - - /** - * The auto-allocated ID of the entity. - * Never equal to zero. Values less than zero are discouraged and may not - * be supported in the future. - * - * Generated from protobuf field int64 id = 2; - * @return int|string - */ - public function getId() - { - return $this->readOneof(2); - } - - public function hasId() - { - return $this->hasOneof(2); - } - - /** - * The auto-allocated ID of the entity. - * Never equal to zero. Values less than zero are discouraged and may not - * be supported in the future. - * - * Generated from protobuf field int64 id = 2; - * @param int|string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkInt64($var); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The name of the entity. - * A name matching regex `__.*__` is reserved/read-only. - * A name must not be more than 1500 bytes when UTF-8 encoded. - * Cannot be `""`. - * - * Generated from protobuf field string name = 3; - * @return string - */ - public function getName() - { - return $this->readOneof(3); - } - - public function hasName() - { - return $this->hasOneof(3); - } - - /** - * The name of the entity. - * A name matching regex `__.*__` is reserved/read-only. - * A name must not be more than 1500 bytes when UTF-8 encoded. - * Cannot be `""`. - * - * Generated from protobuf field string name = 3; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getIdType() - { - return $this->whichOneof("id_type"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PathElement::class, \Google\Cloud\Dlp\V2\Key_PathElement::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KindExpression.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KindExpression.php deleted file mode 100644 index 76d319fa474f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KindExpression.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.KindExpression - */ -class KindExpression extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the kind. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the kind. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * The name of the kind. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the kind. - * - * 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; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KmsWrappedCryptoKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KmsWrappedCryptoKey.php deleted file mode 100644 index 19894467aa2e..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/KmsWrappedCryptoKey.php +++ /dev/null @@ -1,109 +0,0 @@ -google.privacy.dlp.v2.KmsWrappedCryptoKey - */ -class KmsWrappedCryptoKey extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The wrapped data crypto key. - * - * Generated from protobuf field bytes wrapped_key = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $wrapped_key = ''; - /** - * Required. The resource name of the KMS CryptoKey to use for unwrapping. - * - * Generated from protobuf field string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $crypto_key_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $wrapped_key - * Required. The wrapped data crypto key. - * @type string $crypto_key_name - * Required. The resource name of the KMS CryptoKey to use for unwrapping. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. The wrapped data crypto key. - * - * Generated from protobuf field bytes wrapped_key = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getWrappedKey() - { - return $this->wrapped_key; - } - - /** - * Required. The wrapped data crypto key. - * - * Generated from protobuf field bytes wrapped_key = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setWrappedKey($var) - { - GPBUtil::checkString($var, False); - $this->wrapped_key = $var; - - return $this; - } - - /** - * Required. The resource name of the KMS CryptoKey to use for unwrapping. - * - * Generated from protobuf field string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCryptoKeyName() - { - return $this->crypto_key_name; - } - - /** - * Required. The resource name of the KMS CryptoKey to use for unwrapping. - * - * Generated from protobuf field string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCryptoKeyName($var) - { - GPBUtil::checkString($var, True); - $this->crypto_key_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryConfig.php deleted file mode 100644 index 01eb8bd279ee..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryConfig.php +++ /dev/null @@ -1,169 +0,0 @@ -google.privacy.dlp.v2.LargeCustomDictionaryConfig - */ -class LargeCustomDictionaryConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Location to store dictionary artifacts in Cloud Storage. These files - * will only be accessible by project owners and the DLP API. If any of these - * artifacts are modified, the dictionary is considered invalid and can no - * longer be used. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStoragePath output_path = 1; - */ - protected $output_path = null; - protected $source; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\CloudStoragePath $output_path - * Location to store dictionary artifacts in Cloud Storage. These files - * will only be accessible by project owners and the DLP API. If any of these - * artifacts are modified, the dictionary is considered invalid and can no - * longer be used. - * @type \Google\Cloud\Dlp\V2\CloudStorageFileSet $cloud_storage_file_set - * Set of files containing newline-delimited lists of dictionary phrases. - * @type \Google\Cloud\Dlp\V2\BigQueryField $big_query_field - * Field in a BigQuery table where each cell represents a dictionary phrase. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Location to store dictionary artifacts in Cloud Storage. These files - * will only be accessible by project owners and the DLP API. If any of these - * artifacts are modified, the dictionary is considered invalid and can no - * longer be used. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStoragePath output_path = 1; - * @return \Google\Cloud\Dlp\V2\CloudStoragePath|null - */ - public function getOutputPath() - { - return $this->output_path; - } - - public function hasOutputPath() - { - return isset($this->output_path); - } - - public function clearOutputPath() - { - unset($this->output_path); - } - - /** - * Location to store dictionary artifacts in Cloud Storage. These files - * will only be accessible by project owners and the DLP API. If any of these - * artifacts are modified, the dictionary is considered invalid and can no - * longer be used. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStoragePath output_path = 1; - * @param \Google\Cloud\Dlp\V2\CloudStoragePath $var - * @return $this - */ - public function setOutputPath($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudStoragePath::class); - $this->output_path = $var; - - return $this; - } - - /** - * Set of files containing newline-delimited lists of dictionary phrases. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageFileSet cloud_storage_file_set = 2; - * @return \Google\Cloud\Dlp\V2\CloudStorageFileSet|null - */ - public function getCloudStorageFileSet() - { - return $this->readOneof(2); - } - - public function hasCloudStorageFileSet() - { - return $this->hasOneof(2); - } - - /** - * Set of files containing newline-delimited lists of dictionary phrases. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageFileSet cloud_storage_file_set = 2; - * @param \Google\Cloud\Dlp\V2\CloudStorageFileSet $var - * @return $this - */ - public function setCloudStorageFileSet($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudStorageFileSet::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Field in a BigQuery table where each cell represents a dictionary phrase. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryField big_query_field = 3; - * @return \Google\Cloud\Dlp\V2\BigQueryField|null - */ - public function getBigQueryField() - { - return $this->readOneof(3); - } - - public function hasBigQueryField() - { - return $this->hasOneof(3); - } - - /** - * Field in a BigQuery table where each cell represents a dictionary phrase. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryField big_query_field = 3; - * @param \Google\Cloud\Dlp\V2\BigQueryField $var - * @return $this - */ - public function setBigQueryField($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryField::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getSource() - { - return $this->whichOneof("source"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryStats.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryStats.php deleted file mode 100644 index 3e6a9284724e..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/LargeCustomDictionaryStats.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.LargeCustomDictionaryStats - */ -class LargeCustomDictionaryStats extends \Google\Protobuf\Internal\Message -{ - /** - * Approximate number of distinct phrases in the dictionary. - * - * Generated from protobuf field int64 approx_num_phrases = 1; - */ - protected $approx_num_phrases = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $approx_num_phrases - * Approximate number of distinct phrases in the dictionary. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Approximate number of distinct phrases in the dictionary. - * - * Generated from protobuf field int64 approx_num_phrases = 1; - * @return int|string - */ - public function getApproxNumPhrases() - { - return $this->approx_num_phrases; - } - - /** - * Approximate number of distinct phrases in the dictionary. - * - * Generated from protobuf field int64 approx_num_phrases = 1; - * @param int|string $var - * @return $this - */ - public function setApproxNumPhrases($var) - { - GPBUtil::checkInt64($var); - $this->approx_num_phrases = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Likelihood.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Likelihood.php deleted file mode 100644 index bcc9e96e6120..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Likelihood.php +++ /dev/null @@ -1,93 +0,0 @@ -google.privacy.dlp.v2.Likelihood - */ -class Likelihood -{ - /** - * Default value; same as POSSIBLE. - * - * Generated from protobuf enum LIKELIHOOD_UNSPECIFIED = 0; - */ - const LIKELIHOOD_UNSPECIFIED = 0; - /** - * Highest chance of a false positive. - * - * Generated from protobuf enum VERY_UNLIKELY = 1; - */ - const VERY_UNLIKELY = 1; - /** - * High chance of a false positive. - * - * Generated from protobuf enum UNLIKELY = 2; - */ - const UNLIKELY = 2; - /** - * Some matching signals. The default value. - * - * Generated from protobuf enum POSSIBLE = 3; - */ - const POSSIBLE = 3; - /** - * Low chance of a false positive. - * - * Generated from protobuf enum LIKELY = 4; - */ - const LIKELY = 4; - /** - * Confidence level is high. Lowest chance of a false positive. - * - * Generated from protobuf enum VERY_LIKELY = 5; - */ - const VERY_LIKELY = 5; - - private static $valueToName = [ - self::LIKELIHOOD_UNSPECIFIED => 'LIKELIHOOD_UNSPECIFIED', - self::VERY_UNLIKELY => 'VERY_UNLIKELY', - self::UNLIKELY => 'UNLIKELY', - self::POSSIBLE => 'POSSIBLE', - self::LIKELY => 'LIKELY', - self::VERY_LIKELY => 'VERY_LIKELY', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesRequest.php deleted file mode 100644 index 363b066d006f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesRequest.php +++ /dev/null @@ -1,387 +0,0 @@ -google.privacy.dlp.v2.ListColumnDataProfilesRequest - */ -class ListColumnDataProfilesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the organization or project, for - * example `organizations/433245324/locations/europe` or - * `projects/project-id/locations/asia`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Page token to continue retrieval. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * Size of the page. This value can be limited by the server. If zero, server - * returns a page of max size 100. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * Examples: - * * `project_id asc` - * * `table_id` - * * `sensitivity_level desc` - * Supported fields are: - * - `project_id`: The Google Cloud project ID. - * - `dataset_id`: The ID of a BigQuery dataset. - * - `table_id`: The ID of a BigQuery table. - * - `sensitivity_level`: How sensitive the data in a column is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * - * Generated from protobuf field string order_by = 4; - */ - protected $order_by = ''; - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `table_data_profile_name` - The name of the related table data - * profile. - * - `project_id` - The Google Cloud project ID. (REQUIRED) - * - `dataset_id` - The BigQuery dataset ID. (REQUIRED) - * - `table_id` - The BigQuery table ID. (REQUIRED) - * - `field_id` - The ID of the BigQuery field. - * - `info_type` - The infotype detected in the resource. - * - `sensitivity_level` - HIGH|MEDIUM|LOW - * - `data_risk_level`: How much risk is associated with this data. - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` for project_id, dataset_id, and table_id. Other - * filters also support `!=`. - * Examples: - * * project_id = 12345 AND status_code = 1 - * * project_id = 12345 AND sensitivity_level = HIGH - * * project_id = 12345 AND info_type = STREET_ADDRESS - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 5; - */ - protected $filter = ''; - - /** - * @param string $parent Required. Resource name of the organization or project, for - * example `organizations/433245324/locations/europe` or - * `projects/project-id/locations/asia`. Please see - * {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\ListColumnDataProfilesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the organization or project, for - * example `organizations/433245324/locations/europe` or - * `projects/project-id/locations/asia`. - * @type string $page_token - * Page token to continue retrieval. - * @type int $page_size - * Size of the page. This value can be limited by the server. If zero, server - * returns a page of max size 100. - * @type string $order_by - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * Examples: - * * `project_id asc` - * * `table_id` - * * `sensitivity_level desc` - * Supported fields are: - * - `project_id`: The Google Cloud project ID. - * - `dataset_id`: The ID of a BigQuery dataset. - * - `table_id`: The ID of a BigQuery table. - * - `sensitivity_level`: How sensitive the data in a column is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * @type string $filter - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `table_data_profile_name` - The name of the related table data - * profile. - * - `project_id` - The Google Cloud project ID. (REQUIRED) - * - `dataset_id` - The BigQuery dataset ID. (REQUIRED) - * - `table_id` - The BigQuery table ID. (REQUIRED) - * - `field_id` - The ID of the BigQuery field. - * - `info_type` - The infotype detected in the resource. - * - `sensitivity_level` - HIGH|MEDIUM|LOW - * - `data_risk_level`: How much risk is associated with this data. - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` for project_id, dataset_id, and table_id. Other - * filters also support `!=`. - * Examples: - * * project_id = 12345 AND status_code = 1 - * * project_id = 12345 AND sensitivity_level = HIGH - * * project_id = 12345 AND info_type = STREET_ADDRESS - * The length of this field should be no more than 500 characters. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the organization or project, for - * example `organizations/433245324/locations/europe` or - * `projects/project-id/locations/asia`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the organization or project, for - * example `organizations/433245324/locations/europe` or - * `projects/project-id/locations/asia`. - * - * 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; - } - - /** - * Page token to continue retrieval. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token to continue retrieval. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Size of the page. This value can be limited by the server. If zero, server - * returns a page of max size 100. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Size of the page. This value can be limited by the server. If zero, server - * returns a page of max size 100. - * - * 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; - } - - /** - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * Examples: - * * `project_id asc` - * * `table_id` - * * `sensitivity_level desc` - * Supported fields are: - * - `project_id`: The Google Cloud project ID. - * - `dataset_id`: The ID of a BigQuery dataset. - * - `table_id`: The ID of a BigQuery table. - * - `sensitivity_level`: How sensitive the data in a column is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * - * Generated from protobuf field string order_by = 4; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * Examples: - * * `project_id asc` - * * `table_id` - * * `sensitivity_level desc` - * Supported fields are: - * - `project_id`: The Google Cloud project ID. - * - `dataset_id`: The ID of a BigQuery dataset. - * - `table_id`: The ID of a BigQuery table. - * - `sensitivity_level`: How sensitive the data in a column is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * - * Generated from protobuf field string order_by = 4; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `table_data_profile_name` - The name of the related table data - * profile. - * - `project_id` - The Google Cloud project ID. (REQUIRED) - * - `dataset_id` - The BigQuery dataset ID. (REQUIRED) - * - `table_id` - The BigQuery table ID. (REQUIRED) - * - `field_id` - The ID of the BigQuery field. - * - `info_type` - The infotype detected in the resource. - * - `sensitivity_level` - HIGH|MEDIUM|LOW - * - `data_risk_level`: How much risk is associated with this data. - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` for project_id, dataset_id, and table_id. Other - * filters also support `!=`. - * Examples: - * * project_id = 12345 AND status_code = 1 - * * project_id = 12345 AND sensitivity_level = HIGH - * * project_id = 12345 AND info_type = STREET_ADDRESS - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 5; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `table_data_profile_name` - The name of the related table data - * profile. - * - `project_id` - The Google Cloud project ID. (REQUIRED) - * - `dataset_id` - The BigQuery dataset ID. (REQUIRED) - * - `table_id` - The BigQuery table ID. (REQUIRED) - * - `field_id` - The ID of the BigQuery field. - * - `info_type` - The infotype detected in the resource. - * - `sensitivity_level` - HIGH|MEDIUM|LOW - * - `data_risk_level`: How much risk is associated with this data. - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` for project_id, dataset_id, and table_id. Other - * filters also support `!=`. - * Examples: - * * project_id = 12345 AND status_code = 1 - * * project_id = 12345 AND sensitivity_level = HIGH - * * project_id = 12345 AND info_type = STREET_ADDRESS - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 5; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesResponse.php deleted file mode 100644 index 81fea408c64d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListColumnDataProfilesResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.privacy.dlp.v2.ListColumnDataProfilesResponse - */ -class ListColumnDataProfilesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of data profiles. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ColumnDataProfile column_data_profiles = 1; - */ - private $column_data_profiles; - /** - * The next page token. - * - * 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<\Google\Cloud\Dlp\V2\ColumnDataProfile>|\Google\Protobuf\Internal\RepeatedField $column_data_profiles - * List of data profiles. - * @type string $next_page_token - * The next page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of data profiles. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ColumnDataProfile column_data_profiles = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getColumnDataProfiles() - { - return $this->column_data_profiles; - } - - /** - * List of data profiles. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ColumnDataProfile column_data_profiles = 1; - * @param array<\Google\Cloud\Dlp\V2\ColumnDataProfile>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setColumnDataProfiles($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ColumnDataProfile::class); - $this->column_data_profiles = $arr; - - return $this; - } - - /** - * The next page token. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * The next page token. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsRequest.php deleted file mode 100644 index 98a09d1acfe9..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsRequest.php +++ /dev/null @@ -1,192 +0,0 @@ -google.privacy.dlp.v2.ListConnectionsRequest - */ -class ListConnectionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent name, for example: - * `projects/project-id/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. Number of results per page, max 1000. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. Page token from a previous page to return the next set of - * results. If set, all other request fields must match the original request. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - - /** - * @param string $parent Required. Parent name, for example: - * `projects/project-id/locations/global`. Please see - * {@see DlpServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\ListConnectionsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent name, for example: - * `projects/project-id/locations/global`. - * @type int $page_size - * Optional. Number of results per page, max 1000. - * @type string $page_token - * Optional. Page token from a previous page to return the next set of - * results. If set, all other request fields must match the original request. - * @type string $filter - * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent name, for example: - * `projects/project-id/locations/global`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent name, for example: - * `projects/project-id/locations/global`. - * - * 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; - } - - /** - * Optional. Number of results per page, max 1000. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. Number of results per page, max 1000. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. Page token from a previous page to return the next set of - * results. If set, all other request fields must match the original request. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. Page token from a previous page to return the next set of - * results. If set, all other request fields must match the original request. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsResponse.php deleted file mode 100644 index a16148048980..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListConnectionsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.privacy.dlp.v2.ListConnectionsResponse - */ -class ListConnectionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of connections. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Connection connections = 1; - */ - private $connections; - /** - * Token to retrieve the next page of results. An empty value means there are - * 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<\Google\Cloud\Dlp\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $connections - * List of connections. - * @type string $next_page_token - * Token to retrieve the next page of results. An empty value means there are - * no more results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of connections. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Connection connections = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getConnections() - { - return $this->connections; - } - - /** - * List of connections. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Connection connections = 1; - * @param array<\Google\Cloud\Dlp\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setConnections($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Connection::class); - $this->connections = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results. An empty value means there are - * no more results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results. An empty value means there are - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesRequest.php deleted file mode 100644 index c2bb760c2421..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesRequest.php +++ /dev/null @@ -1,340 +0,0 @@ -google.privacy.dlp.v2.ListDeidentifyTemplatesRequest - */ -class ListDeidentifyTemplatesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Page token to continue retrieval. Comes from the previous call - * to `ListDeidentifyTemplates`. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * Size of the page. This value can be limited by the server. If zero server - * returns a page of max size 100. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the template was created. - * - `update_time`: corresponds to the time the template was last updated. - * - `name`: corresponds to the template's name. - * - `display_name`: corresponds to the template's display name. - * - * Generated from protobuf field string order_by = 4; - */ - protected $order_by = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - */ - protected $location_id = ''; - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\ListDeidentifyTemplatesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type string $page_token - * Page token to continue retrieval. Comes from the previous call - * to `ListDeidentifyTemplates`. - * @type int $page_size - * Size of the page. This value can be limited by the server. If zero server - * returns a page of max size 100. - * @type string $order_by - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the template was created. - * - `update_time`: corresponds to the time the template was last updated. - * - `name`: corresponds to the template's name. - * - `display_name`: corresponds to the template's display name. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * 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; - } - - /** - * Page token to continue retrieval. Comes from the previous call - * to `ListDeidentifyTemplates`. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token to continue retrieval. Comes from the previous call - * to `ListDeidentifyTemplates`. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Size of the page. This value can be limited by the server. If zero server - * returns a page of max size 100. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Size of the page. This value can be limited by the server. If zero server - * returns a page of max size 100. - * - * 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; - } - - /** - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the template was created. - * - `update_time`: corresponds to the time the template was last updated. - * - `name`: corresponds to the template's name. - * - `display_name`: corresponds to the template's display name. - * - * Generated from protobuf field string order_by = 4; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the template was created. - * - `update_time`: corresponds to the time the template was last updated. - * - `name`: corresponds to the template's name. - * - `display_name`: corresponds to the template's display name. - * - * Generated from protobuf field string order_by = 4; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesResponse.php deleted file mode 100644 index 078648be7417..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDeidentifyTemplatesResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.privacy.dlp.v2.ListDeidentifyTemplatesResponse - */ -class ListDeidentifyTemplatesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of deidentify templates, up to page_size in - * ListDeidentifyTemplatesRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DeidentifyTemplate deidentify_templates = 1; - */ - private $deidentify_templates; - /** - * If the next page is available then the next page token to be used in the - * following ListDeidentifyTemplates request. - * - * 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<\Google\Cloud\Dlp\V2\DeidentifyTemplate>|\Google\Protobuf\Internal\RepeatedField $deidentify_templates - * List of deidentify templates, up to page_size in - * ListDeidentifyTemplatesRequest. - * @type string $next_page_token - * If the next page is available then the next page token to be used in the - * following ListDeidentifyTemplates request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of deidentify templates, up to page_size in - * ListDeidentifyTemplatesRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DeidentifyTemplate deidentify_templates = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDeidentifyTemplates() - { - return $this->deidentify_templates; - } - - /** - * List of deidentify templates, up to page_size in - * ListDeidentifyTemplatesRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DeidentifyTemplate deidentify_templates = 1; - * @param array<\Google\Cloud\Dlp\V2\DeidentifyTemplate>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDeidentifyTemplates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DeidentifyTemplate::class); - $this->deidentify_templates = $arr; - - return $this; - } - - /** - * If the next page is available then the next page token to be used in the - * following ListDeidentifyTemplates request. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If the next page is available then the next page token to be used in the - * following ListDeidentifyTemplates request. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsRequest.php deleted file mode 100644 index fad47e3fe97a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsRequest.php +++ /dev/null @@ -1,256 +0,0 @@ -google.privacy.dlp.v2.ListDiscoveryConfigsRequest - */ -class ListDiscoveryConfigsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value is as follows: - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Page token to continue retrieval. Comes from the previous call - * to ListDiscoveryConfigs. `order_by` field must not - * change for subsequent calls. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * Size of the page. This value can be limited by a server. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Comma separated list of config fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `last_run_time`: corresponds to the last time the DiscoveryConfig ran. - * - `name`: corresponds to the DiscoveryConfig's name. - * - `status`: corresponds to DiscoveryConfig's status. - * - * Generated from protobuf field string order_by = 4; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value is as follows: - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\ListDiscoveryConfigsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value is as follows: - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type string $page_token - * Page token to continue retrieval. Comes from the previous call - * to ListDiscoveryConfigs. `order_by` field must not - * change for subsequent calls. - * @type int $page_size - * Size of the page. This value can be limited by a server. - * @type string $order_by - * Comma separated list of config fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `last_run_time`: corresponds to the last time the DiscoveryConfig ran. - * - `name`: corresponds to the DiscoveryConfig's name. - * - `status`: corresponds to DiscoveryConfig's status. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value is as follows: - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value is as follows: - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * 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; - } - - /** - * Page token to continue retrieval. Comes from the previous call - * to ListDiscoveryConfigs. `order_by` field must not - * change for subsequent calls. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token to continue retrieval. Comes from the previous call - * to ListDiscoveryConfigs. `order_by` field must not - * change for subsequent calls. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Size of the page. This value can be limited by a server. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Size of the page. This value can be limited by a server. - * - * 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; - } - - /** - * Comma separated list of config fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `last_run_time`: corresponds to the last time the DiscoveryConfig ran. - * - `name`: corresponds to the DiscoveryConfig's name. - * - `status`: corresponds to DiscoveryConfig's status. - * - * Generated from protobuf field string order_by = 4; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Comma separated list of config fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `last_run_time`: corresponds to the last time the DiscoveryConfig ran. - * - `name`: corresponds to the DiscoveryConfig's name. - * - `status`: corresponds to DiscoveryConfig's status. - * - * Generated from protobuf field string order_by = 4; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsResponse.php deleted file mode 100644 index 118594acf0b4..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDiscoveryConfigsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.privacy.dlp.v2.ListDiscoveryConfigsResponse - */ -class ListDiscoveryConfigsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of configs, up to page_size in ListDiscoveryConfigsRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryConfig discovery_configs = 1; - */ - private $discovery_configs; - /** - * If the next page is available then this value is the next page token to be - * used in the following ListDiscoveryConfigs request. - * - * 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<\Google\Cloud\Dlp\V2\DiscoveryConfig>|\Google\Protobuf\Internal\RepeatedField $discovery_configs - * List of configs, up to page_size in ListDiscoveryConfigsRequest. - * @type string $next_page_token - * If the next page is available then this value is the next page token to be - * used in the following ListDiscoveryConfigs request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of configs, up to page_size in ListDiscoveryConfigsRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryConfig discovery_configs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDiscoveryConfigs() - { - return $this->discovery_configs; - } - - /** - * List of configs, up to page_size in ListDiscoveryConfigsRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DiscoveryConfig discovery_configs = 1; - * @param array<\Google\Cloud\Dlp\V2\DiscoveryConfig>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDiscoveryConfigs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DiscoveryConfig::class); - $this->discovery_configs = $arr; - - return $this; - } - - /** - * If the next page is available then this value is the next page token to be - * used in the following ListDiscoveryConfigs request. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If the next page is available then this value is the next page token to be - * used in the following ListDiscoveryConfigs request. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsRequest.php deleted file mode 100644 index 1bc0db8d5e19..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsRequest.php +++ /dev/null @@ -1,468 +0,0 @@ -google.privacy.dlp.v2.ListDlpJobsRequest - */ -class ListDlpJobsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values for inspect jobs: - * - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED - * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - * - `trigger_name` - The name of the trigger that created the job. - * - 'end_time` - Corresponds to the time the job finished. - * - 'start_time` - Corresponds to the time the job finished. - * * Supported fields for risk analysis jobs: - * - `state` - RUNNING|CANCELED|FINISHED|FAILED - * - 'end_time` - Corresponds to the time the job finished. - * - 'start_time` - Corresponds to the time the job finished. - * * The operator must be `=` or `!=`. - * Examples: - * * inspected_storage = cloud_storage AND state = done - * * inspected_storage = cloud_storage OR inspected_storage = bigquery - * * inspected_storage = cloud_storage AND (state = done OR state = canceled) - * * end_time > \"2017-12-12T00:00:00+00:00\" - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 1; - */ - protected $filter = ''; - /** - * The standard list page size. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The standard list page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * The type of job. Defaults to `DlpJobType.INSPECT` - * - * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 5; - */ - protected $type = 0; - /** - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc, end_time asc, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the job was created. - * - `end_time`: corresponds to the time the job ended. - * - `name`: corresponds to the job's name. - * - `state`: corresponds to `state` - * - * Generated from protobuf field string order_by = 6; - */ - protected $order_by = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 7; - */ - protected $location_id = ''; - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::projectName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\ListDlpJobsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type string $filter - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values for inspect jobs: - * - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED - * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - * - `trigger_name` - The name of the trigger that created the job. - * - 'end_time` - Corresponds to the time the job finished. - * - 'start_time` - Corresponds to the time the job finished. - * * Supported fields for risk analysis jobs: - * - `state` - RUNNING|CANCELED|FINISHED|FAILED - * - 'end_time` - Corresponds to the time the job finished. - * - 'start_time` - Corresponds to the time the job finished. - * * The operator must be `=` or `!=`. - * Examples: - * * inspected_storage = cloud_storage AND state = done - * * inspected_storage = cloud_storage OR inspected_storage = bigquery - * * inspected_storage = cloud_storage AND (state = done OR state = canceled) - * * end_time > \"2017-12-12T00:00:00+00:00\" - * The length of this field should be no more than 500 characters. - * @type int $page_size - * The standard list page size. - * @type string $page_token - * The standard list page token. - * @type int $type - * The type of job. Defaults to `DlpJobType.INSPECT` - * @type string $order_by - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc, end_time asc, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the job was created. - * - `end_time`: corresponds to the time the job ended. - * - `name`: corresponds to the job's name. - * - `state`: corresponds to `state` - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 4 [(.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; - } - - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values for inspect jobs: - * - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED - * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - * - `trigger_name` - The name of the trigger that created the job. - * - 'end_time` - Corresponds to the time the job finished. - * - 'start_time` - Corresponds to the time the job finished. - * * Supported fields for risk analysis jobs: - * - `state` - RUNNING|CANCELED|FINISHED|FAILED - * - 'end_time` - Corresponds to the time the job finished. - * - 'start_time` - Corresponds to the time the job finished. - * * The operator must be `=` or `!=`. - * Examples: - * * inspected_storage = cloud_storage AND state = done - * * inspected_storage = cloud_storage OR inspected_storage = bigquery - * * inspected_storage = cloud_storage AND (state = done OR state = canceled) - * * end_time > \"2017-12-12T00:00:00+00:00\" - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 1; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values for inspect jobs: - * - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED - * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - * - `trigger_name` - The name of the trigger that created the job. - * - 'end_time` - Corresponds to the time the job finished. - * - 'start_time` - Corresponds to the time the job finished. - * * Supported fields for risk analysis jobs: - * - `state` - RUNNING|CANCELED|FINISHED|FAILED - * - 'end_time` - Corresponds to the time the job finished. - * - 'start_time` - Corresponds to the time the job finished. - * * The operator must be `=` or `!=`. - * Examples: - * * inspected_storage = cloud_storage AND state = done - * * inspected_storage = cloud_storage OR inspected_storage = bigquery - * * inspected_storage = cloud_storage AND (state = done OR state = canceled) - * * end_time > \"2017-12-12T00:00:00+00:00\" - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 1; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * The standard list page size. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The standard list page size. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The standard list page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The standard list page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The type of job. Defaults to `DlpJobType.INSPECT` - * - * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 5; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The type of job. Defaults to `DlpJobType.INSPECT` - * - * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 5; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DlpJobType::class); - $this->type = $var; - - return $this; - } - - /** - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc, end_time asc, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the job was created. - * - `end_time`: corresponds to the time the job ended. - * - `name`: corresponds to the job's name. - * - `state`: corresponds to `state` - * - * Generated from protobuf field string order_by = 6; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc, end_time asc, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the job was created. - * - `end_time`: corresponds to the time the job ended. - * - `name`: corresponds to the job's name. - * - `state`: corresponds to `state` - * - * Generated from protobuf field string order_by = 6; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 7; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 7; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsResponse.php deleted file mode 100644 index 62d9df6c8efb..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListDlpJobsResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.privacy.dlp.v2.ListDlpJobsResponse - */ -class ListDlpJobsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of DlpJobs that matches the specified filter in the request. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DlpJob jobs = 1; - */ - private $jobs; - /** - * The standard List next-page token. - * - * 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<\Google\Cloud\Dlp\V2\DlpJob>|\Google\Protobuf\Internal\RepeatedField $jobs - * A list of DlpJobs that matches the specified filter in the request. - * @type string $next_page_token - * The standard List next-page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A list of DlpJobs that matches the specified filter in the request. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DlpJob jobs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getJobs() - { - return $this->jobs; - } - - /** - * A list of DlpJobs that matches the specified filter in the request. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.DlpJob jobs = 1; - * @param array<\Google\Cloud\Dlp\V2\DlpJob>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setJobs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\DlpJob::class); - $this->jobs = $arr; - - return $this; - } - - /** - * The standard List next-page token. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * The standard List next-page token. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesRequest.php deleted file mode 100644 index c9217ebba228..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesRequest.php +++ /dev/null @@ -1,206 +0,0 @@ -google.privacy.dlp.v2.ListInfoTypesRequest - */ -class ListInfoTypesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The parent resource name. - * The format of this value is as follows: - * locations/LOCATION_ID - * - * Generated from protobuf field string parent = 4; - */ - protected $parent = ''; - /** - * BCP-47 language code for localized infoType friendly - * names. If omitted, or if localized strings are not available, - * en-US strings will be returned. - * - * Generated from protobuf field string language_code = 1; - */ - protected $language_code = ''; - /** - * filter to only return infoTypes supported by certain parts of the - * API. Defaults to supported_by=INSPECT. - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 3; - */ - protected $location_id = ''; - - /** - * @param string $parent The parent resource name. - * - * The format of this value is as follows: - * - * locations/LOCATION_ID - * - * @return \Google\Cloud\Dlp\V2\ListInfoTypesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * The parent resource name. - * The format of this value is as follows: - * locations/LOCATION_ID - * @type string $language_code - * BCP-47 language code for localized infoType friendly - * names. If omitted, or if localized strings are not available, - * en-US strings will be returned. - * @type string $filter - * filter to only return infoTypes supported by certain parts of the - * API. Defaults to supported_by=INSPECT. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The parent resource name. - * The format of this value is as follows: - * locations/LOCATION_ID - * - * Generated from protobuf field string parent = 4; - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The parent resource name. - * The format of this value is as follows: - * locations/LOCATION_ID - * - * Generated from protobuf field string parent = 4; - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * BCP-47 language code for localized infoType friendly - * names. If omitted, or if localized strings are not available, - * en-US strings will be returned. - * - * Generated from protobuf field string language_code = 1; - * @return string - */ - public function getLanguageCode() - { - return $this->language_code; - } - - /** - * BCP-47 language code for localized infoType friendly - * names. If omitted, or if localized strings are not available, - * en-US strings will be returned. - * - * Generated from protobuf field string language_code = 1; - * @param string $var - * @return $this - */ - public function setLanguageCode($var) - { - GPBUtil::checkString($var, True); - $this->language_code = $var; - - return $this; - } - - /** - * filter to only return infoTypes supported by certain parts of the - * API. Defaults to supported_by=INSPECT. - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * filter to only return infoTypes supported by certain parts of the - * API. Defaults to supported_by=INSPECT. - * - * 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; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 3; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 3; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesResponse.php deleted file mode 100644 index 38951fc4c7e2..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInfoTypesResponse.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.ListInfoTypesResponse - */ -class ListInfoTypesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Set of sensitive infoTypes. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeDescription info_types = 1; - */ - private $info_types; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\InfoTypeDescription>|\Google\Protobuf\Internal\RepeatedField $info_types - * Set of sensitive infoTypes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Set of sensitive infoTypes. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeDescription info_types = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInfoTypes() - { - return $this->info_types; - } - - /** - * Set of sensitive infoTypes. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeDescription info_types = 1; - * @param array<\Google\Cloud\Dlp\V2\InfoTypeDescription>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInfoTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoTypeDescription::class); - $this->info_types = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesRequest.php deleted file mode 100644 index c53d0ee6d0df..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesRequest.php +++ /dev/null @@ -1,340 +0,0 @@ -google.privacy.dlp.v2.ListInspectTemplatesRequest - */ -class ListInspectTemplatesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Page token to continue retrieval. Comes from the previous call - * to `ListInspectTemplates`. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * Size of the page. This value can be limited by the server. If zero server - * returns a page of max size 100. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the template was created. - * - `update_time`: corresponds to the time the template was last updated. - * - `name`: corresponds to the template's name. - * - `display_name`: corresponds to the template's display name. - * - * Generated from protobuf field string order_by = 4; - */ - protected $order_by = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - */ - protected $location_id = ''; - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\ListInspectTemplatesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type string $page_token - * Page token to continue retrieval. Comes from the previous call - * to `ListInspectTemplates`. - * @type int $page_size - * Size of the page. This value can be limited by the server. If zero server - * returns a page of max size 100. - * @type string $order_by - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the template was created. - * - `update_time`: corresponds to the time the template was last updated. - * - `name`: corresponds to the template's name. - * - `display_name`: corresponds to the template's display name. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * 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; - } - - /** - * Page token to continue retrieval. Comes from the previous call - * to `ListInspectTemplates`. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token to continue retrieval. Comes from the previous call - * to `ListInspectTemplates`. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Size of the page. This value can be limited by the server. If zero server - * returns a page of max size 100. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Size of the page. This value can be limited by the server. If zero server - * returns a page of max size 100. - * - * 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; - } - - /** - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the template was created. - * - `update_time`: corresponds to the time the template was last updated. - * - `name`: corresponds to the template's name. - * - `display_name`: corresponds to the template's display name. - * - * Generated from protobuf field string order_by = 4; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the template was created. - * - `update_time`: corresponds to the time the template was last updated. - * - `name`: corresponds to the template's name. - * - `display_name`: corresponds to the template's display name. - * - * Generated from protobuf field string order_by = 4; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesResponse.php deleted file mode 100644 index 8d00e0dab910..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListInspectTemplatesResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.privacy.dlp.v2.ListInspectTemplatesResponse - */ -class ListInspectTemplatesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of inspectTemplates, up to page_size in ListInspectTemplatesRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectTemplate inspect_templates = 1; - */ - private $inspect_templates; - /** - * If the next page is available then the next page token to be used in the - * following ListInspectTemplates request. - * - * 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<\Google\Cloud\Dlp\V2\InspectTemplate>|\Google\Protobuf\Internal\RepeatedField $inspect_templates - * List of inspectTemplates, up to page_size in ListInspectTemplatesRequest. - * @type string $next_page_token - * If the next page is available then the next page token to be used in the - * following ListInspectTemplates request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of inspectTemplates, up to page_size in ListInspectTemplatesRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectTemplate inspect_templates = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInspectTemplates() - { - return $this->inspect_templates; - } - - /** - * List of inspectTemplates, up to page_size in ListInspectTemplatesRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InspectTemplate inspect_templates = 1; - * @param array<\Google\Cloud\Dlp\V2\InspectTemplate>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInspectTemplates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InspectTemplate::class); - $this->inspect_templates = $arr; - - return $this; - } - - /** - * If the next page is available then the next page token to be used in the - * following ListInspectTemplates request. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If the next page is available then the next page token to be used in the - * following ListInspectTemplates request. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersRequest.php deleted file mode 100644 index 3279052b9af6..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersRequest.php +++ /dev/null @@ -1,468 +0,0 @@ -google.privacy.dlp.v2.ListJobTriggersRequest - */ -class ListJobTriggersRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Page token to continue retrieval. Comes from the previous call - * to ListJobTriggers. `order_by` field must not - * change for subsequent calls. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * Size of the page. This value can be limited by a server. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Comma separated list of triggeredJob fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the JobTrigger was created. - * - `update_time`: corresponds to the time the JobTrigger was last updated. - * - `last_run_time`: corresponds to the last time the JobTrigger ran. - * - `name`: corresponds to the JobTrigger's name. - * - `display_name`: corresponds to the JobTrigger's display name. - * - `status`: corresponds to JobTrigger's status. - * - * Generated from protobuf field string order_by = 4; - */ - protected $order_by = ''; - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values for inspect triggers: - * - `status` - HEALTHY|PAUSED|CANCELLED - * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - * - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by - * quotation marks. Nanoseconds are ignored. - * - 'error_count' - Number of errors that have occurred while running. - * * The operator must be `=` or `!=` for status and inspected_storage. - * Examples: - * * inspected_storage = cloud_storage AND status = HEALTHY - * * inspected_storage = cloud_storage OR inspected_storage = bigquery - * * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) - * * last_run_time > \"2017-12-12T00:00:00+00:00\" - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 5; - */ - protected $filter = ''; - /** - * The type of jobs. Will use `DlpJobType.INSPECT` if not set. - * - * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 6; - */ - protected $type = 0; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 7; - */ - protected $location_id = ''; - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::projectName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\ListJobTriggersRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type string $page_token - * Page token to continue retrieval. Comes from the previous call - * to ListJobTriggers. `order_by` field must not - * change for subsequent calls. - * @type int $page_size - * Size of the page. This value can be limited by a server. - * @type string $order_by - * Comma separated list of triggeredJob fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the JobTrigger was created. - * - `update_time`: corresponds to the time the JobTrigger was last updated. - * - `last_run_time`: corresponds to the last time the JobTrigger ran. - * - `name`: corresponds to the JobTrigger's name. - * - `display_name`: corresponds to the JobTrigger's display name. - * - `status`: corresponds to JobTrigger's status. - * @type string $filter - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values for inspect triggers: - * - `status` - HEALTHY|PAUSED|CANCELLED - * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - * - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by - * quotation marks. Nanoseconds are ignored. - * - 'error_count' - Number of errors that have occurred while running. - * * The operator must be `=` or `!=` for status and inspected_storage. - * Examples: - * * inspected_storage = cloud_storage AND status = HEALTHY - * * inspected_storage = cloud_storage OR inspected_storage = bigquery - * * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) - * * last_run_time > \"2017-12-12T00:00:00+00:00\" - * The length of this field should be no more than 500 characters. - * @type int $type - * The type of jobs. Will use `DlpJobType.INSPECT` if not set. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * 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; - } - - /** - * Page token to continue retrieval. Comes from the previous call - * to ListJobTriggers. `order_by` field must not - * change for subsequent calls. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token to continue retrieval. Comes from the previous call - * to ListJobTriggers. `order_by` field must not - * change for subsequent calls. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Size of the page. This value can be limited by a server. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Size of the page. This value can be limited by a server. - * - * 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; - } - - /** - * Comma separated list of triggeredJob fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the JobTrigger was created. - * - `update_time`: corresponds to the time the JobTrigger was last updated. - * - `last_run_time`: corresponds to the last time the JobTrigger ran. - * - `name`: corresponds to the JobTrigger's name. - * - `display_name`: corresponds to the JobTrigger's display name. - * - `status`: corresponds to JobTrigger's status. - * - * Generated from protobuf field string order_by = 4; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Comma separated list of triggeredJob fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc,update_time, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the JobTrigger was created. - * - `update_time`: corresponds to the time the JobTrigger was last updated. - * - `last_run_time`: corresponds to the last time the JobTrigger ran. - * - `name`: corresponds to the JobTrigger's name. - * - `display_name`: corresponds to the JobTrigger's display name. - * - `status`: corresponds to JobTrigger's status. - * - * Generated from protobuf field string order_by = 4; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values for inspect triggers: - * - `status` - HEALTHY|PAUSED|CANCELLED - * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - * - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by - * quotation marks. Nanoseconds are ignored. - * - 'error_count' - Number of errors that have occurred while running. - * * The operator must be `=` or `!=` for status and inspected_storage. - * Examples: - * * inspected_storage = cloud_storage AND status = HEALTHY - * * inspected_storage = cloud_storage OR inspected_storage = bigquery - * * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) - * * last_run_time > \"2017-12-12T00:00:00+00:00\" - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 5; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values for inspect triggers: - * - `status` - HEALTHY|PAUSED|CANCELLED - * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - * - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by - * quotation marks. Nanoseconds are ignored. - * - 'error_count' - Number of errors that have occurred while running. - * * The operator must be `=` or `!=` for status and inspected_storage. - * Examples: - * * inspected_storage = cloud_storage AND status = HEALTHY - * * inspected_storage = cloud_storage OR inspected_storage = bigquery - * * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) - * * last_run_time > \"2017-12-12T00:00:00+00:00\" - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 5; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * The type of jobs. Will use `DlpJobType.INSPECT` if not set. - * - * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 6; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The type of jobs. Will use `DlpJobType.INSPECT` if not set. - * - * Generated from protobuf field .google.privacy.dlp.v2.DlpJobType type = 6; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\DlpJobType::class); - $this->type = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 7; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 7; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersResponse.php deleted file mode 100644 index a271b151b1f8..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListJobTriggersResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.privacy.dlp.v2.ListJobTriggersResponse - */ -class ListJobTriggersResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of triggeredJobs, up to page_size in ListJobTriggersRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.JobTrigger job_triggers = 1; - */ - private $job_triggers; - /** - * If the next page is available then this value is the next page token to be - * used in the following ListJobTriggers request. - * - * 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<\Google\Cloud\Dlp\V2\JobTrigger>|\Google\Protobuf\Internal\RepeatedField $job_triggers - * List of triggeredJobs, up to page_size in ListJobTriggersRequest. - * @type string $next_page_token - * If the next page is available then this value is the next page token to be - * used in the following ListJobTriggers request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of triggeredJobs, up to page_size in ListJobTriggersRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.JobTrigger job_triggers = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getJobTriggers() - { - return $this->job_triggers; - } - - /** - * List of triggeredJobs, up to page_size in ListJobTriggersRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.JobTrigger job_triggers = 1; - * @param array<\Google\Cloud\Dlp\V2\JobTrigger>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setJobTriggers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\JobTrigger::class); - $this->job_triggers = $arr; - - return $this; - } - - /** - * If the next page is available then this value is the next page token to be - * used in the following ListJobTriggers request. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If the next page is available then this value is the next page token to be - * used in the following ListJobTriggers request. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesRequest.php deleted file mode 100644 index 4b3a69cee79c..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesRequest.php +++ /dev/null @@ -1,329 +0,0 @@ -google.privacy.dlp.v2.ListProjectDataProfilesRequest - */ -class ListProjectDataProfilesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. organizations/{org_id}/locations/{loc_id} - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Page token to continue retrieval. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * Size of the page. This value can be limited by the server. If zero, server - * returns a page of max size 100. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * Examples: - * * `project_id` - * * `sensitivity_level desc` - * Supported fields are: - * - `project_id`: Google Cloud project ID - * - `sensitivity_level`: How sensitive the data in a project is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * - * Generated from protobuf field string order_by = 4; - */ - protected $order_by = ''; - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `sensitivity_level` - HIGH|MODERATE|LOW - * - `data_risk_level` - HIGH|MODERATE|LOW - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` or `!=`. - * Examples: - * * `project_id = 12345 AND status_code = 1` - * * `project_id = 12345 AND sensitivity_level = HIGH` - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 5; - */ - protected $filter = ''; - - /** - * @param string $parent Required. organizations/{org_id}/locations/{loc_id} - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\ListProjectDataProfilesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. organizations/{org_id}/locations/{loc_id} - * @type string $page_token - * Page token to continue retrieval. - * @type int $page_size - * Size of the page. This value can be limited by the server. If zero, server - * returns a page of max size 100. - * @type string $order_by - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * Examples: - * * `project_id` - * * `sensitivity_level desc` - * Supported fields are: - * - `project_id`: Google Cloud project ID - * - `sensitivity_level`: How sensitive the data in a project is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * @type string $filter - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `sensitivity_level` - HIGH|MODERATE|LOW - * - `data_risk_level` - HIGH|MODERATE|LOW - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` or `!=`. - * Examples: - * * `project_id = 12345 AND status_code = 1` - * * `project_id = 12345 AND sensitivity_level = HIGH` - * The length of this field should be no more than 500 characters. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. organizations/{org_id}/locations/{loc_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; - } - - /** - * Required. organizations/{org_id}/locations/{loc_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; - } - - /** - * Page token to continue retrieval. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token to continue retrieval. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Size of the page. This value can be limited by the server. If zero, server - * returns a page of max size 100. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Size of the page. This value can be limited by the server. If zero, server - * returns a page of max size 100. - * - * 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; - } - - /** - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * Examples: - * * `project_id` - * * `sensitivity_level desc` - * Supported fields are: - * - `project_id`: Google Cloud project ID - * - `sensitivity_level`: How sensitive the data in a project is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * - * Generated from protobuf field string order_by = 4; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * Examples: - * * `project_id` - * * `sensitivity_level desc` - * Supported fields are: - * - `project_id`: Google Cloud project ID - * - `sensitivity_level`: How sensitive the data in a project is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * - * Generated from protobuf field string order_by = 4; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `sensitivity_level` - HIGH|MODERATE|LOW - * - `data_risk_level` - HIGH|MODERATE|LOW - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` or `!=`. - * Examples: - * * `project_id = 12345 AND status_code = 1` - * * `project_id = 12345 AND sensitivity_level = HIGH` - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 5; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `sensitivity_level` - HIGH|MODERATE|LOW - * - `data_risk_level` - HIGH|MODERATE|LOW - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` or `!=`. - * Examples: - * * `project_id = 12345 AND status_code = 1` - * * `project_id = 12345 AND sensitivity_level = HIGH` - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 5; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesResponse.php deleted file mode 100644 index 3a2e2dab2e96..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListProjectDataProfilesResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.privacy.dlp.v2.ListProjectDataProfilesResponse - */ -class ListProjectDataProfilesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of data profiles. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ProjectDataProfile project_data_profiles = 1; - */ - private $project_data_profiles; - /** - * The next page token. - * - * 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<\Google\Cloud\Dlp\V2\ProjectDataProfile>|\Google\Protobuf\Internal\RepeatedField $project_data_profiles - * List of data profiles. - * @type string $next_page_token - * The next page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of data profiles. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ProjectDataProfile project_data_profiles = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getProjectDataProfiles() - { - return $this->project_data_profiles; - } - - /** - * List of data profiles. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ProjectDataProfile project_data_profiles = 1; - * @param array<\Google\Cloud\Dlp\V2\ProjectDataProfile>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setProjectDataProfiles($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ProjectDataProfile::class); - $this->project_data_profiles = $arr; - - return $this; - } - - /** - * The next page token. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * The next page token. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesRequest.php deleted file mode 100644 index 81069a255cae..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesRequest.php +++ /dev/null @@ -1,324 +0,0 @@ -google.privacy.dlp.v2.ListStoredInfoTypesRequest - */ -class ListStoredInfoTypesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Page token to continue retrieval. Comes from the previous call - * to `ListStoredInfoTypes`. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * Size of the page. This value can be limited by the server. If zero server - * returns a page of max size 100. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc, display_name, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the most recent version of the - * resource was created. - * - `state`: corresponds to the state of the resource. - * - `name`: corresponds to resource name. - * - `display_name`: corresponds to info type's display name. - * - * Generated from protobuf field string order_by = 4; - */ - protected $order_by = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - */ - protected $location_id = ''; - - /** - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\ListStoredInfoTypesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type string $page_token - * Page token to continue retrieval. Comes from the previous call - * to `ListStoredInfoTypes`. - * @type int $page_size - * Size of the page. This value can be limited by the server. If zero server - * returns a page of max size 100. - * @type string $order_by - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc, display_name, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the most recent version of the - * resource was created. - * - `state`: corresponds to the state of the resource. - * - `name`: corresponds to resource name. - * - `display_name`: corresponds to info type's display name. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * 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; - } - - /** - * Page token to continue retrieval. Comes from the previous call - * to `ListStoredInfoTypes`. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token to continue retrieval. Comes from the previous call - * to `ListStoredInfoTypes`. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Size of the page. This value can be limited by the server. If zero server - * returns a page of max size 100. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Size of the page. This value can be limited by the server. If zero server - * returns a page of max size 100. - * - * 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; - } - - /** - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc, display_name, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the most recent version of the - * resource was created. - * - `state`: corresponds to the state of the resource. - * - `name`: corresponds to resource name. - * - `display_name`: corresponds to info type's display name. - * - * Generated from protobuf field string order_by = 4; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * Example: `name asc, display_name, create_time desc` - * Supported fields are: - * - `create_time`: corresponds to the time the most recent version of the - * resource was created. - * - `state`: corresponds to the state of the resource. - * - `name`: corresponds to resource name. - * - `display_name`: corresponds to info type's display name. - * - * Generated from protobuf field string order_by = 4; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 5; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesResponse.php deleted file mode 100644 index 83a7019de840..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListStoredInfoTypesResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.privacy.dlp.v2.ListStoredInfoTypesResponse - */ -class ListStoredInfoTypesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of storedInfoTypes, up to page_size in ListStoredInfoTypesRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.StoredInfoType stored_info_types = 1; - */ - private $stored_info_types; - /** - * If the next page is available then the next page token to be used - * in the following ListStoredInfoTypes request. - * - * 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<\Google\Cloud\Dlp\V2\StoredInfoType>|\Google\Protobuf\Internal\RepeatedField $stored_info_types - * List of storedInfoTypes, up to page_size in ListStoredInfoTypesRequest. - * @type string $next_page_token - * If the next page is available then the next page token to be used - * in the following ListStoredInfoTypes request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of storedInfoTypes, up to page_size in ListStoredInfoTypesRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.StoredInfoType stored_info_types = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getStoredInfoTypes() - { - return $this->stored_info_types; - } - - /** - * List of storedInfoTypes, up to page_size in ListStoredInfoTypesRequest. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.StoredInfoType stored_info_types = 1; - * @param array<\Google\Cloud\Dlp\V2\StoredInfoType>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setStoredInfoTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\StoredInfoType::class); - $this->stored_info_types = $arr; - - return $this; - } - - /** - * If the next page is available then the next page token to be used - * in the following ListStoredInfoTypes request. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If the next page is available then the next page token to be used - * in the following ListStoredInfoTypes request. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesRequest.php deleted file mode 100644 index 1083018845d2..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesRequest.php +++ /dev/null @@ -1,383 +0,0 @@ -google.privacy.dlp.v2.ListTableDataProfilesRequest - */ -class ListTableDataProfilesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the organization or project, for - * example `organizations/433245324/locations/europe` or - * `projects/project-id/locations/asia`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Page token to continue retrieval. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * Size of the page. This value can be limited by the server. If zero, server - * returns a page of max size 100. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * Examples: - * * `project_id asc` - * * `table_id` - * * `sensitivity_level desc` - * Supported fields are: - * - `project_id`: The Google Cloud project ID. - * - `dataset_id`: The ID of a BigQuery dataset. - * - `table_id`: The ID of a BigQuery table. - * - `sensitivity_level`: How sensitive the data in a table is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * - `last_modified`: The last time the resource was modified. - * - `resource_visibility`: Visibility restriction for this resource. - * - `row_count`: Number of rows in this resource. - * - * Generated from protobuf field string order_by = 4; - */ - protected $order_by = ''; - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `project_id` - The Google Cloud project ID. - * - `dataset_id` - The BigQuery dataset ID. - * - `table_id` - The ID of the BigQuery table. - * - `sensitivity_level` - HIGH|MODERATE|LOW - * - `data_risk_level` - HIGH|MODERATE|LOW - * - `resource_visibility`: PUBLIC|RESTRICTED - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` or `!=`. - * Examples: - * * `project_id = 12345 AND status_code = 1` - * * `project_id = 12345 AND sensitivity_level = HIGH` - * * `project_id = 12345 AND resource_visibility = PUBLIC` - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 5; - */ - protected $filter = ''; - - /** - * @param string $parent Required. Resource name of the organization or project, for - * example `organizations/433245324/locations/europe` or - * `projects/project-id/locations/asia`. Please see - * {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\ListTableDataProfilesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the organization or project, for - * example `organizations/433245324/locations/europe` or - * `projects/project-id/locations/asia`. - * @type string $page_token - * Page token to continue retrieval. - * @type int $page_size - * Size of the page. This value can be limited by the server. If zero, server - * returns a page of max size 100. - * @type string $order_by - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * Examples: - * * `project_id asc` - * * `table_id` - * * `sensitivity_level desc` - * Supported fields are: - * - `project_id`: The Google Cloud project ID. - * - `dataset_id`: The ID of a BigQuery dataset. - * - `table_id`: The ID of a BigQuery table. - * - `sensitivity_level`: How sensitive the data in a table is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * - `last_modified`: The last time the resource was modified. - * - `resource_visibility`: Visibility restriction for this resource. - * - `row_count`: Number of rows in this resource. - * @type string $filter - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `project_id` - The Google Cloud project ID. - * - `dataset_id` - The BigQuery dataset ID. - * - `table_id` - The ID of the BigQuery table. - * - `sensitivity_level` - HIGH|MODERATE|LOW - * - `data_risk_level` - HIGH|MODERATE|LOW - * - `resource_visibility`: PUBLIC|RESTRICTED - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` or `!=`. - * Examples: - * * `project_id = 12345 AND status_code = 1` - * * `project_id = 12345 AND sensitivity_level = HIGH` - * * `project_id = 12345 AND resource_visibility = PUBLIC` - * The length of this field should be no more than 500 characters. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the organization or project, for - * example `organizations/433245324/locations/europe` or - * `projects/project-id/locations/asia`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the organization or project, for - * example `organizations/433245324/locations/europe` or - * `projects/project-id/locations/asia`. - * - * 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; - } - - /** - * Page token to continue retrieval. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token to continue retrieval. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Size of the page. This value can be limited by the server. If zero, server - * returns a page of max size 100. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Size of the page. This value can be limited by the server. If zero, server - * returns a page of max size 100. - * - * 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; - } - - /** - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * Examples: - * * `project_id asc` - * * `table_id` - * * `sensitivity_level desc` - * Supported fields are: - * - `project_id`: The Google Cloud project ID. - * - `dataset_id`: The ID of a BigQuery dataset. - * - `table_id`: The ID of a BigQuery table. - * - `sensitivity_level`: How sensitive the data in a table is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * - `last_modified`: The last time the resource was modified. - * - `resource_visibility`: Visibility restriction for this resource. - * - `row_count`: Number of rows in this resource. - * - * Generated from protobuf field string order_by = 4; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * Examples: - * * `project_id asc` - * * `table_id` - * * `sensitivity_level desc` - * Supported fields are: - * - `project_id`: The Google Cloud project ID. - * - `dataset_id`: The ID of a BigQuery dataset. - * - `table_id`: The ID of a BigQuery table. - * - `sensitivity_level`: How sensitive the data in a table is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * - `last_modified`: The last time the resource was modified. - * - `resource_visibility`: Visibility restriction for this resource. - * - `row_count`: Number of rows in this resource. - * - * Generated from protobuf field string order_by = 4; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `project_id` - The Google Cloud project ID. - * - `dataset_id` - The BigQuery dataset ID. - * - `table_id` - The ID of the BigQuery table. - * - `sensitivity_level` - HIGH|MODERATE|LOW - * - `data_risk_level` - HIGH|MODERATE|LOW - * - `resource_visibility`: PUBLIC|RESTRICTED - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` or `!=`. - * Examples: - * * `project_id = 12345 AND status_code = 1` - * * `project_id = 12345 AND sensitivity_level = HIGH` - * * `project_id = 12345 AND resource_visibility = PUBLIC` - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 5; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Allows filtering. - * Supported syntax: - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `project_id` - The Google Cloud project ID. - * - `dataset_id` - The BigQuery dataset ID. - * - `table_id` - The ID of the BigQuery table. - * - `sensitivity_level` - HIGH|MODERATE|LOW - * - `data_risk_level` - HIGH|MODERATE|LOW - * - `resource_visibility`: PUBLIC|RESTRICTED - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` or `!=`. - * Examples: - * * `project_id = 12345 AND status_code = 1` - * * `project_id = 12345 AND sensitivity_level = HIGH` - * * `project_id = 12345 AND resource_visibility = PUBLIC` - * The length of this field should be no more than 500 characters. - * - * Generated from protobuf field string filter = 5; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesResponse.php deleted file mode 100644 index a6b2694c12a0..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ListTableDataProfilesResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.privacy.dlp.v2.ListTableDataProfilesResponse - */ -class ListTableDataProfilesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of data profiles. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.TableDataProfile table_data_profiles = 1; - */ - private $table_data_profiles; - /** - * The next page token. - * - * 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<\Google\Cloud\Dlp\V2\TableDataProfile>|\Google\Protobuf\Internal\RepeatedField $table_data_profiles - * List of data profiles. - * @type string $next_page_token - * The next page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of data profiles. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.TableDataProfile table_data_profiles = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTableDataProfiles() - { - return $this->table_data_profiles; - } - - /** - * List of data profiles. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.TableDataProfile table_data_profiles = 1; - * @param array<\Google\Cloud\Dlp\V2\TableDataProfile>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTableDataProfiles($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\TableDataProfile::class); - $this->table_data_profiles = $arr; - - return $this; - } - - /** - * The next page token. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * The next page token. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Location.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Location.php deleted file mode 100644 index c67c38368c6d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Location.php +++ /dev/null @@ -1,227 +0,0 @@ -google.privacy.dlp.v2.Location - */ -class Location extends \Google\Protobuf\Internal\Message -{ - /** - * Zero-based byte offsets delimiting the finding. - * These are relative to the finding's containing element. - * Note that when the content is not textual, this references - * the UTF-8 encoded textual representation of the content. - * Omitted if content is an image. - * - * Generated from protobuf field .google.privacy.dlp.v2.Range byte_range = 1; - */ - protected $byte_range = null; - /** - * Unicode character offsets delimiting the finding. - * These are relative to the finding's containing element. - * Provided when the content is text. - * - * Generated from protobuf field .google.privacy.dlp.v2.Range codepoint_range = 2; - */ - protected $codepoint_range = null; - /** - * List of nested objects pointing to the precise location of the finding - * within the file or record. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ContentLocation content_locations = 7; - */ - private $content_locations; - /** - * Information about the container where this finding occurred, if available. - * - * Generated from protobuf field .google.privacy.dlp.v2.Container container = 8; - */ - protected $container = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\Range $byte_range - * Zero-based byte offsets delimiting the finding. - * These are relative to the finding's containing element. - * Note that when the content is not textual, this references - * the UTF-8 encoded textual representation of the content. - * Omitted if content is an image. - * @type \Google\Cloud\Dlp\V2\Range $codepoint_range - * Unicode character offsets delimiting the finding. - * These are relative to the finding's containing element. - * Provided when the content is text. - * @type array<\Google\Cloud\Dlp\V2\ContentLocation>|\Google\Protobuf\Internal\RepeatedField $content_locations - * List of nested objects pointing to the precise location of the finding - * within the file or record. - * @type \Google\Cloud\Dlp\V2\Container $container - * Information about the container where this finding occurred, if available. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Zero-based byte offsets delimiting the finding. - * These are relative to the finding's containing element. - * Note that when the content is not textual, this references - * the UTF-8 encoded textual representation of the content. - * Omitted if content is an image. - * - * Generated from protobuf field .google.privacy.dlp.v2.Range byte_range = 1; - * @return \Google\Cloud\Dlp\V2\Range|null - */ - public function getByteRange() - { - return $this->byte_range; - } - - public function hasByteRange() - { - return isset($this->byte_range); - } - - public function clearByteRange() - { - unset($this->byte_range); - } - - /** - * Zero-based byte offsets delimiting the finding. - * These are relative to the finding's containing element. - * Note that when the content is not textual, this references - * the UTF-8 encoded textual representation of the content. - * Omitted if content is an image. - * - * Generated from protobuf field .google.privacy.dlp.v2.Range byte_range = 1; - * @param \Google\Cloud\Dlp\V2\Range $var - * @return $this - */ - public function setByteRange($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Range::class); - $this->byte_range = $var; - - return $this; - } - - /** - * Unicode character offsets delimiting the finding. - * These are relative to the finding's containing element. - * Provided when the content is text. - * - * Generated from protobuf field .google.privacy.dlp.v2.Range codepoint_range = 2; - * @return \Google\Cloud\Dlp\V2\Range|null - */ - public function getCodepointRange() - { - return $this->codepoint_range; - } - - public function hasCodepointRange() - { - return isset($this->codepoint_range); - } - - public function clearCodepointRange() - { - unset($this->codepoint_range); - } - - /** - * Unicode character offsets delimiting the finding. - * These are relative to the finding's containing element. - * Provided when the content is text. - * - * Generated from protobuf field .google.privacy.dlp.v2.Range codepoint_range = 2; - * @param \Google\Cloud\Dlp\V2\Range $var - * @return $this - */ - public function setCodepointRange($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Range::class); - $this->codepoint_range = $var; - - return $this; - } - - /** - * List of nested objects pointing to the precise location of the finding - * within the file or record. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ContentLocation content_locations = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getContentLocations() - { - return $this->content_locations; - } - - /** - * List of nested objects pointing to the precise location of the finding - * within the file or record. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.ContentLocation content_locations = 7; - * @param array<\Google\Cloud\Dlp\V2\ContentLocation>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setContentLocations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\ContentLocation::class); - $this->content_locations = $arr; - - return $this; - } - - /** - * Information about the container where this finding occurred, if available. - * - * Generated from protobuf field .google.privacy.dlp.v2.Container container = 8; - * @return \Google\Cloud\Dlp\V2\Container|null - */ - public function getContainer() - { - return $this->container; - } - - public function hasContainer() - { - return isset($this->container); - } - - public function clearContainer() - { - unset($this->container); - } - - /** - * Information about the container where this finding occurred, if available. - * - * Generated from protobuf field .google.privacy.dlp.v2.Container container = 8; - * @param \Google\Cloud\Dlp\V2\Container $var - * @return $this - */ - public function setContainer($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Container::class); - $this->container = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Manual.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Manual.php deleted file mode 100644 index dbc05788c5db..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Manual.php +++ /dev/null @@ -1,34 +0,0 @@ -google.privacy.dlp.v2.Manual - */ -class Manual extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MatchingType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MatchingType.php deleted file mode 100644 index 5d456a0dc111..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MatchingType.php +++ /dev/null @@ -1,79 +0,0 @@ -google.privacy.dlp.v2.MatchingType - */ -class MatchingType -{ - /** - * Invalid. - * - * Generated from protobuf enum MATCHING_TYPE_UNSPECIFIED = 0; - */ - const MATCHING_TYPE_UNSPECIFIED = 0; - /** - * Full match. - * - Dictionary: join of Dictionary results matched complete finding quote - * - Regex: all regex matches fill a finding quote start to end - * - Exclude info type: completely inside affecting info types findings - * - * Generated from protobuf enum MATCHING_TYPE_FULL_MATCH = 1; - */ - const MATCHING_TYPE_FULL_MATCH = 1; - /** - * Partial match. - * - Dictionary: at least one of the tokens in the finding matches - * - Regex: substring of the finding matches - * - Exclude info type: intersects with affecting info types findings - * - * Generated from protobuf enum MATCHING_TYPE_PARTIAL_MATCH = 2; - */ - const MATCHING_TYPE_PARTIAL_MATCH = 2; - /** - * Inverse match. - * - Dictionary: no tokens in the finding match the dictionary - * - Regex: finding doesn't match the regex - * - Exclude info type: no intersection with affecting info types findings - * - * Generated from protobuf enum MATCHING_TYPE_INVERSE_MATCH = 3; - */ - const MATCHING_TYPE_INVERSE_MATCH = 3; - - private static $valueToName = [ - self::MATCHING_TYPE_UNSPECIFIED => 'MATCHING_TYPE_UNSPECIFIED', - self::MATCHING_TYPE_FULL_MATCH => 'MATCHING_TYPE_FULL_MATCH', - self::MATCHING_TYPE_PARTIAL_MATCH => 'MATCHING_TYPE_PARTIAL_MATCH', - self::MATCHING_TYPE_INVERSE_MATCH => 'MATCHING_TYPE_INVERSE_MATCH', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataLocation.php deleted file mode 100644 index ff36bc6835ea..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataLocation.php +++ /dev/null @@ -1,109 +0,0 @@ -google.privacy.dlp.v2.MetadataLocation - */ -class MetadataLocation extends \Google\Protobuf\Internal\Message -{ - /** - * Type of metadata containing the finding. - * - * Generated from protobuf field .google.privacy.dlp.v2.MetadataType type = 1; - */ - protected $type = 0; - protected $label; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $type - * Type of metadata containing the finding. - * @type \Google\Cloud\Dlp\V2\StorageMetadataLabel $storage_label - * Storage metadata. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Type of metadata containing the finding. - * - * Generated from protobuf field .google.privacy.dlp.v2.MetadataType type = 1; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Type of metadata containing the finding. - * - * Generated from protobuf field .google.privacy.dlp.v2.MetadataType type = 1; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\MetadataType::class); - $this->type = $var; - - return $this; - } - - /** - * Storage metadata. - * - * Generated from protobuf field .google.privacy.dlp.v2.StorageMetadataLabel storage_label = 3; - * @return \Google\Cloud\Dlp\V2\StorageMetadataLabel|null - */ - public function getStorageLabel() - { - return $this->readOneof(3); - } - - public function hasStorageLabel() - { - return $this->hasOneof(3); - } - - /** - * Storage metadata. - * - * Generated from protobuf field .google.privacy.dlp.v2.StorageMetadataLabel storage_label = 3; - * @param \Google\Cloud\Dlp\V2\StorageMetadataLabel $var - * @return $this - */ - public function setStorageLabel($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StorageMetadataLabel::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getLabel() - { - return $this->whichOneof("label"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataType.php deleted file mode 100644 index e99808ba042e..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/MetadataType.php +++ /dev/null @@ -1,54 +0,0 @@ -google.privacy.dlp.v2.MetadataType - */ -class MetadataType -{ - /** - * Unused - * - * Generated from protobuf enum METADATATYPE_UNSPECIFIED = 0; - */ - const METADATATYPE_UNSPECIFIED = 0; - /** - * General file metadata provided by Cloud Storage. - * - * Generated from protobuf enum STORAGE_METADATA = 2; - */ - const STORAGE_METADATA = 2; - - private static $valueToName = [ - self::METADATATYPE_UNSPECIFIED => 'METADATATYPE_UNSPECIFIED', - self::STORAGE_METADATA => 'STORAGE_METADATA', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/NullPercentageLevel.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/NullPercentageLevel.php deleted file mode 100644 index bcd45432e06a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/NullPercentageLevel.php +++ /dev/null @@ -1,76 +0,0 @@ -google.privacy.dlp.v2.NullPercentageLevel - */ -class NullPercentageLevel -{ - /** - * Unused. - * - * Generated from protobuf enum NULL_PERCENTAGE_LEVEL_UNSPECIFIED = 0; - */ - const NULL_PERCENTAGE_LEVEL_UNSPECIFIED = 0; - /** - * Very few null entries. - * - * Generated from protobuf enum NULL_PERCENTAGE_VERY_LOW = 1; - */ - const NULL_PERCENTAGE_VERY_LOW = 1; - /** - * Some null entries. - * - * Generated from protobuf enum NULL_PERCENTAGE_LOW = 2; - */ - const NULL_PERCENTAGE_LOW = 2; - /** - * A few null entries. - * - * Generated from protobuf enum NULL_PERCENTAGE_MEDIUM = 3; - */ - const NULL_PERCENTAGE_MEDIUM = 3; - /** - * A lot of null entries. - * - * Generated from protobuf enum NULL_PERCENTAGE_HIGH = 4; - */ - const NULL_PERCENTAGE_HIGH = 4; - - private static $valueToName = [ - self::NULL_PERCENTAGE_LEVEL_UNSPECIFIED => 'NULL_PERCENTAGE_LEVEL_UNSPECIFIED', - self::NULL_PERCENTAGE_VERY_LOW => 'NULL_PERCENTAGE_VERY_LOW', - self::NULL_PERCENTAGE_LOW => 'NULL_PERCENTAGE_LOW', - self::NULL_PERCENTAGE_MEDIUM => 'NULL_PERCENTAGE_MEDIUM', - self::NULL_PERCENTAGE_HIGH => 'NULL_PERCENTAGE_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); - } -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OtherInfoTypeSummary.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OtherInfoTypeSummary.php deleted file mode 100644 index ea7528a8112b..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OtherInfoTypeSummary.php +++ /dev/null @@ -1,153 +0,0 @@ -google.privacy.dlp.v2.OtherInfoTypeSummary - */ -class OtherInfoTypeSummary extends \Google\Protobuf\Internal\Message -{ - /** - * The other infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - */ - protected $info_type = null; - /** - * Approximate percentage of non-null rows that contained data detected by - * this infotype. - * - * Generated from protobuf field int32 estimated_prevalence = 2; - */ - protected $estimated_prevalence = 0; - /** - * Whether this infoType was excluded from sensitivity and risk analysis due - * to factors such as low prevalence (subject to change). - * - * Generated from protobuf field bool excluded_from_analysis = 3; - */ - protected $excluded_from_analysis = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InfoType $info_type - * The other infoType. - * @type int $estimated_prevalence - * Approximate percentage of non-null rows that contained data detected by - * this infotype. - * @type bool $excluded_from_analysis - * Whether this infoType was excluded from sensitivity and risk analysis due - * to factors such as low prevalence (subject to change). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The other infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getInfoType() - { - return $this->info_type; - } - - public function hasInfoType() - { - return isset($this->info_type); - } - - public function clearInfoType() - { - unset($this->info_type); - } - - /** - * The other infoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_type = $var; - - return $this; - } - - /** - * Approximate percentage of non-null rows that contained data detected by - * this infotype. - * - * Generated from protobuf field int32 estimated_prevalence = 2; - * @return int - */ - public function getEstimatedPrevalence() - { - return $this->estimated_prevalence; - } - - /** - * Approximate percentage of non-null rows that contained data detected by - * this infotype. - * - * Generated from protobuf field int32 estimated_prevalence = 2; - * @param int $var - * @return $this - */ - public function setEstimatedPrevalence($var) - { - GPBUtil::checkInt32($var); - $this->estimated_prevalence = $var; - - return $this; - } - - /** - * Whether this infoType was excluded from sensitivity and risk analysis due - * to factors such as low prevalence (subject to change). - * - * Generated from protobuf field bool excluded_from_analysis = 3; - * @return bool - */ - public function getExcludedFromAnalysis() - { - return $this->excluded_from_analysis; - } - - /** - * Whether this infoType was excluded from sensitivity and risk analysis due - * to factors such as low prevalence (subject to change). - * - * Generated from protobuf field bool excluded_from_analysis = 3; - * @param bool $var - * @return $this - */ - public function setExcludedFromAnalysis($var) - { - GPBUtil::checkBool($var); - $this->excluded_from_analysis = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig.php deleted file mode 100644 index cd7b054981d8..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig.php +++ /dev/null @@ -1,174 +0,0 @@ -google.privacy.dlp.v2.OutputStorageConfig - */ -class OutputStorageConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Schema used for writing the findings for Inspect jobs. This field is only - * used for Inspect and must be unspecified for Risk jobs. Columns are derived - * from the `Finding` object. If appending to an existing table, any columns - * from the predefined schema that are missing will be added. No columns in - * the existing table will be deleted. - * If unspecified, then all available columns will be used for a new table or - * an (existing) table with no schema, and no changes will be made to an - * existing table that has a schema. - * Only for use with external storage. - * - * Generated from protobuf field .google.privacy.dlp.v2.OutputStorageConfig.OutputSchema output_schema = 3; - */ - protected $output_schema = 0; - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\BigQueryTable $table - * Store findings in an existing table or a new table in an existing - * dataset. If table_id is not set a new one will be generated - * for you with the following format: - * dlp_googleapis_yyyy_mm_dd_[dlp_job_id]. Pacific time zone will be used - * for generating the date details. - * For Inspect, each column in an existing output table must have the same - * name, type, and mode of a field in the `Finding` object. - * For Risk, an existing output table should be the output of a previous - * Risk analysis job run on the same source table, with the same privacy - * metric and quasi-identifiers. Risk jobs that analyze the same table but - * compute a different privacy metric, or use different sets of - * quasi-identifiers, cannot store their results in the same table. - * @type int $output_schema - * Schema used for writing the findings for Inspect jobs. This field is only - * used for Inspect and must be unspecified for Risk jobs. Columns are derived - * from the `Finding` object. If appending to an existing table, any columns - * from the predefined schema that are missing will be added. No columns in - * the existing table will be deleted. - * If unspecified, then all available columns will be used for a new table or - * an (existing) table with no schema, and no changes will be made to an - * existing table that has a schema. - * Only for use with external storage. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Store findings in an existing table or a new table in an existing - * dataset. If table_id is not set a new one will be generated - * for you with the following format: - * dlp_googleapis_yyyy_mm_dd_[dlp_job_id]. Pacific time zone will be used - * for generating the date details. - * For Inspect, each column in an existing output table must have the same - * name, type, and mode of a field in the `Finding` object. - * For Risk, an existing output table should be the output of a previous - * Risk analysis job run on the same source table, with the same privacy - * metric and quasi-identifiers. Risk jobs that analyze the same table but - * compute a different privacy metric, or use different sets of - * quasi-identifiers, cannot store their results in the same table. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; - * @return \Google\Cloud\Dlp\V2\BigQueryTable|null - */ - public function getTable() - { - return $this->readOneof(1); - } - - public function hasTable() - { - return $this->hasOneof(1); - } - - /** - * Store findings in an existing table or a new table in an existing - * dataset. If table_id is not set a new one will be generated - * for you with the following format: - * dlp_googleapis_yyyy_mm_dd_[dlp_job_id]. Pacific time zone will be used - * for generating the date details. - * For Inspect, each column in an existing output table must have the same - * name, type, and mode of a field in the `Finding` object. - * For Risk, an existing output table should be the output of a previous - * Risk analysis job run on the same source table, with the same privacy - * metric and quasi-identifiers. Risk jobs that analyze the same table but - * compute a different privacy metric, or use different sets of - * quasi-identifiers, cannot store their results in the same table. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; - * @param \Google\Cloud\Dlp\V2\BigQueryTable $var - * @return $this - */ - public function setTable($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Schema used for writing the findings for Inspect jobs. This field is only - * used for Inspect and must be unspecified for Risk jobs. Columns are derived - * from the `Finding` object. If appending to an existing table, any columns - * from the predefined schema that are missing will be added. No columns in - * the existing table will be deleted. - * If unspecified, then all available columns will be used for a new table or - * an (existing) table with no schema, and no changes will be made to an - * existing table that has a schema. - * Only for use with external storage. - * - * Generated from protobuf field .google.privacy.dlp.v2.OutputStorageConfig.OutputSchema output_schema = 3; - * @return int - */ - public function getOutputSchema() - { - return $this->output_schema; - } - - /** - * Schema used for writing the findings for Inspect jobs. This field is only - * used for Inspect and must be unspecified for Risk jobs. Columns are derived - * from the `Finding` object. If appending to an existing table, any columns - * from the predefined schema that are missing will be added. No columns in - * the existing table will be deleted. - * If unspecified, then all available columns will be used for a new table or - * an (existing) table with no schema, and no changes will be made to an - * existing table that has a schema. - * Only for use with external storage. - * - * Generated from protobuf field .google.privacy.dlp.v2.OutputStorageConfig.OutputSchema output_schema = 3; - * @param int $var - * @return $this - */ - public function setOutputSchema($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\OutputStorageConfig\OutputSchema::class); - $this->output_schema = $var; - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig/OutputSchema.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig/OutputSchema.php deleted file mode 100644 index 561e97f7d483..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/OutputStorageConfig/OutputSchema.php +++ /dev/null @@ -1,87 +0,0 @@ -google.privacy.dlp.v2.OutputStorageConfig.OutputSchema - */ -class OutputSchema -{ - /** - * Unused. - * - * Generated from protobuf enum OUTPUT_SCHEMA_UNSPECIFIED = 0; - */ - const OUTPUT_SCHEMA_UNSPECIFIED = 0; - /** - * Basic schema including only `info_type`, `quote`, `certainty`, and - * `timestamp`. - * - * Generated from protobuf enum BASIC_COLUMNS = 1; - */ - const BASIC_COLUMNS = 1; - /** - * Schema tailored to findings from scanning Cloud Storage. - * - * Generated from protobuf enum GCS_COLUMNS = 2; - */ - const GCS_COLUMNS = 2; - /** - * Schema tailored to findings from scanning Google Datastore. - * - * Generated from protobuf enum DATASTORE_COLUMNS = 3; - */ - const DATASTORE_COLUMNS = 3; - /** - * Schema tailored to findings from scanning Google BigQuery. - * - * Generated from protobuf enum BIG_QUERY_COLUMNS = 4; - */ - const BIG_QUERY_COLUMNS = 4; - /** - * Schema containing all columns. - * - * Generated from protobuf enum ALL_COLUMNS = 5; - */ - const ALL_COLUMNS = 5; - - private static $valueToName = [ - self::OUTPUT_SCHEMA_UNSPECIFIED => 'OUTPUT_SCHEMA_UNSPECIFIED', - self::BASIC_COLUMNS => 'BASIC_COLUMNS', - self::GCS_COLUMNS => 'GCS_COLUMNS', - self::DATASTORE_COLUMNS => 'DATASTORE_COLUMNS', - self::BIG_QUERY_COLUMNS => 'BIG_QUERY_COLUMNS', - self::ALL_COLUMNS => 'ALL_COLUMNS', - ]; - - 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(OutputSchema::class, \Google\Cloud\Dlp\V2\OutputStorageConfig_OutputSchema::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PartitionId.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PartitionId.php deleted file mode 100644 index 1f8527860eb1..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PartitionId.php +++ /dev/null @@ -1,105 +0,0 @@ -google.privacy.dlp.v2.PartitionId - */ -class PartitionId extends \Google\Protobuf\Internal\Message -{ - /** - * The ID of the project to which the entities belong. - * - * Generated from protobuf field string project_id = 2; - */ - protected $project_id = ''; - /** - * If not empty, the ID of the namespace to which the entities belong. - * - * Generated from protobuf field string namespace_id = 4; - */ - protected $namespace_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $project_id - * The ID of the project to which the entities belong. - * @type string $namespace_id - * If not empty, the ID of the namespace to which the entities belong. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * The ID of the project to which the entities belong. - * - * Generated from protobuf field string project_id = 2; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * The ID of the project to which the entities belong. - * - * 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; - } - - /** - * If not empty, the ID of the namespace to which the entities belong. - * - * Generated from protobuf field string namespace_id = 4; - * @return string - */ - public function getNamespaceId() - { - return $this->namespace_id; - } - - /** - * If not empty, the ID of the namespace to which the entities belong. - * - * Generated from protobuf field string namespace_id = 4; - * @param string $var - * @return $this - */ - public function setNamespaceId($var) - { - GPBUtil::checkString($var, True); - $this->namespace_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrimitiveTransformation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrimitiveTransformation.php deleted file mode 100644 index 3e157d333e06..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrimitiveTransformation.php +++ /dev/null @@ -1,438 +0,0 @@ -google.privacy.dlp.v2.PrimitiveTransformation - */ -class PrimitiveTransformation extends \Google\Protobuf\Internal\Message -{ - protected $transformation; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\ReplaceValueConfig $replace_config - * Replace with a specified value. - * @type \Google\Cloud\Dlp\V2\RedactConfig $redact_config - * Redact - * @type \Google\Cloud\Dlp\V2\CharacterMaskConfig $character_mask_config - * Mask - * @type \Google\Cloud\Dlp\V2\CryptoReplaceFfxFpeConfig $crypto_replace_ffx_fpe_config - * Ffx-Fpe - * @type \Google\Cloud\Dlp\V2\FixedSizeBucketingConfig $fixed_size_bucketing_config - * Fixed size bucketing - * @type \Google\Cloud\Dlp\V2\BucketingConfig $bucketing_config - * Bucketing - * @type \Google\Cloud\Dlp\V2\ReplaceWithInfoTypeConfig $replace_with_info_type_config - * Replace with infotype - * @type \Google\Cloud\Dlp\V2\TimePartConfig $time_part_config - * Time extraction - * @type \Google\Cloud\Dlp\V2\CryptoHashConfig $crypto_hash_config - * Crypto - * @type \Google\Cloud\Dlp\V2\DateShiftConfig $date_shift_config - * Date Shift - * @type \Google\Cloud\Dlp\V2\CryptoDeterministicConfig $crypto_deterministic_config - * Deterministic Crypto - * @type \Google\Cloud\Dlp\V2\ReplaceDictionaryConfig $replace_dictionary_config - * Replace with a value randomly drawn (with replacement) from a dictionary. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Replace with a specified value. - * - * Generated from protobuf field .google.privacy.dlp.v2.ReplaceValueConfig replace_config = 1; - * @return \Google\Cloud\Dlp\V2\ReplaceValueConfig|null - */ - public function getReplaceConfig() - { - return $this->readOneof(1); - } - - public function hasReplaceConfig() - { - return $this->hasOneof(1); - } - - /** - * Replace with a specified value. - * - * Generated from protobuf field .google.privacy.dlp.v2.ReplaceValueConfig replace_config = 1; - * @param \Google\Cloud\Dlp\V2\ReplaceValueConfig $var - * @return $this - */ - public function setReplaceConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ReplaceValueConfig::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Redact - * - * Generated from protobuf field .google.privacy.dlp.v2.RedactConfig redact_config = 2; - * @return \Google\Cloud\Dlp\V2\RedactConfig|null - */ - public function getRedactConfig() - { - return $this->readOneof(2); - } - - public function hasRedactConfig() - { - return $this->hasOneof(2); - } - - /** - * Redact - * - * Generated from protobuf field .google.privacy.dlp.v2.RedactConfig redact_config = 2; - * @param \Google\Cloud\Dlp\V2\RedactConfig $var - * @return $this - */ - public function setRedactConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RedactConfig::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Mask - * - * Generated from protobuf field .google.privacy.dlp.v2.CharacterMaskConfig character_mask_config = 3; - * @return \Google\Cloud\Dlp\V2\CharacterMaskConfig|null - */ - public function getCharacterMaskConfig() - { - return $this->readOneof(3); - } - - public function hasCharacterMaskConfig() - { - return $this->hasOneof(3); - } - - /** - * Mask - * - * Generated from protobuf field .google.privacy.dlp.v2.CharacterMaskConfig character_mask_config = 3; - * @param \Google\Cloud\Dlp\V2\CharacterMaskConfig $var - * @return $this - */ - public function setCharacterMaskConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CharacterMaskConfig::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Ffx-Fpe - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - * @return \Google\Cloud\Dlp\V2\CryptoReplaceFfxFpeConfig|null - */ - public function getCryptoReplaceFfxFpeConfig() - { - return $this->readOneof(4); - } - - public function hasCryptoReplaceFfxFpeConfig() - { - return $this->hasOneof(4); - } - - /** - * Ffx-Fpe - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - * @param \Google\Cloud\Dlp\V2\CryptoReplaceFfxFpeConfig $var - * @return $this - */ - public function setCryptoReplaceFfxFpeConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoReplaceFfxFpeConfig::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Fixed size bucketing - * - * Generated from protobuf field .google.privacy.dlp.v2.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - * @return \Google\Cloud\Dlp\V2\FixedSizeBucketingConfig|null - */ - public function getFixedSizeBucketingConfig() - { - return $this->readOneof(5); - } - - public function hasFixedSizeBucketingConfig() - { - return $this->hasOneof(5); - } - - /** - * Fixed size bucketing - * - * Generated from protobuf field .google.privacy.dlp.v2.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - * @param \Google\Cloud\Dlp\V2\FixedSizeBucketingConfig $var - * @return $this - */ - public function setFixedSizeBucketingConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FixedSizeBucketingConfig::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Bucketing - * - * Generated from protobuf field .google.privacy.dlp.v2.BucketingConfig bucketing_config = 6; - * @return \Google\Cloud\Dlp\V2\BucketingConfig|null - */ - public function getBucketingConfig() - { - return $this->readOneof(6); - } - - public function hasBucketingConfig() - { - return $this->hasOneof(6); - } - - /** - * Bucketing - * - * Generated from protobuf field .google.privacy.dlp.v2.BucketingConfig bucketing_config = 6; - * @param \Google\Cloud\Dlp\V2\BucketingConfig $var - * @return $this - */ - public function setBucketingConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BucketingConfig::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * Replace with infotype - * - * Generated from protobuf field .google.privacy.dlp.v2.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - * @return \Google\Cloud\Dlp\V2\ReplaceWithInfoTypeConfig|null - */ - public function getReplaceWithInfoTypeConfig() - { - return $this->readOneof(7); - } - - public function hasReplaceWithInfoTypeConfig() - { - return $this->hasOneof(7); - } - - /** - * Replace with infotype - * - * Generated from protobuf field .google.privacy.dlp.v2.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - * @param \Google\Cloud\Dlp\V2\ReplaceWithInfoTypeConfig $var - * @return $this - */ - public function setReplaceWithInfoTypeConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ReplaceWithInfoTypeConfig::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * Time extraction - * - * Generated from protobuf field .google.privacy.dlp.v2.TimePartConfig time_part_config = 8; - * @return \Google\Cloud\Dlp\V2\TimePartConfig|null - */ - public function getTimePartConfig() - { - return $this->readOneof(8); - } - - public function hasTimePartConfig() - { - return $this->hasOneof(8); - } - - /** - * Time extraction - * - * Generated from protobuf field .google.privacy.dlp.v2.TimePartConfig time_part_config = 8; - * @param \Google\Cloud\Dlp\V2\TimePartConfig $var - * @return $this - */ - public function setTimePartConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TimePartConfig::class); - $this->writeOneof(8, $var); - - return $this; - } - - /** - * Crypto - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoHashConfig crypto_hash_config = 9; - * @return \Google\Cloud\Dlp\V2\CryptoHashConfig|null - */ - public function getCryptoHashConfig() - { - return $this->readOneof(9); - } - - public function hasCryptoHashConfig() - { - return $this->hasOneof(9); - } - - /** - * Crypto - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoHashConfig crypto_hash_config = 9; - * @param \Google\Cloud\Dlp\V2\CryptoHashConfig $var - * @return $this - */ - public function setCryptoHashConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoHashConfig::class); - $this->writeOneof(9, $var); - - return $this; - } - - /** - * Date Shift - * - * Generated from protobuf field .google.privacy.dlp.v2.DateShiftConfig date_shift_config = 11; - * @return \Google\Cloud\Dlp\V2\DateShiftConfig|null - */ - public function getDateShiftConfig() - { - return $this->readOneof(11); - } - - public function hasDateShiftConfig() - { - return $this->hasOneof(11); - } - - /** - * Date Shift - * - * Generated from protobuf field .google.privacy.dlp.v2.DateShiftConfig date_shift_config = 11; - * @param \Google\Cloud\Dlp\V2\DateShiftConfig $var - * @return $this - */ - public function setDateShiftConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DateShiftConfig::class); - $this->writeOneof(11, $var); - - return $this; - } - - /** - * Deterministic Crypto - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoDeterministicConfig crypto_deterministic_config = 12; - * @return \Google\Cloud\Dlp\V2\CryptoDeterministicConfig|null - */ - public function getCryptoDeterministicConfig() - { - return $this->readOneof(12); - } - - public function hasCryptoDeterministicConfig() - { - return $this->hasOneof(12); - } - - /** - * Deterministic Crypto - * - * Generated from protobuf field .google.privacy.dlp.v2.CryptoDeterministicConfig crypto_deterministic_config = 12; - * @param \Google\Cloud\Dlp\V2\CryptoDeterministicConfig $var - * @return $this - */ - public function setCryptoDeterministicConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CryptoDeterministicConfig::class); - $this->writeOneof(12, $var); - - return $this; - } - - /** - * Replace with a value randomly drawn (with replacement) from a dictionary. - * - * Generated from protobuf field .google.privacy.dlp.v2.ReplaceDictionaryConfig replace_dictionary_config = 13; - * @return \Google\Cloud\Dlp\V2\ReplaceDictionaryConfig|null - */ - public function getReplaceDictionaryConfig() - { - return $this->readOneof(13); - } - - public function hasReplaceDictionaryConfig() - { - return $this->hasOneof(13); - } - - /** - * Replace with a value randomly drawn (with replacement) from a dictionary. - * - * Generated from protobuf field .google.privacy.dlp.v2.ReplaceDictionaryConfig replace_dictionary_config = 13; - * @param \Google\Cloud\Dlp\V2\ReplaceDictionaryConfig $var - * @return $this - */ - public function setReplaceDictionaryConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ReplaceDictionaryConfig::class); - $this->writeOneof(13, $var); - - return $this; - } - - /** - * @return string - */ - public function getTransformation() - { - return $this->whichOneof("transformation"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric.php deleted file mode 100644 index 8b9475f69955..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric.php +++ /dev/null @@ -1,240 +0,0 @@ -google.privacy.dlp.v2.PrivacyMetric - */ -class PrivacyMetric extends \Google\Protobuf\Internal\Message -{ - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\PrivacyMetric\NumericalStatsConfig $numerical_stats_config - * Numerical stats - * @type \Google\Cloud\Dlp\V2\PrivacyMetric\CategoricalStatsConfig $categorical_stats_config - * Categorical stats - * @type \Google\Cloud\Dlp\V2\PrivacyMetric\KAnonymityConfig $k_anonymity_config - * K-anonymity - * @type \Google\Cloud\Dlp\V2\PrivacyMetric\LDiversityConfig $l_diversity_config - * l-diversity - * @type \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig $k_map_estimation_config - * k-map - * @type \Google\Cloud\Dlp\V2\PrivacyMetric\DeltaPresenceEstimationConfig $delta_presence_estimation_config - * delta-presence - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Numerical stats - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - * @return \Google\Cloud\Dlp\V2\PrivacyMetric\NumericalStatsConfig|null - */ - public function getNumericalStatsConfig() - { - return $this->readOneof(1); - } - - public function hasNumericalStatsConfig() - { - return $this->hasOneof(1); - } - - /** - * Numerical stats - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - * @param \Google\Cloud\Dlp\V2\PrivacyMetric\NumericalStatsConfig $var - * @return $this - */ - public function setNumericalStatsConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric\NumericalStatsConfig::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Categorical stats - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - * @return \Google\Cloud\Dlp\V2\PrivacyMetric\CategoricalStatsConfig|null - */ - public function getCategoricalStatsConfig() - { - return $this->readOneof(2); - } - - public function hasCategoricalStatsConfig() - { - return $this->hasOneof(2); - } - - /** - * Categorical stats - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - * @param \Google\Cloud\Dlp\V2\PrivacyMetric\CategoricalStatsConfig $var - * @return $this - */ - public function setCategoricalStatsConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric\CategoricalStatsConfig::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * K-anonymity - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - * @return \Google\Cloud\Dlp\V2\PrivacyMetric\KAnonymityConfig|null - */ - public function getKAnonymityConfig() - { - return $this->readOneof(3); - } - - public function hasKAnonymityConfig() - { - return $this->hasOneof(3); - } - - /** - * K-anonymity - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - * @param \Google\Cloud\Dlp\V2\PrivacyMetric\KAnonymityConfig $var - * @return $this - */ - public function setKAnonymityConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric\KAnonymityConfig::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * l-diversity - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - * @return \Google\Cloud\Dlp\V2\PrivacyMetric\LDiversityConfig|null - */ - public function getLDiversityConfig() - { - return $this->readOneof(4); - } - - public function hasLDiversityConfig() - { - return $this->hasOneof(4); - } - - /** - * l-diversity - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - * @param \Google\Cloud\Dlp\V2\PrivacyMetric\LDiversityConfig $var - * @return $this - */ - public function setLDiversityConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric\LDiversityConfig::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * k-map - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig k_map_estimation_config = 5; - * @return \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig|null - */ - public function getKMapEstimationConfig() - { - return $this->readOneof(5); - } - - public function hasKMapEstimationConfig() - { - return $this->hasOneof(5); - } - - /** - * k-map - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig k_map_estimation_config = 5; - * @param \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig $var - * @return $this - */ - public function setKMapEstimationConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * delta-presence - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.DeltaPresenceEstimationConfig delta_presence_estimation_config = 6; - * @return \Google\Cloud\Dlp\V2\PrivacyMetric\DeltaPresenceEstimationConfig|null - */ - public function getDeltaPresenceEstimationConfig() - { - return $this->readOneof(6); - } - - public function hasDeltaPresenceEstimationConfig() - { - return $this->hasOneof(6); - } - - /** - * delta-presence - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric.DeltaPresenceEstimationConfig delta_presence_estimation_config = 6; - * @param \Google\Cloud\Dlp\V2\PrivacyMetric\DeltaPresenceEstimationConfig $var - * @return $this - */ - public function setDeltaPresenceEstimationConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric\DeltaPresenceEstimationConfig::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/CategoricalStatsConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/CategoricalStatsConfig.php deleted file mode 100644 index d00835a5269d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/CategoricalStatsConfig.php +++ /dev/null @@ -1,93 +0,0 @@ -google.privacy.dlp.v2.PrivacyMetric.CategoricalStatsConfig - */ -class CategoricalStatsConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Field to compute categorical stats on. All column types are - * supported except for arrays and structs. However, it may be more - * informative to use NumericalStats when the field type is supported, - * depending on the data. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - */ - protected $field = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\FieldId $field - * Field to compute categorical stats on. All column types are - * supported except for arrays and structs. However, it may be more - * informative to use NumericalStats when the field type is supported, - * depending on the data. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Field to compute categorical stats on. All column types are - * supported except for arrays and structs. However, it may be more - * informative to use NumericalStats when the field type is supported, - * depending on the data. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getField() - { - return $this->field; - } - - public function hasField() - { - return isset($this->field); - } - - public function clearField() - { - unset($this->field); - } - - /** - * Field to compute categorical stats on. All column types are - * supported except for arrays and structs. However, it may be more - * informative to use NumericalStats when the field type is supported, - * depending on the data. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setField($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->field = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(CategoricalStatsConfig::class, \Google\Cloud\Dlp\V2\PrivacyMetric_CategoricalStatsConfig::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/DeltaPresenceEstimationConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/DeltaPresenceEstimationConfig.php deleted file mode 100644 index 101c63e5430c..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/DeltaPresenceEstimationConfig.php +++ /dev/null @@ -1,161 +0,0 @@ -google.privacy.dlp.v2.PrivacyMetric.DeltaPresenceEstimationConfig - */ -class DeltaPresenceEstimationConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Fields considered to be quasi-identifiers. No two fields can - * have the same tag. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.QuasiId quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $quasi_ids; - /** - * ISO 3166-1 alpha-2 region code to use in the statistical modeling. - * Set if no column is tagged with a region-specific InfoType (like - * US_ZIP_5) or a region code. - * - * Generated from protobuf field string region_code = 2; - */ - protected $region_code = ''; - /** - * Several auxiliary tables can be used in the analysis. Each custom_tag - * used to tag a quasi-identifiers field must appear in exactly one - * field of one auxiliary table. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.StatisticalTable auxiliary_tables = 3; - */ - private $auxiliary_tables; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\QuasiId>|\Google\Protobuf\Internal\RepeatedField $quasi_ids - * Required. Fields considered to be quasi-identifiers. No two fields can - * have the same tag. - * @type string $region_code - * ISO 3166-1 alpha-2 region code to use in the statistical modeling. - * Set if no column is tagged with a region-specific InfoType (like - * US_ZIP_5) or a region code. - * @type array<\Google\Cloud\Dlp\V2\StatisticalTable>|\Google\Protobuf\Internal\RepeatedField $auxiliary_tables - * Several auxiliary tables can be used in the analysis. Each custom_tag - * used to tag a quasi-identifiers field must appear in exactly one - * field of one auxiliary table. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Fields considered to be quasi-identifiers. No two fields can - * have the same tag. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.QuasiId quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQuasiIds() - { - return $this->quasi_ids; - } - - /** - * Required. Fields considered to be quasi-identifiers. No two fields can - * have the same tag. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.QuasiId quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\Dlp\V2\QuasiId>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQuasiIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\QuasiId::class); - $this->quasi_ids = $arr; - - return $this; - } - - /** - * ISO 3166-1 alpha-2 region code to use in the statistical modeling. - * Set if no column is tagged with a region-specific InfoType (like - * US_ZIP_5) or a region code. - * - * Generated from protobuf field string region_code = 2; - * @return string - */ - public function getRegionCode() - { - return $this->region_code; - } - - /** - * ISO 3166-1 alpha-2 region code to use in the statistical modeling. - * Set if no column is tagged with a region-specific InfoType (like - * US_ZIP_5) or a region code. - * - * Generated from protobuf field string region_code = 2; - * @param string $var - * @return $this - */ - public function setRegionCode($var) - { - GPBUtil::checkString($var, True); - $this->region_code = $var; - - return $this; - } - - /** - * Several auxiliary tables can be used in the analysis. Each custom_tag - * used to tag a quasi-identifiers field must appear in exactly one - * field of one auxiliary table. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.StatisticalTable auxiliary_tables = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAuxiliaryTables() - { - return $this->auxiliary_tables; - } - - /** - * Several auxiliary tables can be used in the analysis. Each custom_tag - * used to tag a quasi-identifiers field must appear in exactly one - * field of one auxiliary table. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.StatisticalTable auxiliary_tables = 3; - * @param array<\Google\Cloud\Dlp\V2\StatisticalTable>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAuxiliaryTables($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\StatisticalTable::class); - $this->auxiliary_tables = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DeltaPresenceEstimationConfig::class, \Google\Cloud\Dlp\V2\PrivacyMetric_DeltaPresenceEstimationConfig::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KAnonymityConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KAnonymityConfig.php deleted file mode 100644 index 0628b25d574a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KAnonymityConfig.php +++ /dev/null @@ -1,162 +0,0 @@ -google.privacy.dlp.v2.PrivacyMetric.KAnonymityConfig - */ -class KAnonymityConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Set of fields to compute k-anonymity over. When multiple fields are - * specified, they are considered a single composite key. Structs and - * repeated data types are not supported; however, nested fields are - * supported so long as they are not structs themselves or nested within - * a repeated field. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId quasi_ids = 1; - */ - private $quasi_ids; - /** - * Message indicating that multiple rows might be associated to a - * single individual. If the same entity_id is associated to multiple - * quasi-identifier tuples over distinct rows, we consider the entire - * collection of tuples as the composite quasi-identifier. This collection - * is a multiset: the order in which the different tuples appear in the - * dataset is ignored, but their frequency is taken into account. - * Important note: a maximum of 1000 rows can be associated to a single - * entity ID. If more rows are associated with the same entity ID, some - * might be ignored. - * - * Generated from protobuf field .google.privacy.dlp.v2.EntityId entity_id = 2; - */ - protected $entity_id = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $quasi_ids - * Set of fields to compute k-anonymity over. When multiple fields are - * specified, they are considered a single composite key. Structs and - * repeated data types are not supported; however, nested fields are - * supported so long as they are not structs themselves or nested within - * a repeated field. - * @type \Google\Cloud\Dlp\V2\EntityId $entity_id - * Message indicating that multiple rows might be associated to a - * single individual. If the same entity_id is associated to multiple - * quasi-identifier tuples over distinct rows, we consider the entire - * collection of tuples as the composite quasi-identifier. This collection - * is a multiset: the order in which the different tuples appear in the - * dataset is ignored, but their frequency is taken into account. - * Important note: a maximum of 1000 rows can be associated to a single - * entity ID. If more rows are associated with the same entity ID, some - * might be ignored. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Set of fields to compute k-anonymity over. When multiple fields are - * specified, they are considered a single composite key. Structs and - * repeated data types are not supported; however, nested fields are - * supported so long as they are not structs themselves or nested within - * a repeated field. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId quasi_ids = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQuasiIds() - { - return $this->quasi_ids; - } - - /** - * Set of fields to compute k-anonymity over. When multiple fields are - * specified, they are considered a single composite key. Structs and - * repeated data types are not supported; however, nested fields are - * supported so long as they are not structs themselves or nested within - * a repeated field. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId quasi_ids = 1; - * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQuasiIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); - $this->quasi_ids = $arr; - - return $this; - } - - /** - * Message indicating that multiple rows might be associated to a - * single individual. If the same entity_id is associated to multiple - * quasi-identifier tuples over distinct rows, we consider the entire - * collection of tuples as the composite quasi-identifier. This collection - * is a multiset: the order in which the different tuples appear in the - * dataset is ignored, but their frequency is taken into account. - * Important note: a maximum of 1000 rows can be associated to a single - * entity ID. If more rows are associated with the same entity ID, some - * might be ignored. - * - * Generated from protobuf field .google.privacy.dlp.v2.EntityId entity_id = 2; - * @return \Google\Cloud\Dlp\V2\EntityId|null - */ - public function getEntityId() - { - return $this->entity_id; - } - - public function hasEntityId() - { - return isset($this->entity_id); - } - - public function clearEntityId() - { - unset($this->entity_id); - } - - /** - * Message indicating that multiple rows might be associated to a - * single individual. If the same entity_id is associated to multiple - * quasi-identifier tuples over distinct rows, we consider the entire - * collection of tuples as the composite quasi-identifier. This collection - * is a multiset: the order in which the different tuples appear in the - * dataset is ignored, but their frequency is taken into account. - * Important note: a maximum of 1000 rows can be associated to a single - * entity ID. If more rows are associated with the same entity ID, some - * might be ignored. - * - * Generated from protobuf field .google.privacy.dlp.v2.EntityId entity_id = 2; - * @param \Google\Cloud\Dlp\V2\EntityId $var - * @return $this - */ - public function setEntityId($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\EntityId::class); - $this->entity_id = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(KAnonymityConfig::class, \Google\Cloud\Dlp\V2\PrivacyMetric_KAnonymityConfig::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig.php deleted file mode 100644 index 036f106c6a86..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig.php +++ /dev/null @@ -1,163 +0,0 @@ -google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig - */ -class KMapEstimationConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Fields considered to be quasi-identifiers. No two columns can - * have the same tag. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.TaggedField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $quasi_ids; - /** - * ISO 3166-1 alpha-2 region code to use in the statistical modeling. - * Set if no column is tagged with a region-specific InfoType (like - * US_ZIP_5) or a region code. - * - * Generated from protobuf field string region_code = 2; - */ - protected $region_code = ''; - /** - * Several auxiliary tables can be used in the analysis. Each custom_tag - * used to tag a quasi-identifiers column must appear in exactly one column - * of one auxiliary table. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable auxiliary_tables = 3; - */ - private $auxiliary_tables; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\TaggedField>|\Google\Protobuf\Internal\RepeatedField $quasi_ids - * Required. Fields considered to be quasi-identifiers. No two columns can - * have the same tag. - * @type string $region_code - * ISO 3166-1 alpha-2 region code to use in the statistical modeling. - * Set if no column is tagged with a region-specific InfoType (like - * US_ZIP_5) or a region code. - * @type array<\Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\AuxiliaryTable>|\Google\Protobuf\Internal\RepeatedField $auxiliary_tables - * Several auxiliary tables can be used in the analysis. Each custom_tag - * used to tag a quasi-identifiers column must appear in exactly one column - * of one auxiliary table. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Fields considered to be quasi-identifiers. No two columns can - * have the same tag. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.TaggedField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQuasiIds() - { - return $this->quasi_ids; - } - - /** - * Required. Fields considered to be quasi-identifiers. No two columns can - * have the same tag. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.TaggedField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\TaggedField>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQuasiIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\TaggedField::class); - $this->quasi_ids = $arr; - - return $this; - } - - /** - * ISO 3166-1 alpha-2 region code to use in the statistical modeling. - * Set if no column is tagged with a region-specific InfoType (like - * US_ZIP_5) or a region code. - * - * Generated from protobuf field string region_code = 2; - * @return string - */ - public function getRegionCode() - { - return $this->region_code; - } - - /** - * ISO 3166-1 alpha-2 region code to use in the statistical modeling. - * Set if no column is tagged with a region-specific InfoType (like - * US_ZIP_5) or a region code. - * - * Generated from protobuf field string region_code = 2; - * @param string $var - * @return $this - */ - public function setRegionCode($var) - { - GPBUtil::checkString($var, True); - $this->region_code = $var; - - return $this; - } - - /** - * Several auxiliary tables can be used in the analysis. Each custom_tag - * used to tag a quasi-identifiers column must appear in exactly one column - * of one auxiliary table. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable auxiliary_tables = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAuxiliaryTables() - { - return $this->auxiliary_tables; - } - - /** - * Several auxiliary tables can be used in the analysis. Each custom_tag - * used to tag a quasi-identifiers column must appear in exactly one column - * of one auxiliary table. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable auxiliary_tables = 3; - * @param array<\Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\AuxiliaryTable>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAuxiliaryTables($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\AuxiliaryTable::class); - $this->auxiliary_tables = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(KMapEstimationConfig::class, \Google\Cloud\Dlp\V2\PrivacyMetric_KMapEstimationConfig::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable.php deleted file mode 100644 index 339b644973ef..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable.php +++ /dev/null @@ -1,168 +0,0 @@ -google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable - */ -class AuxiliaryTable extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Auxiliary table location. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $table = null; - /** - * Required. Quasi-identifier columns. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable.QuasiIdField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $quasi_ids; - /** - * Required. The relative frequency column must contain a floating-point - * number between 0 and 1 (inclusive). Null values are assumed to be zero. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId relative_frequency = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $relative_frequency = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\BigQueryTable $table - * Required. Auxiliary table location. - * @type array<\Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\AuxiliaryTable\QuasiIdField>|\Google\Protobuf\Internal\RepeatedField $quasi_ids - * Required. Quasi-identifier columns. - * @type \Google\Cloud\Dlp\V2\FieldId $relative_frequency - * Required. The relative frequency column must contain a floating-point - * number between 0 and 1 (inclusive). Null values are assumed to be zero. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Auxiliary table location. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\BigQueryTable|null - */ - public function getTable() - { - return $this->table; - } - - public function hasTable() - { - return isset($this->table); - } - - public function clearTable() - { - unset($this->table); - } - - /** - * Required. Auxiliary table location. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\BigQueryTable $var - * @return $this - */ - public function setTable($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); - $this->table = $var; - - return $this; - } - - /** - * Required. Quasi-identifier columns. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable.QuasiIdField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQuasiIds() - { - return $this->quasi_ids; - } - - /** - * Required. Quasi-identifier columns. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable.QuasiIdField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\AuxiliaryTable\QuasiIdField>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQuasiIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig\AuxiliaryTable\QuasiIdField::class); - $this->quasi_ids = $arr; - - return $this; - } - - /** - * Required. The relative frequency column must contain a floating-point - * number between 0 and 1 (inclusive). Null values are assumed to be zero. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId relative_frequency = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getRelativeFrequency() - { - return $this->relative_frequency; - } - - public function hasRelativeFrequency() - { - return isset($this->relative_frequency); - } - - public function clearRelativeFrequency() - { - unset($this->relative_frequency); - } - - /** - * Required. The relative frequency column must contain a floating-point - * number between 0 and 1 (inclusive). Null values are assumed to be zero. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId relative_frequency = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setRelativeFrequency($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->relative_frequency = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AuxiliaryTable::class, \Google\Cloud\Dlp\V2\PrivacyMetric_KMapEstimationConfig_AuxiliaryTable::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable/QuasiIdField.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable/QuasiIdField.php deleted file mode 100644 index b82e7afcb51f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/AuxiliaryTable/QuasiIdField.php +++ /dev/null @@ -1,115 +0,0 @@ -google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.AuxiliaryTable.QuasiIdField - */ -class QuasiIdField extends \Google\Protobuf\Internal\Message -{ - /** - * Identifies the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - */ - protected $field = null; - /** - * A auxiliary field. - * - * Generated from protobuf field string custom_tag = 2; - */ - protected $custom_tag = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\FieldId $field - * Identifies the column. - * @type string $custom_tag - * A auxiliary field. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Identifies the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getField() - { - return $this->field; - } - - public function hasField() - { - return isset($this->field); - } - - public function clearField() - { - unset($this->field); - } - - /** - * Identifies the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setField($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->field = $var; - - return $this; - } - - /** - * A auxiliary field. - * - * Generated from protobuf field string custom_tag = 2; - * @return string - */ - public function getCustomTag() - { - return $this->custom_tag; - } - - /** - * A auxiliary field. - * - * Generated from protobuf field string custom_tag = 2; - * @param string $var - * @return $this - */ - public function setCustomTag($var) - { - GPBUtil::checkString($var, True); - $this->custom_tag = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(QuasiIdField::class, \Google\Cloud\Dlp\V2\PrivacyMetric_KMapEstimationConfig_AuxiliaryTable_QuasiIdField::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/TaggedField.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/TaggedField.php deleted file mode 100644 index 8de01c61e6ae..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/KMapEstimationConfig/TaggedField.php +++ /dev/null @@ -1,209 +0,0 @@ -google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig.TaggedField - */ -class TaggedField extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Identifies the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $field = null; - protected $tag; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\FieldId $field - * Required. Identifies the column. - * @type \Google\Cloud\Dlp\V2\InfoType $info_type - * A column can be tagged with a InfoType to use the relevant public - * dataset as a statistical model of population, if available. We - * currently support US ZIP codes, region codes, ages and genders. - * To programmatically obtain the list of supported InfoTypes, use - * ListInfoTypes with the supported_by=RISK_ANALYSIS filter. - * @type string $custom_tag - * A column can be tagged with a custom tag. In this case, the user must - * indicate an auxiliary table that contains statistical information on - * the possible values of this column (below). - * @type \Google\Protobuf\GPBEmpty $inferred - * If no semantic tag is indicated, we infer the statistical model from - * the distribution of values in the input data - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Identifies the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getField() - { - return $this->field; - } - - public function hasField() - { - return isset($this->field); - } - - public function clearField() - { - unset($this->field); - } - - /** - * Required. Identifies the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setField($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->field = $var; - - return $this; - } - - /** - * A column can be tagged with a InfoType to use the relevant public - * dataset as a statistical model of population, if available. We - * currently support US ZIP codes, region codes, ages and genders. - * To programmatically obtain the list of supported InfoTypes, use - * ListInfoTypes with the supported_by=RISK_ANALYSIS filter. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getInfoType() - { - return $this->readOneof(2); - } - - public function hasInfoType() - { - return $this->hasOneof(2); - } - - /** - * A column can be tagged with a InfoType to use the relevant public - * dataset as a statistical model of population, if available. We - * currently support US ZIP codes, region codes, ages and genders. - * To programmatically obtain the list of supported InfoTypes, use - * ListInfoTypes with the supported_by=RISK_ANALYSIS filter. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * A column can be tagged with a custom tag. In this case, the user must - * indicate an auxiliary table that contains statistical information on - * the possible values of this column (below). - * - * Generated from protobuf field string custom_tag = 3; - * @return string - */ - public function getCustomTag() - { - return $this->readOneof(3); - } - - public function hasCustomTag() - { - return $this->hasOneof(3); - } - - /** - * A column can be tagged with a custom tag. In this case, the user must - * indicate an auxiliary table that contains statistical information on - * the possible values of this column (below). - * - * Generated from protobuf field string custom_tag = 3; - * @param string $var - * @return $this - */ - public function setCustomTag($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * If no semantic tag is indicated, we infer the statistical model from - * the distribution of values in the input data - * - * Generated from protobuf field .google.protobuf.Empty inferred = 4; - * @return \Google\Protobuf\GPBEmpty|null - */ - public function getInferred() - { - return $this->readOneof(4); - } - - public function hasInferred() - { - return $this->hasOneof(4); - } - - /** - * If no semantic tag is indicated, we infer the statistical model from - * the distribution of values in the input data - * - * Generated from protobuf field .google.protobuf.Empty inferred = 4; - * @param \Google\Protobuf\GPBEmpty $var - * @return $this - */ - public function setInferred($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\GPBEmpty::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getTag() - { - return $this->whichOneof("tag"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(TaggedField::class, \Google\Cloud\Dlp\V2\PrivacyMetric_KMapEstimationConfig_TaggedField::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/LDiversityConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/LDiversityConfig.php deleted file mode 100644 index f75061de054d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/LDiversityConfig.php +++ /dev/null @@ -1,122 +0,0 @@ -google.privacy.dlp.v2.PrivacyMetric.LDiversityConfig - */ -class LDiversityConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Set of quasi-identifiers indicating how equivalence classes are - * defined for the l-diversity computation. When multiple fields are - * specified, they are considered a single composite key. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId quasi_ids = 1; - */ - private $quasi_ids; - /** - * Sensitive field for computing the l-value. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId sensitive_attribute = 2; - */ - protected $sensitive_attribute = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $quasi_ids - * Set of quasi-identifiers indicating how equivalence classes are - * defined for the l-diversity computation. When multiple fields are - * specified, they are considered a single composite key. - * @type \Google\Cloud\Dlp\V2\FieldId $sensitive_attribute - * Sensitive field for computing the l-value. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Set of quasi-identifiers indicating how equivalence classes are - * defined for the l-diversity computation. When multiple fields are - * specified, they are considered a single composite key. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId quasi_ids = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQuasiIds() - { - return $this->quasi_ids; - } - - /** - * Set of quasi-identifiers indicating how equivalence classes are - * defined for the l-diversity computation. When multiple fields are - * specified, they are considered a single composite key. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId quasi_ids = 1; - * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQuasiIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); - $this->quasi_ids = $arr; - - return $this; - } - - /** - * Sensitive field for computing the l-value. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId sensitive_attribute = 2; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getSensitiveAttribute() - { - return $this->sensitive_attribute; - } - - public function hasSensitiveAttribute() - { - return isset($this->sensitive_attribute); - } - - public function clearSensitiveAttribute() - { - unset($this->sensitive_attribute); - } - - /** - * Sensitive field for computing the l-value. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId sensitive_attribute = 2; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setSensitiveAttribute($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->sensitive_attribute = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LDiversityConfig::class, \Google\Cloud\Dlp\V2\PrivacyMetric_LDiversityConfig::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/NumericalStatsConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/NumericalStatsConfig.php deleted file mode 100644 index 95efdae391d6..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/PrivacyMetric/NumericalStatsConfig.php +++ /dev/null @@ -1,85 +0,0 @@ -google.privacy.dlp.v2.PrivacyMetric.NumericalStatsConfig - */ -class NumericalStatsConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Field to compute numerical stats on. Supported types are - * integer, float, date, datetime, timestamp, time. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - */ - protected $field = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\FieldId $field - * Field to compute numerical stats on. Supported types are - * integer, float, date, datetime, timestamp, time. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Field to compute numerical stats on. Supported types are - * integer, float, date, datetime, timestamp, time. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getField() - { - return $this->field; - } - - public function hasField() - { - return isset($this->field); - } - - public function clearField() - { - unset($this->field); - } - - /** - * Field to compute numerical stats on. Supported types are - * integer, float, date, datetime, timestamp, time. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setField($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->field = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(NumericalStatsConfig::class, \Google\Cloud\Dlp\V2\PrivacyMetric_NumericalStatsConfig::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProfileStatus.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProfileStatus.php deleted file mode 100644 index efc705b0d043..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProfileStatus.php +++ /dev/null @@ -1,125 +0,0 @@ -google.privacy.dlp.v2.ProfileStatus - */ -class ProfileStatus extends \Google\Protobuf\Internal\Message -{ - /** - * Profiling status code and optional message. The `status.code` value is 0 - * (default value) for OK. - * - * Generated from protobuf field .google.rpc.Status status = 1; - */ - protected $status = null; - /** - * Time when the profile generation status was updated - * - * Generated from protobuf field .google.protobuf.Timestamp timestamp = 3; - */ - protected $timestamp = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Rpc\Status $status - * Profiling status code and optional message. The `status.code` value is 0 - * (default value) for OK. - * @type \Google\Protobuf\Timestamp $timestamp - * Time when the profile generation status was updated - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Profiling status code and optional message. The `status.code` value is 0 - * (default value) for OK. - * - * Generated from protobuf field .google.rpc.Status status = 1; - * @return \Google\Rpc\Status|null - */ - public function getStatus() - { - return $this->status; - } - - public function hasStatus() - { - return isset($this->status); - } - - public function clearStatus() - { - unset($this->status); - } - - /** - * Profiling status code and optional message. The `status.code` value is 0 - * (default value) for OK. - * - * Generated from protobuf field .google.rpc.Status status = 1; - * @param \Google\Rpc\Status $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkMessage($var, \Google\Rpc\Status::class); - $this->status = $var; - - return $this; - } - - /** - * Time when the profile generation status was updated - * - * Generated from protobuf field .google.protobuf.Timestamp timestamp = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getTimestamp() - { - return $this->timestamp; - } - - public function hasTimestamp() - { - return isset($this->timestamp); - } - - public function clearTimestamp() - { - unset($this->timestamp); - } - - /** - * Time when the profile generation status was updated - * - * Generated from protobuf field .google.protobuf.Timestamp timestamp = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setTimestamp($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->timestamp = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProjectDataProfile.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProjectDataProfile.php deleted file mode 100644 index 9af8b6c77824..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ProjectDataProfile.php +++ /dev/null @@ -1,278 +0,0 @@ -google.privacy.dlp.v2.ProjectDataProfile - */ -class ProjectDataProfile extends \Google\Protobuf\Internal\Message -{ - /** - * The resource name of the profile. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Project ID that was profiled. - * - * Generated from protobuf field string project_id = 2; - */ - protected $project_id = ''; - /** - * The last time the profile was generated. - * - * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 3; - */ - protected $profile_last_generated = null; - /** - * The sensitivity score of this project. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 4; - */ - protected $sensitivity_score = null; - /** - * The data risk level of this project. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 5; - */ - protected $data_risk_level = null; - /** - * Success or error status of the last attempt to profile the project. - * - * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 7; - */ - protected $profile_status = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The resource name of the profile. - * @type string $project_id - * Project ID that was profiled. - * @type \Google\Protobuf\Timestamp $profile_last_generated - * The last time the profile was generated. - * @type \Google\Cloud\Dlp\V2\SensitivityScore $sensitivity_score - * The sensitivity score of this project. - * @type \Google\Cloud\Dlp\V2\DataRiskLevel $data_risk_level - * The data risk level of this project. - * @type \Google\Cloud\Dlp\V2\ProfileStatus $profile_status - * Success or error status of the last attempt to profile the project. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The resource name of the profile. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The resource name of the profile. - * - * 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; - } - - /** - * Project ID that was profiled. - * - * Generated from protobuf field string project_id = 2; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Project ID that was profiled. - * - * 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; - } - - /** - * The last time the profile was generated. - * - * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getProfileLastGenerated() - { - return $this->profile_last_generated; - } - - public function hasProfileLastGenerated() - { - return isset($this->profile_last_generated); - } - - public function clearProfileLastGenerated() - { - unset($this->profile_last_generated); - } - - /** - * The last time the profile was generated. - * - * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setProfileLastGenerated($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->profile_last_generated = $var; - - return $this; - } - - /** - * The sensitivity score of this project. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 4; - * @return \Google\Cloud\Dlp\V2\SensitivityScore|null - */ - public function getSensitivityScore() - { - return $this->sensitivity_score; - } - - public function hasSensitivityScore() - { - return isset($this->sensitivity_score); - } - - public function clearSensitivityScore() - { - unset($this->sensitivity_score); - } - - /** - * The sensitivity score of this project. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 4; - * @param \Google\Cloud\Dlp\V2\SensitivityScore $var - * @return $this - */ - public function setSensitivityScore($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SensitivityScore::class); - $this->sensitivity_score = $var; - - return $this; - } - - /** - * The data risk level of this project. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 5; - * @return \Google\Cloud\Dlp\V2\DataRiskLevel|null - */ - public function getDataRiskLevel() - { - return $this->data_risk_level; - } - - public function hasDataRiskLevel() - { - return isset($this->data_risk_level); - } - - public function clearDataRiskLevel() - { - unset($this->data_risk_level); - } - - /** - * The data risk level of this project. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 5; - * @param \Google\Cloud\Dlp\V2\DataRiskLevel $var - * @return $this - */ - public function setDataRiskLevel($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataRiskLevel::class); - $this->data_risk_level = $var; - - return $this; - } - - /** - * Success or error status of the last attempt to profile the project. - * - * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 7; - * @return \Google\Cloud\Dlp\V2\ProfileStatus|null - */ - public function getProfileStatus() - { - return $this->profile_status; - } - - public function hasProfileStatus() - { - return isset($this->profile_status); - } - - public function clearProfileStatus() - { - unset($this->profile_status); - } - - /** - * Success or error status of the last attempt to profile the project. - * - * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 7; - * @param \Google\Cloud\Dlp\V2\ProfileStatus $var - * @return $this - */ - public function setProfileStatus($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ProfileStatus::class); - $this->profile_status = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuasiId.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuasiId.php deleted file mode 100644 index 032c8e8a2cde..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuasiId.php +++ /dev/null @@ -1,206 +0,0 @@ -google.privacy.dlp.v2.QuasiId - */ -class QuasiId extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Identifies the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $field = null; - protected $tag; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\FieldId $field - * Required. Identifies the column. - * @type \Google\Cloud\Dlp\V2\InfoType $info_type - * A column can be tagged with a InfoType to use the relevant public - * dataset as a statistical model of population, if available. We - * currently support US ZIP codes, region codes, ages and genders. - * To programmatically obtain the list of supported InfoTypes, use - * ListInfoTypes with the supported_by=RISK_ANALYSIS filter. - * @type string $custom_tag - * A column can be tagged with a custom tag. In this case, the user must - * indicate an auxiliary table that contains statistical information on - * the possible values of this column (below). - * @type \Google\Protobuf\GPBEmpty $inferred - * If no semantic tag is indicated, we infer the statistical model from - * the distribution of values in the input data - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Identifies the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getField() - { - return $this->field; - } - - public function hasField() - { - return isset($this->field); - } - - public function clearField() - { - unset($this->field); - } - - /** - * Required. Identifies the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setField($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->field = $var; - - return $this; - } - - /** - * A column can be tagged with a InfoType to use the relevant public - * dataset as a statistical model of population, if available. We - * currently support US ZIP codes, region codes, ages and genders. - * To programmatically obtain the list of supported InfoTypes, use - * ListInfoTypes with the supported_by=RISK_ANALYSIS filter. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getInfoType() - { - return $this->readOneof(2); - } - - public function hasInfoType() - { - return $this->hasOneof(2); - } - - /** - * A column can be tagged with a InfoType to use the relevant public - * dataset as a statistical model of population, if available. We - * currently support US ZIP codes, region codes, ages and genders. - * To programmatically obtain the list of supported InfoTypes, use - * ListInfoTypes with the supported_by=RISK_ANALYSIS filter. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 2; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * A column can be tagged with a custom tag. In this case, the user must - * indicate an auxiliary table that contains statistical information on - * the possible values of this column (below). - * - * Generated from protobuf field string custom_tag = 3; - * @return string - */ - public function getCustomTag() - { - return $this->readOneof(3); - } - - public function hasCustomTag() - { - return $this->hasOneof(3); - } - - /** - * A column can be tagged with a custom tag. In this case, the user must - * indicate an auxiliary table that contains statistical information on - * the possible values of this column (below). - * - * Generated from protobuf field string custom_tag = 3; - * @param string $var - * @return $this - */ - public function setCustomTag($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * If no semantic tag is indicated, we infer the statistical model from - * the distribution of values in the input data - * - * Generated from protobuf field .google.protobuf.Empty inferred = 4; - * @return \Google\Protobuf\GPBEmpty|null - */ - public function getInferred() - { - return $this->readOneof(4); - } - - public function hasInferred() - { - return $this->hasOneof(4); - } - - /** - * If no semantic tag is indicated, we infer the statistical model from - * the distribution of values in the input data - * - * Generated from protobuf field .google.protobuf.Empty inferred = 4; - * @param \Google\Protobuf\GPBEmpty $var - * @return $this - */ - public function setInferred($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\GPBEmpty::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getTag() - { - return $this->whichOneof("tag"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuoteInfo.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuoteInfo.php deleted file mode 100644 index f33288a3dbcc..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/QuoteInfo.php +++ /dev/null @@ -1,75 +0,0 @@ -google.privacy.dlp.v2.QuoteInfo - */ -class QuoteInfo extends \Google\Protobuf\Internal\Message -{ - protected $parsed_quote; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DateTime $date_time - * The date time indicated by the quote. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The date time indicated by the quote. - * - * Generated from protobuf field .google.privacy.dlp.v2.DateTime date_time = 2; - * @return \Google\Cloud\Dlp\V2\DateTime|null - */ - public function getDateTime() - { - return $this->readOneof(2); - } - - public function hasDateTime() - { - return $this->hasOneof(2); - } - - /** - * The date time indicated by the quote. - * - * Generated from protobuf field .google.privacy.dlp.v2.DateTime date_time = 2; - * @param \Google\Cloud\Dlp\V2\DateTime $var - * @return $this - */ - public function setDateTime($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DateTime::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getParsedQuote() - { - return $this->whichOneof("parsed_quote"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Range.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Range.php deleted file mode 100644 index c7f695bcb24f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Range.php +++ /dev/null @@ -1,101 +0,0 @@ -google.privacy.dlp.v2.Range - */ -class Range extends \Google\Protobuf\Internal\Message -{ - /** - * Index of the first character of the range (inclusive). - * - * Generated from protobuf field int64 start = 1; - */ - protected $start = 0; - /** - * Index of the last character of the range (exclusive). - * - * Generated from protobuf field int64 end = 2; - */ - protected $end = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $start - * Index of the first character of the range (inclusive). - * @type int|string $end - * Index of the last character of the range (exclusive). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Index of the first character of the range (inclusive). - * - * Generated from protobuf field int64 start = 1; - * @return int|string - */ - public function getStart() - { - return $this->start; - } - - /** - * Index of the first character of the range (inclusive). - * - * Generated from protobuf field int64 start = 1; - * @param int|string $var - * @return $this - */ - public function setStart($var) - { - GPBUtil::checkInt64($var); - $this->start = $var; - - return $this; - } - - /** - * Index of the last character of the range (exclusive). - * - * Generated from protobuf field int64 end = 2; - * @return int|string - */ - public function getEnd() - { - return $this->end; - } - - /** - * Index of the last character of the range (exclusive). - * - * Generated from protobuf field int64 end = 2; - * @param int|string $var - * @return $this - */ - public function setEnd($var) - { - GPBUtil::checkInt64($var); - $this->end = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition.php deleted file mode 100644 index 8d4ffb088b55..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition.php +++ /dev/null @@ -1,78 +0,0 @@ -google.privacy.dlp.v2.RecordCondition - */ -class RecordCondition extends \Google\Protobuf\Internal\Message -{ - /** - * An expression. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Expressions expressions = 3; - */ - protected $expressions = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\RecordCondition\Expressions $expressions - * An expression. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * An expression. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Expressions expressions = 3; - * @return \Google\Cloud\Dlp\V2\RecordCondition\Expressions|null - */ - public function getExpressions() - { - return $this->expressions; - } - - public function hasExpressions() - { - return isset($this->expressions); - } - - public function clearExpressions() - { - unset($this->expressions); - } - - /** - * An expression. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Expressions expressions = 3; - * @param \Google\Cloud\Dlp\V2\RecordCondition\Expressions $var - * @return $this - */ - public function setExpressions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordCondition\Expressions::class); - $this->expressions = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Condition.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Condition.php deleted file mode 100644 index b1f05c356b4e..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Condition.php +++ /dev/null @@ -1,174 +0,0 @@ -google.privacy.dlp.v2.RecordCondition.Condition - */ -class Condition extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field within the record this condition is evaluated against. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $field = null; - /** - * Required. Operator used to compare the field or infoType to the value. - * - * Generated from protobuf field .google.privacy.dlp.v2.RelationalOperator operator = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $operator = 0; - /** - * Value to compare against. [Mandatory, except for `EXISTS` tests.] - * - * Generated from protobuf field .google.privacy.dlp.v2.Value value = 4; - */ - protected $value = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\FieldId $field - * Required. Field within the record this condition is evaluated against. - * @type int $operator - * Required. Operator used to compare the field or infoType to the value. - * @type \Google\Cloud\Dlp\V2\Value $value - * Value to compare against. [Mandatory, except for `EXISTS` tests.] - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field within the record this condition is evaluated against. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getField() - { - return $this->field; - } - - public function hasField() - { - return isset($this->field); - } - - public function clearField() - { - unset($this->field); - } - - /** - * Required. Field within the record this condition is evaluated against. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setField($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->field = $var; - - return $this; - } - - /** - * Required. Operator used to compare the field or infoType to the value. - * - * Generated from protobuf field .google.privacy.dlp.v2.RelationalOperator operator = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getOperator() - { - return $this->operator; - } - - /** - * Required. Operator used to compare the field or infoType to the value. - * - * Generated from protobuf field .google.privacy.dlp.v2.RelationalOperator operator = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setOperator($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\RelationalOperator::class); - $this->operator = $var; - - return $this; - } - - /** - * Value to compare against. [Mandatory, except for `EXISTS` tests.] - * - * Generated from protobuf field .google.privacy.dlp.v2.Value value = 4; - * @return \Google\Cloud\Dlp\V2\Value|null - */ - public function getValue() - { - return $this->value; - } - - public function hasValue() - { - return isset($this->value); - } - - public function clearValue() - { - unset($this->value); - } - - /** - * Value to compare against. [Mandatory, except for `EXISTS` tests.] - * - * Generated from protobuf field .google.privacy.dlp.v2.Value value = 4; - * @param \Google\Cloud\Dlp\V2\Value $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); - $this->value = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Condition::class, \Google\Cloud\Dlp\V2\RecordCondition_Condition::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Conditions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Conditions.php deleted file mode 100644 index 29e0ab591806..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Conditions.php +++ /dev/null @@ -1,70 +0,0 @@ -google.privacy.dlp.v2.RecordCondition.Conditions - */ -class Conditions extends \Google\Protobuf\Internal\Message -{ - /** - * A collection of conditions. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.RecordCondition.Condition conditions = 1; - */ - private $conditions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\RecordCondition\Condition>|\Google\Protobuf\Internal\RepeatedField $conditions - * A collection of conditions. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A collection of conditions. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.RecordCondition.Condition conditions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getConditions() - { - return $this->conditions; - } - - /** - * A collection of conditions. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.RecordCondition.Condition conditions = 1; - * @param array<\Google\Cloud\Dlp\V2\RecordCondition\Condition>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setConditions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\RecordCondition\Condition::class); - $this->conditions = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Conditions::class, \Google\Cloud\Dlp\V2\RecordCondition_Conditions::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions.php deleted file mode 100644 index eccccbd1959e..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions.php +++ /dev/null @@ -1,116 +0,0 @@ -google.privacy.dlp.v2.RecordCondition.Expressions - */ -class Expressions extends \Google\Protobuf\Internal\Message -{ - /** - * The operator to apply to the result of conditions. Default and currently - * only supported value is `AND`. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Expressions.LogicalOperator logical_operator = 1; - */ - protected $logical_operator = 0; - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $logical_operator - * The operator to apply to the result of conditions. Default and currently - * only supported value is `AND`. - * @type \Google\Cloud\Dlp\V2\RecordCondition\Conditions $conditions - * Conditions to apply to the expression. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The operator to apply to the result of conditions. Default and currently - * only supported value is `AND`. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Expressions.LogicalOperator logical_operator = 1; - * @return int - */ - public function getLogicalOperator() - { - return $this->logical_operator; - } - - /** - * The operator to apply to the result of conditions. Default and currently - * only supported value is `AND`. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Expressions.LogicalOperator logical_operator = 1; - * @param int $var - * @return $this - */ - public function setLogicalOperator($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\RecordCondition\Expressions\LogicalOperator::class); - $this->logical_operator = $var; - - return $this; - } - - /** - * Conditions to apply to the expression. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Conditions conditions = 3; - * @return \Google\Cloud\Dlp\V2\RecordCondition\Conditions|null - */ - public function getConditions() - { - return $this->readOneof(3); - } - - public function hasConditions() - { - return $this->hasOneof(3); - } - - /** - * Conditions to apply to the expression. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition.Conditions conditions = 3; - * @param \Google\Cloud\Dlp\V2\RecordCondition\Conditions $var - * @return $this - */ - public function setConditions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordCondition\Conditions::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Expressions::class, \Google\Cloud\Dlp\V2\RecordCondition_Expressions::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions/LogicalOperator.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions/LogicalOperator.php deleted file mode 100644 index aeb6e0286883..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordCondition/Expressions/LogicalOperator.php +++ /dev/null @@ -1,61 +0,0 @@ -google.privacy.dlp.v2.RecordCondition.Expressions.LogicalOperator - */ -class LogicalOperator -{ - /** - * Unused - * - * Generated from protobuf enum LOGICAL_OPERATOR_UNSPECIFIED = 0; - */ - const LOGICAL_OPERATOR_UNSPECIFIED = 0; - /** - * Conditional AND - * - * Generated from protobuf enum AND = 1; - */ - const PBAND = 1; - - private static $valueToName = [ - self::LOGICAL_OPERATOR_UNSPECIFIED => 'LOGICAL_OPERATOR_UNSPECIFIED', - self::PBAND => 'AND', - ]; - - 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)) { - $pbconst = __CLASS__. '::PB' . strtoupper($name); - if (!defined($pbconst)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($pbconst); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LogicalOperator::class, \Google\Cloud\Dlp\V2\RecordCondition_Expressions_LogicalOperator::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordKey.php deleted file mode 100644 index 12d649962d53..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordKey.php +++ /dev/null @@ -1,146 +0,0 @@ -google.privacy.dlp.v2.RecordKey - */ -class RecordKey extends \Google\Protobuf\Internal\Message -{ - /** - * Values of identifying columns in the given row. Order of values matches - * the order of `identifying_fields` specified in the scanning request. - * - * Generated from protobuf field repeated string id_values = 5; - */ - private $id_values; - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DatastoreKey $datastore_key - * BigQuery key - * @type \Google\Cloud\Dlp\V2\BigQueryKey $big_query_key - * Datastore key - * @type array|\Google\Protobuf\Internal\RepeatedField $id_values - * Values of identifying columns in the given row. Order of values matches - * the order of `identifying_fields` specified in the scanning request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * BigQuery key - * - * Generated from protobuf field .google.privacy.dlp.v2.DatastoreKey datastore_key = 2; - * @return \Google\Cloud\Dlp\V2\DatastoreKey|null - */ - public function getDatastoreKey() - { - return $this->readOneof(2); - } - - public function hasDatastoreKey() - { - return $this->hasOneof(2); - } - - /** - * BigQuery key - * - * Generated from protobuf field .google.privacy.dlp.v2.DatastoreKey datastore_key = 2; - * @param \Google\Cloud\Dlp\V2\DatastoreKey $var - * @return $this - */ - public function setDatastoreKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DatastoreKey::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Datastore key - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryKey big_query_key = 3; - * @return \Google\Cloud\Dlp\V2\BigQueryKey|null - */ - public function getBigQueryKey() - { - return $this->readOneof(3); - } - - public function hasBigQueryKey() - { - return $this->hasOneof(3); - } - - /** - * Datastore key - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryKey big_query_key = 3; - * @param \Google\Cloud\Dlp\V2\BigQueryKey $var - * @return $this - */ - public function setBigQueryKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryKey::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Values of identifying columns in the given row. Order of values matches - * the order of `identifying_fields` specified in the scanning request. - * - * Generated from protobuf field repeated string id_values = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIdValues() - { - return $this->id_values; - } - - /** - * Values of identifying columns in the given row. Order of values matches - * the order of `identifying_fields` specified in the scanning request. - * - * Generated from protobuf field repeated string id_values = 5; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIdValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->id_values = $arr; - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordLocation.php deleted file mode 100644 index 08d3831c17e8..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordLocation.php +++ /dev/null @@ -1,165 +0,0 @@ -google.privacy.dlp.v2.RecordLocation - */ -class RecordLocation extends \Google\Protobuf\Internal\Message -{ - /** - * Key of the finding. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordKey record_key = 1; - */ - protected $record_key = null; - /** - * Field id of the field containing the finding. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field_id = 2; - */ - protected $field_id = null; - /** - * Location within a `ContentItem.Table`. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableLocation table_location = 3; - */ - protected $table_location = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\RecordKey $record_key - * Key of the finding. - * @type \Google\Cloud\Dlp\V2\FieldId $field_id - * Field id of the field containing the finding. - * @type \Google\Cloud\Dlp\V2\TableLocation $table_location - * Location within a `ContentItem.Table`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Key of the finding. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordKey record_key = 1; - * @return \Google\Cloud\Dlp\V2\RecordKey|null - */ - public function getRecordKey() - { - return $this->record_key; - } - - public function hasRecordKey() - { - return isset($this->record_key); - } - - public function clearRecordKey() - { - unset($this->record_key); - } - - /** - * Key of the finding. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordKey record_key = 1; - * @param \Google\Cloud\Dlp\V2\RecordKey $var - * @return $this - */ - public function setRecordKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordKey::class); - $this->record_key = $var; - - return $this; - } - - /** - * Field id of the field containing the finding. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field_id = 2; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getFieldId() - { - return $this->field_id; - } - - public function hasFieldId() - { - return isset($this->field_id); - } - - public function clearFieldId() - { - unset($this->field_id); - } - - /** - * Field id of the field containing the finding. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field_id = 2; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setFieldId($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->field_id = $var; - - return $this; - } - - /** - * Location within a `ContentItem.Table`. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableLocation table_location = 3; - * @return \Google\Cloud\Dlp\V2\TableLocation|null - */ - public function getTableLocation() - { - return $this->table_location; - } - - public function hasTableLocation() - { - return isset($this->table_location); - } - - public function clearTableLocation() - { - unset($this->table_location); - } - - /** - * Location within a `ContentItem.Table`. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableLocation table_location = 3; - * @param \Google\Cloud\Dlp\V2\TableLocation $var - * @return $this - */ - public function setTableLocation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TableLocation::class); - $this->table_location = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordSuppression.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordSuppression.php deleted file mode 100644 index 3a6d09b1bbce..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordSuppression.php +++ /dev/null @@ -1,82 +0,0 @@ -google.privacy.dlp.v2.RecordSuppression - */ -class RecordSuppression extends \Google\Protobuf\Internal\Message -{ - /** - * A condition that when it evaluates to true will result in the record being - * evaluated to be suppressed from the transformed content. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition condition = 1; - */ - protected $condition = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\RecordCondition $condition - * A condition that when it evaluates to true will result in the record being - * evaluated to be suppressed from the transformed content. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A condition that when it evaluates to true will result in the record being - * evaluated to be suppressed from the transformed content. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition condition = 1; - * @return \Google\Cloud\Dlp\V2\RecordCondition|null - */ - public function getCondition() - { - return $this->condition; - } - - public function hasCondition() - { - return isset($this->condition); - } - - public function clearCondition() - { - unset($this->condition); - } - - /** - * A condition that when it evaluates to true will result in the record being - * evaluated to be suppressed from the transformed content. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordCondition condition = 1; - * @param \Google\Cloud\Dlp\V2\RecordCondition $var - * @return $this - */ - public function setCondition($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordCondition::class); - $this->condition = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformation.php deleted file mode 100644 index e802da478496..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformation.php +++ /dev/null @@ -1,155 +0,0 @@ -google.privacy.dlp.v2.RecordTransformation - */ -class RecordTransformation extends \Google\Protobuf\Internal\Message -{ - /** - * For record transformations, provide a field. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field_id = 1; - */ - protected $field_id = null; - /** - * Findings container modification timestamp, if applicable. - * - * Generated from protobuf field .google.protobuf.Timestamp container_timestamp = 2; - */ - protected $container_timestamp = null; - /** - * Container version, if available ("generation" for Cloud Storage). - * - * Generated from protobuf field string container_version = 3; - */ - protected $container_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\FieldId $field_id - * For record transformations, provide a field. - * @type \Google\Protobuf\Timestamp $container_timestamp - * Findings container modification timestamp, if applicable. - * @type string $container_version - * Container version, if available ("generation" for Cloud Storage). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * For record transformations, provide a field. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field_id = 1; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getFieldId() - { - return $this->field_id; - } - - public function hasFieldId() - { - return isset($this->field_id); - } - - public function clearFieldId() - { - unset($this->field_id); - } - - /** - * For record transformations, provide a field. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field_id = 1; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setFieldId($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->field_id = $var; - - return $this; - } - - /** - * Findings container modification timestamp, if applicable. - * - * Generated from protobuf field .google.protobuf.Timestamp container_timestamp = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getContainerTimestamp() - { - return $this->container_timestamp; - } - - public function hasContainerTimestamp() - { - return isset($this->container_timestamp); - } - - public function clearContainerTimestamp() - { - unset($this->container_timestamp); - } - - /** - * Findings container modification timestamp, if applicable. - * - * Generated from protobuf field .google.protobuf.Timestamp container_timestamp = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setContainerTimestamp($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->container_timestamp = $var; - - return $this; - } - - /** - * Container version, if available ("generation" for Cloud Storage). - * - * Generated from protobuf field string container_version = 3; - * @return string - */ - public function getContainerVersion() - { - return $this->container_version; - } - - /** - * Container version, if available ("generation" for Cloud Storage). - * - * Generated from protobuf field string container_version = 3; - * @param string $var - * @return $this - */ - public function setContainerVersion($var) - { - GPBUtil::checkString($var, True); - $this->container_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformations.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformations.php deleted file mode 100644 index 33498ce84dd7..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RecordTransformations.php +++ /dev/null @@ -1,106 +0,0 @@ -google.privacy.dlp.v2.RecordTransformations - */ -class RecordTransformations extends \Google\Protobuf\Internal\Message -{ - /** - * Transform the record by applying various field transformations. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldTransformation field_transformations = 1; - */ - private $field_transformations; - /** - * Configuration defining which records get suppressed entirely. Records that - * match any suppression rule are omitted from the output. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.RecordSuppression record_suppressions = 2; - */ - private $record_suppressions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\FieldTransformation>|\Google\Protobuf\Internal\RepeatedField $field_transformations - * Transform the record by applying various field transformations. - * @type array<\Google\Cloud\Dlp\V2\RecordSuppression>|\Google\Protobuf\Internal\RepeatedField $record_suppressions - * Configuration defining which records get suppressed entirely. Records that - * match any suppression rule are omitted from the output. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Transform the record by applying various field transformations. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldTransformation field_transformations = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFieldTransformations() - { - return $this->field_transformations; - } - - /** - * Transform the record by applying various field transformations. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldTransformation field_transformations = 1; - * @param array<\Google\Cloud\Dlp\V2\FieldTransformation>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFieldTransformations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldTransformation::class); - $this->field_transformations = $arr; - - return $this; - } - - /** - * Configuration defining which records get suppressed entirely. Records that - * match any suppression rule are omitted from the output. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.RecordSuppression record_suppressions = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRecordSuppressions() - { - return $this->record_suppressions; - } - - /** - * Configuration defining which records get suppressed entirely. Records that - * match any suppression rule are omitted from the output. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.RecordSuppression record_suppressions = 2; - * @param array<\Google\Cloud\Dlp\V2\RecordSuppression>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRecordSuppressions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\RecordSuppression::class); - $this->record_suppressions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactConfig.php deleted file mode 100644 index 79729a849f20..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactConfig.php +++ /dev/null @@ -1,35 +0,0 @@ -google.privacy.dlp.v2.RedactConfig - */ -class RedactConfig extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest.php deleted file mode 100644 index 1175ce0477ac..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest.php +++ /dev/null @@ -1,306 +0,0 @@ -google.privacy.dlp.v2.RedactImageRequest - */ -class RedactImageRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 8; - */ - protected $location_id = ''; - /** - * Configuration for the inspector. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; - */ - protected $inspect_config = null; - /** - * The configuration for specifying what content to redact from images. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5; - */ - private $image_redaction_configs; - /** - * Whether the response should include findings along with the redacted - * image. - * - * Generated from protobuf field bool include_findings = 6; - */ - protected $include_findings = false; - /** - * The content must be PNG, JPEG, SVG or BMP. - * - * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem byte_item = 7; - */ - protected $byte_item = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type string $location_id - * Deprecated. This field has no effect. - * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config - * Configuration for the inspector. - * @type array<\Google\Cloud\Dlp\V2\RedactImageRequest\ImageRedactionConfig>|\Google\Protobuf\Internal\RepeatedField $image_redaction_configs - * The configuration for specifying what content to redact from images. - * @type bool $include_findings - * Whether the response should include findings along with the redacted - * image. - * @type \Google\Cloud\Dlp\V2\ByteContentItem $byte_item - * The content must be PNG, JPEG, SVG or BMP. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 8; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 8; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - - /** - * Configuration for the inspector. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; - * @return \Google\Cloud\Dlp\V2\InspectConfig|null - */ - public function getInspectConfig() - { - return $this->inspect_config; - } - - public function hasInspectConfig() - { - return isset($this->inspect_config); - } - - public function clearInspectConfig() - { - unset($this->inspect_config); - } - - /** - * Configuration for the inspector. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 2; - * @param \Google\Cloud\Dlp\V2\InspectConfig $var - * @return $this - */ - public function setInspectConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); - $this->inspect_config = $var; - - return $this; - } - - /** - * The configuration for specifying what content to redact from images. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getImageRedactionConfigs() - { - return $this->image_redaction_configs; - } - - /** - * The configuration for specifying what content to redact from images. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5; - * @param array<\Google\Cloud\Dlp\V2\RedactImageRequest\ImageRedactionConfig>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setImageRedactionConfigs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\RedactImageRequest\ImageRedactionConfig::class); - $this->image_redaction_configs = $arr; - - return $this; - } - - /** - * Whether the response should include findings along with the redacted - * image. - * - * Generated from protobuf field bool include_findings = 6; - * @return bool - */ - public function getIncludeFindings() - { - return $this->include_findings; - } - - /** - * Whether the response should include findings along with the redacted - * image. - * - * Generated from protobuf field bool include_findings = 6; - * @param bool $var - * @return $this - */ - public function setIncludeFindings($var) - { - GPBUtil::checkBool($var); - $this->include_findings = $var; - - return $this; - } - - /** - * The content must be PNG, JPEG, SVG or BMP. - * - * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem byte_item = 7; - * @return \Google\Cloud\Dlp\V2\ByteContentItem|null - */ - public function getByteItem() - { - return $this->byte_item; - } - - public function hasByteItem() - { - return isset($this->byte_item); - } - - public function clearByteItem() - { - unset($this->byte_item); - } - - /** - * The content must be PNG, JPEG, SVG or BMP. - * - * Generated from protobuf field .google.privacy.dlp.v2.ByteContentItem byte_item = 7; - * @param \Google\Cloud\Dlp\V2\ByteContentItem $var - * @return $this - */ - public function setByteItem($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ByteContentItem::class); - $this->byte_item = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest/ImageRedactionConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest/ImageRedactionConfig.php deleted file mode 100644 index d5ba6d7c75f3..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageRequest/ImageRedactionConfig.php +++ /dev/null @@ -1,171 +0,0 @@ -google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig - */ -class ImageRedactionConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The color to use when redacting content from an image. If not specified, - * the default is black. - * - * Generated from protobuf field .google.privacy.dlp.v2.Color redaction_color = 3; - */ - protected $redaction_color = null; - protected $target; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InfoType $info_type - * Only one per info_type should be provided per request. If not - * specified, and redact_all_text is false, the DLP API will redact all - * text that it matches against all info_types that are found, but not - * specified in another ImageRedactionConfig. - * @type bool $redact_all_text - * If true, all text found in the image, regardless whether it matches an - * info_type, is redacted. Only one should be provided. - * @type \Google\Cloud\Dlp\V2\Color $redaction_color - * The color to use when redacting content from an image. If not specified, - * the default is black. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Only one per info_type should be provided per request. If not - * specified, and redact_all_text is false, the DLP API will redact all - * text that it matches against all info_types that are found, but not - * specified in another ImageRedactionConfig. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getInfoType() - { - return $this->readOneof(1); - } - - public function hasInfoType() - { - return $this->hasOneof(1); - } - - /** - * Only one per info_type should be provided per request. If not - * specified, and redact_all_text is false, the DLP API will redact all - * text that it matches against all info_types that are found, but not - * specified in another ImageRedactionConfig. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * If true, all text found in the image, regardless whether it matches an - * info_type, is redacted. Only one should be provided. - * - * Generated from protobuf field bool redact_all_text = 2; - * @return bool - */ - public function getRedactAllText() - { - return $this->readOneof(2); - } - - public function hasRedactAllText() - { - return $this->hasOneof(2); - } - - /** - * If true, all text found in the image, regardless whether it matches an - * info_type, is redacted. Only one should be provided. - * - * Generated from protobuf field bool redact_all_text = 2; - * @param bool $var - * @return $this - */ - public function setRedactAllText($var) - { - GPBUtil::checkBool($var); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The color to use when redacting content from an image. If not specified, - * the default is black. - * - * Generated from protobuf field .google.privacy.dlp.v2.Color redaction_color = 3; - * @return \Google\Cloud\Dlp\V2\Color|null - */ - public function getRedactionColor() - { - return $this->redaction_color; - } - - public function hasRedactionColor() - { - return isset($this->redaction_color); - } - - public function clearRedactionColor() - { - unset($this->redaction_color); - } - - /** - * The color to use when redacting content from an image. If not specified, - * the default is black. - * - * Generated from protobuf field .google.privacy.dlp.v2.Color redaction_color = 3; - * @param \Google\Cloud\Dlp\V2\Color $var - * @return $this - */ - public function setRedactionColor($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Color::class); - $this->redaction_color = $var; - - return $this; - } - - /** - * @return string - */ - public function getTarget() - { - return $this->whichOneof("target"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ImageRedactionConfig::class, \Google\Cloud\Dlp\V2\RedactImageRequest_ImageRedactionConfig::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageResponse.php deleted file mode 100644 index 2f749551986a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RedactImageResponse.php +++ /dev/null @@ -1,153 +0,0 @@ -google.privacy.dlp.v2.RedactImageResponse - */ -class RedactImageResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The redacted image. The type will be the same as the original image. - * - * Generated from protobuf field bytes redacted_image = 1; - */ - protected $redacted_image = ''; - /** - * If an image was being inspected and the InspectConfig's include_quote was - * set to true, then this field will include all text, if any, that was found - * in the image. - * - * Generated from protobuf field string extracted_text = 2; - */ - protected $extracted_text = ''; - /** - * The findings. Populated when include_findings in the request is true. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectResult inspect_result = 3; - */ - protected $inspect_result = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $redacted_image - * The redacted image. The type will be the same as the original image. - * @type string $extracted_text - * If an image was being inspected and the InspectConfig's include_quote was - * set to true, then this field will include all text, if any, that was found - * in the image. - * @type \Google\Cloud\Dlp\V2\InspectResult $inspect_result - * The findings. Populated when include_findings in the request is true. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The redacted image. The type will be the same as the original image. - * - * Generated from protobuf field bytes redacted_image = 1; - * @return string - */ - public function getRedactedImage() - { - return $this->redacted_image; - } - - /** - * The redacted image. The type will be the same as the original image. - * - * Generated from protobuf field bytes redacted_image = 1; - * @param string $var - * @return $this - */ - public function setRedactedImage($var) - { - GPBUtil::checkString($var, False); - $this->redacted_image = $var; - - return $this; - } - - /** - * If an image was being inspected and the InspectConfig's include_quote was - * set to true, then this field will include all text, if any, that was found - * in the image. - * - * Generated from protobuf field string extracted_text = 2; - * @return string - */ - public function getExtractedText() - { - return $this->extracted_text; - } - - /** - * If an image was being inspected and the InspectConfig's include_quote was - * set to true, then this field will include all text, if any, that was found - * in the image. - * - * Generated from protobuf field string extracted_text = 2; - * @param string $var - * @return $this - */ - public function setExtractedText($var) - { - GPBUtil::checkString($var, True); - $this->extracted_text = $var; - - return $this; - } - - /** - * The findings. Populated when include_findings in the request is true. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectResult inspect_result = 3; - * @return \Google\Cloud\Dlp\V2\InspectResult|null - */ - public function getInspectResult() - { - return $this->inspect_result; - } - - public function hasInspectResult() - { - return isset($this->inspect_result); - } - - public function clearInspectResult() - { - unset($this->inspect_result); - } - - /** - * The findings. Populated when include_findings in the request is true. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectResult inspect_result = 3; - * @param \Google\Cloud\Dlp\V2\InspectResult $var - * @return $this - */ - public function setInspectResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectResult::class); - $this->inspect_result = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentRequest.php deleted file mode 100644 index f87523fc482e..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentRequest.php +++ /dev/null @@ -1,417 +0,0 @@ -google.privacy.dlp.v2.ReidentifyContentRequest - */ -class ReidentifyContentRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Configuration for the re-identification of the content item. - * This field shares the same proto message type that is used for - * de-identification, however its usage here is for the reversal of the - * previous de-identification. Re-identification is performed by examining - * the transformations used to de-identify the items and executing the - * reverse. This requires that only reversible transformations - * be provided here. The reversible transformations are: - * - `CryptoDeterministicConfig` - * - `CryptoReplaceFfxFpeConfig` - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig reidentify_config = 2; - */ - protected $reidentify_config = null; - /** - * Configuration for the inspector. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 3; - */ - protected $inspect_config = null; - /** - * The item to re-identify. Will be treated as text. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 4; - */ - protected $item = null; - /** - * Template to use. Any configuration directly specified in - * `inspect_config` will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * - * Generated from protobuf field string inspect_template_name = 5; - */ - protected $inspect_template_name = ''; - /** - * Template to use. References an instance of `DeidentifyTemplate`. - * Any configuration directly specified in `reidentify_config` or - * `inspect_config` will override those set in the template. The - * `DeidentifyTemplate` used must include only reversible transformations. - * Singular fields that are set in this request will replace their - * corresponding fields in the template. Repeated fields are appended. - * Singular sub-messages and groups are recursively merged. - * - * Generated from protobuf field string reidentify_template_name = 6; - */ - protected $reidentify_template_name = ''; - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 7; - */ - protected $location_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * @type \Google\Cloud\Dlp\V2\DeidentifyConfig $reidentify_config - * Configuration for the re-identification of the content item. - * This field shares the same proto message type that is used for - * de-identification, however its usage here is for the reversal of the - * previous de-identification. Re-identification is performed by examining - * the transformations used to de-identify the items and executing the - * reverse. This requires that only reversible transformations - * be provided here. The reversible transformations are: - * - `CryptoDeterministicConfig` - * - `CryptoReplaceFfxFpeConfig` - * @type \Google\Cloud\Dlp\V2\InspectConfig $inspect_config - * Configuration for the inspector. - * @type \Google\Cloud\Dlp\V2\ContentItem $item - * The item to re-identify. Will be treated as text. - * @type string $inspect_template_name - * Template to use. Any configuration directly specified in - * `inspect_config` will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * @type string $reidentify_template_name - * Template to use. References an instance of `DeidentifyTemplate`. - * Any configuration directly specified in `reidentify_config` or - * `inspect_config` will override those set in the template. The - * `DeidentifyTemplate` used must include only reversible transformations. - * Singular fields that are set in this request will replace their - * corresponding fields in the template. Repeated fields are appended. - * Singular sub-messages and groups are recursively merged. - * @type string $location_id - * Deprecated. This field has no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource name. - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * parent=projects/example-project/locations/europe-west3 - * - * 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; - } - - /** - * Configuration for the re-identification of the content item. - * This field shares the same proto message type that is used for - * de-identification, however its usage here is for the reversal of the - * previous de-identification. Re-identification is performed by examining - * the transformations used to de-identify the items and executing the - * reverse. This requires that only reversible transformations - * be provided here. The reversible transformations are: - * - `CryptoDeterministicConfig` - * - `CryptoReplaceFfxFpeConfig` - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig reidentify_config = 2; - * @return \Google\Cloud\Dlp\V2\DeidentifyConfig|null - */ - public function getReidentifyConfig() - { - return $this->reidentify_config; - } - - public function hasReidentifyConfig() - { - return isset($this->reidentify_config); - } - - public function clearReidentifyConfig() - { - unset($this->reidentify_config); - } - - /** - * Configuration for the re-identification of the content item. - * This field shares the same proto message type that is used for - * de-identification, however its usage here is for the reversal of the - * previous de-identification. Re-identification is performed by examining - * the transformations used to de-identify the items and executing the - * reverse. This requires that only reversible transformations - * be provided here. The reversible transformations are: - * - `CryptoDeterministicConfig` - * - `CryptoReplaceFfxFpeConfig` - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyConfig reidentify_config = 2; - * @param \Google\Cloud\Dlp\V2\DeidentifyConfig $var - * @return $this - */ - public function setReidentifyConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyConfig::class); - $this->reidentify_config = $var; - - return $this; - } - - /** - * Configuration for the inspector. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 3; - * @return \Google\Cloud\Dlp\V2\InspectConfig|null - */ - public function getInspectConfig() - { - return $this->inspect_config; - } - - public function hasInspectConfig() - { - return isset($this->inspect_config); - } - - public function clearInspectConfig() - { - unset($this->inspect_config); - } - - /** - * Configuration for the inspector. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectConfig inspect_config = 3; - * @param \Google\Cloud\Dlp\V2\InspectConfig $var - * @return $this - */ - public function setInspectConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectConfig::class); - $this->inspect_config = $var; - - return $this; - } - - /** - * The item to re-identify. Will be treated as text. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 4; - * @return \Google\Cloud\Dlp\V2\ContentItem|null - */ - public function getItem() - { - return $this->item; - } - - public function hasItem() - { - return isset($this->item); - } - - public function clearItem() - { - unset($this->item); - } - - /** - * The item to re-identify. Will be treated as text. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 4; - * @param \Google\Cloud\Dlp\V2\ContentItem $var - * @return $this - */ - public function setItem($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ContentItem::class); - $this->item = $var; - - return $this; - } - - /** - * Template to use. Any configuration directly specified in - * `inspect_config` will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * - * Generated from protobuf field string inspect_template_name = 5; - * @return string - */ - public function getInspectTemplateName() - { - return $this->inspect_template_name; - } - - /** - * Template to use. Any configuration directly specified in - * `inspect_config` will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * - * Generated from protobuf field string inspect_template_name = 5; - * @param string $var - * @return $this - */ - public function setInspectTemplateName($var) - { - GPBUtil::checkString($var, True); - $this->inspect_template_name = $var; - - return $this; - } - - /** - * Template to use. References an instance of `DeidentifyTemplate`. - * Any configuration directly specified in `reidentify_config` or - * `inspect_config` will override those set in the template. The - * `DeidentifyTemplate` used must include only reversible transformations. - * Singular fields that are set in this request will replace their - * corresponding fields in the template. Repeated fields are appended. - * Singular sub-messages and groups are recursively merged. - * - * Generated from protobuf field string reidentify_template_name = 6; - * @return string - */ - public function getReidentifyTemplateName() - { - return $this->reidentify_template_name; - } - - /** - * Template to use. References an instance of `DeidentifyTemplate`. - * Any configuration directly specified in `reidentify_config` or - * `inspect_config` will override those set in the template. The - * `DeidentifyTemplate` used must include only reversible transformations. - * Singular fields that are set in this request will replace their - * corresponding fields in the template. Repeated fields are appended. - * Singular sub-messages and groups are recursively merged. - * - * Generated from protobuf field string reidentify_template_name = 6; - * @param string $var - * @return $this - */ - public function setReidentifyTemplateName($var) - { - GPBUtil::checkString($var, True); - $this->reidentify_template_name = $var; - - return $this; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 7; - * @return string - */ - public function getLocationId() - { - return $this->location_id; - } - - /** - * Deprecated. This field has no effect. - * - * Generated from protobuf field string location_id = 7; - * @param string $var - * @return $this - */ - public function setLocationId($var) - { - GPBUtil::checkString($var, True); - $this->location_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentResponse.php deleted file mode 100644 index 645c5eb06117..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReidentifyContentResponse.php +++ /dev/null @@ -1,121 +0,0 @@ -google.privacy.dlp.v2.ReidentifyContentResponse - */ -class ReidentifyContentResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The re-identified item. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; - */ - protected $item = null; - /** - * An overview of the changes that were made to the `item`. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationOverview overview = 2; - */ - protected $overview = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\ContentItem $item - * The re-identified item. - * @type \Google\Cloud\Dlp\V2\TransformationOverview $overview - * An overview of the changes that were made to the `item`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The re-identified item. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; - * @return \Google\Cloud\Dlp\V2\ContentItem|null - */ - public function getItem() - { - return $this->item; - } - - public function hasItem() - { - return isset($this->item); - } - - public function clearItem() - { - unset($this->item); - } - - /** - * The re-identified item. - * - * Generated from protobuf field .google.privacy.dlp.v2.ContentItem item = 1; - * @param \Google\Cloud\Dlp\V2\ContentItem $var - * @return $this - */ - public function setItem($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ContentItem::class); - $this->item = $var; - - return $this; - } - - /** - * An overview of the changes that were made to the `item`. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationOverview overview = 2; - * @return \Google\Cloud\Dlp\V2\TransformationOverview|null - */ - public function getOverview() - { - return $this->overview; - } - - public function hasOverview() - { - return isset($this->overview); - } - - public function clearOverview() - { - unset($this->overview); - } - - /** - * An overview of the changes that were made to the `item`. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationOverview overview = 2; - * @param \Google\Cloud\Dlp\V2\TransformationOverview $var - * @return $this - */ - public function setOverview($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationOverview::class); - $this->overview = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RelationalOperator.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RelationalOperator.php deleted file mode 100644 index 6ed71c1ce458..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RelationalOperator.php +++ /dev/null @@ -1,96 +0,0 @@ -google.privacy.dlp.v2.RelationalOperator - */ -class RelationalOperator -{ - /** - * Unused - * - * Generated from protobuf enum RELATIONAL_OPERATOR_UNSPECIFIED = 0; - */ - const RELATIONAL_OPERATOR_UNSPECIFIED = 0; - /** - * Equal. Attempts to match even with incompatible types. - * - * Generated from protobuf enum EQUAL_TO = 1; - */ - const EQUAL_TO = 1; - /** - * Not equal to. Attempts to match even with incompatible types. - * - * Generated from protobuf enum NOT_EQUAL_TO = 2; - */ - const NOT_EQUAL_TO = 2; - /** - * Greater than. - * - * Generated from protobuf enum GREATER_THAN = 3; - */ - const GREATER_THAN = 3; - /** - * Less than. - * - * Generated from protobuf enum LESS_THAN = 4; - */ - const LESS_THAN = 4; - /** - * Greater than or equals. - * - * Generated from protobuf enum GREATER_THAN_OR_EQUALS = 5; - */ - const GREATER_THAN_OR_EQUALS = 5; - /** - * Less than or equals. - * - * Generated from protobuf enum LESS_THAN_OR_EQUALS = 6; - */ - const LESS_THAN_OR_EQUALS = 6; - /** - * Exists - * - * Generated from protobuf enum EXISTS = 7; - */ - const EXISTS = 7; - - private static $valueToName = [ - self::RELATIONAL_OPERATOR_UNSPECIFIED => 'RELATIONAL_OPERATOR_UNSPECIFIED', - self::EQUAL_TO => 'EQUAL_TO', - self::NOT_EQUAL_TO => 'NOT_EQUAL_TO', - self::GREATER_THAN => 'GREATER_THAN', - self::LESS_THAN => 'LESS_THAN', - self::GREATER_THAN_OR_EQUALS => 'GREATER_THAN_OR_EQUALS', - self::LESS_THAN_OR_EQUALS => 'LESS_THAN_OR_EQUALS', - self::EXISTS => 'EXISTS', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceDictionaryConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceDictionaryConfig.php deleted file mode 100644 index 334777891ff9..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceDictionaryConfig.php +++ /dev/null @@ -1,81 +0,0 @@ -google.privacy.dlp.v2.ReplaceDictionaryConfig - */ -class ReplaceDictionaryConfig extends \Google\Protobuf\Internal\Message -{ - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList $word_list - * A list of words to select from for random replacement. The - * [limits](https://cloud.google.com/sensitive-data-protection/limits) page - * contains details about the size limits of dictionaries. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A list of words to select from for random replacement. The - * [limits](https://cloud.google.com/sensitive-data-protection/limits) page - * contains details about the size limits of dictionaries. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary.WordList word_list = 1; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList|null - */ - public function getWordList() - { - return $this->readOneof(1); - } - - public function hasWordList() - { - return $this->hasOneof(1); - } - - /** - * A list of words to select from for random replacement. The - * [limits](https://cloud.google.com/sensitive-data-protection/limits) page - * contains details about the size limits of dictionaries. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary.WordList word_list = 1; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList $var - * @return $this - */ - public function setWordList($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary\WordList::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceValueConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceValueConfig.php deleted file mode 100644 index 6b6b0f7a06d1..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceValueConfig.php +++ /dev/null @@ -1,77 +0,0 @@ -google.privacy.dlp.v2.ReplaceValueConfig - */ -class ReplaceValueConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Value to replace it with. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value new_value = 1; - */ - protected $new_value = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\Value $new_value - * Value to replace it with. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Value to replace it with. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value new_value = 1; - * @return \Google\Cloud\Dlp\V2\Value|null - */ - public function getNewValue() - { - return $this->new_value; - } - - public function hasNewValue() - { - return isset($this->new_value); - } - - public function clearNewValue() - { - unset($this->new_value); - } - - /** - * Value to replace it with. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value new_value = 1; - * @param \Google\Cloud\Dlp\V2\Value $var - * @return $this - */ - public function setNewValue($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); - $this->new_value = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceWithInfoTypeConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceWithInfoTypeConfig.php deleted file mode 100644 index 5896285166fe..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ReplaceWithInfoTypeConfig.php +++ /dev/null @@ -1,33 +0,0 @@ -google.privacy.dlp.v2.ReplaceWithInfoTypeConfig - */ -class ReplaceWithInfoTypeConfig extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ResourceVisibility.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ResourceVisibility.php deleted file mode 100644 index 091e4e5299f2..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ResourceVisibility.php +++ /dev/null @@ -1,71 +0,0 @@ -google.privacy.dlp.v2.ResourceVisibility - */ -class ResourceVisibility -{ - /** - * Unused. - * - * Generated from protobuf enum RESOURCE_VISIBILITY_UNSPECIFIED = 0; - */ - const RESOURCE_VISIBILITY_UNSPECIFIED = 0; - /** - * Visible to any user. - * - * Generated from protobuf enum RESOURCE_VISIBILITY_PUBLIC = 10; - */ - const RESOURCE_VISIBILITY_PUBLIC = 10; - /** - * May contain public items. - * For example, if a Cloud Storage bucket has uniform bucket level access - * disabled, some objects inside it may be public. - * - * Generated from protobuf enum RESOURCE_VISIBILITY_INCONCLUSIVE = 15; - */ - const RESOURCE_VISIBILITY_INCONCLUSIVE = 15; - /** - * Visible only to specific users. - * - * Generated from protobuf enum RESOURCE_VISIBILITY_RESTRICTED = 20; - */ - const RESOURCE_VISIBILITY_RESTRICTED = 20; - - private static $valueToName = [ - self::RESOURCE_VISIBILITY_UNSPECIFIED => 'RESOURCE_VISIBILITY_UNSPECIFIED', - self::RESOURCE_VISIBILITY_PUBLIC => 'RESOURCE_VISIBILITY_PUBLIC', - self::RESOURCE_VISIBILITY_INCONCLUSIVE => 'RESOURCE_VISIBILITY_INCONCLUSIVE', - self::RESOURCE_VISIBILITY_RESTRICTED => 'RESOURCE_VISIBILITY_RESTRICTED', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RiskAnalysisJobConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RiskAnalysisJobConfig.php deleted file mode 100644 index d188958519c0..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/RiskAnalysisJobConfig.php +++ /dev/null @@ -1,161 +0,0 @@ -google.privacy.dlp.v2.RiskAnalysisJobConfig - */ -class RiskAnalysisJobConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Privacy metric to compute. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric privacy_metric = 1; - */ - protected $privacy_metric = null; - /** - * Input dataset to compute metrics over. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable source_table = 2; - */ - protected $source_table = null; - /** - * Actions to execute at the completion of the job. Are executed in the order - * provided. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Action actions = 3; - */ - private $actions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\PrivacyMetric $privacy_metric - * Privacy metric to compute. - * @type \Google\Cloud\Dlp\V2\BigQueryTable $source_table - * Input dataset to compute metrics over. - * @type array<\Google\Cloud\Dlp\V2\Action>|\Google\Protobuf\Internal\RepeatedField $actions - * Actions to execute at the completion of the job. Are executed in the order - * provided. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Privacy metric to compute. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric privacy_metric = 1; - * @return \Google\Cloud\Dlp\V2\PrivacyMetric|null - */ - public function getPrivacyMetric() - { - return $this->privacy_metric; - } - - public function hasPrivacyMetric() - { - return isset($this->privacy_metric); - } - - public function clearPrivacyMetric() - { - unset($this->privacy_metric); - } - - /** - * Privacy metric to compute. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrivacyMetric privacy_metric = 1; - * @param \Google\Cloud\Dlp\V2\PrivacyMetric $var - * @return $this - */ - public function setPrivacyMetric($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric::class); - $this->privacy_metric = $var; - - return $this; - } - - /** - * Input dataset to compute metrics over. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable source_table = 2; - * @return \Google\Cloud\Dlp\V2\BigQueryTable|null - */ - public function getSourceTable() - { - return $this->source_table; - } - - public function hasSourceTable() - { - return isset($this->source_table); - } - - public function clearSourceTable() - { - unset($this->source_table); - } - - /** - * Input dataset to compute metrics over. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable source_table = 2; - * @param \Google\Cloud\Dlp\V2\BigQueryTable $var - * @return $this - */ - public function setSourceTable($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); - $this->source_table = $var; - - return $this; - } - - /** - * Actions to execute at the completion of the job. Are executed in the order - * provided. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Action actions = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getActions() - { - return $this->actions; - } - - /** - * Actions to execute at the completion of the job. Are executed in the order - * provided. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Action actions = 3; - * @param array<\Google\Cloud\Dlp\V2\Action>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setActions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Action::class); - $this->actions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Schedule.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Schedule.php deleted file mode 100644 index f7fe89d24dac..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Schedule.php +++ /dev/null @@ -1,90 +0,0 @@ -google.privacy.dlp.v2.Schedule - */ -class Schedule extends \Google\Protobuf\Internal\Message -{ - protected $option; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Duration $recurrence_period_duration - * With this option a job is started on a regular periodic basis. For - * example: every day (86400 seconds). - * A scheduled start time will be skipped if the previous - * execution has not ended when its scheduled time occurs. - * This value must be set to a time duration greater than or equal - * to 1 day and can be no longer than 60 days. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * With this option a job is started on a regular periodic basis. For - * example: every day (86400 seconds). - * A scheduled start time will be skipped if the previous - * execution has not ended when its scheduled time occurs. - * This value must be set to a time duration greater than or equal - * to 1 day and can be no longer than 60 days. - * - * Generated from protobuf field .google.protobuf.Duration recurrence_period_duration = 1; - * @return \Google\Protobuf\Duration|null - */ - public function getRecurrencePeriodDuration() - { - return $this->readOneof(1); - } - - public function hasRecurrencePeriodDuration() - { - return $this->hasOneof(1); - } - - /** - * With this option a job is started on a regular periodic basis. For - * example: every day (86400 seconds). - * A scheduled start time will be skipped if the previous - * execution has not ended when its scheduled time occurs. - * This value must be set to a time duration greater than or equal - * to 1 day and can be no longer than 60 days. - * - * Generated from protobuf field .google.protobuf.Duration recurrence_period_duration = 1; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setRecurrencePeriodDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getOption() - { - return $this->whichOneof("option"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsRequest.php deleted file mode 100644 index e7293ed166f1..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsRequest.php +++ /dev/null @@ -1,192 +0,0 @@ -google.privacy.dlp.v2.SearchConnectionsRequest - */ -class SearchConnectionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent name, typically an organization, without location. - * For example: `organizations/12345678`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. Number of results per page, max 1000. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. Page token from a previous page to return the next set of - * results. If set, all other request fields must match the original request. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - - /** - * @param string $parent Required. Parent name, typically an organization, without location. - * For example: `organizations/12345678`. Please see - * {@see DlpServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\SearchConnectionsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent name, typically an organization, without location. - * For example: `organizations/12345678`. - * @type int $page_size - * Optional. Number of results per page, max 1000. - * @type string $page_token - * Optional. Page token from a previous page to return the next set of - * results. If set, all other request fields must match the original request. - * @type string $filter - * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent name, typically an organization, without location. - * For example: `organizations/12345678`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent name, typically an organization, without location. - * For example: `organizations/12345678`. - * - * 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; - } - - /** - * Optional. Number of results per page, max 1000. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. Number of results per page, max 1000. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. Page token from a previous page to return the next set of - * results. If set, all other request fields must match the original request. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. Page token from a previous page to return the next set of - * results. If set, all other request fields must match the original request. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsResponse.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsResponse.php deleted file mode 100644 index 291026d1abed..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SearchConnectionsResponse.php +++ /dev/null @@ -1,113 +0,0 @@ -google.privacy.dlp.v2.SearchConnectionsResponse - */ -class SearchConnectionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of connections that match the search query. Note that only a subset - * of the fields will be populated, and only "name" is guaranteed to be set. - * For full details of a Connection, call GetConnection with the name. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Connection connections = 1; - */ - private $connections; - /** - * Token to retrieve the next page of results. An empty value means there are - * 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<\Google\Cloud\Dlp\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $connections - * List of connections that match the search query. Note that only a subset - * of the fields will be populated, and only "name" is guaranteed to be set. - * For full details of a Connection, call GetConnection with the name. - * @type string $next_page_token - * Token to retrieve the next page of results. An empty value means there are - * no more results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * List of connections that match the search query. Note that only a subset - * of the fields will be populated, and only "name" is guaranteed to be set. - * For full details of a Connection, call GetConnection with the name. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Connection connections = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getConnections() - { - return $this->connections; - } - - /** - * List of connections that match the search query. Note that only a subset - * of the fields will be populated, and only "name" is guaranteed to be set. - * For full details of a Connection, call GetConnection with the name. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Connection connections = 1; - * @param array<\Google\Cloud\Dlp\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setConnections($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Connection::class); - $this->connections = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results. An empty value means there are - * no more results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results. An empty value means there are - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretManagerCredential.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretManagerCredential.php deleted file mode 100644 index 280526b8b2ab..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SecretManagerCredential.php +++ /dev/null @@ -1,108 +0,0 @@ -google.privacy.dlp.v2.SecretManagerCredential - */ -class SecretManagerCredential extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The username. - * - * Generated from protobuf field string username = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $username = ''; - /** - * Required. The name of the Secret Manager resource that stores the password, - * in the form `projects/project-id/secrets/secret-name/versions/version`. - * - * Generated from protobuf field string password_secret_version_name = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $password_secret_version_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $username - * Required. The username. - * @type string $password_secret_version_name - * Required. The name of the Secret Manager resource that stores the password, - * in the form `projects/project-id/secrets/secret-name/versions/version`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. The username. - * - * Generated from protobuf field string username = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getUsername() - { - return $this->username; - } - - /** - * Required. The username. - * - * Generated from protobuf field string username = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setUsername($var) - { - GPBUtil::checkString($var, True); - $this->username = $var; - - return $this; - } - - /** - * Required. The name of the Secret Manager resource that stores the password, - * in the form `projects/project-id/secrets/secret-name/versions/version`. - * - * Generated from protobuf field string password_secret_version_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getPasswordSecretVersionName() - { - return $this->password_secret_version_name; - } - - /** - * Required. The name of the Secret Manager resource that stores the password, - * in the form `projects/project-id/secrets/secret-name/versions/version`. - * - * Generated from protobuf field string password_secret_version_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setPasswordSecretVersionName($var) - { - GPBUtil::checkString($var, True); - $this->password_secret_version_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore.php deleted file mode 100644 index 90daf36c4bf9..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore.php +++ /dev/null @@ -1,68 +0,0 @@ -google.privacy.dlp.v2.SensitivityScore - */ -class SensitivityScore extends \Google\Protobuf\Internal\Message -{ - /** - * The sensitivity score applied to the resource. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore.SensitivityScoreLevel score = 1; - */ - protected $score = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $score - * The sensitivity score applied to the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * The sensitivity score applied to the resource. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore.SensitivityScoreLevel score = 1; - * @return int - */ - public function getScore() - { - return $this->score; - } - - /** - * The sensitivity score applied to the resource. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore.SensitivityScoreLevel score = 1; - * @param int $var - * @return $this - */ - public function setScore($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\SensitivityScore\SensitivityScoreLevel::class); - $this->score = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore/SensitivityScoreLevel.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore/SensitivityScoreLevel.php deleted file mode 100644 index dd35a70fb36d..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/SensitivityScore/SensitivityScoreLevel.php +++ /dev/null @@ -1,78 +0,0 @@ -google.privacy.dlp.v2.SensitivityScore.SensitivityScoreLevel - */ -class SensitivityScoreLevel -{ - /** - * Unused. - * - * Generated from protobuf enum SENSITIVITY_SCORE_UNSPECIFIED = 0; - */ - const SENSITIVITY_SCORE_UNSPECIFIED = 0; - /** - * No sensitive information detected. The resource isn't publicly - * accessible. - * - * Generated from protobuf enum SENSITIVITY_LOW = 10; - */ - const SENSITIVITY_LOW = 10; - /** - * Medium risk. Contains personally identifiable information (PII), - * potentially sensitive data, or fields with free-text data that are at a - * higher risk of having intermittent sensitive data. Consider limiting - * access. - * - * Generated from protobuf enum SENSITIVITY_MODERATE = 20; - */ - const SENSITIVITY_MODERATE = 20; - /** - * High risk. Sensitive personally identifiable information (SPII) can be - * present. Exfiltration of data can lead to user data loss. - * Re-identification of users might be possible. Consider limiting usage and - * or removing SPII. - * - * Generated from protobuf enum SENSITIVITY_HIGH = 30; - */ - const SENSITIVITY_HIGH = 30; - - private static $valueToName = [ - self::SENSITIVITY_SCORE_UNSPECIFIED => 'SENSITIVITY_SCORE_UNSPECIFIED', - self::SENSITIVITY_LOW => 'SENSITIVITY_LOW', - self::SENSITIVITY_MODERATE => 'SENSITIVITY_MODERATE', - self::SENSITIVITY_HIGH => 'SENSITIVITY_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(SensitivityScoreLevel::class, \Google\Cloud\Dlp\V2\SensitivityScore_SensitivityScoreLevel::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable.php deleted file mode 100644 index 533649a094e9..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable.php +++ /dev/null @@ -1,165 +0,0 @@ -google.privacy.dlp.v2.StatisticalTable - */ -class StatisticalTable extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Auxiliary table location. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $table = null; - /** - * Required. Quasi-identifier columns. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.StatisticalTable.QuasiIdentifierField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $quasi_ids; - /** - * Required. The relative frequency column must contain a floating-point - * number between 0 and 1 (inclusive). Null values are assumed to be zero. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId relative_frequency = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $relative_frequency = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\BigQueryTable $table - * Required. Auxiliary table location. - * @type array<\Google\Cloud\Dlp\V2\StatisticalTable\QuasiIdentifierField>|\Google\Protobuf\Internal\RepeatedField $quasi_ids - * Required. Quasi-identifier columns. - * @type \Google\Cloud\Dlp\V2\FieldId $relative_frequency - * Required. The relative frequency column must contain a floating-point - * number between 0 and 1 (inclusive). Null values are assumed to be zero. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Auxiliary table location. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\BigQueryTable|null - */ - public function getTable() - { - return $this->table; - } - - public function hasTable() - { - return isset($this->table); - } - - public function clearTable() - { - unset($this->table); - } - - /** - * Required. Auxiliary table location. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\BigQueryTable $var - * @return $this - */ - public function setTable($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); - $this->table = $var; - - return $this; - } - - /** - * Required. Quasi-identifier columns. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.StatisticalTable.QuasiIdentifierField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQuasiIds() - { - return $this->quasi_ids; - } - - /** - * Required. Quasi-identifier columns. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.StatisticalTable.QuasiIdentifierField quasi_ids = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\Dlp\V2\StatisticalTable\QuasiIdentifierField>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQuasiIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\StatisticalTable\QuasiIdentifierField::class); - $this->quasi_ids = $arr; - - return $this; - } - - /** - * Required. The relative frequency column must contain a floating-point - * number between 0 and 1 (inclusive). Null values are assumed to be zero. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId relative_frequency = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getRelativeFrequency() - { - return $this->relative_frequency; - } - - public function hasRelativeFrequency() - { - return isset($this->relative_frequency); - } - - public function clearRelativeFrequency() - { - unset($this->relative_frequency); - } - - /** - * Required. The relative frequency column must contain a floating-point - * number between 0 and 1 (inclusive). Null values are assumed to be zero. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId relative_frequency = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setRelativeFrequency($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->relative_frequency = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable/QuasiIdentifierField.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable/QuasiIdentifierField.php deleted file mode 100644 index eac02a9161ed..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StatisticalTable/QuasiIdentifierField.php +++ /dev/null @@ -1,123 +0,0 @@ -google.privacy.dlp.v2.StatisticalTable.QuasiIdentifierField - */ -class QuasiIdentifierField extends \Google\Protobuf\Internal\Message -{ - /** - * Identifies the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - */ - protected $field = null; - /** - * A column can be tagged with a custom tag. In this case, the user must - * indicate an auxiliary table that contains statistical information on - * the possible values of this column (below). - * - * Generated from protobuf field string custom_tag = 2; - */ - protected $custom_tag = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\FieldId $field - * Identifies the column. - * @type string $custom_tag - * A column can be tagged with a custom tag. In this case, the user must - * indicate an auxiliary table that contains statistical information on - * the possible values of this column (below). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Identifies the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getField() - { - return $this->field; - } - - public function hasField() - { - return isset($this->field); - } - - public function clearField() - { - unset($this->field); - } - - /** - * Identifies the column. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 1; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setField($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->field = $var; - - return $this; - } - - /** - * A column can be tagged with a custom tag. In this case, the user must - * indicate an auxiliary table that contains statistical information on - * the possible values of this column (below). - * - * Generated from protobuf field string custom_tag = 2; - * @return string - */ - public function getCustomTag() - { - return $this->custom_tag; - } - - /** - * A column can be tagged with a custom tag. In this case, the user must - * indicate an auxiliary table that contains statistical information on - * the possible values of this column (below). - * - * Generated from protobuf field string custom_tag = 2; - * @param string $var - * @return $this - */ - public function setCustomTag($var) - { - GPBUtil::checkString($var, True); - $this->custom_tag = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(QuasiIdentifierField::class, \Google\Cloud\Dlp\V2\StatisticalTable_QuasiIdentifierField::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig.php deleted file mode 100644 index 630d3b44dda2..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig.php +++ /dev/null @@ -1,218 +0,0 @@ -google.privacy.dlp.v2.StorageConfig - */ -class StorageConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Configuration of the timespan of the items to include in scanning. - * - * Generated from protobuf field .google.privacy.dlp.v2.StorageConfig.TimespanConfig timespan_config = 6; - */ - protected $timespan_config = null; - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\DatastoreOptions $datastore_options - * Google Cloud Datastore options. - * @type \Google\Cloud\Dlp\V2\CloudStorageOptions $cloud_storage_options - * Cloud Storage options. - * @type \Google\Cloud\Dlp\V2\BigQueryOptions $big_query_options - * BigQuery options. - * @type \Google\Cloud\Dlp\V2\HybridOptions $hybrid_options - * Hybrid inspection options. - * @type \Google\Cloud\Dlp\V2\StorageConfig\TimespanConfig $timespan_config - * Configuration of the timespan of the items to include in scanning. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Google Cloud Datastore options. - * - * Generated from protobuf field .google.privacy.dlp.v2.DatastoreOptions datastore_options = 2; - * @return \Google\Cloud\Dlp\V2\DatastoreOptions|null - */ - public function getDatastoreOptions() - { - return $this->readOneof(2); - } - - public function hasDatastoreOptions() - { - return $this->hasOneof(2); - } - - /** - * Google Cloud Datastore options. - * - * Generated from protobuf field .google.privacy.dlp.v2.DatastoreOptions datastore_options = 2; - * @param \Google\Cloud\Dlp\V2\DatastoreOptions $var - * @return $this - */ - public function setDatastoreOptions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DatastoreOptions::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Cloud Storage options. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions cloud_storage_options = 3; - * @return \Google\Cloud\Dlp\V2\CloudStorageOptions|null - */ - public function getCloudStorageOptions() - { - return $this->readOneof(3); - } - - public function hasCloudStorageOptions() - { - return $this->hasOneof(3); - } - - /** - * Cloud Storage options. - * - * Generated from protobuf field .google.privacy.dlp.v2.CloudStorageOptions cloud_storage_options = 3; - * @param \Google\Cloud\Dlp\V2\CloudStorageOptions $var - * @return $this - */ - public function setCloudStorageOptions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CloudStorageOptions::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * BigQuery options. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryOptions big_query_options = 4; - * @return \Google\Cloud\Dlp\V2\BigQueryOptions|null - */ - public function getBigQueryOptions() - { - return $this->readOneof(4); - } - - public function hasBigQueryOptions() - { - return $this->hasOneof(4); - } - - /** - * BigQuery options. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryOptions big_query_options = 4; - * @param \Google\Cloud\Dlp\V2\BigQueryOptions $var - * @return $this - */ - public function setBigQueryOptions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryOptions::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Hybrid inspection options. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridOptions hybrid_options = 9; - * @return \Google\Cloud\Dlp\V2\HybridOptions|null - */ - public function getHybridOptions() - { - return $this->readOneof(9); - } - - public function hasHybridOptions() - { - return $this->hasOneof(9); - } - - /** - * Hybrid inspection options. - * - * Generated from protobuf field .google.privacy.dlp.v2.HybridOptions hybrid_options = 9; - * @param \Google\Cloud\Dlp\V2\HybridOptions $var - * @return $this - */ - public function setHybridOptions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\HybridOptions::class); - $this->writeOneof(9, $var); - - return $this; - } - - /** - * Configuration of the timespan of the items to include in scanning. - * - * Generated from protobuf field .google.privacy.dlp.v2.StorageConfig.TimespanConfig timespan_config = 6; - * @return \Google\Cloud\Dlp\V2\StorageConfig\TimespanConfig|null - */ - public function getTimespanConfig() - { - return $this->timespan_config; - } - - public function hasTimespanConfig() - { - return isset($this->timespan_config); - } - - public function clearTimespanConfig() - { - unset($this->timespan_config); - } - - /** - * Configuration of the timespan of the items to include in scanning. - * - * Generated from protobuf field .google.privacy.dlp.v2.StorageConfig.TimespanConfig timespan_config = 6; - * @param \Google\Cloud\Dlp\V2\StorageConfig\TimespanConfig $var - * @return $this - */ - public function setTimespanConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StorageConfig\TimespanConfig::class); - $this->timespan_config = $var; - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig/TimespanConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig/TimespanConfig.php deleted file mode 100644 index 102874db60d0..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageConfig/TimespanConfig.php +++ /dev/null @@ -1,367 +0,0 @@ -google.privacy.dlp.v2.StorageConfig.TimespanConfig - */ -class TimespanConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Exclude files, tables, or rows older than this value. - * If not set, no lower time limit is applied. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 1; - */ - protected $start_time = null; - /** - * Exclude files, tables, or rows newer than this value. - * If not set, no upper time limit is applied. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - */ - protected $end_time = null; - /** - * Specification of the field containing the timestamp of scanned items. - * Used for data sources like Datastore and BigQuery. - * For BigQuery - * If this value is not specified and the table was modified between the - * given start and end times, the entire table will be scanned. If this - * value is specified, then rows are filtered based on the given start and - * end times. Rows with a `NULL` value in the provided BigQuery column are - * skipped. - * Valid data types of the provided BigQuery column are: `INTEGER`, `DATE`, - * `TIMESTAMP`, and `DATETIME`. - * If your BigQuery table is [partitioned at ingestion - * time](https://cloud.google.com/bigquery/docs/partitioned-tables#ingestion_time), - * you can use any of the following pseudo-columns as your timestamp field. - * When used with Cloud DLP, these pseudo-column names are case sensitive. - *
    - *
  • _PARTITIONTIME
  • - *
  • _PARTITIONDATE
  • - *
  • _PARTITION_LOAD_TIME
  • - *
- * For Datastore - * If this value is specified, then entities are filtered based on the given - * start and end times. If an entity does not contain the provided timestamp - * property or contains empty or invalid values, then it is included. - * Valid data types of the provided timestamp property are: `TIMESTAMP`. - * See the - * [known - * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-timespan) - * related to this operation. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId timestamp_field = 3; - */ - protected $timestamp_field = null; - /** - * When the job is started by a JobTrigger we will automatically figure out - * a valid start_time to avoid scanning files that have not been modified - * since the last time the JobTrigger executed. This will be based on the - * time of the execution of the last run of the JobTrigger or the timespan - * end_time used in the last run of the JobTrigger. - * **For BigQuery** - * Inspect jobs triggered by automatic population will scan data that is at - * least three hours old when the job starts. This is because streaming - * buffer rows are not read during inspection and reading up to the current - * timestamp will result in skipped rows. - * See the [known - * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#recently-streamed-data) - * related to this operation. - * - * Generated from protobuf field bool enable_auto_population_of_timespan_config = 4; - */ - protected $enable_auto_population_of_timespan_config = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $start_time - * Exclude files, tables, or rows older than this value. - * If not set, no lower time limit is applied. - * @type \Google\Protobuf\Timestamp $end_time - * Exclude files, tables, or rows newer than this value. - * If not set, no upper time limit is applied. - * @type \Google\Cloud\Dlp\V2\FieldId $timestamp_field - * Specification of the field containing the timestamp of scanned items. - * Used for data sources like Datastore and BigQuery. - * For BigQuery - * If this value is not specified and the table was modified between the - * given start and end times, the entire table will be scanned. If this - * value is specified, then rows are filtered based on the given start and - * end times. Rows with a `NULL` value in the provided BigQuery column are - * skipped. - * Valid data types of the provided BigQuery column are: `INTEGER`, `DATE`, - * `TIMESTAMP`, and `DATETIME`. - * If your BigQuery table is [partitioned at ingestion - * time](https://cloud.google.com/bigquery/docs/partitioned-tables#ingestion_time), - * you can use any of the following pseudo-columns as your timestamp field. - * When used with Cloud DLP, these pseudo-column names are case sensitive. - *
    - *
  • _PARTITIONTIME
  • - *
  • _PARTITIONDATE
  • - *
  • _PARTITION_LOAD_TIME
  • - *
- * For Datastore - * If this value is specified, then entities are filtered based on the given - * start and end times. If an entity does not contain the provided timestamp - * property or contains empty or invalid values, then it is included. - * Valid data types of the provided timestamp property are: `TIMESTAMP`. - * See the - * [known - * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-timespan) - * related to this operation. - * @type bool $enable_auto_population_of_timespan_config - * When the job is started by a JobTrigger we will automatically figure out - * a valid start_time to avoid scanning files that have not been modified - * since the last time the JobTrigger executed. This will be based on the - * time of the execution of the last run of the JobTrigger or the timespan - * end_time used in the last run of the JobTrigger. - * **For BigQuery** - * Inspect jobs triggered by automatic population will scan data that is at - * least three hours old when the job starts. This is because streaming - * buffer rows are not read during inspection and reading up to the current - * timestamp will result in skipped rows. - * See the [known - * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#recently-streamed-data) - * related to this operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Exclude files, tables, or rows older than this value. - * If not set, no lower time limit is applied. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 1; - * @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); - } - - /** - * Exclude files, tables, or rows older than this value. - * If not set, no lower time limit is applied. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 1; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - - /** - * Exclude files, tables, or rows newer than this value. - * If not set, no upper time limit is applied. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - * @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); - } - - /** - * Exclude files, tables, or rows newer than this value. - * If not set, no upper time limit is applied. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Specification of the field containing the timestamp of scanned items. - * Used for data sources like Datastore and BigQuery. - * For BigQuery - * If this value is not specified and the table was modified between the - * given start and end times, the entire table will be scanned. If this - * value is specified, then rows are filtered based on the given start and - * end times. Rows with a `NULL` value in the provided BigQuery column are - * skipped. - * Valid data types of the provided BigQuery column are: `INTEGER`, `DATE`, - * `TIMESTAMP`, and `DATETIME`. - * If your BigQuery table is [partitioned at ingestion - * time](https://cloud.google.com/bigquery/docs/partitioned-tables#ingestion_time), - * you can use any of the following pseudo-columns as your timestamp field. - * When used with Cloud DLP, these pseudo-column names are case sensitive. - *
    - *
  • _PARTITIONTIME
  • - *
  • _PARTITIONDATE
  • - *
  • _PARTITION_LOAD_TIME
  • - *
- * For Datastore - * If this value is specified, then entities are filtered based on the given - * start and end times. If an entity does not contain the provided timestamp - * property or contains empty or invalid values, then it is included. - * Valid data types of the provided timestamp property are: `TIMESTAMP`. - * See the - * [known - * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-timespan) - * related to this operation. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId timestamp_field = 3; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getTimestampField() - { - return $this->timestamp_field; - } - - public function hasTimestampField() - { - return isset($this->timestamp_field); - } - - public function clearTimestampField() - { - unset($this->timestamp_field); - } - - /** - * Specification of the field containing the timestamp of scanned items. - * Used for data sources like Datastore and BigQuery. - * For BigQuery - * If this value is not specified and the table was modified between the - * given start and end times, the entire table will be scanned. If this - * value is specified, then rows are filtered based on the given start and - * end times. Rows with a `NULL` value in the provided BigQuery column are - * skipped. - * Valid data types of the provided BigQuery column are: `INTEGER`, `DATE`, - * `TIMESTAMP`, and `DATETIME`. - * If your BigQuery table is [partitioned at ingestion - * time](https://cloud.google.com/bigquery/docs/partitioned-tables#ingestion_time), - * you can use any of the following pseudo-columns as your timestamp field. - * When used with Cloud DLP, these pseudo-column names are case sensitive. - *
    - *
  • _PARTITIONTIME
  • - *
  • _PARTITIONDATE
  • - *
  • _PARTITION_LOAD_TIME
  • - *
- * For Datastore - * If this value is specified, then entities are filtered based on the given - * start and end times. If an entity does not contain the provided timestamp - * property or contains empty or invalid values, then it is included. - * Valid data types of the provided timestamp property are: `TIMESTAMP`. - * See the - * [known - * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-timespan) - * related to this operation. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId timestamp_field = 3; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setTimestampField($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->timestamp_field = $var; - - return $this; - } - - /** - * When the job is started by a JobTrigger we will automatically figure out - * a valid start_time to avoid scanning files that have not been modified - * since the last time the JobTrigger executed. This will be based on the - * time of the execution of the last run of the JobTrigger or the timespan - * end_time used in the last run of the JobTrigger. - * **For BigQuery** - * Inspect jobs triggered by automatic population will scan data that is at - * least three hours old when the job starts. This is because streaming - * buffer rows are not read during inspection and reading up to the current - * timestamp will result in skipped rows. - * See the [known - * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#recently-streamed-data) - * related to this operation. - * - * Generated from protobuf field bool enable_auto_population_of_timespan_config = 4; - * @return bool - */ - public function getEnableAutoPopulationOfTimespanConfig() - { - return $this->enable_auto_population_of_timespan_config; - } - - /** - * When the job is started by a JobTrigger we will automatically figure out - * a valid start_time to avoid scanning files that have not been modified - * since the last time the JobTrigger executed. This will be based on the - * time of the execution of the last run of the JobTrigger or the timespan - * end_time used in the last run of the JobTrigger. - * **For BigQuery** - * Inspect jobs triggered by automatic population will scan data that is at - * least three hours old when the job starts. This is because streaming - * buffer rows are not read during inspection and reading up to the current - * timestamp will result in skipped rows. - * See the [known - * issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#recently-streamed-data) - * related to this operation. - * - * Generated from protobuf field bool enable_auto_population_of_timespan_config = 4; - * @param bool $var - * @return $this - */ - public function setEnableAutoPopulationOfTimespanConfig($var) - { - GPBUtil::checkBool($var); - $this->enable_auto_population_of_timespan_config = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(TimespanConfig::class, \Google\Cloud\Dlp\V2\StorageConfig_TimespanConfig::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageMetadataLabel.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageMetadataLabel.php deleted file mode 100644 index e982b805e95c..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StorageMetadataLabel.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.StorageMetadataLabel - */ -class StorageMetadataLabel extends \Google\Protobuf\Internal\Message -{ - /** - * Label name. - * - * Generated from protobuf field string key = 1; - */ - protected $key = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $key - * Label name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Label name. - * - * Generated from protobuf field string key = 1; - * @return string - */ - public function getKey() - { - return $this->key; - } - - /** - * Label name. - * - * Generated from protobuf field string key = 1; - * @param string $var - * @return $this - */ - public function setKey($var) - { - GPBUtil::checkString($var, True); - $this->key = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoType.php deleted file mode 100644 index 156e6335b473..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoType.php +++ /dev/null @@ -1,150 +0,0 @@ -google.privacy.dlp.v2.StoredInfoType - */ -class StoredInfoType extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Current version of the stored info type. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeVersion current_version = 2; - */ - protected $current_version = null; - /** - * Pending versions of the stored info type. Empty if no versions are - * pending. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.StoredInfoTypeVersion pending_versions = 3; - */ - private $pending_versions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Resource name. - * @type \Google\Cloud\Dlp\V2\StoredInfoTypeVersion $current_version - * Current version of the stored info type. - * @type array<\Google\Cloud\Dlp\V2\StoredInfoTypeVersion>|\Google\Protobuf\Internal\RepeatedField $pending_versions - * Pending versions of the stored info type. Empty if no versions are - * pending. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Resource 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; - } - - /** - * Current version of the stored info type. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeVersion current_version = 2; - * @return \Google\Cloud\Dlp\V2\StoredInfoTypeVersion|null - */ - public function getCurrentVersion() - { - return $this->current_version; - } - - public function hasCurrentVersion() - { - return isset($this->current_version); - } - - public function clearCurrentVersion() - { - unset($this->current_version); - } - - /** - * Current version of the stored info type. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeVersion current_version = 2; - * @param \Google\Cloud\Dlp\V2\StoredInfoTypeVersion $var - * @return $this - */ - public function setCurrentVersion($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StoredInfoTypeVersion::class); - $this->current_version = $var; - - return $this; - } - - /** - * Pending versions of the stored info type. Empty if no versions are - * pending. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.StoredInfoTypeVersion pending_versions = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPendingVersions() - { - return $this->pending_versions; - } - - /** - * Pending versions of the stored info type. Empty if no versions are - * pending. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.StoredInfoTypeVersion pending_versions = 3; - * @param array<\Google\Cloud\Dlp\V2\StoredInfoTypeVersion>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPendingVersions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\StoredInfoTypeVersion::class); - $this->pending_versions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeConfig.php deleted file mode 100644 index ac6a4b96e563..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeConfig.php +++ /dev/null @@ -1,211 +0,0 @@ -google.privacy.dlp.v2.StoredInfoTypeConfig - */ -class StoredInfoTypeConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Display name of the StoredInfoType (max 256 characters). - * - * Generated from protobuf field string display_name = 1; - */ - protected $display_name = ''; - /** - * Description of the StoredInfoType (max 256 characters). - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $display_name - * Display name of the StoredInfoType (max 256 characters). - * @type string $description - * Description of the StoredInfoType (max 256 characters). - * @type \Google\Cloud\Dlp\V2\LargeCustomDictionaryConfig $large_custom_dictionary - * StoredInfoType where findings are defined by a dictionary of phrases. - * @type \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary $dictionary - * Store dictionary-based CustomInfoType. - * @type \Google\Cloud\Dlp\V2\CustomInfoType\Regex $regex - * Store regular expression-based StoredInfoType. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Display name of the StoredInfoType (max 256 characters). - * - * Generated from protobuf field string display_name = 1; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Display name of the StoredInfoType (max 256 characters). - * - * Generated from protobuf field string display_name = 1; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Description of the StoredInfoType (max 256 characters). - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Description of the StoredInfoType (max 256 characters). - * - * 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; - } - - /** - * StoredInfoType where findings are defined by a dictionary of phrases. - * - * Generated from protobuf field .google.privacy.dlp.v2.LargeCustomDictionaryConfig large_custom_dictionary = 3; - * @return \Google\Cloud\Dlp\V2\LargeCustomDictionaryConfig|null - */ - public function getLargeCustomDictionary() - { - return $this->readOneof(3); - } - - public function hasLargeCustomDictionary() - { - return $this->hasOneof(3); - } - - /** - * StoredInfoType where findings are defined by a dictionary of phrases. - * - * Generated from protobuf field .google.privacy.dlp.v2.LargeCustomDictionaryConfig large_custom_dictionary = 3; - * @param \Google\Cloud\Dlp\V2\LargeCustomDictionaryConfig $var - * @return $this - */ - public function setLargeCustomDictionary($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\LargeCustomDictionaryConfig::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Store dictionary-based CustomInfoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary dictionary = 4; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary|null - */ - public function getDictionary() - { - return $this->readOneof(4); - } - - public function hasDictionary() - { - return $this->hasOneof(4); - } - - /** - * Store dictionary-based CustomInfoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Dictionary dictionary = 4; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary $var - * @return $this - */ - public function setDictionary($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Dictionary::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Store regular expression-based StoredInfoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex regex = 5; - * @return \Google\Cloud\Dlp\V2\CustomInfoType\Regex|null - */ - public function getRegex() - { - return $this->readOneof(5); - } - - public function hasRegex() - { - return $this->hasOneof(5); - } - - /** - * Store regular expression-based StoredInfoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.CustomInfoType.Regex regex = 5; - * @param \Google\Cloud\Dlp\V2\CustomInfoType\Regex $var - * @return $this - */ - public function setRegex($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\CustomInfoType\Regex::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeState.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeState.php deleted file mode 100644 index 8b2ebfc111d0..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeState.php +++ /dev/null @@ -1,78 +0,0 @@ -google.privacy.dlp.v2.StoredInfoTypeState - */ -class StoredInfoTypeState -{ - /** - * Unused - * - * Generated from protobuf enum STORED_INFO_TYPE_STATE_UNSPECIFIED = 0; - */ - const STORED_INFO_TYPE_STATE_UNSPECIFIED = 0; - /** - * StoredInfoType version is being created. - * - * Generated from protobuf enum PENDING = 1; - */ - const PENDING = 1; - /** - * StoredInfoType version is ready for use. - * - * Generated from protobuf enum READY = 2; - */ - const READY = 2; - /** - * StoredInfoType creation failed. All relevant error messages are returned in - * the `StoredInfoTypeVersion` message. - * - * Generated from protobuf enum FAILED = 3; - */ - const FAILED = 3; - /** - * StoredInfoType is no longer valid because artifacts stored in - * user-controlled storage were modified. To fix an invalid StoredInfoType, - * use the `UpdateStoredInfoType` method to create a new version. - * - * Generated from protobuf enum INVALID = 4; - */ - const INVALID = 4; - - private static $valueToName = [ - self::STORED_INFO_TYPE_STATE_UNSPECIFIED => 'STORED_INFO_TYPE_STATE_UNSPECIFIED', - self::PENDING => 'PENDING', - self::READY => 'READY', - self::FAILED => 'FAILED', - self::INVALID => 'INVALID', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeStats.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeStats.php deleted file mode 100644 index b6c9b0b25919..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeStats.php +++ /dev/null @@ -1,75 +0,0 @@ -google.privacy.dlp.v2.StoredInfoTypeStats - */ -class StoredInfoTypeStats extends \Google\Protobuf\Internal\Message -{ - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\LargeCustomDictionaryStats $large_custom_dictionary - * StoredInfoType where findings are defined by a dictionary of phrases. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * StoredInfoType where findings are defined by a dictionary of phrases. - * - * Generated from protobuf field .google.privacy.dlp.v2.LargeCustomDictionaryStats large_custom_dictionary = 1; - * @return \Google\Cloud\Dlp\V2\LargeCustomDictionaryStats|null - */ - public function getLargeCustomDictionary() - { - return $this->readOneof(1); - } - - public function hasLargeCustomDictionary() - { - return $this->hasOneof(1); - } - - /** - * StoredInfoType where findings are defined by a dictionary of phrases. - * - * Generated from protobuf field .google.privacy.dlp.v2.LargeCustomDictionaryStats large_custom_dictionary = 1; - * @param \Google\Cloud\Dlp\V2\LargeCustomDictionaryStats $var - * @return $this - */ - public function setLargeCustomDictionary($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\LargeCustomDictionaryStats::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeVersion.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeVersion.php deleted file mode 100644 index a9ad81826cb3..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredInfoTypeVersion.php +++ /dev/null @@ -1,282 +0,0 @@ -google.privacy.dlp.v2.StoredInfoTypeVersion - */ -class StoredInfoTypeVersion extends \Google\Protobuf\Internal\Message -{ - /** - * StoredInfoType configuration. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 1; - */ - protected $config = null; - /** - * Create timestamp of the version. Read-only, determined by the system - * when the version is created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - */ - protected $create_time = null; - /** - * Stored info type version state. Read-only, updated by the system - * during dictionary creation. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeState state = 3; - */ - protected $state = 0; - /** - * Errors that occurred when creating this storedInfoType version, or - * anomalies detected in the storedInfoType data that render it unusable. Only - * the five most recent errors will be displayed, with the most recent error - * appearing first. - * For example, some of the data for stored custom dictionaries is put in - * the user's Cloud Storage bucket, and if this data is modified or - * deleted by the user or another system, the dictionary becomes invalid. - * If any errors occur, fix the problem indicated by the error message and - * use the UpdateStoredInfoType API method to create another version of the - * storedInfoType to continue using it, reusing the same `config` if it was - * not the source of the error. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 4; - */ - private $errors; - /** - * Statistics about this storedInfoType version. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeStats stats = 5; - */ - protected $stats = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config - * StoredInfoType configuration. - * @type \Google\Protobuf\Timestamp $create_time - * Create timestamp of the version. Read-only, determined by the system - * when the version is created. - * @type int $state - * Stored info type version state. Read-only, updated by the system - * during dictionary creation. - * @type array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $errors - * Errors that occurred when creating this storedInfoType version, or - * anomalies detected in the storedInfoType data that render it unusable. Only - * the five most recent errors will be displayed, with the most recent error - * appearing first. - * For example, some of the data for stored custom dictionaries is put in - * the user's Cloud Storage bucket, and if this data is modified or - * deleted by the user or another system, the dictionary becomes invalid. - * If any errors occur, fix the problem indicated by the error message and - * use the UpdateStoredInfoType API method to create another version of the - * storedInfoType to continue using it, reusing the same `config` if it was - * not the source of the error. - * @type \Google\Cloud\Dlp\V2\StoredInfoTypeStats $stats - * Statistics about this storedInfoType version. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * StoredInfoType configuration. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 1; - * @return \Google\Cloud\Dlp\V2\StoredInfoTypeConfig|null - */ - public function getConfig() - { - return $this->config; - } - - public function hasConfig() - { - return isset($this->config); - } - - public function clearConfig() - { - unset($this->config); - } - - /** - * StoredInfoType configuration. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 1; - * @param \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StoredInfoTypeConfig::class); - $this->config = $var; - - return $this; - } - - /** - * Create timestamp of the version. Read-only, determined by the system - * when the version is created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - * @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); - } - - /** - * Create timestamp of the version. Read-only, determined by the system - * when the version is created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Stored info type version state. Read-only, updated by the system - * during dictionary creation. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeState state = 3; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Stored info type version state. Read-only, updated by the system - * during dictionary creation. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeState state = 3; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\StoredInfoTypeState::class); - $this->state = $var; - - return $this; - } - - /** - * Errors that occurred when creating this storedInfoType version, or - * anomalies detected in the storedInfoType data that render it unusable. Only - * the five most recent errors will be displayed, with the most recent error - * appearing first. - * For example, some of the data for stored custom dictionaries is put in - * the user's Cloud Storage bucket, and if this data is modified or - * deleted by the user or another system, the dictionary becomes invalid. - * If any errors occur, fix the problem indicated by the error message and - * use the UpdateStoredInfoType API method to create another version of the - * storedInfoType to continue using it, reusing the same `config` if it was - * not the source of the error. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getErrors() - { - return $this->errors; - } - - /** - * Errors that occurred when creating this storedInfoType version, or - * anomalies detected in the storedInfoType data that render it unusable. Only - * the five most recent errors will be displayed, with the most recent error - * appearing first. - * For example, some of the data for stored custom dictionaries is put in - * the user's Cloud Storage bucket, and if this data is modified or - * deleted by the user or another system, the dictionary becomes invalid. - * If any errors occur, fix the problem indicated by the error message and - * use the UpdateStoredInfoType API method to create another version of the - * storedInfoType to continue using it, reusing the same `config` if it was - * not the source of the error. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Error errors = 4; - * @param array<\Google\Cloud\Dlp\V2\Error>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setErrors($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Error::class); - $this->errors = $arr; - - return $this; - } - - /** - * Statistics about this storedInfoType version. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeStats stats = 5; - * @return \Google\Cloud\Dlp\V2\StoredInfoTypeStats|null - */ - public function getStats() - { - return $this->stats; - } - - public function hasStats() - { - return isset($this->stats); - } - - public function clearStats() - { - unset($this->stats); - } - - /** - * Statistics about this storedInfoType version. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeStats stats = 5; - * @param \Google\Cloud\Dlp\V2\StoredInfoTypeStats $var - * @return $this - */ - public function setStats($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StoredInfoTypeStats::class); - $this->stats = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredType.php deleted file mode 100644 index e240578bf676..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/StoredType.php +++ /dev/null @@ -1,123 +0,0 @@ -google.privacy.dlp.v2.StoredType - */ -class StoredType extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name of the requested `StoredInfoType`, for example - * `organizations/433245324/storedInfoTypes/432452342` or - * `projects/project-id/storedInfoTypes/432452342`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Timestamp indicating when the version of the `StoredInfoType` used for - * inspection was created. Output-only field, populated by the system. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - */ - protected $create_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Resource name of the requested `StoredInfoType`, for example - * `organizations/433245324/storedInfoTypes/432452342` or - * `projects/project-id/storedInfoTypes/432452342`. - * @type \Google\Protobuf\Timestamp $create_time - * Timestamp indicating when the version of the `StoredInfoType` used for - * inspection was created. Output-only field, populated by the system. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * Resource name of the requested `StoredInfoType`, for example - * `organizations/433245324/storedInfoTypes/432452342` or - * `projects/project-id/storedInfoTypes/432452342`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Resource name of the requested `StoredInfoType`, for example - * `organizations/433245324/storedInfoTypes/432452342` or - * `projects/project-id/storedInfoTypes/432452342`. - * - * 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; - } - - /** - * Timestamp indicating when the version of the `StoredInfoType` used for - * inspection was created. Output-only field, populated by the system. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - * @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); - } - - /** - * Timestamp indicating when the version of the `StoredInfoType` used for - * inspection was created. Output-only field, populated by the system. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table.php deleted file mode 100644 index 3fda5434774a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table.php +++ /dev/null @@ -1,103 +0,0 @@ -google.privacy.dlp.v2.Table - */ -class Table extends \Google\Protobuf\Internal\Message -{ - /** - * Headers of the table. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId headers = 1; - */ - private $headers; - /** - * Rows of the table. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Table.Row rows = 2; - */ - private $rows; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $headers - * Headers of the table. - * @type array<\Google\Cloud\Dlp\V2\Table\Row>|\Google\Protobuf\Internal\RepeatedField $rows - * Rows of the table. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Headers of the table. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId headers = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getHeaders() - { - return $this->headers; - } - - /** - * Headers of the table. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId headers = 1; - * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); - $this->headers = $arr; - - return $this; - } - - /** - * Rows of the table. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Table.Row rows = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRows() - { - return $this->rows; - } - - /** - * Rows of the table. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Table.Row rows = 2; - * @param array<\Google\Cloud\Dlp\V2\Table\Row>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRows($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Table\Row::class); - $this->rows = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table/Row.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table/Row.php deleted file mode 100644 index 18ab4403ca50..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Table/Row.php +++ /dev/null @@ -1,70 +0,0 @@ -google.privacy.dlp.v2.Table.Row - */ -class Row extends \Google\Protobuf\Internal\Message -{ - /** - * Individual cells. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value values = 1; - */ - private $values; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $values - * Individual cells. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Individual cells. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value values = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getValues() - { - return $this->values; - } - - /** - * Individual cells. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.Value values = 1; - * @param array<\Google\Cloud\Dlp\V2\Value>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\Value::class); - $this->values = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Row::class, \Google\Cloud\Dlp\V2\Table_Row::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile.php deleted file mode 100644 index d923b7458aba..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile.php +++ /dev/null @@ -1,1027 +0,0 @@ -google.privacy.dlp.v2.TableDataProfile - */ -class TableDataProfile extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the profile. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The resource type that was profiled. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataSourceType data_source_type = 36; - */ - protected $data_source_type = null; - /** - * The resource name to the project data profile for this table. - * - * Generated from protobuf field string project_data_profile = 2; - */ - protected $project_data_profile = ''; - /** - * The Google Cloud project ID that owns the resource. - * - * Generated from protobuf field string dataset_project_id = 24; - */ - protected $dataset_project_id = ''; - /** - * If supported, the location where the dataset's data is stored. - * See https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * - * Generated from protobuf field string dataset_location = 29; - */ - protected $dataset_location = ''; - /** - * If the resource is BigQuery, the dataset ID. - * - * Generated from protobuf field string dataset_id = 25; - */ - protected $dataset_id = ''; - /** - * If the resource is BigQuery, the BigQuery table ID. - * - * Generated from protobuf field string table_id = 26; - */ - protected $table_id = ''; - /** - * The resource name of the resource profiled. - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string full_resource = 3; - */ - protected $full_resource = ''; - /** - * Success or error status from the most recent profile generation attempt. - * May be empty if the profile is still being generated. - * - * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 21; - */ - protected $profile_status = null; - /** - * State of a profile. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile.State state = 22; - */ - protected $state = 0; - /** - * The sensitivity score of this table. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 5; - */ - protected $sensitivity_score = null; - /** - * The data risk level of this table. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 6; - */ - protected $data_risk_level = null; - /** - * The infoTypes predicted from this table's data. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeSummary predicted_info_types = 27; - */ - private $predicted_info_types; - /** - * Other infoTypes found in this table's data. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.OtherInfoTypeSummary other_info_types = 28; - */ - private $other_info_types; - /** - * The snapshot of the configurations used to generate the profile. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileConfigSnapshot config_snapshot = 7; - */ - protected $config_snapshot = null; - /** - * The time when this table was last modified - * - * Generated from protobuf field .google.protobuf.Timestamp last_modified_time = 8; - */ - protected $last_modified_time = null; - /** - * Optional. The time when this table expires. - * - * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 9; - */ - protected $expiration_time = null; - /** - * The number of columns profiled in the table. - * - * Generated from protobuf field int64 scanned_column_count = 10; - */ - protected $scanned_column_count = 0; - /** - * The number of columns skipped in the table because of an error. - * - * Generated from protobuf field int64 failed_column_count = 11; - */ - protected $failed_column_count = 0; - /** - * The size of the table when the profile was generated. - * - * Generated from protobuf field int64 table_size_bytes = 12; - */ - protected $table_size_bytes = 0; - /** - * Number of rows in the table when the profile was generated. - * This will not be populated for BigLake tables. - * - * Generated from protobuf field int64 row_count = 13; - */ - protected $row_count = 0; - /** - * How the table is encrypted. - * - * Generated from protobuf field .google.privacy.dlp.v2.EncryptionStatus encryption_status = 14; - */ - protected $encryption_status = 0; - /** - * How broadly a resource has been shared. - * - * Generated from protobuf field .google.privacy.dlp.v2.ResourceVisibility resource_visibility = 15; - */ - protected $resource_visibility = 0; - /** - * The last time the profile was generated. - * - * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 16; - */ - protected $profile_last_generated = null; - /** - * The labels applied to the resource at the time the profile was generated. - * - * Generated from protobuf field map resource_labels = 17; - */ - private $resource_labels; - /** - * The time at which the table was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 23; - */ - protected $create_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the profile. - * @type \Google\Cloud\Dlp\V2\DataSourceType $data_source_type - * The resource type that was profiled. - * @type string $project_data_profile - * The resource name to the project data profile for this table. - * @type string $dataset_project_id - * The Google Cloud project ID that owns the resource. - * @type string $dataset_location - * If supported, the location where the dataset's data is stored. - * See https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * @type string $dataset_id - * If the resource is BigQuery, the dataset ID. - * @type string $table_id - * If the resource is BigQuery, the BigQuery table ID. - * @type string $full_resource - * The resource name of the resource profiled. - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type \Google\Cloud\Dlp\V2\ProfileStatus $profile_status - * Success or error status from the most recent profile generation attempt. - * May be empty if the profile is still being generated. - * @type int $state - * State of a profile. - * @type \Google\Cloud\Dlp\V2\SensitivityScore $sensitivity_score - * The sensitivity score of this table. - * @type \Google\Cloud\Dlp\V2\DataRiskLevel $data_risk_level - * The data risk level of this table. - * @type array<\Google\Cloud\Dlp\V2\InfoTypeSummary>|\Google\Protobuf\Internal\RepeatedField $predicted_info_types - * The infoTypes predicted from this table's data. - * @type array<\Google\Cloud\Dlp\V2\OtherInfoTypeSummary>|\Google\Protobuf\Internal\RepeatedField $other_info_types - * Other infoTypes found in this table's data. - * @type \Google\Cloud\Dlp\V2\DataProfileConfigSnapshot $config_snapshot - * The snapshot of the configurations used to generate the profile. - * @type \Google\Protobuf\Timestamp $last_modified_time - * The time when this table was last modified - * @type \Google\Protobuf\Timestamp $expiration_time - * Optional. The time when this table expires. - * @type int|string $scanned_column_count - * The number of columns profiled in the table. - * @type int|string $failed_column_count - * The number of columns skipped in the table because of an error. - * @type int|string $table_size_bytes - * The size of the table when the profile was generated. - * @type int|string $row_count - * Number of rows in the table when the profile was generated. - * This will not be populated for BigLake tables. - * @type int $encryption_status - * How the table is encrypted. - * @type int $resource_visibility - * How broadly a resource has been shared. - * @type \Google\Protobuf\Timestamp $profile_last_generated - * The last time the profile was generated. - * @type array|\Google\Protobuf\Internal\MapField $resource_labels - * The labels applied to the resource at the time the profile was generated. - * @type \Google\Protobuf\Timestamp $create_time - * The time at which the table was created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The name of the profile. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the profile. - * - * 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; - } - - /** - * The resource type that was profiled. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataSourceType data_source_type = 36; - * @return \Google\Cloud\Dlp\V2\DataSourceType|null - */ - public function getDataSourceType() - { - return $this->data_source_type; - } - - public function hasDataSourceType() - { - return isset($this->data_source_type); - } - - public function clearDataSourceType() - { - unset($this->data_source_type); - } - - /** - * The resource type that was profiled. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataSourceType data_source_type = 36; - * @param \Google\Cloud\Dlp\V2\DataSourceType $var - * @return $this - */ - public function setDataSourceType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataSourceType::class); - $this->data_source_type = $var; - - return $this; - } - - /** - * The resource name to the project data profile for this table. - * - * Generated from protobuf field string project_data_profile = 2; - * @return string - */ - public function getProjectDataProfile() - { - return $this->project_data_profile; - } - - /** - * The resource name to the project data profile for this table. - * - * Generated from protobuf field string project_data_profile = 2; - * @param string $var - * @return $this - */ - public function setProjectDataProfile($var) - { - GPBUtil::checkString($var, True); - $this->project_data_profile = $var; - - return $this; - } - - /** - * The Google Cloud project ID that owns the resource. - * - * Generated from protobuf field string dataset_project_id = 24; - * @return string - */ - public function getDatasetProjectId() - { - return $this->dataset_project_id; - } - - /** - * The Google Cloud project ID that owns the resource. - * - * Generated from protobuf field string dataset_project_id = 24; - * @param string $var - * @return $this - */ - public function setDatasetProjectId($var) - { - GPBUtil::checkString($var, True); - $this->dataset_project_id = $var; - - return $this; - } - - /** - * If supported, the location where the dataset's data is stored. - * See https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * - * Generated from protobuf field string dataset_location = 29; - * @return string - */ - public function getDatasetLocation() - { - return $this->dataset_location; - } - - /** - * If supported, the location where the dataset's data is stored. - * See https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * - * Generated from protobuf field string dataset_location = 29; - * @param string $var - * @return $this - */ - public function setDatasetLocation($var) - { - GPBUtil::checkString($var, True); - $this->dataset_location = $var; - - return $this; - } - - /** - * If the resource is BigQuery, the dataset ID. - * - * Generated from protobuf field string dataset_id = 25; - * @return string - */ - public function getDatasetId() - { - return $this->dataset_id; - } - - /** - * If the resource is BigQuery, the dataset ID. - * - * Generated from protobuf field string dataset_id = 25; - * @param string $var - * @return $this - */ - public function setDatasetId($var) - { - GPBUtil::checkString($var, True); - $this->dataset_id = $var; - - return $this; - } - - /** - * If the resource is BigQuery, the BigQuery table ID. - * - * Generated from protobuf field string table_id = 26; - * @return string - */ - public function getTableId() - { - return $this->table_id; - } - - /** - * If the resource is BigQuery, the BigQuery table ID. - * - * Generated from protobuf field string table_id = 26; - * @param string $var - * @return $this - */ - public function setTableId($var) - { - GPBUtil::checkString($var, True); - $this->table_id = $var; - - return $this; - } - - /** - * The resource name of the resource profiled. - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string full_resource = 3; - * @return string - */ - public function getFullResource() - { - return $this->full_resource; - } - - /** - * The resource name of the resource profiled. - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string full_resource = 3; - * @param string $var - * @return $this - */ - public function setFullResource($var) - { - GPBUtil::checkString($var, True); - $this->full_resource = $var; - - return $this; - } - - /** - * Success or error status from the most recent profile generation attempt. - * May be empty if the profile is still being generated. - * - * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 21; - * @return \Google\Cloud\Dlp\V2\ProfileStatus|null - */ - public function getProfileStatus() - { - return $this->profile_status; - } - - public function hasProfileStatus() - { - return isset($this->profile_status); - } - - public function clearProfileStatus() - { - unset($this->profile_status); - } - - /** - * Success or error status from the most recent profile generation attempt. - * May be empty if the profile is still being generated. - * - * Generated from protobuf field .google.privacy.dlp.v2.ProfileStatus profile_status = 21; - * @param \Google\Cloud\Dlp\V2\ProfileStatus $var - * @return $this - */ - public function setProfileStatus($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\ProfileStatus::class); - $this->profile_status = $var; - - return $this; - } - - /** - * State of a profile. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile.State state = 22; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * State of a profile. - * - * Generated from protobuf field .google.privacy.dlp.v2.TableDataProfile.State state = 22; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\TableDataProfile\State::class); - $this->state = $var; - - return $this; - } - - /** - * The sensitivity score of this table. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 5; - * @return \Google\Cloud\Dlp\V2\SensitivityScore|null - */ - public function getSensitivityScore() - { - return $this->sensitivity_score; - } - - public function hasSensitivityScore() - { - return isset($this->sensitivity_score); - } - - public function clearSensitivityScore() - { - unset($this->sensitivity_score); - } - - /** - * The sensitivity score of this table. - * - * Generated from protobuf field .google.privacy.dlp.v2.SensitivityScore sensitivity_score = 5; - * @param \Google\Cloud\Dlp\V2\SensitivityScore $var - * @return $this - */ - public function setSensitivityScore($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\SensitivityScore::class); - $this->sensitivity_score = $var; - - return $this; - } - - /** - * The data risk level of this table. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 6; - * @return \Google\Cloud\Dlp\V2\DataRiskLevel|null - */ - public function getDataRiskLevel() - { - return $this->data_risk_level; - } - - public function hasDataRiskLevel() - { - return isset($this->data_risk_level); - } - - public function clearDataRiskLevel() - { - unset($this->data_risk_level); - } - - /** - * The data risk level of this table. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataRiskLevel data_risk_level = 6; - * @param \Google\Cloud\Dlp\V2\DataRiskLevel $var - * @return $this - */ - public function setDataRiskLevel($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataRiskLevel::class); - $this->data_risk_level = $var; - - return $this; - } - - /** - * The infoTypes predicted from this table's data. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeSummary predicted_info_types = 27; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPredictedInfoTypes() - { - return $this->predicted_info_types; - } - - /** - * The infoTypes predicted from this table's data. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.InfoTypeSummary predicted_info_types = 27; - * @param array<\Google\Cloud\Dlp\V2\InfoTypeSummary>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPredictedInfoTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\InfoTypeSummary::class); - $this->predicted_info_types = $arr; - - return $this; - } - - /** - * Other infoTypes found in this table's data. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.OtherInfoTypeSummary other_info_types = 28; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getOtherInfoTypes() - { - return $this->other_info_types; - } - - /** - * Other infoTypes found in this table's data. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.OtherInfoTypeSummary other_info_types = 28; - * @param array<\Google\Cloud\Dlp\V2\OtherInfoTypeSummary>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setOtherInfoTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\OtherInfoTypeSummary::class); - $this->other_info_types = $arr; - - return $this; - } - - /** - * The snapshot of the configurations used to generate the profile. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileConfigSnapshot config_snapshot = 7; - * @return \Google\Cloud\Dlp\V2\DataProfileConfigSnapshot|null - */ - public function getConfigSnapshot() - { - return $this->config_snapshot; - } - - public function hasConfigSnapshot() - { - return isset($this->config_snapshot); - } - - public function clearConfigSnapshot() - { - unset($this->config_snapshot); - } - - /** - * The snapshot of the configurations used to generate the profile. - * - * Generated from protobuf field .google.privacy.dlp.v2.DataProfileConfigSnapshot config_snapshot = 7; - * @param \Google\Cloud\Dlp\V2\DataProfileConfigSnapshot $var - * @return $this - */ - public function setConfigSnapshot($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DataProfileConfigSnapshot::class); - $this->config_snapshot = $var; - - return $this; - } - - /** - * The time when this table was last modified - * - * Generated from protobuf field .google.protobuf.Timestamp last_modified_time = 8; - * @return \Google\Protobuf\Timestamp|null - */ - public function getLastModifiedTime() - { - return $this->last_modified_time; - } - - public function hasLastModifiedTime() - { - return isset($this->last_modified_time); - } - - public function clearLastModifiedTime() - { - unset($this->last_modified_time); - } - - /** - * The time when this table was last modified - * - * Generated from protobuf field .google.protobuf.Timestamp last_modified_time = 8; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setLastModifiedTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->last_modified_time = $var; - - return $this; - } - - /** - * Optional. The time when this table expires. - * - * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 9; - * @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); - } - - /** - * Optional. The time when this table expires. - * - * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 9; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setExpirationTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->expiration_time = $var; - - return $this; - } - - /** - * The number of columns profiled in the table. - * - * Generated from protobuf field int64 scanned_column_count = 10; - * @return int|string - */ - public function getScannedColumnCount() - { - return $this->scanned_column_count; - } - - /** - * The number of columns profiled in the table. - * - * Generated from protobuf field int64 scanned_column_count = 10; - * @param int|string $var - * @return $this - */ - public function setScannedColumnCount($var) - { - GPBUtil::checkInt64($var); - $this->scanned_column_count = $var; - - return $this; - } - - /** - * The number of columns skipped in the table because of an error. - * - * Generated from protobuf field int64 failed_column_count = 11; - * @return int|string - */ - public function getFailedColumnCount() - { - return $this->failed_column_count; - } - - /** - * The number of columns skipped in the table because of an error. - * - * Generated from protobuf field int64 failed_column_count = 11; - * @param int|string $var - * @return $this - */ - public function setFailedColumnCount($var) - { - GPBUtil::checkInt64($var); - $this->failed_column_count = $var; - - return $this; - } - - /** - * The size of the table when the profile was generated. - * - * Generated from protobuf field int64 table_size_bytes = 12; - * @return int|string - */ - public function getTableSizeBytes() - { - return $this->table_size_bytes; - } - - /** - * The size of the table when the profile was generated. - * - * Generated from protobuf field int64 table_size_bytes = 12; - * @param int|string $var - * @return $this - */ - public function setTableSizeBytes($var) - { - GPBUtil::checkInt64($var); - $this->table_size_bytes = $var; - - return $this; - } - - /** - * Number of rows in the table when the profile was generated. - * This will not be populated for BigLake tables. - * - * Generated from protobuf field int64 row_count = 13; - * @return int|string - */ - public function getRowCount() - { - return $this->row_count; - } - - /** - * Number of rows in the table when the profile was generated. - * This will not be populated for BigLake tables. - * - * Generated from protobuf field int64 row_count = 13; - * @param int|string $var - * @return $this - */ - public function setRowCount($var) - { - GPBUtil::checkInt64($var); - $this->row_count = $var; - - return $this; - } - - /** - * How the table is encrypted. - * - * Generated from protobuf field .google.privacy.dlp.v2.EncryptionStatus encryption_status = 14; - * @return int - */ - public function getEncryptionStatus() - { - return $this->encryption_status; - } - - /** - * How the table is encrypted. - * - * Generated from protobuf field .google.privacy.dlp.v2.EncryptionStatus encryption_status = 14; - * @param int $var - * @return $this - */ - public function setEncryptionStatus($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\EncryptionStatus::class); - $this->encryption_status = $var; - - return $this; - } - - /** - * How broadly a resource has been shared. - * - * Generated from protobuf field .google.privacy.dlp.v2.ResourceVisibility resource_visibility = 15; - * @return int - */ - public function getResourceVisibility() - { - return $this->resource_visibility; - } - - /** - * How broadly a resource has been shared. - * - * Generated from protobuf field .google.privacy.dlp.v2.ResourceVisibility resource_visibility = 15; - * @param int $var - * @return $this - */ - public function setResourceVisibility($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\ResourceVisibility::class); - $this->resource_visibility = $var; - - return $this; - } - - /** - * The last time the profile was generated. - * - * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 16; - * @return \Google\Protobuf\Timestamp|null - */ - public function getProfileLastGenerated() - { - return $this->profile_last_generated; - } - - public function hasProfileLastGenerated() - { - return isset($this->profile_last_generated); - } - - public function clearProfileLastGenerated() - { - unset($this->profile_last_generated); - } - - /** - * The last time the profile was generated. - * - * Generated from protobuf field .google.protobuf.Timestamp profile_last_generated = 16; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setProfileLastGenerated($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->profile_last_generated = $var; - - return $this; - } - - /** - * The labels applied to the resource at the time the profile was generated. - * - * Generated from protobuf field map resource_labels = 17; - * @return \Google\Protobuf\Internal\MapField - */ - public function getResourceLabels() - { - return $this->resource_labels; - } - - /** - * The labels applied to the resource at the time the profile was generated. - * - * Generated from protobuf field map resource_labels = 17; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setResourceLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->resource_labels = $arr; - - return $this; - } - - /** - * The time at which the table was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 23; - * @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); - } - - /** - * The time at which the table was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 23; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile/State.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile/State.php deleted file mode 100644 index c28719cfb2e3..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableDataProfile/State.php +++ /dev/null @@ -1,67 +0,0 @@ -google.privacy.dlp.v2.TableDataProfile.State - */ -class State -{ - /** - * Unused. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The profile is currently running. Once a profile has finished it will - * transition to DONE. - * - * Generated from protobuf enum RUNNING = 1; - */ - const RUNNING = 1; - /** - * The profile is no longer generating. - * If profile_status.status.code is 0, the profile succeeded, otherwise, it - * failed. - * - * Generated from protobuf enum DONE = 2; - */ - const DONE = 2; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::RUNNING => 'RUNNING', - self::DONE => 'DONE', - ]; - - 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, \Google\Cloud\Dlp\V2\TableDataProfile_State::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableLocation.php deleted file mode 100644 index 16a8dbadb8fb..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableLocation.php +++ /dev/null @@ -1,87 +0,0 @@ -google.privacy.dlp.v2.TableLocation - */ -class TableLocation extends \Google\Protobuf\Internal\Message -{ - /** - * The zero-based index of the row where the finding is located. Only - * populated for resources that have a natural ordering, not BigQuery. In - * BigQuery, to identify the row a finding came from, populate - * BigQueryOptions.identifying_fields with your primary key column names and - * when you store the findings the value of those columns will be stored - * inside of Finding. - * - * Generated from protobuf field int64 row_index = 1; - */ - protected $row_index = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $row_index - * The zero-based index of the row where the finding is located. Only - * populated for resources that have a natural ordering, not BigQuery. In - * BigQuery, to identify the row a finding came from, populate - * BigQueryOptions.identifying_fields with your primary key column names and - * when you store the findings the value of those columns will be stored - * inside of Finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The zero-based index of the row where the finding is located. Only - * populated for resources that have a natural ordering, not BigQuery. In - * BigQuery, to identify the row a finding came from, populate - * BigQueryOptions.identifying_fields with your primary key column names and - * when you store the findings the value of those columns will be stored - * inside of Finding. - * - * Generated from protobuf field int64 row_index = 1; - * @return int|string - */ - public function getRowIndex() - { - return $this->row_index; - } - - /** - * The zero-based index of the row where the finding is located. Only - * populated for resources that have a natural ordering, not BigQuery. In - * BigQuery, to identify the row a finding came from, populate - * BigQueryOptions.identifying_fields with your primary key column names and - * when you store the findings the value of those columns will be stored - * inside of Finding. - * - * Generated from protobuf field int64 row_index = 1; - * @param int|string $var - * @return $this - */ - public function setRowIndex($var) - { - GPBUtil::checkInt64($var); - $this->row_index = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableOptions.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableOptions.php deleted file mode 100644 index 46fbb8dc8f82..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TableOptions.php +++ /dev/null @@ -1,79 +0,0 @@ -google.privacy.dlp.v2.TableOptions - */ -class TableOptions extends \Google\Protobuf\Internal\Message -{ - /** - * The columns that are the primary keys for table objects included in - * ContentItem. A copy of this cell's value will stored alongside alongside - * each finding so that the finding can be traced to the specific row it came - * from. No more than 3 may be provided. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId identifying_fields = 1; - */ - private $identifying_fields; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $identifying_fields - * The columns that are the primary keys for table objects included in - * ContentItem. A copy of this cell's value will stored alongside alongside - * each finding so that the finding can be traced to the specific row it came - * from. No more than 3 may be provided. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Storage::initOnce(); - parent::__construct($data); - } - - /** - * The columns that are the primary keys for table objects included in - * ContentItem. A copy of this cell's value will stored alongside alongside - * each finding so that the finding can be traced to the specific row it came - * from. No more than 3 may be provided. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId identifying_fields = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIdentifyingFields() - { - return $this->identifying_fields; - } - - /** - * The columns that are the primary keys for table objects included in - * ContentItem. A copy of this cell's value will stored alongside alongside - * each finding so that the finding can be traced to the specific row it came - * from. No more than 3 may be provided. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldId identifying_fields = 1; - * @param array<\Google\Cloud\Dlp\V2\FieldId>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIdentifyingFields($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldId::class); - $this->identifying_fields = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig.php deleted file mode 100644 index 56ef5ac5f19b..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig.php +++ /dev/null @@ -1,68 +0,0 @@ -google.privacy.dlp.v2.TimePartConfig - */ -class TimePartConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The part of the time to keep. - * - * Generated from protobuf field .google.privacy.dlp.v2.TimePartConfig.TimePart part_to_extract = 1; - */ - protected $part_to_extract = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $part_to_extract - * The part of the time to keep. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The part of the time to keep. - * - * Generated from protobuf field .google.privacy.dlp.v2.TimePartConfig.TimePart part_to_extract = 1; - * @return int - */ - public function getPartToExtract() - { - return $this->part_to_extract; - } - - /** - * The part of the time to keep. - * - * Generated from protobuf field .google.privacy.dlp.v2.TimePartConfig.TimePart part_to_extract = 1; - * @param int $var - * @return $this - */ - public function setPartToExtract($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\TimePartConfig\TimePart::class); - $this->part_to_extract = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig/TimePart.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig/TimePart.php deleted file mode 100644 index a1b53ed057fc..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TimePartConfig/TimePart.php +++ /dev/null @@ -1,92 +0,0 @@ -google.privacy.dlp.v2.TimePartConfig.TimePart - */ -class TimePart -{ - /** - * Unused - * - * Generated from protobuf enum TIME_PART_UNSPECIFIED = 0; - */ - const TIME_PART_UNSPECIFIED = 0; - /** - * [0-9999] - * - * Generated from protobuf enum YEAR = 1; - */ - const YEAR = 1; - /** - * [1-12] - * - * Generated from protobuf enum MONTH = 2; - */ - const MONTH = 2; - /** - * [1-31] - * - * Generated from protobuf enum DAY_OF_MONTH = 3; - */ - const DAY_OF_MONTH = 3; - /** - * [1-7] - * - * Generated from protobuf enum DAY_OF_WEEK = 4; - */ - const DAY_OF_WEEK = 4; - /** - * [1-53] - * - * Generated from protobuf enum WEEK_OF_YEAR = 5; - */ - const WEEK_OF_YEAR = 5; - /** - * [0-23] - * - * Generated from protobuf enum HOUR_OF_DAY = 6; - */ - const HOUR_OF_DAY = 6; - - private static $valueToName = [ - self::TIME_PART_UNSPECIFIED => 'TIME_PART_UNSPECIFIED', - self::YEAR => 'YEAR', - self::MONTH => 'MONTH', - self::DAY_OF_MONTH => 'DAY_OF_MONTH', - self::DAY_OF_WEEK => 'DAY_OF_WEEK', - self::WEEK_OF_YEAR => 'WEEK_OF_YEAR', - self::HOUR_OF_DAY => 'HOUR_OF_DAY', - ]; - - 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(TimePart::class, \Google\Cloud\Dlp\V2\TimePartConfig_TimePart::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationConfig.php deleted file mode 100644 index ba44342662ed..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationConfig.php +++ /dev/null @@ -1,193 +0,0 @@ -google.privacy.dlp.v2.TransformationConfig - */ -class TransformationConfig extends \Google\Protobuf\Internal\Message -{ - /** - * De-identify template. - * If this template is specified, it will serve as the default de-identify - * template. This template cannot contain `record_transformations` since it - * can be used for unstructured content such as free-form text files. If this - * template is not set, a default `ReplaceWithInfoTypeConfig` will be used to - * de-identify unstructured content. - * - * Generated from protobuf field string deidentify_template = 1; - */ - protected $deidentify_template = ''; - /** - * Structured de-identify template. - * If this template is specified, it will serve as the de-identify template - * for structured content such as delimited files and tables. If this template - * is not set but the `deidentify_template` is set, then `deidentify_template` - * will also apply to the structured content. If neither template is set, a - * default `ReplaceWithInfoTypeConfig` will be used to de-identify structured - * content. - * - * Generated from protobuf field string structured_deidentify_template = 2; - */ - protected $structured_deidentify_template = ''; - /** - * Image redact template. - * If this template is specified, it will serve as the de-identify template - * for images. If this template is not set, all findings in the image will be - * redacted with a black box. - * - * Generated from protobuf field string image_redact_template = 4; - */ - protected $image_redact_template = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $deidentify_template - * De-identify template. - * If this template is specified, it will serve as the default de-identify - * template. This template cannot contain `record_transformations` since it - * can be used for unstructured content such as free-form text files. If this - * template is not set, a default `ReplaceWithInfoTypeConfig` will be used to - * de-identify unstructured content. - * @type string $structured_deidentify_template - * Structured de-identify template. - * If this template is specified, it will serve as the de-identify template - * for structured content such as delimited files and tables. If this template - * is not set but the `deidentify_template` is set, then `deidentify_template` - * will also apply to the structured content. If neither template is set, a - * default `ReplaceWithInfoTypeConfig` will be used to de-identify structured - * content. - * @type string $image_redact_template - * Image redact template. - * If this template is specified, it will serve as the de-identify template - * for images. If this template is not set, all findings in the image will be - * redacted with a black box. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * De-identify template. - * If this template is specified, it will serve as the default de-identify - * template. This template cannot contain `record_transformations` since it - * can be used for unstructured content such as free-form text files. If this - * template is not set, a default `ReplaceWithInfoTypeConfig` will be used to - * de-identify unstructured content. - * - * Generated from protobuf field string deidentify_template = 1; - * @return string - */ - public function getDeidentifyTemplate() - { - return $this->deidentify_template; - } - - /** - * De-identify template. - * If this template is specified, it will serve as the default de-identify - * template. This template cannot contain `record_transformations` since it - * can be used for unstructured content such as free-form text files. If this - * template is not set, a default `ReplaceWithInfoTypeConfig` will be used to - * de-identify unstructured content. - * - * Generated from protobuf field string deidentify_template = 1; - * @param string $var - * @return $this - */ - public function setDeidentifyTemplate($var) - { - GPBUtil::checkString($var, True); - $this->deidentify_template = $var; - - return $this; - } - - /** - * Structured de-identify template. - * If this template is specified, it will serve as the de-identify template - * for structured content such as delimited files and tables. If this template - * is not set but the `deidentify_template` is set, then `deidentify_template` - * will also apply to the structured content. If neither template is set, a - * default `ReplaceWithInfoTypeConfig` will be used to de-identify structured - * content. - * - * Generated from protobuf field string structured_deidentify_template = 2; - * @return string - */ - public function getStructuredDeidentifyTemplate() - { - return $this->structured_deidentify_template; - } - - /** - * Structured de-identify template. - * If this template is specified, it will serve as the de-identify template - * for structured content such as delimited files and tables. If this template - * is not set but the `deidentify_template` is set, then `deidentify_template` - * will also apply to the structured content. If neither template is set, a - * default `ReplaceWithInfoTypeConfig` will be used to de-identify structured - * content. - * - * Generated from protobuf field string structured_deidentify_template = 2; - * @param string $var - * @return $this - */ - public function setStructuredDeidentifyTemplate($var) - { - GPBUtil::checkString($var, True); - $this->structured_deidentify_template = $var; - - return $this; - } - - /** - * Image redact template. - * If this template is specified, it will serve as the de-identify template - * for images. If this template is not set, all findings in the image will be - * redacted with a black box. - * - * Generated from protobuf field string image_redact_template = 4; - * @return string - */ - public function getImageRedactTemplate() - { - return $this->image_redact_template; - } - - /** - * Image redact template. - * If this template is specified, it will serve as the de-identify template - * for images. If this template is not set, all findings in the image will be - * redacted with a black box. - * - * Generated from protobuf field string image_redact_template = 4; - * @param string $var - * @return $this - */ - public function setImageRedactTemplate($var) - { - GPBUtil::checkString($var, True); - $this->image_redact_template = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationContainerType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationContainerType.php deleted file mode 100644 index 2030c3527e9f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationContainerType.php +++ /dev/null @@ -1,68 +0,0 @@ -google.privacy.dlp.v2.TransformationContainerType - */ -class TransformationContainerType -{ - /** - * Unused. - * - * Generated from protobuf enum TRANSFORM_UNKNOWN_CONTAINER = 0; - */ - const TRANSFORM_UNKNOWN_CONTAINER = 0; - /** - * Body of a file. - * - * Generated from protobuf enum TRANSFORM_BODY = 1; - */ - const TRANSFORM_BODY = 1; - /** - * Metadata for a file. - * - * Generated from protobuf enum TRANSFORM_METADATA = 2; - */ - const TRANSFORM_METADATA = 2; - /** - * A table. - * - * Generated from protobuf enum TRANSFORM_TABLE = 3; - */ - const TRANSFORM_TABLE = 3; - - private static $valueToName = [ - self::TRANSFORM_UNKNOWN_CONTAINER => 'TRANSFORM_UNKNOWN_CONTAINER', - self::TRANSFORM_BODY => 'TRANSFORM_BODY', - self::TRANSFORM_METADATA => 'TRANSFORM_METADATA', - self::TRANSFORM_TABLE => 'TRANSFORM_TABLE', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDescription.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDescription.php deleted file mode 100644 index 1f75fa66768f..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDescription.php +++ /dev/null @@ -1,224 +0,0 @@ -google.privacy.dlp.v2.TransformationDescription - */ -class TransformationDescription extends \Google\Protobuf\Internal\Message -{ - /** - * The transformation type. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationType type = 1; - */ - protected $type = 0; - /** - * A description of the transformation. This is empty for a - * RECORD_SUPPRESSION, or is the output of calling toString() on the - * `PrimitiveTransformation` protocol buffer message for any other type of - * transformation. - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - /** - * A human-readable string representation of the `RecordCondition` - * corresponding to this transformation. Set if a `RecordCondition` was used - * to determine whether or not to apply this transformation. - * Examples: - * * (age_field > 85) - * * (age_field <= 18) - * * (zip_field exists) - * * (zip_field == 01234) && (city_field != "Springville") - * * (zip_field == 01234) && (age_field <= 18) && (city_field exists) - * - * Generated from protobuf field string condition = 3; - */ - protected $condition = ''; - /** - * Set if the transformation was limited to a specific `InfoType`. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 4; - */ - protected $info_type = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $type - * The transformation type. - * @type string $description - * A description of the transformation. This is empty for a - * RECORD_SUPPRESSION, or is the output of calling toString() on the - * `PrimitiveTransformation` protocol buffer message for any other type of - * transformation. - * @type string $condition - * A human-readable string representation of the `RecordCondition` - * corresponding to this transformation. Set if a `RecordCondition` was used - * to determine whether or not to apply this transformation. - * Examples: - * * (age_field > 85) - * * (age_field <= 18) - * * (zip_field exists) - * * (zip_field == 01234) && (city_field != "Springville") - * * (zip_field == 01234) && (age_field <= 18) && (city_field exists) - * @type \Google\Cloud\Dlp\V2\InfoType $info_type - * Set if the transformation was limited to a specific `InfoType`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The transformation type. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationType type = 1; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The transformation type. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationType type = 1; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\TransformationType::class); - $this->type = $var; - - return $this; - } - - /** - * A description of the transformation. This is empty for a - * RECORD_SUPPRESSION, or is the output of calling toString() on the - * `PrimitiveTransformation` protocol buffer message for any other type of - * transformation. - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * A description of the transformation. This is empty for a - * RECORD_SUPPRESSION, or is the output of calling toString() on the - * `PrimitiveTransformation` protocol buffer message for any other type of - * transformation. - * - * 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; - } - - /** - * A human-readable string representation of the `RecordCondition` - * corresponding to this transformation. Set if a `RecordCondition` was used - * to determine whether or not to apply this transformation. - * Examples: - * * (age_field > 85) - * * (age_field <= 18) - * * (zip_field exists) - * * (zip_field == 01234) && (city_field != "Springville") - * * (zip_field == 01234) && (age_field <= 18) && (city_field exists) - * - * Generated from protobuf field string condition = 3; - * @return string - */ - public function getCondition() - { - return $this->condition; - } - - /** - * A human-readable string representation of the `RecordCondition` - * corresponding to this transformation. Set if a `RecordCondition` was used - * to determine whether or not to apply this transformation. - * Examples: - * * (age_field > 85) - * * (age_field <= 18) - * * (zip_field exists) - * * (zip_field == 01234) && (city_field != "Springville") - * * (zip_field == 01234) && (age_field <= 18) && (city_field exists) - * - * Generated from protobuf field string condition = 3; - * @param string $var - * @return $this - */ - public function setCondition($var) - { - GPBUtil::checkString($var, True); - $this->condition = $var; - - return $this; - } - - /** - * Set if the transformation was limited to a specific `InfoType`. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 4; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getInfoType() - { - return $this->info_type; - } - - public function hasInfoType() - { - return isset($this->info_type); - } - - public function clearInfoType() - { - unset($this->info_type); - } - - /** - * Set if the transformation was limited to a specific `InfoType`. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 4; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetails.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetails.php deleted file mode 100644 index 4dd1b7730d8a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetails.php +++ /dev/null @@ -1,296 +0,0 @@ -google.privacy.dlp.v2.TransformationDetails - */ -class TransformationDetails extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the job that completed the transformation. - * - * Generated from protobuf field string resource_name = 1; - */ - protected $resource_name = ''; - /** - * The top level name of the container where the transformation is located - * (this will be the source file name or table name). - * - * Generated from protobuf field string container_name = 2; - */ - protected $container_name = ''; - /** - * Description of transformation. This would only contain more than one - * element if there were multiple matching transformations and which one to - * apply was ambiguous. Not set for states that contain no transformation, - * currently only state that contains no transformation is - * TransformationResultStateType.METADATA_UNRETRIEVABLE. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationDescription transformation = 3; - */ - private $transformation; - /** - * Status of the transformation, if transformation was not successful, this - * will specify what caused it to fail, otherwise it will show that the - * transformation was successful. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationResultStatus status_details = 4; - */ - protected $status_details = null; - /** - * The number of bytes that were transformed. If transformation was - * unsuccessful or did not take place because there was no content to - * transform, this will be zero. - * - * Generated from protobuf field int64 transformed_bytes = 5; - */ - protected $transformed_bytes = 0; - /** - * The precise location of the transformed content in the original container. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationLocation transformation_location = 6; - */ - protected $transformation_location = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $resource_name - * The name of the job that completed the transformation. - * @type string $container_name - * The top level name of the container where the transformation is located - * (this will be the source file name or table name). - * @type array<\Google\Cloud\Dlp\V2\TransformationDescription>|\Google\Protobuf\Internal\RepeatedField $transformation - * Description of transformation. This would only contain more than one - * element if there were multiple matching transformations and which one to - * apply was ambiguous. Not set for states that contain no transformation, - * currently only state that contains no transformation is - * TransformationResultStateType.METADATA_UNRETRIEVABLE. - * @type \Google\Cloud\Dlp\V2\TransformationResultStatus $status_details - * Status of the transformation, if transformation was not successful, this - * will specify what caused it to fail, otherwise it will show that the - * transformation was successful. - * @type int|string $transformed_bytes - * The number of bytes that were transformed. If transformation was - * unsuccessful or did not take place because there was no content to - * transform, this will be zero. - * @type \Google\Cloud\Dlp\V2\TransformationLocation $transformation_location - * The precise location of the transformed content in the original container. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The name of the job that completed the transformation. - * - * Generated from protobuf field string resource_name = 1; - * @return string - */ - public function getResourceName() - { - return $this->resource_name; - } - - /** - * The name of the job that completed the transformation. - * - * Generated from protobuf field string resource_name = 1; - * @param string $var - * @return $this - */ - public function setResourceName($var) - { - GPBUtil::checkString($var, True); - $this->resource_name = $var; - - return $this; - } - - /** - * The top level name of the container where the transformation is located - * (this will be the source file name or table name). - * - * Generated from protobuf field string container_name = 2; - * @return string - */ - public function getContainerName() - { - return $this->container_name; - } - - /** - * The top level name of the container where the transformation is located - * (this will be the source file name or table name). - * - * Generated from protobuf field string container_name = 2; - * @param string $var - * @return $this - */ - public function setContainerName($var) - { - GPBUtil::checkString($var, True); - $this->container_name = $var; - - return $this; - } - - /** - * Description of transformation. This would only contain more than one - * element if there were multiple matching transformations and which one to - * apply was ambiguous. Not set for states that contain no transformation, - * currently only state that contains no transformation is - * TransformationResultStateType.METADATA_UNRETRIEVABLE. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationDescription transformation = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTransformation() - { - return $this->transformation; - } - - /** - * Description of transformation. This would only contain more than one - * element if there were multiple matching transformations and which one to - * apply was ambiguous. Not set for states that contain no transformation, - * currently only state that contains no transformation is - * TransformationResultStateType.METADATA_UNRETRIEVABLE. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationDescription transformation = 3; - * @param array<\Google\Cloud\Dlp\V2\TransformationDescription>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTransformation($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\TransformationDescription::class); - $this->transformation = $arr; - - return $this; - } - - /** - * Status of the transformation, if transformation was not successful, this - * will specify what caused it to fail, otherwise it will show that the - * transformation was successful. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationResultStatus status_details = 4; - * @return \Google\Cloud\Dlp\V2\TransformationResultStatus|null - */ - public function getStatusDetails() - { - return $this->status_details; - } - - public function hasStatusDetails() - { - return isset($this->status_details); - } - - public function clearStatusDetails() - { - unset($this->status_details); - } - - /** - * Status of the transformation, if transformation was not successful, this - * will specify what caused it to fail, otherwise it will show that the - * transformation was successful. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationResultStatus status_details = 4; - * @param \Google\Cloud\Dlp\V2\TransformationResultStatus $var - * @return $this - */ - public function setStatusDetails($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationResultStatus::class); - $this->status_details = $var; - - return $this; - } - - /** - * The number of bytes that were transformed. If transformation was - * unsuccessful or did not take place because there was no content to - * transform, this will be zero. - * - * Generated from protobuf field int64 transformed_bytes = 5; - * @return int|string - */ - public function getTransformedBytes() - { - return $this->transformed_bytes; - } - - /** - * The number of bytes that were transformed. If transformation was - * unsuccessful or did not take place because there was no content to - * transform, this will be zero. - * - * Generated from protobuf field int64 transformed_bytes = 5; - * @param int|string $var - * @return $this - */ - public function setTransformedBytes($var) - { - GPBUtil::checkInt64($var); - $this->transformed_bytes = $var; - - return $this; - } - - /** - * The precise location of the transformed content in the original container. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationLocation transformation_location = 6; - * @return \Google\Cloud\Dlp\V2\TransformationLocation|null - */ - public function getTransformationLocation() - { - return $this->transformation_location; - } - - public function hasTransformationLocation() - { - return isset($this->transformation_location); - } - - public function clearTransformationLocation() - { - unset($this->transformation_location); - } - - /** - * The precise location of the transformed content in the original container. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationLocation transformation_location = 6; - * @param \Google\Cloud\Dlp\V2\TransformationLocation $var - * @return $this - */ - public function setTransformationLocation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationLocation::class); - $this->transformation_location = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetailsStorageConfig.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetailsStorageConfig.php deleted file mode 100644 index 24bf69f6a45b..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationDetailsStorageConfig.php +++ /dev/null @@ -1,90 +0,0 @@ -google.privacy.dlp.v2.TransformationDetailsStorageConfig - */ -class TransformationDetailsStorageConfig extends \Google\Protobuf\Internal\Message -{ - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\BigQueryTable $table - * The BigQuery table in which to store the output. This may be an existing - * table or in a new table in an existing dataset. - * If table_id is not set a new one will be generated for you with the - * following format: - * dlp_googleapis_transformation_details_yyyy_mm_dd_[dlp_job_id]. Pacific - * time zone will be used for generating the date details. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * The BigQuery table in which to store the output. This may be an existing - * table or in a new table in an existing dataset. - * If table_id is not set a new one will be generated for you with the - * following format: - * dlp_googleapis_transformation_details_yyyy_mm_dd_[dlp_job_id]. Pacific - * time zone will be used for generating the date details. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; - * @return \Google\Cloud\Dlp\V2\BigQueryTable|null - */ - public function getTable() - { - return $this->readOneof(1); - } - - public function hasTable() - { - return $this->hasOneof(1); - } - - /** - * The BigQuery table in which to store the output. This may be an existing - * table or in a new table in an existing dataset. - * If table_id is not set a new one will be generated for you with the - * following format: - * dlp_googleapis_transformation_details_yyyy_mm_dd_[dlp_job_id]. Pacific - * time zone will be used for generating the date details. - * - * Generated from protobuf field .google.privacy.dlp.v2.BigQueryTable table = 1; - * @param \Google\Cloud\Dlp\V2\BigQueryTable $var - * @return $this - */ - public function setTable($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\BigQueryTable::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling.php deleted file mode 100644 index 59e5328ad8ef..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling.php +++ /dev/null @@ -1,115 +0,0 @@ -google.privacy.dlp.v2.TransformationErrorHandling - */ -class TransformationErrorHandling extends \Google\Protobuf\Internal\Message -{ - protected $mode; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\TransformationErrorHandling\ThrowError $throw_error - * Throw an error - * @type \Google\Cloud\Dlp\V2\TransformationErrorHandling\LeaveUntransformed $leave_untransformed - * Ignore errors - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Throw an error - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling.ThrowError throw_error = 1; - * @return \Google\Cloud\Dlp\V2\TransformationErrorHandling\ThrowError|null - */ - public function getThrowError() - { - return $this->readOneof(1); - } - - public function hasThrowError() - { - return $this->hasOneof(1); - } - - /** - * Throw an error - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling.ThrowError throw_error = 1; - * @param \Google\Cloud\Dlp\V2\TransformationErrorHandling\ThrowError $var - * @return $this - */ - public function setThrowError($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationErrorHandling\ThrowError::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Ignore errors - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling.LeaveUntransformed leave_untransformed = 2; - * @return \Google\Cloud\Dlp\V2\TransformationErrorHandling\LeaveUntransformed|null - */ - public function getLeaveUntransformed() - { - return $this->readOneof(2); - } - - public function hasLeaveUntransformed() - { - return $this->hasOneof(2); - } - - /** - * Ignore errors - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationErrorHandling.LeaveUntransformed leave_untransformed = 2; - * @param \Google\Cloud\Dlp\V2\TransformationErrorHandling\LeaveUntransformed $var - * @return $this - */ - public function setLeaveUntransformed($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\TransformationErrorHandling\LeaveUntransformed::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getMode() - { - return $this->whichOneof("mode"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/LeaveUntransformed.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/LeaveUntransformed.php deleted file mode 100644 index 6bae015ce978..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/LeaveUntransformed.php +++ /dev/null @@ -1,39 +0,0 @@ -google.privacy.dlp.v2.TransformationErrorHandling.LeaveUntransformed - */ -class LeaveUntransformed extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LeaveUntransformed::class, \Google\Cloud\Dlp\V2\TransformationErrorHandling_LeaveUntransformed::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/ThrowError.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/ThrowError.php deleted file mode 100644 index 7333a88ddd7e..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationErrorHandling/ThrowError.php +++ /dev/null @@ -1,36 +0,0 @@ -google.privacy.dlp.v2.TransformationErrorHandling.ThrowError - */ -class ThrowError extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ThrowError::class, \Google\Cloud\Dlp\V2\TransformationErrorHandling_ThrowError::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationLocation.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationLocation.php deleted file mode 100644 index 458b4a9e22ad..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationLocation.php +++ /dev/null @@ -1,158 +0,0 @@ -google.privacy.dlp.v2.TransformationLocation - */ -class TransformationLocation extends \Google\Protobuf\Internal\Message -{ - /** - * Information about the functionality of the container where this finding - * occurred, if available. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationContainerType container_type = 3; - */ - protected $container_type = 0; - protected $location_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $finding_id - * For infotype transformations, link to the corresponding findings ID so - * that location information does not need to be duplicated. Each findings - * ID correlates to an entry in the findings output table, this table only - * gets created when users specify to save findings (add the save findings - * action to the request). - * @type \Google\Cloud\Dlp\V2\RecordTransformation $record_transformation - * For record transformations, provide a field and container information. - * @type int $container_type - * Information about the functionality of the container where this finding - * occurred, if available. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * For infotype transformations, link to the corresponding findings ID so - * that location information does not need to be duplicated. Each findings - * ID correlates to an entry in the findings output table, this table only - * gets created when users specify to save findings (add the save findings - * action to the request). - * - * Generated from protobuf field string finding_id = 1; - * @return string - */ - public function getFindingId() - { - return $this->readOneof(1); - } - - public function hasFindingId() - { - return $this->hasOneof(1); - } - - /** - * For infotype transformations, link to the corresponding findings ID so - * that location information does not need to be duplicated. Each findings - * ID correlates to an entry in the findings output table, this table only - * gets created when users specify to save findings (add the save findings - * action to the request). - * - * Generated from protobuf field string finding_id = 1; - * @param string $var - * @return $this - */ - public function setFindingId($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * For record transformations, provide a field and container information. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordTransformation record_transformation = 2; - * @return \Google\Cloud\Dlp\V2\RecordTransformation|null - */ - public function getRecordTransformation() - { - return $this->readOneof(2); - } - - public function hasRecordTransformation() - { - return $this->hasOneof(2); - } - - /** - * For record transformations, provide a field and container information. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordTransformation record_transformation = 2; - * @param \Google\Cloud\Dlp\V2\RecordTransformation $var - * @return $this - */ - public function setRecordTransformation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordTransformation::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Information about the functionality of the container where this finding - * occurred, if available. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationContainerType container_type = 3; - * @return int - */ - public function getContainerType() - { - return $this->container_type; - } - - /** - * Information about the functionality of the container where this finding - * occurred, if available. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationContainerType container_type = 3; - * @param int $var - * @return $this - */ - public function setContainerType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\TransformationContainerType::class); - $this->container_type = $var; - - return $this; - } - - /** - * @return string - */ - public function getLocationType() - { - return $this->whichOneof("location_type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationOverview.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationOverview.php deleted file mode 100644 index 74a2de1d0589..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationOverview.php +++ /dev/null @@ -1,101 +0,0 @@ -google.privacy.dlp.v2.TransformationOverview - */ -class TransformationOverview extends \Google\Protobuf\Internal\Message -{ - /** - * Total size in bytes that were transformed in some way. - * - * Generated from protobuf field int64 transformed_bytes = 2; - */ - protected $transformed_bytes = 0; - /** - * Transformations applied to the dataset. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationSummary transformation_summaries = 3; - */ - private $transformation_summaries; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $transformed_bytes - * Total size in bytes that were transformed in some way. - * @type array<\Google\Cloud\Dlp\V2\TransformationSummary>|\Google\Protobuf\Internal\RepeatedField $transformation_summaries - * Transformations applied to the dataset. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Total size in bytes that were transformed in some way. - * - * Generated from protobuf field int64 transformed_bytes = 2; - * @return int|string - */ - public function getTransformedBytes() - { - return $this->transformed_bytes; - } - - /** - * Total size in bytes that were transformed in some way. - * - * Generated from protobuf field int64 transformed_bytes = 2; - * @param int|string $var - * @return $this - */ - public function setTransformedBytes($var) - { - GPBUtil::checkInt64($var); - $this->transformed_bytes = $var; - - return $this; - } - - /** - * Transformations applied to the dataset. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationSummary transformation_summaries = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTransformationSummaries() - { - return $this->transformation_summaries; - } - - /** - * Transformations applied to the dataset. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationSummary transformation_summaries = 3; - * @param array<\Google\Cloud\Dlp\V2\TransformationSummary>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTransformationSummaries($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\TransformationSummary::class); - $this->transformation_summaries = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatus.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatus.php deleted file mode 100644 index 28eb9e5aa675..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatus.php +++ /dev/null @@ -1,115 +0,0 @@ -google.privacy.dlp.v2.TransformationResultStatus - */ -class TransformationResultStatus extends \Google\Protobuf\Internal\Message -{ - /** - * Transformation result status type, this will be either SUCCESS, or it will - * be the reason for why the transformation was not completely successful. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationResultStatusType result_status_type = 1; - */ - protected $result_status_type = 0; - /** - * Detailed error codes and messages - * - * Generated from protobuf field .google.rpc.Status details = 2; - */ - protected $details = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $result_status_type - * Transformation result status type, this will be either SUCCESS, or it will - * be the reason for why the transformation was not completely successful. - * @type \Google\Rpc\Status $details - * Detailed error codes and messages - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Transformation result status type, this will be either SUCCESS, or it will - * be the reason for why the transformation was not completely successful. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationResultStatusType result_status_type = 1; - * @return int - */ - public function getResultStatusType() - { - return $this->result_status_type; - } - - /** - * Transformation result status type, this will be either SUCCESS, or it will - * be the reason for why the transformation was not completely successful. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationResultStatusType result_status_type = 1; - * @param int $var - * @return $this - */ - public function setResultStatusType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\TransformationResultStatusType::class); - $this->result_status_type = $var; - - return $this; - } - - /** - * Detailed error codes and messages - * - * Generated from protobuf field .google.rpc.Status details = 2; - * @return \Google\Rpc\Status|null - */ - public function getDetails() - { - return $this->details; - } - - public function hasDetails() - { - return isset($this->details); - } - - public function clearDetails() - { - unset($this->details); - } - - /** - * Detailed error codes and messages - * - * Generated from protobuf field .google.rpc.Status details = 2; - * @param \Google\Rpc\Status $var - * @return $this - */ - public function setDetails($var) - { - GPBUtil::checkMessage($var, \Google\Rpc\Status::class); - $this->details = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatusType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatusType.php deleted file mode 100644 index a308e60c8154..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationResultStatusType.php +++ /dev/null @@ -1,82 +0,0 @@ -google.privacy.dlp.v2.TransformationResultStatusType - */ -class TransformationResultStatusType -{ - /** - * Unused. - * - * Generated from protobuf enum STATE_TYPE_UNSPECIFIED = 0; - */ - const STATE_TYPE_UNSPECIFIED = 0; - /** - * This will be set when a finding could not be transformed (i.e. outside user - * set bucket range). - * - * Generated from protobuf enum INVALID_TRANSFORM = 1; - */ - const INVALID_TRANSFORM = 1; - /** - * This will be set when a BigQuery transformation was successful but could - * not be stored back in BigQuery because the transformed row exceeds - * BigQuery's max row size. - * - * Generated from protobuf enum BIGQUERY_MAX_ROW_SIZE_EXCEEDED = 2; - */ - const BIGQUERY_MAX_ROW_SIZE_EXCEEDED = 2; - /** - * This will be set when there is a finding in the custom metadata of a file, - * but at the write time of the transformed file, this key / value pair is - * unretrievable. - * - * Generated from protobuf enum METADATA_UNRETRIEVABLE = 3; - */ - const METADATA_UNRETRIEVABLE = 3; - /** - * This will be set when the transformation and storing of it is successful. - * - * Generated from protobuf enum SUCCESS = 4; - */ - const SUCCESS = 4; - - private static $valueToName = [ - self::STATE_TYPE_UNSPECIFIED => 'STATE_TYPE_UNSPECIFIED', - self::INVALID_TRANSFORM => 'INVALID_TRANSFORM', - self::BIGQUERY_MAX_ROW_SIZE_EXCEEDED => 'BIGQUERY_MAX_ROW_SIZE_EXCEEDED', - self::METADATA_UNRETRIEVABLE => 'METADATA_UNRETRIEVABLE', - self::SUCCESS => 'SUCCESS', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary.php deleted file mode 100644 index 04cfa3e5e049..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary.php +++ /dev/null @@ -1,321 +0,0 @@ -google.privacy.dlp.v2.TransformationSummary - */ -class TransformationSummary extends \Google\Protobuf\Internal\Message -{ - /** - * Set if the transformation was limited to a specific InfoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - */ - protected $info_type = null; - /** - * Set if the transformation was limited to a specific FieldId. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 2; - */ - protected $field = null; - /** - * The specific transformation these stats apply to. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation transformation = 3; - */ - protected $transformation = null; - /** - * The field transformation that was applied. - * If multiple field transformations are requested for a single field, - * this list will contain all of them; otherwise, only one is supplied. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldTransformation field_transformations = 5; - */ - private $field_transformations; - /** - * The specific suppression option these stats apply to. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordSuppression record_suppress = 6; - */ - protected $record_suppress = null; - /** - * Collection of all transformations that took place or had an error. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationSummary.SummaryResult results = 4; - */ - private $results; - /** - * Total size in bytes that were transformed in some way. - * - * Generated from protobuf field int64 transformed_bytes = 7; - */ - protected $transformed_bytes = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\InfoType $info_type - * Set if the transformation was limited to a specific InfoType. - * @type \Google\Cloud\Dlp\V2\FieldId $field - * Set if the transformation was limited to a specific FieldId. - * @type \Google\Cloud\Dlp\V2\PrimitiveTransformation $transformation - * The specific transformation these stats apply to. - * @type array<\Google\Cloud\Dlp\V2\FieldTransformation>|\Google\Protobuf\Internal\RepeatedField $field_transformations - * The field transformation that was applied. - * If multiple field transformations are requested for a single field, - * this list will contain all of them; otherwise, only one is supplied. - * @type \Google\Cloud\Dlp\V2\RecordSuppression $record_suppress - * The specific suppression option these stats apply to. - * @type array<\Google\Cloud\Dlp\V2\TransformationSummary\SummaryResult>|\Google\Protobuf\Internal\RepeatedField $results - * Collection of all transformations that took place or had an error. - * @type int|string $transformed_bytes - * Total size in bytes that were transformed in some way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Set if the transformation was limited to a specific InfoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @return \Google\Cloud\Dlp\V2\InfoType|null - */ - public function getInfoType() - { - return $this->info_type; - } - - public function hasInfoType() - { - return isset($this->info_type); - } - - public function clearInfoType() - { - unset($this->info_type); - } - - /** - * Set if the transformation was limited to a specific InfoType. - * - * Generated from protobuf field .google.privacy.dlp.v2.InfoType info_type = 1; - * @param \Google\Cloud\Dlp\V2\InfoType $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InfoType::class); - $this->info_type = $var; - - return $this; - } - - /** - * Set if the transformation was limited to a specific FieldId. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 2; - * @return \Google\Cloud\Dlp\V2\FieldId|null - */ - public function getField() - { - return $this->field; - } - - public function hasField() - { - return isset($this->field); - } - - public function clearField() - { - unset($this->field); - } - - /** - * Set if the transformation was limited to a specific FieldId. - * - * Generated from protobuf field .google.privacy.dlp.v2.FieldId field = 2; - * @param \Google\Cloud\Dlp\V2\FieldId $var - * @return $this - */ - public function setField($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\FieldId::class); - $this->field = $var; - - return $this; - } - - /** - * The specific transformation these stats apply to. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation transformation = 3; - * @return \Google\Cloud\Dlp\V2\PrimitiveTransformation|null - */ - public function getTransformation() - { - return $this->transformation; - } - - public function hasTransformation() - { - return isset($this->transformation); - } - - public function clearTransformation() - { - unset($this->transformation); - } - - /** - * The specific transformation these stats apply to. - * - * Generated from protobuf field .google.privacy.dlp.v2.PrimitiveTransformation transformation = 3; - * @param \Google\Cloud\Dlp\V2\PrimitiveTransformation $var - * @return $this - */ - public function setTransformation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrimitiveTransformation::class); - $this->transformation = $var; - - return $this; - } - - /** - * The field transformation that was applied. - * If multiple field transformations are requested for a single field, - * this list will contain all of them; otherwise, only one is supplied. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldTransformation field_transformations = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFieldTransformations() - { - return $this->field_transformations; - } - - /** - * The field transformation that was applied. - * If multiple field transformations are requested for a single field, - * this list will contain all of them; otherwise, only one is supplied. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.FieldTransformation field_transformations = 5; - * @param array<\Google\Cloud\Dlp\V2\FieldTransformation>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFieldTransformations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\FieldTransformation::class); - $this->field_transformations = $arr; - - return $this; - } - - /** - * The specific suppression option these stats apply to. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordSuppression record_suppress = 6; - * @return \Google\Cloud\Dlp\V2\RecordSuppression|null - */ - public function getRecordSuppress() - { - return $this->record_suppress; - } - - public function hasRecordSuppress() - { - return isset($this->record_suppress); - } - - public function clearRecordSuppress() - { - unset($this->record_suppress); - } - - /** - * The specific suppression option these stats apply to. - * - * Generated from protobuf field .google.privacy.dlp.v2.RecordSuppression record_suppress = 6; - * @param \Google\Cloud\Dlp\V2\RecordSuppression $var - * @return $this - */ - public function setRecordSuppress($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\RecordSuppression::class); - $this->record_suppress = $var; - - return $this; - } - - /** - * Collection of all transformations that took place or had an error. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationSummary.SummaryResult results = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getResults() - { - return $this->results; - } - - /** - * Collection of all transformations that took place or had an error. - * - * Generated from protobuf field repeated .google.privacy.dlp.v2.TransformationSummary.SummaryResult results = 4; - * @param array<\Google\Cloud\Dlp\V2\TransformationSummary\SummaryResult>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\TransformationSummary\SummaryResult::class); - $this->results = $arr; - - return $this; - } - - /** - * Total size in bytes that were transformed in some way. - * - * Generated from protobuf field int64 transformed_bytes = 7; - * @return int|string - */ - public function getTransformedBytes() - { - return $this->transformed_bytes; - } - - /** - * Total size in bytes that were transformed in some way. - * - * Generated from protobuf field int64 transformed_bytes = 7; - * @param int|string $var - * @return $this - */ - public function setTransformedBytes($var) - { - GPBUtil::checkInt64($var); - $this->transformed_bytes = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/SummaryResult.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/SummaryResult.php deleted file mode 100644 index fc99bcd54c85..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/SummaryResult.php +++ /dev/null @@ -1,143 +0,0 @@ -google.privacy.dlp.v2.TransformationSummary.SummaryResult - */ -class SummaryResult extends \Google\Protobuf\Internal\Message -{ - /** - * Number of transformations counted by this result. - * - * Generated from protobuf field int64 count = 1; - */ - protected $count = 0; - /** - * Outcome of the transformation. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationSummary.TransformationResultCode code = 2; - */ - protected $code = 0; - /** - * A place for warnings or errors to show up if a transformation didn't - * work as expected. - * - * Generated from protobuf field string details = 3; - */ - protected $details = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $count - * Number of transformations counted by this result. - * @type int $code - * Outcome of the transformation. - * @type string $details - * A place for warnings or errors to show up if a transformation didn't - * work as expected. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Number of transformations counted by this result. - * - * Generated from protobuf field int64 count = 1; - * @return int|string - */ - public function getCount() - { - return $this->count; - } - - /** - * Number of transformations counted by this result. - * - * Generated from protobuf field int64 count = 1; - * @param int|string $var - * @return $this - */ - public function setCount($var) - { - GPBUtil::checkInt64($var); - $this->count = $var; - - return $this; - } - - /** - * Outcome of the transformation. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationSummary.TransformationResultCode code = 2; - * @return int - */ - public function getCode() - { - return $this->code; - } - - /** - * Outcome of the transformation. - * - * Generated from protobuf field .google.privacy.dlp.v2.TransformationSummary.TransformationResultCode code = 2; - * @param int $var - * @return $this - */ - public function setCode($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Dlp\V2\TransformationSummary\TransformationResultCode::class); - $this->code = $var; - - return $this; - } - - /** - * A place for warnings or errors to show up if a transformation didn't - * work as expected. - * - * Generated from protobuf field string details = 3; - * @return string - */ - public function getDetails() - { - return $this->details; - } - - /** - * A place for warnings or errors to show up if a transformation didn't - * work as expected. - * - * Generated from protobuf field string details = 3; - * @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(SummaryResult::class, \Google\Cloud\Dlp\V2\TransformationSummary_SummaryResult::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/TransformationResultCode.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/TransformationResultCode.php deleted file mode 100644 index e2f82e986ca2..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationSummary/TransformationResultCode.php +++ /dev/null @@ -1,64 +0,0 @@ -google.privacy.dlp.v2.TransformationSummary.TransformationResultCode - */ -class TransformationResultCode -{ - /** - * Unused - * - * Generated from protobuf enum TRANSFORMATION_RESULT_CODE_UNSPECIFIED = 0; - */ - const TRANSFORMATION_RESULT_CODE_UNSPECIFIED = 0; - /** - * Transformation completed without an error. - * - * Generated from protobuf enum SUCCESS = 1; - */ - const SUCCESS = 1; - /** - * Transformation had an error. - * - * Generated from protobuf enum ERROR = 2; - */ - const ERROR = 2; - - private static $valueToName = [ - self::TRANSFORMATION_RESULT_CODE_UNSPECIFIED => 'TRANSFORMATION_RESULT_CODE_UNSPECIFIED', - self::SUCCESS => 'SUCCESS', - self::ERROR => 'ERROR', - ]; - - 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(TransformationResultCode::class, \Google\Cloud\Dlp\V2\TransformationSummary_TransformationResultCode::class); - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationType.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationType.php deleted file mode 100644 index 0bff43bdcf5e..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransformationType.php +++ /dev/null @@ -1,147 +0,0 @@ -google.privacy.dlp.v2.TransformationType - */ -class TransformationType -{ - /** - * Unused - * - * Generated from protobuf enum TRANSFORMATION_TYPE_UNSPECIFIED = 0; - */ - const TRANSFORMATION_TYPE_UNSPECIFIED = 0; - /** - * Record suppression - * - * Generated from protobuf enum RECORD_SUPPRESSION = 1; - */ - const RECORD_SUPPRESSION = 1; - /** - * Replace value - * - * Generated from protobuf enum REPLACE_VALUE = 2; - */ - const REPLACE_VALUE = 2; - /** - * Replace value using a dictionary. - * - * Generated from protobuf enum REPLACE_DICTIONARY = 15; - */ - const REPLACE_DICTIONARY = 15; - /** - * Redact - * - * Generated from protobuf enum REDACT = 3; - */ - const REDACT = 3; - /** - * Character mask - * - * Generated from protobuf enum CHARACTER_MASK = 4; - */ - const CHARACTER_MASK = 4; - /** - * FFX-FPE - * - * Generated from protobuf enum CRYPTO_REPLACE_FFX_FPE = 5; - */ - const CRYPTO_REPLACE_FFX_FPE = 5; - /** - * Fixed size bucketing - * - * Generated from protobuf enum FIXED_SIZE_BUCKETING = 6; - */ - const FIXED_SIZE_BUCKETING = 6; - /** - * Bucketing - * - * Generated from protobuf enum BUCKETING = 7; - */ - const BUCKETING = 7; - /** - * Replace with info type - * - * Generated from protobuf enum REPLACE_WITH_INFO_TYPE = 8; - */ - const REPLACE_WITH_INFO_TYPE = 8; - /** - * Time part - * - * Generated from protobuf enum TIME_PART = 9; - */ - const TIME_PART = 9; - /** - * Crypto hash - * - * Generated from protobuf enum CRYPTO_HASH = 10; - */ - const CRYPTO_HASH = 10; - /** - * Date shift - * - * Generated from protobuf enum DATE_SHIFT = 12; - */ - const DATE_SHIFT = 12; - /** - * Deterministic crypto - * - * Generated from protobuf enum CRYPTO_DETERMINISTIC_CONFIG = 13; - */ - const CRYPTO_DETERMINISTIC_CONFIG = 13; - /** - * Redact image - * - * Generated from protobuf enum REDACT_IMAGE = 14; - */ - const REDACT_IMAGE = 14; - - private static $valueToName = [ - self::TRANSFORMATION_TYPE_UNSPECIFIED => 'TRANSFORMATION_TYPE_UNSPECIFIED', - self::RECORD_SUPPRESSION => 'RECORD_SUPPRESSION', - self::REPLACE_VALUE => 'REPLACE_VALUE', - self::REPLACE_DICTIONARY => 'REPLACE_DICTIONARY', - self::REDACT => 'REDACT', - self::CHARACTER_MASK => 'CHARACTER_MASK', - self::CRYPTO_REPLACE_FFX_FPE => 'CRYPTO_REPLACE_FFX_FPE', - self::FIXED_SIZE_BUCKETING => 'FIXED_SIZE_BUCKETING', - self::BUCKETING => 'BUCKETING', - self::REPLACE_WITH_INFO_TYPE => 'REPLACE_WITH_INFO_TYPE', - self::TIME_PART => 'TIME_PART', - self::CRYPTO_HASH => 'CRYPTO_HASH', - self::DATE_SHIFT => 'DATE_SHIFT', - self::CRYPTO_DETERMINISTIC_CONFIG => 'CRYPTO_DETERMINISTIC_CONFIG', - self::REDACT_IMAGE => 'REDACT_IMAGE', - ]; - - 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransientCryptoKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransientCryptoKey.php deleted file mode 100644 index d489aa9fe140..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/TransientCryptoKey.php +++ /dev/null @@ -1,88 +0,0 @@ -google.privacy.dlp.v2.TransientCryptoKey - */ -class TransientCryptoKey extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the key. - * This is an arbitrary string used to differentiate different keys. - * A unique key is generated per name: two separate `TransientCryptoKey` - * protos share the same generated key if their names are the same. - * When the data crypto key is generated, this name is not used in any way - * (repeating the api call will result in a different key being generated). - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the key. - * This is an arbitrary string used to differentiate different keys. - * A unique key is generated per name: two separate `TransientCryptoKey` - * protos share the same generated key if their names are the same. - * When the data crypto key is generated, this name is not used in any way - * (repeating the api call will result in a different key being generated). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the key. - * This is an arbitrary string used to differentiate different keys. - * A unique key is generated per name: two separate `TransientCryptoKey` - * protos share the same generated key if their names are the same. - * When the data crypto key is generated, this name is not used in any way - * (repeating the api call will result in a different key being generated). - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the key. - * This is an arbitrary string used to differentiate different keys. - * A unique key is generated per name: two separate `TransientCryptoKey` - * protos share the same generated key if their names are the same. - * When the data crypto key is generated, this name is not used in any way - * (repeating the api call will result in a different key being generated). - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UniquenessScoreLevel.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UniquenessScoreLevel.php deleted file mode 100644 index 32a233f41645..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UniquenessScoreLevel.php +++ /dev/null @@ -1,72 +0,0 @@ -google.privacy.dlp.v2.UniquenessScoreLevel - */ -class UniquenessScoreLevel -{ - /** - * Some columns do not have estimated uniqueness. Possible reasons include - * having too few values. - * - * Generated from protobuf enum UNIQUENESS_SCORE_LEVEL_UNSPECIFIED = 0; - */ - const UNIQUENESS_SCORE_LEVEL_UNSPECIFIED = 0; - /** - * Low uniqueness, possibly a boolean, enum or similiarly typed column. - * - * Generated from protobuf enum UNIQUENESS_SCORE_LOW = 1; - */ - const UNIQUENESS_SCORE_LOW = 1; - /** - * Medium uniqueness. - * - * Generated from protobuf enum UNIQUENESS_SCORE_MEDIUM = 2; - */ - const UNIQUENESS_SCORE_MEDIUM = 2; - /** - * High uniqueness, possibly a column of free text or unique identifiers. - * - * Generated from protobuf enum UNIQUENESS_SCORE_HIGH = 3; - */ - const UNIQUENESS_SCORE_HIGH = 3; - - private static $valueToName = [ - self::UNIQUENESS_SCORE_LEVEL_UNSPECIFIED => 'UNIQUENESS_SCORE_LEVEL_UNSPECIFIED', - self::UNIQUENESS_SCORE_LOW => 'UNIQUENESS_SCORE_LOW', - self::UNIQUENESS_SCORE_MEDIUM => 'UNIQUENESS_SCORE_MEDIUM', - self::UNIQUENESS_SCORE_HIGH => 'UNIQUENESS_SCORE_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); - } -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UnwrappedCryptoKey.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UnwrappedCryptoKey.php deleted file mode 100644 index 5fc83b85b802..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UnwrappedCryptoKey.php +++ /dev/null @@ -1,68 +0,0 @@ -google.privacy.dlp.v2.UnwrappedCryptoKey - */ -class UnwrappedCryptoKey extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A 128/192/256 bit key. - * - * Generated from protobuf field bytes key = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $key = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $key - * Required. A 128/192/256 bit key. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. A 128/192/256 bit key. - * - * Generated from protobuf field bytes key = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getKey() - { - return $this->key; - } - - /** - * Required. A 128/192/256 bit key. - * - * Generated from protobuf field bytes key = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setKey($var) - { - GPBUtil::checkString($var, False); - $this->key = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateConnectionRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateConnectionRequest.php deleted file mode 100644 index 71462dea509e..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateConnectionRequest.php +++ /dev/null @@ -1,174 +0,0 @@ -google.privacy.dlp.v2.UpdateConnectionRequest - */ -class UpdateConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The connection with new values for the relevant fields. - * - * Generated from protobuf field .google.privacy.dlp.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $connection = null; - /** - * Optional. Mask to control which fields get updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $update_mask = null; - - /** - * @param string $name Required. Resource name in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. Please see - * {@see DlpServiceClient::connectionName()} for help formatting this field. - * - * @return \Google\Cloud\Dlp\V2\UpdateConnectionRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * @type \Google\Cloud\Dlp\V2\Connection $connection - * Required. The connection with new values for the relevant fields. - * @type \Google\Protobuf\FieldMask $update_mask - * Optional. Mask to control which fields get updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * - * 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; - } - - /** - * Required. The connection with new values for the relevant fields. - * - * Generated from protobuf field .google.privacy.dlp.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\Connection|null - */ - public function getConnection() - { - return $this->connection; - } - - public function hasConnection() - { - return isset($this->connection); - } - - public function clearConnection() - { - unset($this->connection); - } - - /** - * Required. The connection with new values for the relevant fields. - * - * Generated from protobuf field .google.privacy.dlp.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\Connection $var - * @return $this - */ - public function setConnection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Connection::class); - $this->connection = $var; - - return $this; - } - - /** - * Optional. Mask to control which fields get updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @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); - } - - /** - * Optional. Mask to control which fields get updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDeidentifyTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDeidentifyTemplateRequest.php deleted file mode 100644 index 5a3369b76e63..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDeidentifyTemplateRequest.php +++ /dev/null @@ -1,188 +0,0 @@ -google.privacy.dlp.v2.UpdateDeidentifyTemplateRequest - */ -class UpdateDeidentifyTemplateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of organization and deidentify template to be - * updated, for example - * `organizations/433245324/deidentifyTemplates/432452342` or - * projects/project-id/deidentifyTemplates/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * New DeidentifyTemplate value. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate deidentify_template = 2; - */ - protected $deidentify_template = null; - /** - * Mask to control which fields get updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; - */ - protected $update_mask = null; - - /** - * @param string $name Required. Resource name of organization and deidentify template to be - * updated, for example - * `organizations/433245324/deidentifyTemplates/432452342` or - * projects/project-id/deidentifyTemplates/432452342. Please see - * {@see DlpServiceClient::deidentifyTemplateName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $deidentifyTemplate New DeidentifyTemplate value. - * @param \Google\Protobuf\FieldMask $updateMask Mask to control which fields get updated. - * - * @return \Google\Cloud\Dlp\V2\UpdateDeidentifyTemplateRequest - * - * @experimental - */ - public static function build(string $name, \Google\Cloud\Dlp\V2\DeidentifyTemplate $deidentifyTemplate, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setName($name) - ->setDeidentifyTemplate($deidentifyTemplate) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of organization and deidentify template to be - * updated, for example - * `organizations/433245324/deidentifyTemplates/432452342` or - * projects/project-id/deidentifyTemplates/432452342. - * @type \Google\Cloud\Dlp\V2\DeidentifyTemplate $deidentify_template - * New DeidentifyTemplate value. - * @type \Google\Protobuf\FieldMask $update_mask - * Mask to control which fields get updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of organization and deidentify template to be - * updated, for example - * `organizations/433245324/deidentifyTemplates/432452342` or - * projects/project-id/deidentifyTemplates/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of organization and deidentify template to be - * updated, for example - * `organizations/433245324/deidentifyTemplates/432452342` or - * projects/project-id/deidentifyTemplates/432452342. - * - * 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; - } - - /** - * New DeidentifyTemplate value. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate deidentify_template = 2; - * @return \Google\Cloud\Dlp\V2\DeidentifyTemplate|null - */ - public function getDeidentifyTemplate() - { - return $this->deidentify_template; - } - - public function hasDeidentifyTemplate() - { - return isset($this->deidentify_template); - } - - public function clearDeidentifyTemplate() - { - unset($this->deidentify_template); - } - - /** - * New DeidentifyTemplate value. - * - * Generated from protobuf field .google.privacy.dlp.v2.DeidentifyTemplate deidentify_template = 2; - * @param \Google\Cloud\Dlp\V2\DeidentifyTemplate $var - * @return $this - */ - public function setDeidentifyTemplate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DeidentifyTemplate::class); - $this->deidentify_template = $var; - - return $this; - } - - /** - * Mask to control which fields get updated. - * - * 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); - } - - /** - * Mask to control which fields get updated. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDiscoveryConfigRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDiscoveryConfigRequest.php deleted file mode 100644 index 90b9eda83aa7..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateDiscoveryConfigRequest.php +++ /dev/null @@ -1,178 +0,0 @@ -google.privacy.dlp.v2.UpdateDiscoveryConfigRequest - */ -class UpdateDiscoveryConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the project and the configuration, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. New DiscoveryConfig value. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $discovery_config = null; - /** - * Mask to control which fields get updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; - */ - protected $update_mask = null; - - /** - * @param string $name Required. Resource name of the project and the configuration, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. Please see - * {@see DlpServiceClient::discoveryConfigName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\DiscoveryConfig $discoveryConfig Required. New DiscoveryConfig value. - * @param \Google\Protobuf\FieldMask $updateMask Mask to control which fields get updated. - * - * @return \Google\Cloud\Dlp\V2\UpdateDiscoveryConfigRequest - * - * @experimental - */ - public static function build(string $name, \Google\Cloud\Dlp\V2\DiscoveryConfig $discoveryConfig, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setName($name) - ->setDiscoveryConfig($discoveryConfig) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the project and the configuration, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * @type \Google\Cloud\Dlp\V2\DiscoveryConfig $discovery_config - * Required. New DiscoveryConfig value. - * @type \Google\Protobuf\FieldMask $update_mask - * Mask to control which fields get updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the project and the configuration, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the project and the configuration, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * - * 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; - } - - /** - * Required. New DiscoveryConfig value. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Dlp\V2\DiscoveryConfig|null - */ - public function getDiscoveryConfig() - { - return $this->discovery_config; - } - - public function hasDiscoveryConfig() - { - return isset($this->discovery_config); - } - - public function clearDiscoveryConfig() - { - unset($this->discovery_config); - } - - /** - * Required. New DiscoveryConfig value. - * - * Generated from protobuf field .google.privacy.dlp.v2.DiscoveryConfig discovery_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Dlp\V2\DiscoveryConfig $var - * @return $this - */ - public function setDiscoveryConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\DiscoveryConfig::class); - $this->discovery_config = $var; - - return $this; - } - - /** - * Mask to control which fields get updated. - * - * 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); - } - - /** - * Mask to control which fields get updated. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateInspectTemplateRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateInspectTemplateRequest.php deleted file mode 100644 index 9333298d1856..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateInspectTemplateRequest.php +++ /dev/null @@ -1,183 +0,0 @@ -google.privacy.dlp.v2.UpdateInspectTemplateRequest - */ -class UpdateInspectTemplateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of organization and inspectTemplate to be updated, - * for example `organizations/433245324/inspectTemplates/432452342` or - * projects/project-id/inspectTemplates/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * New InspectTemplate value. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate inspect_template = 2; - */ - protected $inspect_template = null; - /** - * Mask to control which fields get updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; - */ - protected $update_mask = null; - - /** - * @param string $name Required. Resource name of organization and inspectTemplate to be updated, - * for example `organizations/433245324/inspectTemplates/432452342` or - * projects/project-id/inspectTemplates/432452342. Please see - * {@see DlpServiceClient::inspectTemplateName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\InspectTemplate $inspectTemplate New InspectTemplate value. - * @param \Google\Protobuf\FieldMask $updateMask Mask to control which fields get updated. - * - * @return \Google\Cloud\Dlp\V2\UpdateInspectTemplateRequest - * - * @experimental - */ - public static function build(string $name, \Google\Cloud\Dlp\V2\InspectTemplate $inspectTemplate, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setName($name) - ->setInspectTemplate($inspectTemplate) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of organization and inspectTemplate to be updated, - * for example `organizations/433245324/inspectTemplates/432452342` or - * projects/project-id/inspectTemplates/432452342. - * @type \Google\Cloud\Dlp\V2\InspectTemplate $inspect_template - * New InspectTemplate value. - * @type \Google\Protobuf\FieldMask $update_mask - * Mask to control which fields get updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of organization and inspectTemplate to be updated, - * for example `organizations/433245324/inspectTemplates/432452342` or - * projects/project-id/inspectTemplates/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of organization and inspectTemplate to be updated, - * for example `organizations/433245324/inspectTemplates/432452342` or - * projects/project-id/inspectTemplates/432452342. - * - * 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; - } - - /** - * New InspectTemplate value. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate inspect_template = 2; - * @return \Google\Cloud\Dlp\V2\InspectTemplate|null - */ - public function getInspectTemplate() - { - return $this->inspect_template; - } - - public function hasInspectTemplate() - { - return isset($this->inspect_template); - } - - public function clearInspectTemplate() - { - unset($this->inspect_template); - } - - /** - * New InspectTemplate value. - * - * Generated from protobuf field .google.privacy.dlp.v2.InspectTemplate inspect_template = 2; - * @param \Google\Cloud\Dlp\V2\InspectTemplate $var - * @return $this - */ - public function setInspectTemplate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectTemplate::class); - $this->inspect_template = $var; - - return $this; - } - - /** - * Mask to control which fields get updated. - * - * 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); - } - - /** - * Mask to control which fields get updated. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateJobTriggerRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateJobTriggerRequest.php deleted file mode 100644 index faa41ba7a46a..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateJobTriggerRequest.php +++ /dev/null @@ -1,178 +0,0 @@ -google.privacy.dlp.v2.UpdateJobTriggerRequest - */ -class UpdateJobTriggerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * New JobTrigger value. - * - * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger job_trigger = 2; - */ - protected $job_trigger = null; - /** - * Mask to control which fields get updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; - */ - protected $update_mask = null; - - /** - * @param string $name Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. Please see - * {@see DlpServiceClient::jobTriggerName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\JobTrigger $jobTrigger New JobTrigger value. - * @param \Google\Protobuf\FieldMask $updateMask Mask to control which fields get updated. - * - * @return \Google\Cloud\Dlp\V2\UpdateJobTriggerRequest - * - * @experimental - */ - public static function build(string $name, \Google\Cloud\Dlp\V2\JobTrigger $jobTrigger, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setName($name) - ->setJobTrigger($jobTrigger) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * @type \Google\Cloud\Dlp\V2\JobTrigger $job_trigger - * New JobTrigger value. - * @type \Google\Protobuf\FieldMask $update_mask - * Mask to control which fields get updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * - * 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; - } - - /** - * New JobTrigger value. - * - * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger job_trigger = 2; - * @return \Google\Cloud\Dlp\V2\JobTrigger|null - */ - public function getJobTrigger() - { - return $this->job_trigger; - } - - public function hasJobTrigger() - { - return isset($this->job_trigger); - } - - public function clearJobTrigger() - { - unset($this->job_trigger); - } - - /** - * New JobTrigger value. - * - * Generated from protobuf field .google.privacy.dlp.v2.JobTrigger job_trigger = 2; - * @param \Google\Cloud\Dlp\V2\JobTrigger $var - * @return $this - */ - public function setJobTrigger($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\JobTrigger::class); - $this->job_trigger = $var; - - return $this; - } - - /** - * Mask to control which fields get updated. - * - * 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); - } - - /** - * Mask to control which fields get updated. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateStoredInfoTypeRequest.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateStoredInfoTypeRequest.php deleted file mode 100644 index 65cf0b18fe2b..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/UpdateStoredInfoTypeRequest.php +++ /dev/null @@ -1,193 +0,0 @@ -google.privacy.dlp.v2.UpdateStoredInfoTypeRequest - */ -class UpdateStoredInfoTypeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of organization and storedInfoType to be updated, - * for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Updated configuration for the storedInfoType. If not provided, a new - * version of the storedInfoType will be created with the existing - * configuration. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 2; - */ - protected $config = null; - /** - * Mask to control which fields get updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 3; - */ - protected $update_mask = null; - - /** - * @param string $name Required. Resource name of organization and storedInfoType to be updated, - * for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. Please see - * {@see DlpServiceClient::storedInfoTypeName()} for help formatting this field. - * @param \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config Updated configuration for the storedInfoType. If not provided, a new - * version of the storedInfoType will be created with the existing - * configuration. - * @param \Google\Protobuf\FieldMask $updateMask Mask to control which fields get updated. - * - * @return \Google\Cloud\Dlp\V2\UpdateStoredInfoTypeRequest - * - * @experimental - */ - public static function build(string $name, \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setName($name) - ->setConfig($config) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of organization and storedInfoType to be updated, - * for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * @type \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $config - * Updated configuration for the storedInfoType. If not provided, a new - * version of the storedInfoType will be created with the existing - * configuration. - * @type \Google\Protobuf\FieldMask $update_mask - * Mask to control which fields get updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of organization and storedInfoType to be updated, - * for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of organization and storedInfoType to be updated, - * for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * - * 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; - } - - /** - * Updated configuration for the storedInfoType. If not provided, a new - * version of the storedInfoType will be created with the existing - * configuration. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 2; - * @return \Google\Cloud\Dlp\V2\StoredInfoTypeConfig|null - */ - public function getConfig() - { - return $this->config; - } - - public function hasConfig() - { - return isset($this->config); - } - - public function clearConfig() - { - unset($this->config); - } - - /** - * Updated configuration for the storedInfoType. If not provided, a new - * version of the storedInfoType will be created with the existing - * configuration. - * - * Generated from protobuf field .google.privacy.dlp.v2.StoredInfoTypeConfig config = 2; - * @param \Google\Cloud\Dlp\V2\StoredInfoTypeConfig $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\StoredInfoTypeConfig::class); - $this->config = $var; - - return $this; - } - - /** - * Mask to control which fields get updated. - * - * 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); - } - - /** - * Mask to control which fields get updated. - * - * 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/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Value.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Value.php deleted file mode 100644 index d32ec7e852e8..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/Value.php +++ /dev/null @@ -1,311 +0,0 @@ -google.privacy.dlp.v2.Value - */ -class Value extends \Google\Protobuf\Internal\Message -{ - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $integer_value - * integer - * @type float $float_value - * float - * @type string $string_value - * string - * @type bool $boolean_value - * boolean - * @type \Google\Protobuf\Timestamp $timestamp_value - * timestamp - * @type \Google\Type\TimeOfDay $time_value - * time of day - * @type \Google\Type\Date $date_value - * date - * @type int $day_of_week_value - * day of week - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * integer - * - * Generated from protobuf field int64 integer_value = 1; - * @return int|string - */ - public function getIntegerValue() - { - return $this->readOneof(1); - } - - public function hasIntegerValue() - { - return $this->hasOneof(1); - } - - /** - * integer - * - * Generated from protobuf field int64 integer_value = 1; - * @param int|string $var - * @return $this - */ - public function setIntegerValue($var) - { - GPBUtil::checkInt64($var); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * float - * - * Generated from protobuf field double float_value = 2; - * @return float - */ - public function getFloatValue() - { - return $this->readOneof(2); - } - - public function hasFloatValue() - { - return $this->hasOneof(2); - } - - /** - * float - * - * Generated from protobuf field double float_value = 2; - * @param float $var - * @return $this - */ - public function setFloatValue($var) - { - GPBUtil::checkDouble($var); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * string - * - * Generated from protobuf field string string_value = 3; - * @return string - */ - public function getStringValue() - { - return $this->readOneof(3); - } - - public function hasStringValue() - { - return $this->hasOneof(3); - } - - /** - * string - * - * Generated from protobuf field string string_value = 3; - * @param string $var - * @return $this - */ - public function setStringValue($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * boolean - * - * Generated from protobuf field bool boolean_value = 4; - * @return bool - */ - public function getBooleanValue() - { - return $this->readOneof(4); - } - - public function hasBooleanValue() - { - return $this->hasOneof(4); - } - - /** - * boolean - * - * Generated from protobuf field bool boolean_value = 4; - * @param bool $var - * @return $this - */ - public function setBooleanValue($var) - { - GPBUtil::checkBool($var); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * timestamp - * - * Generated from protobuf field .google.protobuf.Timestamp timestamp_value = 5; - * @return \Google\Protobuf\Timestamp|null - */ - public function getTimestampValue() - { - return $this->readOneof(5); - } - - public function hasTimestampValue() - { - return $this->hasOneof(5); - } - - /** - * timestamp - * - * Generated from protobuf field .google.protobuf.Timestamp timestamp_value = 5; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setTimestampValue($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * time of day - * - * Generated from protobuf field .google.type.TimeOfDay time_value = 6; - * @return \Google\Type\TimeOfDay|null - */ - public function getTimeValue() - { - return $this->readOneof(6); - } - - public function hasTimeValue() - { - return $this->hasOneof(6); - } - - /** - * time of day - * - * Generated from protobuf field .google.type.TimeOfDay time_value = 6; - * @param \Google\Type\TimeOfDay $var - * @return $this - */ - public function setTimeValue($var) - { - GPBUtil::checkMessage($var, \Google\Type\TimeOfDay::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * date - * - * Generated from protobuf field .google.type.Date date_value = 7; - * @return \Google\Type\Date|null - */ - public function getDateValue() - { - return $this->readOneof(7); - } - - public function hasDateValue() - { - return $this->hasOneof(7); - } - - /** - * date - * - * Generated from protobuf field .google.type.Date date_value = 7; - * @param \Google\Type\Date $var - * @return $this - */ - public function setDateValue($var) - { - GPBUtil::checkMessage($var, \Google\Type\Date::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * day of week - * - * Generated from protobuf field .google.type.DayOfWeek day_of_week_value = 8; - * @return int - */ - public function getDayOfWeekValue() - { - return $this->readOneof(8); - } - - public function hasDayOfWeekValue() - { - return $this->hasOneof(8); - } - - /** - * day of week - * - * Generated from protobuf field .google.type.DayOfWeek day_of_week_value = 8; - * @param int $var - * @return $this - */ - public function setDayOfWeekValue($var) - { - GPBUtil::checkEnum($var, \Google\Type\DayOfWeek::class); - $this->writeOneof(8, $var); - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ValueFrequency.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ValueFrequency.php deleted file mode 100644 index 577cbb1ecedf..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/ValueFrequency.php +++ /dev/null @@ -1,111 +0,0 @@ -google.privacy.dlp.v2.ValueFrequency - */ -class ValueFrequency extends \Google\Protobuf\Internal\Message -{ - /** - * A value contained in the field in question. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value value = 1; - */ - protected $value = null; - /** - * How many times the value is contained in the field. - * - * Generated from protobuf field int64 count = 2; - */ - protected $count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Dlp\V2\Value $value - * A value contained in the field in question. - * @type int|string $count - * How many times the value is contained in the field. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * A value contained in the field in question. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value value = 1; - * @return \Google\Cloud\Dlp\V2\Value|null - */ - public function getValue() - { - return $this->value; - } - - public function hasValue() - { - return isset($this->value); - } - - public function clearValue() - { - unset($this->value); - } - - /** - * A value contained in the field in question. - * - * Generated from protobuf field .google.privacy.dlp.v2.Value value = 1; - * @param \Google\Cloud\Dlp\V2\Value $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\Value::class); - $this->value = $var; - - return $this; - } - - /** - * How many times the value is contained in the field. - * - * Generated from protobuf field int64 count = 2; - * @return int|string - */ - public function getCount() - { - return $this->count; - } - - /** - * How many times the value is contained in the field. - * - * Generated from protobuf field int64 count = 2; - * @param int|string $var - * @return $this - */ - public function setCount($var) - { - GPBUtil::checkInt64($var); - $this->count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/VersionDescription.php b/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/VersionDescription.php deleted file mode 100644 index af4ade2c2724..000000000000 --- a/owl-bot-staging/Dlp/v2/proto/src/Google/Cloud/Dlp/V2/VersionDescription.php +++ /dev/null @@ -1,101 +0,0 @@ -google.privacy.dlp.v2.VersionDescription - */ -class VersionDescription extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the version - * - * Generated from protobuf field string version = 1; - */ - protected $version = ''; - /** - * Description of the version. - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $version - * Name of the version - * @type string $description - * Description of the version. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce(); - parent::__construct($data); - } - - /** - * Name of the version - * - * Generated from protobuf field string version = 1; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * Name of the version - * - * Generated from protobuf field string version = 1; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - - /** - * Description of the version. - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Description of the version. - * - * 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; - } - -} - diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/activate_job_trigger.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/activate_job_trigger.php deleted file mode 100644 index 3ac8b7fe7b8a..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/activate_job_trigger.php +++ /dev/null @@ -1,73 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var DlpJob $response */ - $response = $dlpServiceClient->activateJobTrigger($request); - 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 = DlpServiceClient::jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - - activate_job_trigger_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_ActivateJobTrigger_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/cancel_dlp_job.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/cancel_dlp_job.php deleted file mode 100644 index b410e49dfc12..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/cancel_dlp_job.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $dlpServiceClient->cancelDlpJob($request); - 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 = DlpServiceClient::dlpJobName('[PROJECT]', '[DLP_JOB]'); - - cancel_dlp_job_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_CancelDlpJob_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_connection.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_connection.php deleted file mode 100644 index abbf09650f9a..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_connection.php +++ /dev/null @@ -1,78 +0,0 @@ -setState($connectionState); - $request = (new CreateConnectionRequest()) - ->setParent($formattedParent) - ->setConnection($connection); - - // Call the API and handle any network failures. - try { - /** @var Connection $response */ - $response = $dlpServiceClient->createConnection($request); - 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 = DlpServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; - - create_connection_sample($formattedParent, $connectionState); -} -// [END dlp_v2_generated_DlpService_CreateConnection_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_deidentify_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_deidentify_template.php deleted file mode 100644 index d5439ac39162..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_deidentify_template.php +++ /dev/null @@ -1,96 +0,0 @@ - - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - */ -function create_deidentify_template_sample(string $formattedParent): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $deidentifyTemplate = new DeidentifyTemplate(); - $request = (new CreateDeidentifyTemplateRequest()) - ->setParent($formattedParent) - ->setDeidentifyTemplate($deidentifyTemplate); - - // Call the API and handle any network failures. - try { - /** @var DeidentifyTemplate $response */ - $response = $dlpServiceClient->createDeidentifyTemplate($request); - 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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - create_deidentify_template_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_CreateDeidentifyTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_discovery_config.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_discovery_config.php deleted file mode 100644 index 9da45eea0f0f..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_discovery_config.php +++ /dev/null @@ -1,86 +0,0 @@ -PROJECT_ID`/locations/`LOCATION_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::locationName()} for help formatting this field. - * @param int $discoveryConfigStatus A status for this configuration. - */ -function create_discovery_config_sample(string $formattedParent, int $discoveryConfigStatus): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $discoveryConfig = (new DiscoveryConfig()) - ->setStatus($discoveryConfigStatus); - $request = (new CreateDiscoveryConfigRequest()) - ->setParent($formattedParent) - ->setDiscoveryConfig($discoveryConfig); - - // Call the API and handle any network failures. - try { - /** @var DiscoveryConfig $response */ - $response = $dlpServiceClient->createDiscoveryConfig($request); - 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 = DlpServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; - - create_discovery_config_sample($formattedParent, $discoveryConfigStatus); -} -// [END dlp_v2_generated_DlpService_CreateDiscoveryConfig_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_dlp_job.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_dlp_job.php deleted file mode 100644 index 3e997b6520b5..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_dlp_job.php +++ /dev/null @@ -1,95 +0,0 @@ - - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::projectName()} for help formatting this field. - */ -function create_dlp_job_sample(string $formattedParent): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $request = (new CreateDlpJobRequest()) - ->setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var DlpJob $response */ - $response = $dlpServiceClient->createDlpJob($request); - 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 = DlpServiceClient::projectName('[PROJECT]'); - - create_dlp_job_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_CreateDlpJob_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_inspect_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_inspect_template.php deleted file mode 100644 index c9dd64e3fa12..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_inspect_template.php +++ /dev/null @@ -1,96 +0,0 @@ - - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - */ -function create_inspect_template_sample(string $formattedParent): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $inspectTemplate = new InspectTemplate(); - $request = (new CreateInspectTemplateRequest()) - ->setParent($formattedParent) - ->setInspectTemplate($inspectTemplate); - - // Call the API and handle any network failures. - try { - /** @var InspectTemplate $response */ - $response = $dlpServiceClient->createInspectTemplate($request); - 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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - create_inspect_template_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_CreateInspectTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_job_trigger.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_job_trigger.php deleted file mode 100644 index ae8c2c18bea1..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_job_trigger.php +++ /dev/null @@ -1,96 +0,0 @@ - - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::projectName()} for help formatting this field. - * @param int $jobTriggerStatus A status for this trigger. - */ -function create_job_trigger_sample(string $formattedParent, int $jobTriggerStatus): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $jobTrigger = (new JobTrigger()) - ->setStatus($jobTriggerStatus); - $request = (new CreateJobTriggerRequest()) - ->setParent($formattedParent) - ->setJobTrigger($jobTrigger); - - // Call the API and handle any network failures. - try { - /** @var JobTrigger $response */ - $response = $dlpServiceClient->createJobTrigger($request); - 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 = DlpServiceClient::projectName('[PROJECT]'); - $jobTriggerStatus = Status::STATUS_UNSPECIFIED; - - create_job_trigger_sample($formattedParent, $jobTriggerStatus); -} -// [END dlp_v2_generated_DlpService_CreateJobTrigger_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_stored_info_type.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_stored_info_type.php deleted file mode 100644 index 7a0d31df44e8..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/create_stored_info_type.php +++ /dev/null @@ -1,96 +0,0 @@ - - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - */ -function create_stored_info_type_sample(string $formattedParent): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $config = new StoredInfoTypeConfig(); - $request = (new CreateStoredInfoTypeRequest()) - ->setParent($formattedParent) - ->setConfig($config); - - // Call the API and handle any network failures. - try { - /** @var StoredInfoType $response */ - $response = $dlpServiceClient->createStoredInfoType($request); - 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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - create_stored_info_type_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_CreateStoredInfoType_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/deidentify_content.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/deidentify_content.php deleted file mode 100644 index 0ae7367e3e2d..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/deidentify_content.php +++ /dev/null @@ -1,65 +0,0 @@ -deidentifyContent($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END dlp_v2_generated_DlpService_DeidentifyContent_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_connection.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_connection.php deleted file mode 100644 index 13dbad8fcf6d..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_connection.php +++ /dev/null @@ -1,70 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $dlpServiceClient->deleteConnection($request); - 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 = DlpServiceClient::connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - - delete_connection_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_DeleteConnection_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_deidentify_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_deidentify_template.php deleted file mode 100644 index 36870d8af3d8..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_deidentify_template.php +++ /dev/null @@ -1,78 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $dlpServiceClient->deleteDeidentifyTemplate($request); - 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 = DlpServiceClient::deidentifyTemplateName( - '[ORGANIZATION]', - '[DEIDENTIFY_TEMPLATE]' - ); - - delete_deidentify_template_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_DeleteDeidentifyTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_discovery_config.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_discovery_config.php deleted file mode 100644 index 8f5fba101b53..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_discovery_config.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $dlpServiceClient->deleteDiscoveryConfig($request); - 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 = DlpServiceClient::discoveryConfigName( - '[PROJECT]', - '[LOCATION]', - '[DISCOVERY_CONFIG]' - ); - - delete_discovery_config_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_DeleteDiscoveryConfig_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_dlp_job.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_dlp_job.php deleted file mode 100644 index 829b2413c84f..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_dlp_job.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $dlpServiceClient->deleteDlpJob($request); - 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 = DlpServiceClient::dlpJobName('[PROJECT]', '[DLP_JOB]'); - - delete_dlp_job_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_DeleteDlpJob_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_inspect_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_inspect_template.php deleted file mode 100644 index b8fd4bbdb772..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_inspect_template.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $dlpServiceClient->deleteInspectTemplate($request); - 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 = DlpServiceClient::inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - - delete_inspect_template_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_DeleteInspectTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_job_trigger.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_job_trigger.php deleted file mode 100644 index 5660e40af05f..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_job_trigger.php +++ /dev/null @@ -1,73 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $dlpServiceClient->deleteJobTrigger($request); - 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 = DlpServiceClient::jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - - delete_job_trigger_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_DeleteJobTrigger_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_stored_info_type.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_stored_info_type.php deleted file mode 100644 index 48a1cc206f7b..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_stored_info_type.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $dlpServiceClient->deleteStoredInfoType($request); - 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 = DlpServiceClient::storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - - delete_stored_info_type_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_DeleteStoredInfoType_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_table_data_profile.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_table_data_profile.php deleted file mode 100644 index 05e273d94ca0..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/delete_table_data_profile.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $dlpServiceClient->deleteTableDataProfile($request); - 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 = DlpServiceClient::tableDataProfileName( - '[ORGANIZATION]', - '[LOCATION]', - '[TABLE_DATA_PROFILE]' - ); - - delete_table_data_profile_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_DeleteTableDataProfile_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/finish_dlp_job.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/finish_dlp_job.php deleted file mode 100644 index ce0e1c6b5cad..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/finish_dlp_job.php +++ /dev/null @@ -1,70 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $dlpServiceClient->finishDlpJob($request); - 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 = DlpServiceClient::dlpJobName('[PROJECT]', '[DLP_JOB]'); - - finish_dlp_job_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_FinishDlpJob_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_column_data_profile.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_column_data_profile.php deleted file mode 100644 index 1ff5cabcb1f6..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_column_data_profile.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ColumnDataProfile $response */ - $response = $dlpServiceClient->getColumnDataProfile($request); - 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 = DlpServiceClient::columnDataProfileName( - '[ORGANIZATION]', - '[LOCATION]', - '[COLUMN_DATA_PROFILE]' - ); - - get_column_data_profile_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_GetColumnDataProfile_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_connection.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_connection.php deleted file mode 100644 index e5af3e946341..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_connection.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Connection $response */ - $response = $dlpServiceClient->getConnection($request); - 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 = DlpServiceClient::connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - - get_connection_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_GetConnection_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_deidentify_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_deidentify_template.php deleted file mode 100644 index a896ef5090b4..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_deidentify_template.php +++ /dev/null @@ -1,79 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var DeidentifyTemplate $response */ - $response = $dlpServiceClient->getDeidentifyTemplate($request); - 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 = DlpServiceClient::deidentifyTemplateName( - '[ORGANIZATION]', - '[DEIDENTIFY_TEMPLATE]' - ); - - get_deidentify_template_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_GetDeidentifyTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_discovery_config.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_discovery_config.php deleted file mode 100644 index 0eb106a1d567..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_discovery_config.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var DiscoveryConfig $response */ - $response = $dlpServiceClient->getDiscoveryConfig($request); - 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 = DlpServiceClient::discoveryConfigName( - '[PROJECT]', - '[LOCATION]', - '[DISCOVERY_CONFIG]' - ); - - get_discovery_config_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_GetDiscoveryConfig_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_dlp_job.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_dlp_job.php deleted file mode 100644 index a06e53cdf0f6..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_dlp_job.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var DlpJob $response */ - $response = $dlpServiceClient->getDlpJob($request); - 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 = DlpServiceClient::dlpJobName('[PROJECT]', '[DLP_JOB]'); - - get_dlp_job_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_GetDlpJob_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_inspect_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_inspect_template.php deleted file mode 100644 index f5626a183e68..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_inspect_template.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var InspectTemplate $response */ - $response = $dlpServiceClient->getInspectTemplate($request); - 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 = DlpServiceClient::inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - - get_inspect_template_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_GetInspectTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_job_trigger.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_job_trigger.php deleted file mode 100644 index ac5bfce6ed72..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_job_trigger.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var JobTrigger $response */ - $response = $dlpServiceClient->getJobTrigger($request); - 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 = DlpServiceClient::jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - - get_job_trigger_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_GetJobTrigger_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_project_data_profile.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_project_data_profile.php deleted file mode 100644 index 7c1e508c3485..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_project_data_profile.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ProjectDataProfile $response */ - $response = $dlpServiceClient->getProjectDataProfile($request); - 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 = DlpServiceClient::projectDataProfileName( - '[ORGANIZATION]', - '[LOCATION]', - '[PROJECT_DATA_PROFILE]' - ); - - get_project_data_profile_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_GetProjectDataProfile_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_stored_info_type.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_stored_info_type.php deleted file mode 100644 index 6491468fabde..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_stored_info_type.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var StoredInfoType $response */ - $response = $dlpServiceClient->getStoredInfoType($request); - 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 = DlpServiceClient::storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - - get_stored_info_type_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_GetStoredInfoType_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_table_data_profile.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_table_data_profile.php deleted file mode 100644 index 4fddfb768cd8..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/get_table_data_profile.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var TableDataProfile $response */ - $response = $dlpServiceClient->getTableDataProfile($request); - 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 = DlpServiceClient::tableDataProfileName( - '[ORGANIZATION]', - '[LOCATION]', - '[TABLE_DATA_PROFILE]' - ); - - get_table_data_profile_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_GetTableDataProfile_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_dlp_job.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_dlp_job.php deleted file mode 100644 index 70a712699349..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_dlp_job.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var HybridInspectResponse $response */ - $response = $dlpServiceClient->hybridInspectDlpJob($request); - 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 = DlpServiceClient::dlpJobName('[PROJECT]', '[DLP_JOB]'); - - hybrid_inspect_dlp_job_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_HybridInspectDlpJob_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_job_trigger.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_job_trigger.php deleted file mode 100644 index 116810f1d105..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/hybrid_inspect_job_trigger.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var HybridInspectResponse $response */ - $response = $dlpServiceClient->hybridInspectJobTrigger($request); - 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 = DlpServiceClient::jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - - hybrid_inspect_job_trigger_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_HybridInspectJobTrigger_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/inspect_content.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/inspect_content.php deleted file mode 100644 index 164e183c94db..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/inspect_content.php +++ /dev/null @@ -1,67 +0,0 @@ -inspectContent($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END dlp_v2_generated_DlpService_InspectContent_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_column_data_profiles.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_column_data_profiles.php deleted file mode 100644 index a285f12d5096..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_column_data_profiles.php +++ /dev/null @@ -1,78 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dlpServiceClient->listColumnDataProfiles($request); - - /** @var ColumnDataProfile $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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - list_column_data_profiles_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_ListColumnDataProfiles_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_connections.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_connections.php deleted file mode 100644 index 31cee6928593..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_connections.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dlpServiceClient->listConnections($request); - - /** @var Connection $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 = DlpServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_connections_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_ListConnections_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_deidentify_templates.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_deidentify_templates.php deleted file mode 100644 index e3a467950c3f..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_deidentify_templates.php +++ /dev/null @@ -1,98 +0,0 @@ - - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - */ -function list_deidentify_templates_sample(string $formattedParent): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $request = (new ListDeidentifyTemplatesRequest()) - ->setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dlpServiceClient->listDeidentifyTemplates($request); - - /** @var DeidentifyTemplate $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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - list_deidentify_templates_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_ListDeidentifyTemplates_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_discovery_configs.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_discovery_configs.php deleted file mode 100644 index accf03e2f512..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_discovery_configs.php +++ /dev/null @@ -1,85 +0,0 @@ -PROJECT_ID`/locations/`LOCATION_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::locationName()} for help formatting this field. - */ -function list_discovery_configs_sample(string $formattedParent): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $request = (new ListDiscoveryConfigsRequest()) - ->setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dlpServiceClient->listDiscoveryConfigs($request); - - /** @var DiscoveryConfig $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 = DlpServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_discovery_configs_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_ListDiscoveryConfigs_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_dlp_jobs.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_dlp_jobs.php deleted file mode 100644 index 43ad531dae5d..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_dlp_jobs.php +++ /dev/null @@ -1,96 +0,0 @@ - - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::projectName()} for help formatting this field. - */ -function list_dlp_jobs_sample(string $formattedParent): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $request = (new ListDlpJobsRequest()) - ->setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dlpServiceClient->listDlpJobs($request); - - /** @var DlpJob $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 = DlpServiceClient::projectName('[PROJECT]'); - - list_dlp_jobs_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_ListDlpJobs_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_info_types.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_info_types.php deleted file mode 100644 index 3ba2a2be6eaf..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_info_types.php +++ /dev/null @@ -1,60 +0,0 @@ -listInfoTypes($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END dlp_v2_generated_DlpService_ListInfoTypes_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_inspect_templates.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_inspect_templates.php deleted file mode 100644 index 538de701a50b..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_inspect_templates.php +++ /dev/null @@ -1,98 +0,0 @@ - - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - */ -function list_inspect_templates_sample(string $formattedParent): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $request = (new ListInspectTemplatesRequest()) - ->setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dlpServiceClient->listInspectTemplates($request); - - /** @var InspectTemplate $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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - list_inspect_templates_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_ListInspectTemplates_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_job_triggers.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_job_triggers.php deleted file mode 100644 index 6f75c9282169..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_job_triggers.php +++ /dev/null @@ -1,94 +0,0 @@ - - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::projectName()} for help formatting this field. - */ -function list_job_triggers_sample(string $formattedParent): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $request = (new ListJobTriggersRequest()) - ->setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dlpServiceClient->listJobTriggers($request); - - /** @var JobTrigger $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 = DlpServiceClient::projectName('[PROJECT]'); - - list_job_triggers_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_ListJobTriggers_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_project_data_profiles.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_project_data_profiles.php deleted file mode 100644 index d5548dedc860..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_project_data_profiles.php +++ /dev/null @@ -1,76 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dlpServiceClient->listProjectDataProfiles($request); - - /** @var ProjectDataProfile $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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - list_project_data_profiles_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_ListProjectDataProfiles_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_stored_info_types.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_stored_info_types.php deleted file mode 100644 index 15de2ce15026..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_stored_info_types.php +++ /dev/null @@ -1,94 +0,0 @@ - - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::organizationLocationName()} for help formatting this field. - */ -function list_stored_info_types_sample(string $formattedParent): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $request = (new ListStoredInfoTypesRequest()) - ->setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dlpServiceClient->listStoredInfoTypes($request); - - /** @var StoredInfoType $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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - list_stored_info_types_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_ListStoredInfoTypes_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_table_data_profiles.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_table_data_profiles.php deleted file mode 100644 index 256859c421db..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/list_table_data_profiles.php +++ /dev/null @@ -1,78 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dlpServiceClient->listTableDataProfiles($request); - - /** @var TableDataProfile $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 = DlpServiceClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - list_table_data_profiles_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_ListTableDataProfiles_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/redact_image.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/redact_image.php deleted file mode 100644 index e8c3b377d874..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/redact_image.php +++ /dev/null @@ -1,65 +0,0 @@ -redactImage($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END dlp_v2_generated_DlpService_RedactImage_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/reidentify_content.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/reidentify_content.php deleted file mode 100644 index 005c337558fb..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/reidentify_content.php +++ /dev/null @@ -1,89 +0,0 @@ - - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * Please see {@see DlpServiceClient::projectName()} for help formatting this field. - */ -function reidentify_content_sample(string $formattedParent): void -{ - // Create a client. - $dlpServiceClient = new DlpServiceClient(); - - // Prepare the request message. - $request = (new ReidentifyContentRequest()) - ->setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var ReidentifyContentResponse $response */ - $response = $dlpServiceClient->reidentifyContent($request); - 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 = DlpServiceClient::projectName('[PROJECT]'); - - reidentify_content_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_ReidentifyContent_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/search_connections.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/search_connections.php deleted file mode 100644 index 8156bf13200e..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/search_connections.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dlpServiceClient->searchConnections($request); - - /** @var Connection $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 = DlpServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - search_connections_sample($formattedParent); -} -// [END dlp_v2_generated_DlpService_SearchConnections_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_connection.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_connection.php deleted file mode 100644 index 05f37b598201..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_connection.php +++ /dev/null @@ -1,78 +0,0 @@ -setState($connectionState); - $request = (new UpdateConnectionRequest()) - ->setName($formattedName) - ->setConnection($connection); - - // Call the API and handle any network failures. - try { - /** @var Connection $response */ - $response = $dlpServiceClient->updateConnection($request); - 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 = DlpServiceClient::connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; - - update_connection_sample($formattedName, $connectionState); -} -// [END dlp_v2_generated_DlpService_UpdateConnection_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_deidentify_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_deidentify_template.php deleted file mode 100644 index 7989fa347c7d..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_deidentify_template.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var DeidentifyTemplate $response */ - $response = $dlpServiceClient->updateDeidentifyTemplate($request); - 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 = DlpServiceClient::deidentifyTemplateName( - '[ORGANIZATION]', - '[DEIDENTIFY_TEMPLATE]' - ); - - update_deidentify_template_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_UpdateDeidentifyTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_discovery_config.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_discovery_config.php deleted file mode 100644 index a815aa24c00b..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_discovery_config.php +++ /dev/null @@ -1,82 +0,0 @@ -setStatus($discoveryConfigStatus); - $request = (new UpdateDiscoveryConfigRequest()) - ->setName($formattedName) - ->setDiscoveryConfig($discoveryConfig); - - // Call the API and handle any network failures. - try { - /** @var DiscoveryConfig $response */ - $response = $dlpServiceClient->updateDiscoveryConfig($request); - 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 = DlpServiceClient::discoveryConfigName( - '[PROJECT]', - '[LOCATION]', - '[DISCOVERY_CONFIG]' - ); - $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; - - update_discovery_config_sample($formattedName, $discoveryConfigStatus); -} -// [END dlp_v2_generated_DlpService_UpdateDiscoveryConfig_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_inspect_template.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_inspect_template.php deleted file mode 100644 index 530580f344e4..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_inspect_template.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var InspectTemplate $response */ - $response = $dlpServiceClient->updateInspectTemplate($request); - 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 = DlpServiceClient::inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - - update_inspect_template_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_UpdateInspectTemplate_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_job_trigger.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_job_trigger.php deleted file mode 100644 index d8db2492a4d2..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_job_trigger.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var JobTrigger $response */ - $response = $dlpServiceClient->updateJobTrigger($request); - 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 = DlpServiceClient::jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - - update_job_trigger_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_UpdateJobTrigger_sync] diff --git a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_stored_info_type.php b/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_stored_info_type.php deleted file mode 100644 index c5d29a624887..000000000000 --- a/owl-bot-staging/Dlp/v2/samples/V2/DlpServiceClient/update_stored_info_type.php +++ /dev/null @@ -1,77 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var StoredInfoType $response */ - $response = $dlpServiceClient->updateStoredInfoType($request); - 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 = DlpServiceClient::storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - - update_stored_info_type_sample($formattedName); -} -// [END dlp_v2_generated_DlpService_UpdateStoredInfoType_sync] diff --git a/owl-bot-staging/Dlp/v2/src/V2/Client/DlpServiceClient.php b/owl-bot-staging/Dlp/v2/src/V2/Client/DlpServiceClient.php deleted file mode 100644 index 08f750231f74..000000000000 --- a/owl-bot-staging/Dlp/v2/src/V2/Client/DlpServiceClient.php +++ /dev/null @@ -1,2469 +0,0 @@ - self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/dlp_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/dlp_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/dlp_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/dlp_service_rest_client_config.php', - ], - ], - ]; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * column_data_profile resource. - * - * @param string $organization - * @param string $location - * @param string $columnDataProfile - * - * @return string The formatted column_data_profile resource. - */ - public static function columnDataProfileName(string $organization, string $location, string $columnDataProfile): string - { - return self::getPathTemplate('columnDataProfile')->render([ - 'organization' => $organization, - 'location' => $location, - 'column_data_profile' => $columnDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a connection - * resource. - * - * @param string $project - * @param string $location - * @param string $connection - * - * @return string The formatted connection resource. - */ - public static function connectionName(string $project, string $location, string $connection): string - { - return self::getPathTemplate('connection')->render([ - 'project' => $project, - 'location' => $location, - 'connection' => $connection, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * deidentify_template resource. - * - * @param string $organization - * @param string $deidentifyTemplate - * - * @return string The formatted deidentify_template resource. - */ - public static function deidentifyTemplateName(string $organization, string $deidentifyTemplate): string - { - return self::getPathTemplate('deidentifyTemplate')->render([ - 'organization' => $organization, - 'deidentify_template' => $deidentifyTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * discovery_config resource. - * - * @param string $project - * @param string $location - * @param string $discoveryConfig - * - * @return string The formatted discovery_config resource. - */ - public static function discoveryConfigName(string $project, string $location, string $discoveryConfig): string - { - return self::getPathTemplate('discoveryConfig')->render([ - 'project' => $project, - 'location' => $location, - 'discovery_config' => $discoveryConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a dlp_job - * resource. - * - * @param string $project - * @param string $dlpJob - * - * @return string The formatted dlp_job resource. - */ - public static function dlpJobName(string $project, string $dlpJob): string - { - return self::getPathTemplate('dlpJob')->render([ - 'project' => $project, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * inspect_template resource. - * - * @param string $organization - * @param string $inspectTemplate - * - * @return string The formatted inspect_template resource. - */ - public static function inspectTemplateName(string $organization, string $inspectTemplate): string - { - return self::getPathTemplate('inspectTemplate')->render([ - 'organization' => $organization, - 'inspect_template' => $inspectTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a job_trigger - * resource. - * - * @param string $project - * @param string $jobTrigger - * - * @return string The formatted job_trigger resource. - */ - public static function jobTriggerName(string $project, string $jobTrigger): string - { - return self::getPathTemplate('jobTrigger')->render([ - 'project' => $project, - 'job_trigger' => $jobTrigger, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName(string $project, string $location): string - { - return self::getPathTemplate('location')->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a organization - * resource. - * - * @param string $organization - * - * @return string The formatted organization resource. - */ - public static function organizationName(string $organization): string - { - return self::getPathTemplate('organization')->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_deidentify_template resource. - * - * @param string $organization - * @param string $deidentifyTemplate - * - * @return string The formatted organization_deidentify_template resource. - */ - public static function organizationDeidentifyTemplateName(string $organization, string $deidentifyTemplate): string - { - return self::getPathTemplate('organizationDeidentifyTemplate')->render([ - 'organization' => $organization, - 'deidentify_template' => $deidentifyTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_inspect_template resource. - * - * @param string $organization - * @param string $inspectTemplate - * - * @return string The formatted organization_inspect_template resource. - */ - public static function organizationInspectTemplateName(string $organization, string $inspectTemplate): string - { - return self::getPathTemplate('organizationInspectTemplate')->render([ - 'organization' => $organization, - 'inspect_template' => $inspectTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location resource. - * - * @param string $organization - * @param string $location - * - * @return string The formatted organization_location resource. - */ - public static function organizationLocationName(string $organization, string $location): string - { - return self::getPathTemplate('organizationLocation')->render([ - 'organization' => $organization, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_column_data_profile resource. - * - * @param string $organization - * @param string $location - * @param string $columnDataProfile - * - * @return string The formatted organization_location_column_data_profile resource. - */ - public static function organizationLocationColumnDataProfileName(string $organization, string $location, string $columnDataProfile): string - { - return self::getPathTemplate('organizationLocationColumnDataProfile')->render([ - 'organization' => $organization, - 'location' => $location, - 'column_data_profile' => $columnDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_deidentify_template resource. - * - * @param string $organization - * @param string $location - * @param string $deidentifyTemplate - * - * @return string The formatted organization_location_deidentify_template resource. - */ - public static function organizationLocationDeidentifyTemplateName(string $organization, string $location, string $deidentifyTemplate): string - { - return self::getPathTemplate('organizationLocationDeidentifyTemplate')->render([ - 'organization' => $organization, - 'location' => $location, - 'deidentify_template' => $deidentifyTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_inspect_template resource. - * - * @param string $organization - * @param string $location - * @param string $inspectTemplate - * - * @return string The formatted organization_location_inspect_template resource. - */ - public static function organizationLocationInspectTemplateName(string $organization, string $location, string $inspectTemplate): string - { - return self::getPathTemplate('organizationLocationInspectTemplate')->render([ - 'organization' => $organization, - 'location' => $location, - 'inspect_template' => $inspectTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_project_data_profile resource. - * - * @param string $organization - * @param string $location - * @param string $projectDataProfile - * - * @return string The formatted organization_location_project_data_profile resource. - */ - public static function organizationLocationProjectDataProfileName(string $organization, string $location, string $projectDataProfile): string - { - return self::getPathTemplate('organizationLocationProjectDataProfile')->render([ - 'organization' => $organization, - 'location' => $location, - 'project_data_profile' => $projectDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_stored_info_type resource. - * - * @param string $organization - * @param string $location - * @param string $storedInfoType - * - * @return string The formatted organization_location_stored_info_type resource. - */ - public static function organizationLocationStoredInfoTypeName(string $organization, string $location, string $storedInfoType): string - { - return self::getPathTemplate('organizationLocationStoredInfoType')->render([ - 'organization' => $organization, - 'location' => $location, - 'stored_info_type' => $storedInfoType, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_table_data_profile resource. - * - * @param string $organization - * @param string $location - * @param string $tableDataProfile - * - * @return string The formatted organization_location_table_data_profile resource. - */ - public static function organizationLocationTableDataProfileName(string $organization, string $location, string $tableDataProfile): string - { - return self::getPathTemplate('organizationLocationTableDataProfile')->render([ - 'organization' => $organization, - 'location' => $location, - 'table_data_profile' => $tableDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_stored_info_type resource. - * - * @param string $organization - * @param string $storedInfoType - * - * @return string The formatted organization_stored_info_type resource. - */ - public static function organizationStoredInfoTypeName(string $organization, string $storedInfoType): string - { - return self::getPathTemplate('organizationStoredInfoType')->render([ - 'organization' => $organization, - 'stored_info_type' => $storedInfoType, - ]); - } - - /** - * 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(string $project): string - { - return self::getPathTemplate('project')->render([ - 'project' => $project, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_data_profile resource. - * - * @param string $organization - * @param string $location - * @param string $projectDataProfile - * - * @return string The formatted project_data_profile resource. - */ - public static function projectDataProfileName(string $organization, string $location, string $projectDataProfile): string - { - return self::getPathTemplate('projectDataProfile')->render([ - 'organization' => $organization, - 'location' => $location, - 'project_data_profile' => $projectDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_deidentify_template resource. - * - * @param string $project - * @param string $deidentifyTemplate - * - * @return string The formatted project_deidentify_template resource. - */ - public static function projectDeidentifyTemplateName(string $project, string $deidentifyTemplate): string - { - return self::getPathTemplate('projectDeidentifyTemplate')->render([ - 'project' => $project, - 'deidentify_template' => $deidentifyTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_dlp_job resource. - * - * @param string $project - * @param string $dlpJob - * - * @return string The formatted project_dlp_job resource. - */ - public static function projectDlpJobName(string $project, string $dlpJob): string - { - return self::getPathTemplate('projectDlpJob')->render([ - 'project' => $project, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_inspect_template resource. - * - * @param string $project - * @param string $inspectTemplate - * - * @return string The formatted project_inspect_template resource. - */ - public static function projectInspectTemplateName(string $project, string $inspectTemplate): string - { - return self::getPathTemplate('projectInspectTemplate')->render([ - 'project' => $project, - 'inspect_template' => $inspectTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_job_trigger resource. - * - * @param string $project - * @param string $jobTrigger - * - * @return string The formatted project_job_trigger resource. - */ - public static function projectJobTriggerName(string $project, string $jobTrigger): string - { - return self::getPathTemplate('projectJobTrigger')->render([ - 'project' => $project, - 'job_trigger' => $jobTrigger, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_column_data_profile resource. - * - * @param string $project - * @param string $location - * @param string $columnDataProfile - * - * @return string The formatted project_location_column_data_profile resource. - */ - public static function projectLocationColumnDataProfileName(string $project, string $location, string $columnDataProfile): string - { - return self::getPathTemplate('projectLocationColumnDataProfile')->render([ - 'project' => $project, - 'location' => $location, - 'column_data_profile' => $columnDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_deidentify_template resource. - * - * @param string $project - * @param string $location - * @param string $deidentifyTemplate - * - * @return string The formatted project_location_deidentify_template resource. - */ - public static function projectLocationDeidentifyTemplateName(string $project, string $location, string $deidentifyTemplate): string - { - return self::getPathTemplate('projectLocationDeidentifyTemplate')->render([ - 'project' => $project, - 'location' => $location, - 'deidentify_template' => $deidentifyTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_dlp_job resource. - * - * @param string $project - * @param string $location - * @param string $dlpJob - * - * @return string The formatted project_location_dlp_job resource. - */ - public static function projectLocationDlpJobName(string $project, string $location, string $dlpJob): string - { - return self::getPathTemplate('projectLocationDlpJob')->render([ - 'project' => $project, - 'location' => $location, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_inspect_template resource. - * - * @param string $project - * @param string $location - * @param string $inspectTemplate - * - * @return string The formatted project_location_inspect_template resource. - */ - public static function projectLocationInspectTemplateName(string $project, string $location, string $inspectTemplate): string - { - return self::getPathTemplate('projectLocationInspectTemplate')->render([ - 'project' => $project, - 'location' => $location, - 'inspect_template' => $inspectTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_job_trigger resource. - * - * @param string $project - * @param string $location - * @param string $jobTrigger - * - * @return string The formatted project_location_job_trigger resource. - */ - public static function projectLocationJobTriggerName(string $project, string $location, string $jobTrigger): string - { - return self::getPathTemplate('projectLocationJobTrigger')->render([ - 'project' => $project, - 'location' => $location, - 'job_trigger' => $jobTrigger, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_project_data_profile resource. - * - * @param string $project - * @param string $location - * @param string $projectDataProfile - * - * @return string The formatted project_location_project_data_profile resource. - */ - public static function projectLocationProjectDataProfileName(string $project, string $location, string $projectDataProfile): string - { - return self::getPathTemplate('projectLocationProjectDataProfile')->render([ - 'project' => $project, - 'location' => $location, - 'project_data_profile' => $projectDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_stored_info_type resource. - * - * @param string $project - * @param string $location - * @param string $storedInfoType - * - * @return string The formatted project_location_stored_info_type resource. - */ - public static function projectLocationStoredInfoTypeName(string $project, string $location, string $storedInfoType): string - { - return self::getPathTemplate('projectLocationStoredInfoType')->render([ - 'project' => $project, - 'location' => $location, - 'stored_info_type' => $storedInfoType, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_table_data_profile resource. - * - * @param string $project - * @param string $location - * @param string $tableDataProfile - * - * @return string The formatted project_location_table_data_profile resource. - */ - public static function projectLocationTableDataProfileName(string $project, string $location, string $tableDataProfile): string - { - return self::getPathTemplate('projectLocationTableDataProfile')->render([ - 'project' => $project, - 'location' => $location, - 'table_data_profile' => $tableDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_stored_info_type resource. - * - * @param string $project - * @param string $storedInfoType - * - * @return string The formatted project_stored_info_type resource. - */ - public static function projectStoredInfoTypeName(string $project, string $storedInfoType): string - { - return self::getPathTemplate('projectStoredInfoType')->render([ - 'project' => $project, - 'stored_info_type' => $storedInfoType, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * stored_info_type resource. - * - * @param string $organization - * @param string $storedInfoType - * - * @return string The formatted stored_info_type resource. - */ - public static function storedInfoTypeName(string $organization, string $storedInfoType): string - { - return self::getPathTemplate('storedInfoType')->render([ - 'organization' => $organization, - 'stored_info_type' => $storedInfoType, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * table_data_profile resource. - * - * @param string $organization - * @param string $location - * @param string $tableDataProfile - * - * @return string The formatted table_data_profile resource. - */ - public static function tableDataProfileName(string $organization, string $location, string $tableDataProfile): string - { - return self::getPathTemplate('tableDataProfile')->render([ - 'organization' => $organization, - 'location' => $location, - 'table_data_profile' => $tableDataProfile, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - columnDataProfile: organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile} - * - connection: projects/{project}/locations/{location}/connections/{connection} - * - deidentifyTemplate: organizations/{organization}/deidentifyTemplates/{deidentify_template} - * - discoveryConfig: projects/{project}/locations/{location}/discoveryConfigs/{discovery_config} - * - dlpJob: projects/{project}/dlpJobs/{dlp_job} - * - inspectTemplate: organizations/{organization}/inspectTemplates/{inspect_template} - * - jobTrigger: projects/{project}/jobTriggers/{job_trigger} - * - location: projects/{project}/locations/{location} - * - organization: organizations/{organization} - * - organizationDeidentifyTemplate: organizations/{organization}/deidentifyTemplates/{deidentify_template} - * - organizationInspectTemplate: organizations/{organization}/inspectTemplates/{inspect_template} - * - organizationLocation: organizations/{organization}/locations/{location} - * - organizationLocationColumnDataProfile: organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile} - * - organizationLocationDeidentifyTemplate: organizations/{organization}/locations/{location}/deidentifyTemplates/{deidentify_template} - * - organizationLocationInspectTemplate: organizations/{organization}/locations/{location}/inspectTemplates/{inspect_template} - * - organizationLocationProjectDataProfile: organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile} - * - organizationLocationStoredInfoType: organizations/{organization}/locations/{location}/storedInfoTypes/{stored_info_type} - * - organizationLocationTableDataProfile: organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile} - * - organizationStoredInfoType: organizations/{organization}/storedInfoTypes/{stored_info_type} - * - project: projects/{project} - * - projectDataProfile: organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile} - * - projectDeidentifyTemplate: projects/{project}/deidentifyTemplates/{deidentify_template} - * - projectDlpJob: projects/{project}/dlpJobs/{dlp_job} - * - projectInspectTemplate: projects/{project}/inspectTemplates/{inspect_template} - * - projectJobTrigger: projects/{project}/jobTriggers/{job_trigger} - * - projectLocationColumnDataProfile: projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile} - * - projectLocationDeidentifyTemplate: projects/{project}/locations/{location}/deidentifyTemplates/{deidentify_template} - * - projectLocationDlpJob: projects/{project}/locations/{location}/dlpJobs/{dlp_job} - * - projectLocationInspectTemplate: projects/{project}/locations/{location}/inspectTemplates/{inspect_template} - * - projectLocationJobTrigger: projects/{project}/locations/{location}/jobTriggers/{job_trigger} - * - projectLocationProjectDataProfile: projects/{project}/locations/{location}/projectDataProfiles/{project_data_profile} - * - projectLocationStoredInfoType: projects/{project}/locations/{location}/storedInfoTypes/{stored_info_type} - * - projectLocationTableDataProfile: projects/{project}/locations/{location}/tableDataProfiles/{table_data_profile} - * - projectStoredInfoType: projects/{project}/storedInfoTypes/{stored_info_type} - * - storedInfoType: organizations/{organization}/storedInfoTypes/{stored_info_type} - * - tableDataProfile: organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile} - * - * 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(string $formattedName, string $template = null): array - { - return self::parseFormattedName($formattedName, $template); - } - - /** - * 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 'dlp.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); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Activate a job trigger. Causes the immediate execute of a trigger - * instead of waiting on the trigger event to occur. - * - * The async variant is {@see DlpServiceClient::activateJobTriggerAsync()} . - * - * @example samples/V2/DlpServiceClient/activate_job_trigger.php - * - * @param ActivateJobTriggerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DlpJob - * - * @throws ApiException Thrown if the API call fails. - */ - public function activateJobTrigger(ActivateJobTriggerRequest $request, array $callOptions = []): DlpJob - { - return $this->startApiCall('ActivateJobTrigger', $request, $callOptions)->wait(); - } - - /** - * Starts asynchronous cancellation on a long-running DlpJob. The server - * makes a best effort to cancel the DlpJob, but success is not - * guaranteed. - * See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage - * and - * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis - * to learn more. - * - * The async variant is {@see DlpServiceClient::cancelDlpJobAsync()} . - * - * @example samples/V2/DlpServiceClient/cancel_dlp_job.php - * - * @param CancelDlpJobRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Thrown if the API call fails. - */ - public function cancelDlpJob(CancelDlpJobRequest $request, array $callOptions = []): void - { - $this->startApiCall('CancelDlpJob', $request, $callOptions)->wait(); - } - - /** - * Create a Connection to an external data source. - * - * The async variant is {@see DlpServiceClient::createConnectionAsync()} . - * - * @example samples/V2/DlpServiceClient/create_connection.php - * - * @param CreateConnectionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Connection - * - * @throws ApiException Thrown if the API call fails. - */ - public function createConnection(CreateConnectionRequest $request, array $callOptions = []): Connection - { - return $this->startApiCall('CreateConnection', $request, $callOptions)->wait(); - } - - /** - * Creates a DeidentifyTemplate for reusing frequently used configuration - * for de-identifying content, images, and storage. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid - * to learn more. - * - * The async variant is {@see DlpServiceClient::createDeidentifyTemplateAsync()} . - * - * @example samples/V2/DlpServiceClient/create_deidentify_template.php - * - * @param CreateDeidentifyTemplateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DeidentifyTemplate - * - * @throws ApiException Thrown if the API call fails. - */ - public function createDeidentifyTemplate(CreateDeidentifyTemplateRequest $request, array $callOptions = []): DeidentifyTemplate - { - return $this->startApiCall('CreateDeidentifyTemplate', $request, $callOptions)->wait(); - } - - /** - * Creates a config for discovery to scan and profile storage. - * - * The async variant is {@see DlpServiceClient::createDiscoveryConfigAsync()} . - * - * @example samples/V2/DlpServiceClient/create_discovery_config.php - * - * @param CreateDiscoveryConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DiscoveryConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function createDiscoveryConfig(CreateDiscoveryConfigRequest $request, array $callOptions = []): DiscoveryConfig - { - return $this->startApiCall('CreateDiscoveryConfig', $request, $callOptions)->wait(); - } - - /** - * Creates a new job to inspect storage or calculate risk metrics. - * See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage - * and - * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis - * to learn more. - * - * When no InfoTypes or CustomInfoTypes are specified in inspect jobs, the - * system will automatically choose what detectors to run. By default this may - * be all types, but may change over time as detectors are updated. - * - * The async variant is {@see DlpServiceClient::createDlpJobAsync()} . - * - * @example samples/V2/DlpServiceClient/create_dlp_job.php - * - * @param CreateDlpJobRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DlpJob - * - * @throws ApiException Thrown if the API call fails. - */ - public function createDlpJob(CreateDlpJobRequest $request, array $callOptions = []): DlpJob - { - return $this->startApiCall('CreateDlpJob', $request, $callOptions)->wait(); - } - - /** - * Creates an InspectTemplate for reusing frequently used configuration - * for inspecting content, images, and storage. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates - * to learn more. - * - * The async variant is {@see DlpServiceClient::createInspectTemplateAsync()} . - * - * @example samples/V2/DlpServiceClient/create_inspect_template.php - * - * @param CreateInspectTemplateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 InspectTemplate - * - * @throws ApiException Thrown if the API call fails. - */ - public function createInspectTemplate(CreateInspectTemplateRequest $request, array $callOptions = []): InspectTemplate - { - return $this->startApiCall('CreateInspectTemplate', $request, $callOptions)->wait(); - } - - /** - * Creates a job trigger to run DLP actions such as scanning storage for - * sensitive information on a set schedule. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers - * to learn more. - * - * The async variant is {@see DlpServiceClient::createJobTriggerAsync()} . - * - * @example samples/V2/DlpServiceClient/create_job_trigger.php - * - * @param CreateJobTriggerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 JobTrigger - * - * @throws ApiException Thrown if the API call fails. - */ - public function createJobTrigger(CreateJobTriggerRequest $request, array $callOptions = []): JobTrigger - { - return $this->startApiCall('CreateJobTrigger', $request, $callOptions)->wait(); - } - - /** - * Creates a pre-built stored infoType to be used for inspection. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes - * to learn more. - * - * The async variant is {@see DlpServiceClient::createStoredInfoTypeAsync()} . - * - * @example samples/V2/DlpServiceClient/create_stored_info_type.php - * - * @param CreateStoredInfoTypeRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 StoredInfoType - * - * @throws ApiException Thrown if the API call fails. - */ - public function createStoredInfoType(CreateStoredInfoTypeRequest $request, array $callOptions = []): StoredInfoType - { - return $this->startApiCall('CreateStoredInfoType', $request, $callOptions)->wait(); - } - - /** - * De-identifies potentially sensitive info from a ContentItem. - * This method has limits on input size and output size. - * See - * https://cloud.google.com/sensitive-data-protection/docs/deidentify-sensitive-data - * to learn more. - * - * When no InfoTypes or CustomInfoTypes are specified in this request, the - * system will automatically choose what detectors to run. By default this may - * be all types, but may change over time as detectors are updated. - * - * The async variant is {@see DlpServiceClient::deidentifyContentAsync()} . - * - * @example samples/V2/DlpServiceClient/deidentify_content.php - * - * @param DeidentifyContentRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DeidentifyContentResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deidentifyContent(DeidentifyContentRequest $request, array $callOptions = []): DeidentifyContentResponse - { - return $this->startApiCall('DeidentifyContent', $request, $callOptions)->wait(); - } - - /** - * Delete a Connection. - * - * The async variant is {@see DlpServiceClient::deleteConnectionAsync()} . - * - * @example samples/V2/DlpServiceClient/delete_connection.php - * - * @param DeleteConnectionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Thrown if the API call fails. - */ - public function deleteConnection(DeleteConnectionRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteConnection', $request, $callOptions)->wait(); - } - - /** - * Deletes a DeidentifyTemplate. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid - * to learn more. - * - * The async variant is {@see DlpServiceClient::deleteDeidentifyTemplateAsync()} . - * - * @example samples/V2/DlpServiceClient/delete_deidentify_template.php - * - * @param DeleteDeidentifyTemplateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Thrown if the API call fails. - */ - public function deleteDeidentifyTemplate(DeleteDeidentifyTemplateRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteDeidentifyTemplate', $request, $callOptions)->wait(); - } - - /** - * Deletes a discovery configuration. - * - * The async variant is {@see DlpServiceClient::deleteDiscoveryConfigAsync()} . - * - * @example samples/V2/DlpServiceClient/delete_discovery_config.php - * - * @param DeleteDiscoveryConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Thrown if the API call fails. - */ - public function deleteDiscoveryConfig(DeleteDiscoveryConfigRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteDiscoveryConfig', $request, $callOptions)->wait(); - } - - /** - * Deletes a long-running DlpJob. This method indicates that the client is - * no longer interested in the DlpJob result. The job will be canceled if - * possible. - * See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage - * and - * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis - * to learn more. - * - * The async variant is {@see DlpServiceClient::deleteDlpJobAsync()} . - * - * @example samples/V2/DlpServiceClient/delete_dlp_job.php - * - * @param DeleteDlpJobRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Thrown if the API call fails. - */ - public function deleteDlpJob(DeleteDlpJobRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteDlpJob', $request, $callOptions)->wait(); - } - - /** - * Deletes an InspectTemplate. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates - * to learn more. - * - * The async variant is {@see DlpServiceClient::deleteInspectTemplateAsync()} . - * - * @example samples/V2/DlpServiceClient/delete_inspect_template.php - * - * @param DeleteInspectTemplateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Thrown if the API call fails. - */ - public function deleteInspectTemplate(DeleteInspectTemplateRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteInspectTemplate', $request, $callOptions)->wait(); - } - - /** - * Deletes a job trigger. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers - * to learn more. - * - * The async variant is {@see DlpServiceClient::deleteJobTriggerAsync()} . - * - * @example samples/V2/DlpServiceClient/delete_job_trigger.php - * - * @param DeleteJobTriggerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Thrown if the API call fails. - */ - public function deleteJobTrigger(DeleteJobTriggerRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteJobTrigger', $request, $callOptions)->wait(); - } - - /** - * Deletes a stored infoType. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes - * to learn more. - * - * The async variant is {@see DlpServiceClient::deleteStoredInfoTypeAsync()} . - * - * @example samples/V2/DlpServiceClient/delete_stored_info_type.php - * - * @param DeleteStoredInfoTypeRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Thrown if the API call fails. - */ - public function deleteStoredInfoType(DeleteStoredInfoTypeRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteStoredInfoType', $request, $callOptions)->wait(); - } - - /** - * Delete a TableDataProfile. Will not prevent the profile from being - * regenerated if the table is still included in a discovery configuration. - * - * The async variant is {@see DlpServiceClient::deleteTableDataProfileAsync()} . - * - * @example samples/V2/DlpServiceClient/delete_table_data_profile.php - * - * @param DeleteTableDataProfileRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Thrown if the API call fails. - */ - public function deleteTableDataProfile(DeleteTableDataProfileRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteTableDataProfile', $request, $callOptions)->wait(); - } - - /** - * Finish a running hybrid DlpJob. Triggers the finalization steps and running - * of any enabled actions that have not yet run. - * - * The async variant is {@see DlpServiceClient::finishDlpJobAsync()} . - * - * @example samples/V2/DlpServiceClient/finish_dlp_job.php - * - * @param FinishDlpJobRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Thrown if the API call fails. - */ - public function finishDlpJob(FinishDlpJobRequest $request, array $callOptions = []): void - { - $this->startApiCall('FinishDlpJob', $request, $callOptions)->wait(); - } - - /** - * Gets a column data profile. - * - * The async variant is {@see DlpServiceClient::getColumnDataProfileAsync()} . - * - * @example samples/V2/DlpServiceClient/get_column_data_profile.php - * - * @param GetColumnDataProfileRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 ColumnDataProfile - * - * @throws ApiException Thrown if the API call fails. - */ - public function getColumnDataProfile(GetColumnDataProfileRequest $request, array $callOptions = []): ColumnDataProfile - { - return $this->startApiCall('GetColumnDataProfile', $request, $callOptions)->wait(); - } - - /** - * Get a Connection by name. - * - * The async variant is {@see DlpServiceClient::getConnectionAsync()} . - * - * @example samples/V2/DlpServiceClient/get_connection.php - * - * @param GetConnectionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Connection - * - * @throws ApiException Thrown if the API call fails. - */ - public function getConnection(GetConnectionRequest $request, array $callOptions = []): Connection - { - return $this->startApiCall('GetConnection', $request, $callOptions)->wait(); - } - - /** - * Gets a DeidentifyTemplate. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid - * to learn more. - * - * The async variant is {@see DlpServiceClient::getDeidentifyTemplateAsync()} . - * - * @example samples/V2/DlpServiceClient/get_deidentify_template.php - * - * @param GetDeidentifyTemplateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DeidentifyTemplate - * - * @throws ApiException Thrown if the API call fails. - */ - public function getDeidentifyTemplate(GetDeidentifyTemplateRequest $request, array $callOptions = []): DeidentifyTemplate - { - return $this->startApiCall('GetDeidentifyTemplate', $request, $callOptions)->wait(); - } - - /** - * Gets a discovery configuration. - * - * The async variant is {@see DlpServiceClient::getDiscoveryConfigAsync()} . - * - * @example samples/V2/DlpServiceClient/get_discovery_config.php - * - * @param GetDiscoveryConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DiscoveryConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function getDiscoveryConfig(GetDiscoveryConfigRequest $request, array $callOptions = []): DiscoveryConfig - { - return $this->startApiCall('GetDiscoveryConfig', $request, $callOptions)->wait(); - } - - /** - * Gets the latest state of a long-running DlpJob. - * See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage - * and - * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis - * to learn more. - * - * The async variant is {@see DlpServiceClient::getDlpJobAsync()} . - * - * @example samples/V2/DlpServiceClient/get_dlp_job.php - * - * @param GetDlpJobRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DlpJob - * - * @throws ApiException Thrown if the API call fails. - */ - public function getDlpJob(GetDlpJobRequest $request, array $callOptions = []): DlpJob - { - return $this->startApiCall('GetDlpJob', $request, $callOptions)->wait(); - } - - /** - * Gets an InspectTemplate. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates - * to learn more. - * - * The async variant is {@see DlpServiceClient::getInspectTemplateAsync()} . - * - * @example samples/V2/DlpServiceClient/get_inspect_template.php - * - * @param GetInspectTemplateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 InspectTemplate - * - * @throws ApiException Thrown if the API call fails. - */ - public function getInspectTemplate(GetInspectTemplateRequest $request, array $callOptions = []): InspectTemplate - { - return $this->startApiCall('GetInspectTemplate', $request, $callOptions)->wait(); - } - - /** - * Gets a job trigger. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers - * to learn more. - * - * The async variant is {@see DlpServiceClient::getJobTriggerAsync()} . - * - * @example samples/V2/DlpServiceClient/get_job_trigger.php - * - * @param GetJobTriggerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 JobTrigger - * - * @throws ApiException Thrown if the API call fails. - */ - public function getJobTrigger(GetJobTriggerRequest $request, array $callOptions = []): JobTrigger - { - return $this->startApiCall('GetJobTrigger', $request, $callOptions)->wait(); - } - - /** - * Gets a project data profile. - * - * The async variant is {@see DlpServiceClient::getProjectDataProfileAsync()} . - * - * @example samples/V2/DlpServiceClient/get_project_data_profile.php - * - * @param GetProjectDataProfileRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 ProjectDataProfile - * - * @throws ApiException Thrown if the API call fails. - */ - public function getProjectDataProfile(GetProjectDataProfileRequest $request, array $callOptions = []): ProjectDataProfile - { - return $this->startApiCall('GetProjectDataProfile', $request, $callOptions)->wait(); - } - - /** - * Gets a stored infoType. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes - * to learn more. - * - * The async variant is {@see DlpServiceClient::getStoredInfoTypeAsync()} . - * - * @example samples/V2/DlpServiceClient/get_stored_info_type.php - * - * @param GetStoredInfoTypeRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 StoredInfoType - * - * @throws ApiException Thrown if the API call fails. - */ - public function getStoredInfoType(GetStoredInfoTypeRequest $request, array $callOptions = []): StoredInfoType - { - return $this->startApiCall('GetStoredInfoType', $request, $callOptions)->wait(); - } - - /** - * Gets a table data profile. - * - * The async variant is {@see DlpServiceClient::getTableDataProfileAsync()} . - * - * @example samples/V2/DlpServiceClient/get_table_data_profile.php - * - * @param GetTableDataProfileRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 TableDataProfile - * - * @throws ApiException Thrown if the API call fails. - */ - public function getTableDataProfile(GetTableDataProfileRequest $request, array $callOptions = []): TableDataProfile - { - return $this->startApiCall('GetTableDataProfile', $request, $callOptions)->wait(); - } - - /** - * Inspect hybrid content and store findings to a job. - * To review the findings, inspect the job. Inspection will occur - * asynchronously. - * - * The async variant is {@see DlpServiceClient::hybridInspectDlpJobAsync()} . - * - * @example samples/V2/DlpServiceClient/hybrid_inspect_dlp_job.php - * - * @param HybridInspectDlpJobRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 HybridInspectResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function hybridInspectDlpJob(HybridInspectDlpJobRequest $request, array $callOptions = []): HybridInspectResponse - { - return $this->startApiCall('HybridInspectDlpJob', $request, $callOptions)->wait(); - } - - /** - * Inspect hybrid content and store findings to a trigger. The inspection - * will be processed asynchronously. To review the findings monitor the - * jobs within the trigger. - * - * The async variant is {@see DlpServiceClient::hybridInspectJobTriggerAsync()} . - * - * @example samples/V2/DlpServiceClient/hybrid_inspect_job_trigger.php - * - * @param HybridInspectJobTriggerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 HybridInspectResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function hybridInspectJobTrigger(HybridInspectJobTriggerRequest $request, array $callOptions = []): HybridInspectResponse - { - return $this->startApiCall('HybridInspectJobTrigger', $request, $callOptions)->wait(); - } - - /** - * Finds potentially sensitive info in content. - * This method has limits on input size, processing time, and output size. - * - * When no InfoTypes or CustomInfoTypes are specified in this request, the - * system will automatically choose what detectors to run. By default this may - * be all types, but may change over time as detectors are updated. - * - * For how to guides, see - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-images - * and - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-text, - * - * The async variant is {@see DlpServiceClient::inspectContentAsync()} . - * - * @example samples/V2/DlpServiceClient/inspect_content.php - * - * @param InspectContentRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 InspectContentResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function inspectContent(InspectContentRequest $request, array $callOptions = []): InspectContentResponse - { - return $this->startApiCall('InspectContent', $request, $callOptions)->wait(); - } - - /** - * Lists column data profiles for an organization. - * - * The async variant is {@see DlpServiceClient::listColumnDataProfilesAsync()} . - * - * @example samples/V2/DlpServiceClient/list_column_data_profiles.php - * - * @param ListColumnDataProfilesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listColumnDataProfiles(ListColumnDataProfilesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListColumnDataProfiles', $request, $callOptions); - } - - /** - * Lists Connections in a parent. - * - * The async variant is {@see DlpServiceClient::listConnectionsAsync()} . - * - * @example samples/V2/DlpServiceClient/list_connections.php - * - * @param ListConnectionsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listConnections(ListConnectionsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListConnections', $request, $callOptions); - } - - /** - * Lists DeidentifyTemplates. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid - * to learn more. - * - * The async variant is {@see DlpServiceClient::listDeidentifyTemplatesAsync()} . - * - * @example samples/V2/DlpServiceClient/list_deidentify_templates.php - * - * @param ListDeidentifyTemplatesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listDeidentifyTemplates(ListDeidentifyTemplatesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListDeidentifyTemplates', $request, $callOptions); - } - - /** - * Lists discovery configurations. - * - * The async variant is {@see DlpServiceClient::listDiscoveryConfigsAsync()} . - * - * @example samples/V2/DlpServiceClient/list_discovery_configs.php - * - * @param ListDiscoveryConfigsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listDiscoveryConfigs(ListDiscoveryConfigsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListDiscoveryConfigs', $request, $callOptions); - } - - /** - * Lists DlpJobs that match the specified filter in the request. - * See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage - * and - * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis - * to learn more. - * - * The async variant is {@see DlpServiceClient::listDlpJobsAsync()} . - * - * @example samples/V2/DlpServiceClient/list_dlp_jobs.php - * - * @param ListDlpJobsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listDlpJobs(ListDlpJobsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListDlpJobs', $request, $callOptions); - } - - /** - * Returns a list of the sensitive information types that DLP API - * supports. See - * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference - * to learn more. - * - * The async variant is {@see DlpServiceClient::listInfoTypesAsync()} . - * - * @example samples/V2/DlpServiceClient/list_info_types.php - * - * @param ListInfoTypesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 ListInfoTypesResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listInfoTypes(ListInfoTypesRequest $request, array $callOptions = []): ListInfoTypesResponse - { - return $this->startApiCall('ListInfoTypes', $request, $callOptions)->wait(); - } - - /** - * Lists InspectTemplates. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates - * to learn more. - * - * The async variant is {@see DlpServiceClient::listInspectTemplatesAsync()} . - * - * @example samples/V2/DlpServiceClient/list_inspect_templates.php - * - * @param ListInspectTemplatesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listInspectTemplates(ListInspectTemplatesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListInspectTemplates', $request, $callOptions); - } - - /** - * Lists job triggers. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers - * to learn more. - * - * The async variant is {@see DlpServiceClient::listJobTriggersAsync()} . - * - * @example samples/V2/DlpServiceClient/list_job_triggers.php - * - * @param ListJobTriggersRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listJobTriggers(ListJobTriggersRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListJobTriggers', $request, $callOptions); - } - - /** - * Lists project data profiles for an organization. - * - * The async variant is {@see DlpServiceClient::listProjectDataProfilesAsync()} . - * - * @example samples/V2/DlpServiceClient/list_project_data_profiles.php - * - * @param ListProjectDataProfilesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listProjectDataProfiles(ListProjectDataProfilesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListProjectDataProfiles', $request, $callOptions); - } - - /** - * Lists stored infoTypes. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes - * to learn more. - * - * The async variant is {@see DlpServiceClient::listStoredInfoTypesAsync()} . - * - * @example samples/V2/DlpServiceClient/list_stored_info_types.php - * - * @param ListStoredInfoTypesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listStoredInfoTypes(ListStoredInfoTypesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListStoredInfoTypes', $request, $callOptions); - } - - /** - * Lists table data profiles for an organization. - * - * The async variant is {@see DlpServiceClient::listTableDataProfilesAsync()} . - * - * @example samples/V2/DlpServiceClient/list_table_data_profiles.php - * - * @param ListTableDataProfilesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listTableDataProfiles(ListTableDataProfilesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListTableDataProfiles', $request, $callOptions); - } - - /** - * Redacts potentially sensitive info from an image. - * This method has limits on input size, processing time, and output size. - * See - * https://cloud.google.com/sensitive-data-protection/docs/redacting-sensitive-data-images - * to learn more. - * - * When no InfoTypes or CustomInfoTypes are specified in this request, the - * system will automatically choose what detectors to run. By default this may - * be all types, but may change over time as detectors are updated. - * - * The async variant is {@see DlpServiceClient::redactImageAsync()} . - * - * @example samples/V2/DlpServiceClient/redact_image.php - * - * @param RedactImageRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 RedactImageResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function redactImage(RedactImageRequest $request, array $callOptions = []): RedactImageResponse - { - return $this->startApiCall('RedactImage', $request, $callOptions)->wait(); - } - - /** - * Re-identifies content that has been de-identified. - * See - * https://cloud.google.com/sensitive-data-protection/docs/pseudonymization#re-identification_in_free_text_code_example - * to learn more. - * - * The async variant is {@see DlpServiceClient::reidentifyContentAsync()} . - * - * @example samples/V2/DlpServiceClient/reidentify_content.php - * - * @param ReidentifyContentRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 ReidentifyContentResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function reidentifyContent(ReidentifyContentRequest $request, array $callOptions = []): ReidentifyContentResponse - { - return $this->startApiCall('ReidentifyContent', $request, $callOptions)->wait(); - } - - /** - * Searches for Connections in a parent. - * - * The async variant is {@see DlpServiceClient::searchConnectionsAsync()} . - * - * @example samples/V2/DlpServiceClient/search_connections.php - * - * @param SearchConnectionsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function searchConnections(SearchConnectionsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('SearchConnections', $request, $callOptions); - } - - /** - * Update a Connection. - * - * The async variant is {@see DlpServiceClient::updateConnectionAsync()} . - * - * @example samples/V2/DlpServiceClient/update_connection.php - * - * @param UpdateConnectionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Connection - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateConnection(UpdateConnectionRequest $request, array $callOptions = []): Connection - { - return $this->startApiCall('UpdateConnection', $request, $callOptions)->wait(); - } - - /** - * Updates the DeidentifyTemplate. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid - * to learn more. - * - * The async variant is {@see DlpServiceClient::updateDeidentifyTemplateAsync()} . - * - * @example samples/V2/DlpServiceClient/update_deidentify_template.php - * - * @param UpdateDeidentifyTemplateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DeidentifyTemplate - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateDeidentifyTemplate(UpdateDeidentifyTemplateRequest $request, array $callOptions = []): DeidentifyTemplate - { - return $this->startApiCall('UpdateDeidentifyTemplate', $request, $callOptions)->wait(); - } - - /** - * Updates a discovery configuration. - * - * The async variant is {@see DlpServiceClient::updateDiscoveryConfigAsync()} . - * - * @example samples/V2/DlpServiceClient/update_discovery_config.php - * - * @param UpdateDiscoveryConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DiscoveryConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateDiscoveryConfig(UpdateDiscoveryConfigRequest $request, array $callOptions = []): DiscoveryConfig - { - return $this->startApiCall('UpdateDiscoveryConfig', $request, $callOptions)->wait(); - } - - /** - * Updates the InspectTemplate. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates - * to learn more. - * - * The async variant is {@see DlpServiceClient::updateInspectTemplateAsync()} . - * - * @example samples/V2/DlpServiceClient/update_inspect_template.php - * - * @param UpdateInspectTemplateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 InspectTemplate - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateInspectTemplate(UpdateInspectTemplateRequest $request, array $callOptions = []): InspectTemplate - { - return $this->startApiCall('UpdateInspectTemplate', $request, $callOptions)->wait(); - } - - /** - * Updates a job trigger. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers - * to learn more. - * - * The async variant is {@see DlpServiceClient::updateJobTriggerAsync()} . - * - * @example samples/V2/DlpServiceClient/update_job_trigger.php - * - * @param UpdateJobTriggerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 JobTrigger - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateJobTrigger(UpdateJobTriggerRequest $request, array $callOptions = []): JobTrigger - { - return $this->startApiCall('UpdateJobTrigger', $request, $callOptions)->wait(); - } - - /** - * Updates the stored infoType by creating a new version. The existing version - * will continue to be used until the new version is ready. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes - * to learn more. - * - * The async variant is {@see DlpServiceClient::updateStoredInfoTypeAsync()} . - * - * @example samples/V2/DlpServiceClient/update_stored_info_type.php - * - * @param UpdateStoredInfoTypeRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 StoredInfoType - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateStoredInfoType(UpdateStoredInfoTypeRequest $request, array $callOptions = []): StoredInfoType - { - return $this->startApiCall('UpdateStoredInfoType', $request, $callOptions)->wait(); - } -} diff --git a/owl-bot-staging/Dlp/v2/src/V2/DlpServiceClient.php b/owl-bot-staging/Dlp/v2/src/V2/DlpServiceClient.php deleted file mode 100644 index feca6924635f..000000000000 --- a/owl-bot-staging/Dlp/v2/src/V2/DlpServiceClient.php +++ /dev/null @@ -1,34 +0,0 @@ -jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - * $response = $dlpServiceClient->activateJobTrigger($formattedName); - * } finally { - * $dlpServiceClient->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. - * - * @deprecated Please use the new service client {@see \Google\Cloud\Dlp\V2\Client\DlpServiceClient}. - */ -class DlpServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.privacy.dlp.v2.DlpService'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - const SERVICE_ADDRESS = 'dlp.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'dlp.UNIVERSE_DOMAIN'; - - /** 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 = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $columnDataProfileNameTemplate; - - private static $connectionNameTemplate; - - private static $deidentifyTemplateNameTemplate; - - private static $discoveryConfigNameTemplate; - - private static $dlpJobNameTemplate; - - private static $inspectTemplateNameTemplate; - - private static $jobTriggerNameTemplate; - - private static $locationNameTemplate; - - private static $organizationNameTemplate; - - private static $organizationDeidentifyTemplateNameTemplate; - - private static $organizationInspectTemplateNameTemplate; - - private static $organizationLocationNameTemplate; - - private static $organizationLocationColumnDataProfileNameTemplate; - - private static $organizationLocationDeidentifyTemplateNameTemplate; - - private static $organizationLocationInspectTemplateNameTemplate; - - private static $organizationLocationProjectDataProfileNameTemplate; - - private static $organizationLocationStoredInfoTypeNameTemplate; - - private static $organizationLocationTableDataProfileNameTemplate; - - private static $organizationStoredInfoTypeNameTemplate; - - private static $projectNameTemplate; - - private static $projectDataProfileNameTemplate; - - private static $projectDeidentifyTemplateNameTemplate; - - private static $projectDlpJobNameTemplate; - - private static $projectInspectTemplateNameTemplate; - - private static $projectJobTriggerNameTemplate; - - private static $projectLocationColumnDataProfileNameTemplate; - - private static $projectLocationDeidentifyTemplateNameTemplate; - - private static $projectLocationDlpJobNameTemplate; - - private static $projectLocationInspectTemplateNameTemplate; - - private static $projectLocationJobTriggerNameTemplate; - - private static $projectLocationProjectDataProfileNameTemplate; - - private static $projectLocationStoredInfoTypeNameTemplate; - - private static $projectLocationTableDataProfileNameTemplate; - - private static $projectStoredInfoTypeNameTemplate; - - private static $storedInfoTypeNameTemplate; - - private static $tableDataProfileNameTemplate; - - private static $pathTemplateMap; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/dlp_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/dlp_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/dlp_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/dlp_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getColumnDataProfileNameTemplate() - { - if (self::$columnDataProfileNameTemplate == null) { - self::$columnDataProfileNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}'); - } - - return self::$columnDataProfileNameTemplate; - } - - private static function getConnectionNameTemplate() - { - if (self::$connectionNameTemplate == null) { - self::$connectionNameTemplate = new PathTemplate('projects/{project}/locations/{location}/connections/{connection}'); - } - - return self::$connectionNameTemplate; - } - - private static function getDeidentifyTemplateNameTemplate() - { - if (self::$deidentifyTemplateNameTemplate == null) { - self::$deidentifyTemplateNameTemplate = new PathTemplate('organizations/{organization}/deidentifyTemplates/{deidentify_template}'); - } - - return self::$deidentifyTemplateNameTemplate; - } - - private static function getDiscoveryConfigNameTemplate() - { - if (self::$discoveryConfigNameTemplate == null) { - self::$discoveryConfigNameTemplate = new PathTemplate('projects/{project}/locations/{location}/discoveryConfigs/{discovery_config}'); - } - - return self::$discoveryConfigNameTemplate; - } - - private static function getDlpJobNameTemplate() - { - if (self::$dlpJobNameTemplate == null) { - self::$dlpJobNameTemplate = new PathTemplate('projects/{project}/dlpJobs/{dlp_job}'); - } - - return self::$dlpJobNameTemplate; - } - - private static function getInspectTemplateNameTemplate() - { - if (self::$inspectTemplateNameTemplate == null) { - self::$inspectTemplateNameTemplate = new PathTemplate('organizations/{organization}/inspectTemplates/{inspect_template}'); - } - - return self::$inspectTemplateNameTemplate; - } - - private static function getJobTriggerNameTemplate() - { - if (self::$jobTriggerNameTemplate == null) { - self::$jobTriggerNameTemplate = new PathTemplate('projects/{project}/jobTriggers/{job_trigger}'); - } - - return self::$jobTriggerNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getOrganizationNameTemplate() - { - if (self::$organizationNameTemplate == null) { - self::$organizationNameTemplate = new PathTemplate('organizations/{organization}'); - } - - return self::$organizationNameTemplate; - } - - private static function getOrganizationDeidentifyTemplateNameTemplate() - { - if (self::$organizationDeidentifyTemplateNameTemplate == null) { - self::$organizationDeidentifyTemplateNameTemplate = new PathTemplate('organizations/{organization}/deidentifyTemplates/{deidentify_template}'); - } - - return self::$organizationDeidentifyTemplateNameTemplate; - } - - private static function getOrganizationInspectTemplateNameTemplate() - { - if (self::$organizationInspectTemplateNameTemplate == null) { - self::$organizationInspectTemplateNameTemplate = new PathTemplate('organizations/{organization}/inspectTemplates/{inspect_template}'); - } - - return self::$organizationInspectTemplateNameTemplate; - } - - private static function getOrganizationLocationNameTemplate() - { - if (self::$organizationLocationNameTemplate == null) { - self::$organizationLocationNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}'); - } - - return self::$organizationLocationNameTemplate; - } - - private static function getOrganizationLocationColumnDataProfileNameTemplate() - { - if (self::$organizationLocationColumnDataProfileNameTemplate == null) { - self::$organizationLocationColumnDataProfileNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}'); - } - - return self::$organizationLocationColumnDataProfileNameTemplate; - } - - private static function getOrganizationLocationDeidentifyTemplateNameTemplate() - { - if (self::$organizationLocationDeidentifyTemplateNameTemplate == null) { - self::$organizationLocationDeidentifyTemplateNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/deidentifyTemplates/{deidentify_template}'); - } - - return self::$organizationLocationDeidentifyTemplateNameTemplate; - } - - private static function getOrganizationLocationInspectTemplateNameTemplate() - { - if (self::$organizationLocationInspectTemplateNameTemplate == null) { - self::$organizationLocationInspectTemplateNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/inspectTemplates/{inspect_template}'); - } - - return self::$organizationLocationInspectTemplateNameTemplate; - } - - private static function getOrganizationLocationProjectDataProfileNameTemplate() - { - if (self::$organizationLocationProjectDataProfileNameTemplate == null) { - self::$organizationLocationProjectDataProfileNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile}'); - } - - return self::$organizationLocationProjectDataProfileNameTemplate; - } - - private static function getOrganizationLocationStoredInfoTypeNameTemplate() - { - if (self::$organizationLocationStoredInfoTypeNameTemplate == null) { - self::$organizationLocationStoredInfoTypeNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/storedInfoTypes/{stored_info_type}'); - } - - return self::$organizationLocationStoredInfoTypeNameTemplate; - } - - private static function getOrganizationLocationTableDataProfileNameTemplate() - { - if (self::$organizationLocationTableDataProfileNameTemplate == null) { - self::$organizationLocationTableDataProfileNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile}'); - } - - return self::$organizationLocationTableDataProfileNameTemplate; - } - - private static function getOrganizationStoredInfoTypeNameTemplate() - { - if (self::$organizationStoredInfoTypeNameTemplate == null) { - self::$organizationStoredInfoTypeNameTemplate = new PathTemplate('organizations/{organization}/storedInfoTypes/{stored_info_type}'); - } - - return self::$organizationStoredInfoTypeNameTemplate; - } - - private static function getProjectNameTemplate() - { - if (self::$projectNameTemplate == null) { - self::$projectNameTemplate = new PathTemplate('projects/{project}'); - } - - return self::$projectNameTemplate; - } - - private static function getProjectDataProfileNameTemplate() - { - if (self::$projectDataProfileNameTemplate == null) { - self::$projectDataProfileNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile}'); - } - - return self::$projectDataProfileNameTemplate; - } - - private static function getProjectDeidentifyTemplateNameTemplate() - { - if (self::$projectDeidentifyTemplateNameTemplate == null) { - self::$projectDeidentifyTemplateNameTemplate = new PathTemplate('projects/{project}/deidentifyTemplates/{deidentify_template}'); - } - - return self::$projectDeidentifyTemplateNameTemplate; - } - - private static function getProjectDlpJobNameTemplate() - { - if (self::$projectDlpJobNameTemplate == null) { - self::$projectDlpJobNameTemplate = new PathTemplate('projects/{project}/dlpJobs/{dlp_job}'); - } - - return self::$projectDlpJobNameTemplate; - } - - private static function getProjectInspectTemplateNameTemplate() - { - if (self::$projectInspectTemplateNameTemplate == null) { - self::$projectInspectTemplateNameTemplate = new PathTemplate('projects/{project}/inspectTemplates/{inspect_template}'); - } - - return self::$projectInspectTemplateNameTemplate; - } - - private static function getProjectJobTriggerNameTemplate() - { - if (self::$projectJobTriggerNameTemplate == null) { - self::$projectJobTriggerNameTemplate = new PathTemplate('projects/{project}/jobTriggers/{job_trigger}'); - } - - return self::$projectJobTriggerNameTemplate; - } - - private static function getProjectLocationColumnDataProfileNameTemplate() - { - if (self::$projectLocationColumnDataProfileNameTemplate == null) { - self::$projectLocationColumnDataProfileNameTemplate = new PathTemplate('projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile}'); - } - - return self::$projectLocationColumnDataProfileNameTemplate; - } - - private static function getProjectLocationDeidentifyTemplateNameTemplate() - { - if (self::$projectLocationDeidentifyTemplateNameTemplate == null) { - self::$projectLocationDeidentifyTemplateNameTemplate = new PathTemplate('projects/{project}/locations/{location}/deidentifyTemplates/{deidentify_template}'); - } - - return self::$projectLocationDeidentifyTemplateNameTemplate; - } - - private static function getProjectLocationDlpJobNameTemplate() - { - if (self::$projectLocationDlpJobNameTemplate == null) { - self::$projectLocationDlpJobNameTemplate = new PathTemplate('projects/{project}/locations/{location}/dlpJobs/{dlp_job}'); - } - - return self::$projectLocationDlpJobNameTemplate; - } - - private static function getProjectLocationInspectTemplateNameTemplate() - { - if (self::$projectLocationInspectTemplateNameTemplate == null) { - self::$projectLocationInspectTemplateNameTemplate = new PathTemplate('projects/{project}/locations/{location}/inspectTemplates/{inspect_template}'); - } - - return self::$projectLocationInspectTemplateNameTemplate; - } - - private static function getProjectLocationJobTriggerNameTemplate() - { - if (self::$projectLocationJobTriggerNameTemplate == null) { - self::$projectLocationJobTriggerNameTemplate = new PathTemplate('projects/{project}/locations/{location}/jobTriggers/{job_trigger}'); - } - - return self::$projectLocationJobTriggerNameTemplate; - } - - private static function getProjectLocationProjectDataProfileNameTemplate() - { - if (self::$projectLocationProjectDataProfileNameTemplate == null) { - self::$projectLocationProjectDataProfileNameTemplate = new PathTemplate('projects/{project}/locations/{location}/projectDataProfiles/{project_data_profile}'); - } - - return self::$projectLocationProjectDataProfileNameTemplate; - } - - private static function getProjectLocationStoredInfoTypeNameTemplate() - { - if (self::$projectLocationStoredInfoTypeNameTemplate == null) { - self::$projectLocationStoredInfoTypeNameTemplate = new PathTemplate('projects/{project}/locations/{location}/storedInfoTypes/{stored_info_type}'); - } - - return self::$projectLocationStoredInfoTypeNameTemplate; - } - - private static function getProjectLocationTableDataProfileNameTemplate() - { - if (self::$projectLocationTableDataProfileNameTemplate == null) { - self::$projectLocationTableDataProfileNameTemplate = new PathTemplate('projects/{project}/locations/{location}/tableDataProfiles/{table_data_profile}'); - } - - return self::$projectLocationTableDataProfileNameTemplate; - } - - private static function getProjectStoredInfoTypeNameTemplate() - { - if (self::$projectStoredInfoTypeNameTemplate == null) { - self::$projectStoredInfoTypeNameTemplate = new PathTemplate('projects/{project}/storedInfoTypes/{stored_info_type}'); - } - - return self::$projectStoredInfoTypeNameTemplate; - } - - private static function getStoredInfoTypeNameTemplate() - { - if (self::$storedInfoTypeNameTemplate == null) { - self::$storedInfoTypeNameTemplate = new PathTemplate('organizations/{organization}/storedInfoTypes/{stored_info_type}'); - } - - return self::$storedInfoTypeNameTemplate; - } - - private static function getTableDataProfileNameTemplate() - { - if (self::$tableDataProfileNameTemplate == null) { - self::$tableDataProfileNameTemplate = new PathTemplate('organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile}'); - } - - return self::$tableDataProfileNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'columnDataProfile' => self::getColumnDataProfileNameTemplate(), - 'connection' => self::getConnectionNameTemplate(), - 'deidentifyTemplate' => self::getDeidentifyTemplateNameTemplate(), - 'discoveryConfig' => self::getDiscoveryConfigNameTemplate(), - 'dlpJob' => self::getDlpJobNameTemplate(), - 'inspectTemplate' => self::getInspectTemplateNameTemplate(), - 'jobTrigger' => self::getJobTriggerNameTemplate(), - 'location' => self::getLocationNameTemplate(), - 'organization' => self::getOrganizationNameTemplate(), - 'organizationDeidentifyTemplate' => self::getOrganizationDeidentifyTemplateNameTemplate(), - 'organizationInspectTemplate' => self::getOrganizationInspectTemplateNameTemplate(), - 'organizationLocation' => self::getOrganizationLocationNameTemplate(), - 'organizationLocationColumnDataProfile' => self::getOrganizationLocationColumnDataProfileNameTemplate(), - 'organizationLocationDeidentifyTemplate' => self::getOrganizationLocationDeidentifyTemplateNameTemplate(), - 'organizationLocationInspectTemplate' => self::getOrganizationLocationInspectTemplateNameTemplate(), - 'organizationLocationProjectDataProfile' => self::getOrganizationLocationProjectDataProfileNameTemplate(), - 'organizationLocationStoredInfoType' => self::getOrganizationLocationStoredInfoTypeNameTemplate(), - 'organizationLocationTableDataProfile' => self::getOrganizationLocationTableDataProfileNameTemplate(), - 'organizationStoredInfoType' => self::getOrganizationStoredInfoTypeNameTemplate(), - 'project' => self::getProjectNameTemplate(), - 'projectDataProfile' => self::getProjectDataProfileNameTemplate(), - 'projectDeidentifyTemplate' => self::getProjectDeidentifyTemplateNameTemplate(), - 'projectDlpJob' => self::getProjectDlpJobNameTemplate(), - 'projectInspectTemplate' => self::getProjectInspectTemplateNameTemplate(), - 'projectJobTrigger' => self::getProjectJobTriggerNameTemplate(), - 'projectLocationColumnDataProfile' => self::getProjectLocationColumnDataProfileNameTemplate(), - 'projectLocationDeidentifyTemplate' => self::getProjectLocationDeidentifyTemplateNameTemplate(), - 'projectLocationDlpJob' => self::getProjectLocationDlpJobNameTemplate(), - 'projectLocationInspectTemplate' => self::getProjectLocationInspectTemplateNameTemplate(), - 'projectLocationJobTrigger' => self::getProjectLocationJobTriggerNameTemplate(), - 'projectLocationProjectDataProfile' => self::getProjectLocationProjectDataProfileNameTemplate(), - 'projectLocationStoredInfoType' => self::getProjectLocationStoredInfoTypeNameTemplate(), - 'projectLocationTableDataProfile' => self::getProjectLocationTableDataProfileNameTemplate(), - 'projectStoredInfoType' => self::getProjectStoredInfoTypeNameTemplate(), - 'storedInfoType' => self::getStoredInfoTypeNameTemplate(), - 'tableDataProfile' => self::getTableDataProfileNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * column_data_profile resource. - * - * @param string $organization - * @param string $location - * @param string $columnDataProfile - * - * @return string The formatted column_data_profile resource. - */ - public static function columnDataProfileName($organization, $location, $columnDataProfile) - { - return self::getColumnDataProfileNameTemplate()->render([ - 'organization' => $organization, - 'location' => $location, - 'column_data_profile' => $columnDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a connection - * resource. - * - * @param string $project - * @param string $location - * @param string $connection - * - * @return string The formatted connection resource. - */ - public static function connectionName($project, $location, $connection) - { - return self::getConnectionNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'connection' => $connection, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * deidentify_template resource. - * - * @param string $organization - * @param string $deidentifyTemplate - * - * @return string The formatted deidentify_template resource. - */ - public static function deidentifyTemplateName($organization, $deidentifyTemplate) - { - return self::getDeidentifyTemplateNameTemplate()->render([ - 'organization' => $organization, - 'deidentify_template' => $deidentifyTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * discovery_config resource. - * - * @param string $project - * @param string $location - * @param string $discoveryConfig - * - * @return string The formatted discovery_config resource. - */ - public static function discoveryConfigName($project, $location, $discoveryConfig) - { - return self::getDiscoveryConfigNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'discovery_config' => $discoveryConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a dlp_job - * resource. - * - * @param string $project - * @param string $dlpJob - * - * @return string The formatted dlp_job resource. - */ - public static function dlpJobName($project, $dlpJob) - { - return self::getDlpJobNameTemplate()->render([ - 'project' => $project, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * inspect_template resource. - * - * @param string $organization - * @param string $inspectTemplate - * - * @return string The formatted inspect_template resource. - */ - public static function inspectTemplateName($organization, $inspectTemplate) - { - return self::getInspectTemplateNameTemplate()->render([ - 'organization' => $organization, - 'inspect_template' => $inspectTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a job_trigger - * resource. - * - * @param string $project - * @param string $jobTrigger - * - * @return string The formatted job_trigger resource. - */ - public static function jobTriggerName($project, $jobTrigger) - { - return self::getJobTriggerNameTemplate()->render([ - 'project' => $project, - 'job_trigger' => $jobTrigger, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a organization - * resource. - * - * @param string $organization - * - * @return string The formatted organization resource. - */ - public static function organizationName($organization) - { - return self::getOrganizationNameTemplate()->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_deidentify_template resource. - * - * @param string $organization - * @param string $deidentifyTemplate - * - * @return string The formatted organization_deidentify_template resource. - */ - public static function organizationDeidentifyTemplateName($organization, $deidentifyTemplate) - { - return self::getOrganizationDeidentifyTemplateNameTemplate()->render([ - 'organization' => $organization, - 'deidentify_template' => $deidentifyTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_inspect_template resource. - * - * @param string $organization - * @param string $inspectTemplate - * - * @return string The formatted organization_inspect_template resource. - */ - public static function organizationInspectTemplateName($organization, $inspectTemplate) - { - return self::getOrganizationInspectTemplateNameTemplate()->render([ - 'organization' => $organization, - 'inspect_template' => $inspectTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location resource. - * - * @param string $organization - * @param string $location - * - * @return string The formatted organization_location resource. - */ - public static function organizationLocationName($organization, $location) - { - return self::getOrganizationLocationNameTemplate()->render([ - 'organization' => $organization, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_column_data_profile resource. - * - * @param string $organization - * @param string $location - * @param string $columnDataProfile - * - * @return string The formatted organization_location_column_data_profile resource. - */ - public static function organizationLocationColumnDataProfileName($organization, $location, $columnDataProfile) - { - return self::getOrganizationLocationColumnDataProfileNameTemplate()->render([ - 'organization' => $organization, - 'location' => $location, - 'column_data_profile' => $columnDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_deidentify_template resource. - * - * @param string $organization - * @param string $location - * @param string $deidentifyTemplate - * - * @return string The formatted organization_location_deidentify_template resource. - */ - public static function organizationLocationDeidentifyTemplateName($organization, $location, $deidentifyTemplate) - { - return self::getOrganizationLocationDeidentifyTemplateNameTemplate()->render([ - 'organization' => $organization, - 'location' => $location, - 'deidentify_template' => $deidentifyTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_inspect_template resource. - * - * @param string $organization - * @param string $location - * @param string $inspectTemplate - * - * @return string The formatted organization_location_inspect_template resource. - */ - public static function organizationLocationInspectTemplateName($organization, $location, $inspectTemplate) - { - return self::getOrganizationLocationInspectTemplateNameTemplate()->render([ - 'organization' => $organization, - 'location' => $location, - 'inspect_template' => $inspectTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_project_data_profile resource. - * - * @param string $organization - * @param string $location - * @param string $projectDataProfile - * - * @return string The formatted organization_location_project_data_profile resource. - */ - public static function organizationLocationProjectDataProfileName($organization, $location, $projectDataProfile) - { - return self::getOrganizationLocationProjectDataProfileNameTemplate()->render([ - 'organization' => $organization, - 'location' => $location, - 'project_data_profile' => $projectDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_stored_info_type resource. - * - * @param string $organization - * @param string $location - * @param string $storedInfoType - * - * @return string The formatted organization_location_stored_info_type resource. - */ - public static function organizationLocationStoredInfoTypeName($organization, $location, $storedInfoType) - { - return self::getOrganizationLocationStoredInfoTypeNameTemplate()->render([ - 'organization' => $organization, - 'location' => $location, - 'stored_info_type' => $storedInfoType, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_table_data_profile resource. - * - * @param string $organization - * @param string $location - * @param string $tableDataProfile - * - * @return string The formatted organization_location_table_data_profile resource. - */ - public static function organizationLocationTableDataProfileName($organization, $location, $tableDataProfile) - { - return self::getOrganizationLocationTableDataProfileNameTemplate()->render([ - 'organization' => $organization, - 'location' => $location, - 'table_data_profile' => $tableDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_stored_info_type resource. - * - * @param string $organization - * @param string $storedInfoType - * - * @return string The formatted organization_stored_info_type resource. - */ - public static function organizationStoredInfoTypeName($organization, $storedInfoType) - { - return self::getOrganizationStoredInfoTypeNameTemplate()->render([ - 'organization' => $organization, - 'stored_info_type' => $storedInfoType, - ]); - } - - /** - * 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, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_data_profile resource. - * - * @param string $organization - * @param string $location - * @param string $projectDataProfile - * - * @return string The formatted project_data_profile resource. - */ - public static function projectDataProfileName($organization, $location, $projectDataProfile) - { - return self::getProjectDataProfileNameTemplate()->render([ - 'organization' => $organization, - 'location' => $location, - 'project_data_profile' => $projectDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_deidentify_template resource. - * - * @param string $project - * @param string $deidentifyTemplate - * - * @return string The formatted project_deidentify_template resource. - */ - public static function projectDeidentifyTemplateName($project, $deidentifyTemplate) - { - return self::getProjectDeidentifyTemplateNameTemplate()->render([ - 'project' => $project, - 'deidentify_template' => $deidentifyTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_dlp_job resource. - * - * @param string $project - * @param string $dlpJob - * - * @return string The formatted project_dlp_job resource. - */ - public static function projectDlpJobName($project, $dlpJob) - { - return self::getProjectDlpJobNameTemplate()->render([ - 'project' => $project, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_inspect_template resource. - * - * @param string $project - * @param string $inspectTemplate - * - * @return string The formatted project_inspect_template resource. - */ - public static function projectInspectTemplateName($project, $inspectTemplate) - { - return self::getProjectInspectTemplateNameTemplate()->render([ - 'project' => $project, - 'inspect_template' => $inspectTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_job_trigger resource. - * - * @param string $project - * @param string $jobTrigger - * - * @return string The formatted project_job_trigger resource. - */ - public static function projectJobTriggerName($project, $jobTrigger) - { - return self::getProjectJobTriggerNameTemplate()->render([ - 'project' => $project, - 'job_trigger' => $jobTrigger, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_column_data_profile resource. - * - * @param string $project - * @param string $location - * @param string $columnDataProfile - * - * @return string The formatted project_location_column_data_profile resource. - */ - public static function projectLocationColumnDataProfileName($project, $location, $columnDataProfile) - { - return self::getProjectLocationColumnDataProfileNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'column_data_profile' => $columnDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_deidentify_template resource. - * - * @param string $project - * @param string $location - * @param string $deidentifyTemplate - * - * @return string The formatted project_location_deidentify_template resource. - */ - public static function projectLocationDeidentifyTemplateName($project, $location, $deidentifyTemplate) - { - return self::getProjectLocationDeidentifyTemplateNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'deidentify_template' => $deidentifyTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_dlp_job resource. - * - * @param string $project - * @param string $location - * @param string $dlpJob - * - * @return string The formatted project_location_dlp_job resource. - */ - public static function projectLocationDlpJobName($project, $location, $dlpJob) - { - return self::getProjectLocationDlpJobNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_inspect_template resource. - * - * @param string $project - * @param string $location - * @param string $inspectTemplate - * - * @return string The formatted project_location_inspect_template resource. - */ - public static function projectLocationInspectTemplateName($project, $location, $inspectTemplate) - { - return self::getProjectLocationInspectTemplateNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'inspect_template' => $inspectTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_job_trigger resource. - * - * @param string $project - * @param string $location - * @param string $jobTrigger - * - * @return string The formatted project_location_job_trigger resource. - */ - public static function projectLocationJobTriggerName($project, $location, $jobTrigger) - { - return self::getProjectLocationJobTriggerNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'job_trigger' => $jobTrigger, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_project_data_profile resource. - * - * @param string $project - * @param string $location - * @param string $projectDataProfile - * - * @return string The formatted project_location_project_data_profile resource. - */ - public static function projectLocationProjectDataProfileName($project, $location, $projectDataProfile) - { - return self::getProjectLocationProjectDataProfileNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'project_data_profile' => $projectDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_stored_info_type resource. - * - * @param string $project - * @param string $location - * @param string $storedInfoType - * - * @return string The formatted project_location_stored_info_type resource. - */ - public static function projectLocationStoredInfoTypeName($project, $location, $storedInfoType) - { - return self::getProjectLocationStoredInfoTypeNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'stored_info_type' => $storedInfoType, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_table_data_profile resource. - * - * @param string $project - * @param string $location - * @param string $tableDataProfile - * - * @return string The formatted project_location_table_data_profile resource. - */ - public static function projectLocationTableDataProfileName($project, $location, $tableDataProfile) - { - return self::getProjectLocationTableDataProfileNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'table_data_profile' => $tableDataProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_stored_info_type resource. - * - * @param string $project - * @param string $storedInfoType - * - * @return string The formatted project_stored_info_type resource. - */ - public static function projectStoredInfoTypeName($project, $storedInfoType) - { - return self::getProjectStoredInfoTypeNameTemplate()->render([ - 'project' => $project, - 'stored_info_type' => $storedInfoType, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * stored_info_type resource. - * - * @param string $organization - * @param string $storedInfoType - * - * @return string The formatted stored_info_type resource. - */ - public static function storedInfoTypeName($organization, $storedInfoType) - { - return self::getStoredInfoTypeNameTemplate()->render([ - 'organization' => $organization, - 'stored_info_type' => $storedInfoType, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * table_data_profile resource. - * - * @param string $organization - * @param string $location - * @param string $tableDataProfile - * - * @return string The formatted table_data_profile resource. - */ - public static function tableDataProfileName($organization, $location, $tableDataProfile) - { - return self::getTableDataProfileNameTemplate()->render([ - 'organization' => $organization, - 'location' => $location, - 'table_data_profile' => $tableDataProfile, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - columnDataProfile: organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile} - * - connection: projects/{project}/locations/{location}/connections/{connection} - * - deidentifyTemplate: organizations/{organization}/deidentifyTemplates/{deidentify_template} - * - discoveryConfig: projects/{project}/locations/{location}/discoveryConfigs/{discovery_config} - * - dlpJob: projects/{project}/dlpJobs/{dlp_job} - * - inspectTemplate: organizations/{organization}/inspectTemplates/{inspect_template} - * - jobTrigger: projects/{project}/jobTriggers/{job_trigger} - * - location: projects/{project}/locations/{location} - * - organization: organizations/{organization} - * - organizationDeidentifyTemplate: organizations/{organization}/deidentifyTemplates/{deidentify_template} - * - organizationInspectTemplate: organizations/{organization}/inspectTemplates/{inspect_template} - * - organizationLocation: organizations/{organization}/locations/{location} - * - organizationLocationColumnDataProfile: organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile} - * - organizationLocationDeidentifyTemplate: organizations/{organization}/locations/{location}/deidentifyTemplates/{deidentify_template} - * - organizationLocationInspectTemplate: organizations/{organization}/locations/{location}/inspectTemplates/{inspect_template} - * - organizationLocationProjectDataProfile: organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile} - * - organizationLocationStoredInfoType: organizations/{organization}/locations/{location}/storedInfoTypes/{stored_info_type} - * - organizationLocationTableDataProfile: organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile} - * - organizationStoredInfoType: organizations/{organization}/storedInfoTypes/{stored_info_type} - * - project: projects/{project} - * - projectDataProfile: organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile} - * - projectDeidentifyTemplate: projects/{project}/deidentifyTemplates/{deidentify_template} - * - projectDlpJob: projects/{project}/dlpJobs/{dlp_job} - * - projectInspectTemplate: projects/{project}/inspectTemplates/{inspect_template} - * - projectJobTrigger: projects/{project}/jobTriggers/{job_trigger} - * - projectLocationColumnDataProfile: projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile} - * - projectLocationDeidentifyTemplate: projects/{project}/locations/{location}/deidentifyTemplates/{deidentify_template} - * - projectLocationDlpJob: projects/{project}/locations/{location}/dlpJobs/{dlp_job} - * - projectLocationInspectTemplate: projects/{project}/locations/{location}/inspectTemplates/{inspect_template} - * - projectLocationJobTrigger: projects/{project}/locations/{location}/jobTriggers/{job_trigger} - * - projectLocationProjectDataProfile: projects/{project}/locations/{location}/projectDataProfiles/{project_data_profile} - * - projectLocationStoredInfoType: projects/{project}/locations/{location}/storedInfoTypes/{stored_info_type} - * - projectLocationTableDataProfile: projects/{project}/locations/{location}/tableDataProfiles/{table_data_profile} - * - projectStoredInfoType: projects/{project}/storedInfoTypes/{stored_info_type} - * - storedInfoType: organizations/{organization}/storedInfoTypes/{stored_info_type} - * - tableDataProfile: organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile} - * - * 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 'dlp.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); - } - - /** - * Activate a job trigger. Causes the immediate execute of a trigger - * instead of waiting on the trigger event to occur. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - * $response = $dlpServiceClient->activateJobTrigger($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the trigger to activate, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * @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 \Google\Cloud\Dlp\V2\DlpJob - * - * @throws ApiException if the remote call fails - */ - public function activateJobTrigger($name, array $optionalArgs = []) - { - $request = new ActivateJobTriggerRequest(); - $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('ActivateJobTrigger', DlpJob::class, $optionalArgs, $request)->wait(); - } - - /** - * Starts asynchronous cancellation on a long-running DlpJob. The server - * makes a best effort to cancel the DlpJob, but success is not - * guaranteed. - * See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage - * and - * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - * $dlpServiceClient->cancelDlpJob($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the DlpJob resource to be cancelled. - * @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 cancelDlpJob($name, array $optionalArgs = []) - { - $request = new CancelDlpJobRequest(); - $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('CancelDlpJob', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Create a Connection to an external data source. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $connection = new Connection(); - * $response = $dlpServiceClient->createConnection($formattedParent, $connection); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name in the format: - * `projects/{project}/locations/{location}`. - * @param Connection $connection Required. The connection resource. - * @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 \Google\Cloud\Dlp\V2\Connection - * - * @throws ApiException if the remote call fails - */ - public function createConnection($parent, $connection, array $optionalArgs = []) - { - $request = new CreateConnectionRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setConnection($connection); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateConnection', Connection::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a DeidentifyTemplate for reusing frequently used configuration - * for de-identifying content, images, and storage. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - * $deidentifyTemplate = new DeidentifyTemplate(); - * $response = $dlpServiceClient->createDeidentifyTemplate($formattedParent, $deidentifyTemplate); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param DeidentifyTemplate $deidentifyTemplate Required. The DeidentifyTemplate to create. - * @param array $optionalArgs { - * Optional. - * - * @type string $templateId - * The template id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * @type string $locationId - * Deprecated. This field has no effect. - * @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\Cloud\Dlp\V2\DeidentifyTemplate - * - * @throws ApiException if the remote call fails - */ - public function createDeidentifyTemplate($parent, $deidentifyTemplate, array $optionalArgs = []) - { - $request = new CreateDeidentifyTemplateRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setDeidentifyTemplate($deidentifyTemplate); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['templateId'])) { - $request->setTemplateId($optionalArgs['templateId']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateDeidentifyTemplate', DeidentifyTemplate::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a config for discovery to scan and profile storage. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $discoveryConfig = new DiscoveryConfig(); - * $response = $dlpServiceClient->createDiscoveryConfig($formattedParent, $discoveryConfig); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value is as follows: - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param DiscoveryConfig $discoveryConfig Required. The DiscoveryConfig to create. - * @param array $optionalArgs { - * Optional. - * - * @type string $configId - * The config ID can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * @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\Cloud\Dlp\V2\DiscoveryConfig - * - * @throws ApiException if the remote call fails - */ - public function createDiscoveryConfig($parent, $discoveryConfig, array $optionalArgs = []) - { - $request = new CreateDiscoveryConfigRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setDiscoveryConfig($discoveryConfig); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['configId'])) { - $request->setConfigId($optionalArgs['configId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateDiscoveryConfig', DiscoveryConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a new job to inspect storage or calculate risk metrics. - * See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage - * and - * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis - * to learn more. - * - * When no InfoTypes or CustomInfoTypes are specified in inspect jobs, the - * system will automatically choose what detectors to run. By default this may - * be all types, but may change over time as detectors are updated. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->projectName('[PROJECT]'); - * $response = $dlpServiceClient->createDlpJob($formattedParent); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param array $optionalArgs { - * Optional. - * - * @type InspectJobConfig $inspectJob - * An inspection job scans a storage repository for InfoTypes. - * @type RiskAnalysisJobConfig $riskJob - * A risk analysis job calculates re-identification risk metrics for a - * BigQuery table. - * @type string $jobId - * The job id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * @type string $locationId - * Deprecated. This field has no effect. - * @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\Cloud\Dlp\V2\DlpJob - * - * @throws ApiException if the remote call fails - */ - public function createDlpJob($parent, array $optionalArgs = []) - { - $request = new CreateDlpJobRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['inspectJob'])) { - $request->setInspectJob($optionalArgs['inspectJob']); - } - - if (isset($optionalArgs['riskJob'])) { - $request->setRiskJob($optionalArgs['riskJob']); - } - - if (isset($optionalArgs['jobId'])) { - $request->setJobId($optionalArgs['jobId']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateDlpJob', DlpJob::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates an InspectTemplate for reusing frequently used configuration - * for inspecting content, images, and storage. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - * $inspectTemplate = new InspectTemplate(); - * $response = $dlpServiceClient->createInspectTemplate($formattedParent, $inspectTemplate); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param InspectTemplate $inspectTemplate Required. The InspectTemplate to create. - * @param array $optionalArgs { - * Optional. - * - * @type string $templateId - * The template id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * @type string $locationId - * Deprecated. This field has no effect. - * @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\Cloud\Dlp\V2\InspectTemplate - * - * @throws ApiException if the remote call fails - */ - public function createInspectTemplate($parent, $inspectTemplate, array $optionalArgs = []) - { - $request = new CreateInspectTemplateRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setInspectTemplate($inspectTemplate); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['templateId'])) { - $request->setTemplateId($optionalArgs['templateId']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateInspectTemplate', InspectTemplate::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a job trigger to run DLP actions such as scanning storage for - * sensitive information on a set schedule. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->projectName('[PROJECT]'); - * $jobTrigger = new JobTrigger(); - * $response = $dlpServiceClient->createJobTrigger($formattedParent, $jobTrigger); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param JobTrigger $jobTrigger Required. The JobTrigger to create. - * @param array $optionalArgs { - * Optional. - * - * @type string $triggerId - * The trigger id can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * @type string $locationId - * Deprecated. This field has no effect. - * @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\Cloud\Dlp\V2\JobTrigger - * - * @throws ApiException if the remote call fails - */ - public function createJobTrigger($parent, $jobTrigger, array $optionalArgs = []) - { - $request = new CreateJobTriggerRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setJobTrigger($jobTrigger); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['triggerId'])) { - $request->setTriggerId($optionalArgs['triggerId']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateJobTrigger', JobTrigger::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a pre-built stored infoType to be used for inspection. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - * $config = new StoredInfoTypeConfig(); - * $response = $dlpServiceClient->createStoredInfoType($formattedParent, $config); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param StoredInfoTypeConfig $config Required. Configuration of the storedInfoType to create. - * @param array $optionalArgs { - * Optional. - * - * @type string $storedInfoTypeId - * The storedInfoType ID can contain uppercase and lowercase letters, - * numbers, and hyphens; that is, it must match the regular - * expression: `[a-zA-Z\d-_]+`. The maximum length is 100 - * characters. Can be empty to allow the system to generate one. - * @type string $locationId - * Deprecated. This field has no effect. - * @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\Cloud\Dlp\V2\StoredInfoType - * - * @throws ApiException if the remote call fails - */ - public function createStoredInfoType($parent, $config, array $optionalArgs = []) - { - $request = new CreateStoredInfoTypeRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setConfig($config); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['storedInfoTypeId'])) { - $request->setStoredInfoTypeId($optionalArgs['storedInfoTypeId']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateStoredInfoType', StoredInfoType::class, $optionalArgs, $request)->wait(); - } - - /** - * De-identifies potentially sensitive info from a ContentItem. - * This method has limits on input size and output size. - * See - * https://cloud.google.com/sensitive-data-protection/docs/deidentify-sensitive-data - * to learn more. - * - * When no InfoTypes or CustomInfoTypes are specified in this request, the - * system will automatically choose what detectors to run. By default this may - * be all types, but may change over time as detectors are updated. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $response = $dlpServiceClient->deidentifyContent(); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $parent - * Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @type DeidentifyConfig $deidentifyConfig - * Configuration for the de-identification of the content item. - * Items specified here will override the template referenced by the - * deidentify_template_name argument. - * @type InspectConfig $inspectConfig - * Configuration for the inspector. - * Items specified here will override the template referenced by the - * inspect_template_name argument. - * @type ContentItem $item - * The item to de-identify. Will be treated as text. - * - * This value must be of type - * [Table][google.privacy.dlp.v2.Table] if your - * [deidentify_config][google.privacy.dlp.v2.DeidentifyContentRequest.deidentify_config] - * is a - * [RecordTransformations][google.privacy.dlp.v2.RecordTransformations] - * object. - * @type string $inspectTemplateName - * Template to use. Any configuration directly specified in - * inspect_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * @type string $deidentifyTemplateName - * Template to use. Any configuration directly specified in - * deidentify_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * @type string $locationId - * Deprecated. This field has no effect. - * @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\Cloud\Dlp\V2\DeidentifyContentResponse - * - * @throws ApiException if the remote call fails - */ - public function deidentifyContent(array $optionalArgs = []) - { - $request = new DeidentifyContentRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['parent'])) { - $request->setParent($optionalArgs['parent']); - $requestParamHeaders['parent'] = $optionalArgs['parent']; - } - - if (isset($optionalArgs['deidentifyConfig'])) { - $request->setDeidentifyConfig($optionalArgs['deidentifyConfig']); - } - - if (isset($optionalArgs['inspectConfig'])) { - $request->setInspectConfig($optionalArgs['inspectConfig']); - } - - if (isset($optionalArgs['item'])) { - $request->setItem($optionalArgs['item']); - } - - if (isset($optionalArgs['inspectTemplateName'])) { - $request->setInspectTemplateName($optionalArgs['inspectTemplateName']); - } - - if (isset($optionalArgs['deidentifyTemplateName'])) { - $request->setDeidentifyTemplateName($optionalArgs['deidentifyTemplateName']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeidentifyContent', DeidentifyContentResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Delete a Connection. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - * $dlpServiceClient->deleteConnection($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the Connection to be deleted, in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * @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 deleteConnection($name, array $optionalArgs = []) - { - $request = new DeleteConnectionRequest(); - $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('DeleteConnection', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a DeidentifyTemplate. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - * $dlpServiceClient->deleteDeidentifyTemplate($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the organization and deidentify template to be - * deleted, for example - * `organizations/433245324/deidentifyTemplates/432452342` or - * projects/project-id/deidentifyTemplates/432452342. - * @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 deleteDeidentifyTemplate($name, array $optionalArgs = []) - { - $request = new DeleteDeidentifyTemplateRequest(); - $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('DeleteDeidentifyTemplate', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a discovery configuration. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - * $dlpServiceClient->deleteDiscoveryConfig($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the project and the config, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * @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 deleteDiscoveryConfig($name, array $optionalArgs = []) - { - $request = new DeleteDiscoveryConfigRequest(); - $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('DeleteDiscoveryConfig', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a long-running DlpJob. This method indicates that the client is - * no longer interested in the DlpJob result. The job will be canceled if - * possible. - * See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage - * and - * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - * $dlpServiceClient->deleteDlpJob($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the DlpJob resource to be deleted. - * @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 deleteDlpJob($name, array $optionalArgs = []) - { - $request = new DeleteDlpJobRequest(); - $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('DeleteDlpJob', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes an InspectTemplate. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - * $dlpServiceClient->deleteInspectTemplate($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the organization and inspectTemplate to be - * deleted, for example `organizations/433245324/inspectTemplates/432452342` - * or projects/project-id/inspectTemplates/432452342. - * @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 deleteInspectTemplate($name, array $optionalArgs = []) - { - $request = new DeleteInspectTemplateRequest(); - $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('DeleteInspectTemplate', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a job trigger. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - * $dlpServiceClient->deleteJobTrigger($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * @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 deleteJobTrigger($name, array $optionalArgs = []) - { - $request = new DeleteJobTriggerRequest(); - $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('DeleteJobTrigger', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a stored infoType. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - * $dlpServiceClient->deleteStoredInfoType($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the organization and storedInfoType to be - * deleted, for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * @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 deleteStoredInfoType($name, array $optionalArgs = []) - { - $request = new DeleteStoredInfoTypeRequest(); - $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('DeleteStoredInfoType', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Delete a TableDataProfile. Will not prevent the profile from being - * regenerated if the table is still included in a discovery configuration. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); - * $dlpServiceClient->deleteTableDataProfile($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the table data profile. - * @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 deleteTableDataProfile($name, array $optionalArgs = []) - { - $request = new DeleteTableDataProfileRequest(); - $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('DeleteTableDataProfile', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Finish a running hybrid DlpJob. Triggers the finalization steps and running - * of any enabled actions that have not yet run. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - * $dlpServiceClient->finishDlpJob($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the DlpJob resource to be finished. - * @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 finishDlpJob($name, array $optionalArgs = []) - { - $request = new FinishDlpJobRequest(); - $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('FinishDlpJob', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a column data profile. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->columnDataProfileName('[ORGANIZATION]', '[LOCATION]', '[COLUMN_DATA_PROFILE]'); - * $response = $dlpServiceClient->getColumnDataProfile($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name, for example - * `organizations/12345/locations/us/columnDataProfiles/53234423`. - * @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 \Google\Cloud\Dlp\V2\ColumnDataProfile - * - * @throws ApiException if the remote call fails - */ - public function getColumnDataProfile($name, array $optionalArgs = []) - { - $request = new GetColumnDataProfileRequest(); - $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('GetColumnDataProfile', ColumnDataProfile::class, $optionalArgs, $request)->wait(); - } - - /** - * Get a Connection by name. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - * $response = $dlpServiceClient->getConnection($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * @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 \Google\Cloud\Dlp\V2\Connection - * - * @throws ApiException if the remote call fails - */ - public function getConnection($name, array $optionalArgs = []) - { - $request = new GetConnectionRequest(); - $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('GetConnection', Connection::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a DeidentifyTemplate. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - * $response = $dlpServiceClient->getDeidentifyTemplate($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the organization and deidentify template to be - * read, for example `organizations/433245324/deidentifyTemplates/432452342` - * or projects/project-id/deidentifyTemplates/432452342. - * @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 \Google\Cloud\Dlp\V2\DeidentifyTemplate - * - * @throws ApiException if the remote call fails - */ - public function getDeidentifyTemplate($name, array $optionalArgs = []) - { - $request = new GetDeidentifyTemplateRequest(); - $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('GetDeidentifyTemplate', DeidentifyTemplate::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a discovery configuration. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - * $response = $dlpServiceClient->getDiscoveryConfig($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the project and the configuration, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * @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 \Google\Cloud\Dlp\V2\DiscoveryConfig - * - * @throws ApiException if the remote call fails - */ - public function getDiscoveryConfig($name, array $optionalArgs = []) - { - $request = new GetDiscoveryConfigRequest(); - $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('GetDiscoveryConfig', DiscoveryConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the latest state of a long-running DlpJob. - * See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage - * and - * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - * $response = $dlpServiceClient->getDlpJob($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the DlpJob resource. - * @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 \Google\Cloud\Dlp\V2\DlpJob - * - * @throws ApiException if the remote call fails - */ - public function getDlpJob($name, array $optionalArgs = []) - { - $request = new GetDlpJobRequest(); - $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('GetDlpJob', DlpJob::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets an InspectTemplate. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - * $response = $dlpServiceClient->getInspectTemplate($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the organization and inspectTemplate to be read, - * for example `organizations/433245324/inspectTemplates/432452342` or - * projects/project-id/inspectTemplates/432452342. - * @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 \Google\Cloud\Dlp\V2\InspectTemplate - * - * @throws ApiException if the remote call fails - */ - public function getInspectTemplate($name, array $optionalArgs = []) - { - $request = new GetInspectTemplateRequest(); - $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('GetInspectTemplate', InspectTemplate::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a job trigger. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - * $response = $dlpServiceClient->getJobTrigger($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * @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 \Google\Cloud\Dlp\V2\JobTrigger - * - * @throws ApiException if the remote call fails - */ - public function getJobTrigger($name, array $optionalArgs = []) - { - $request = new GetJobTriggerRequest(); - $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('GetJobTrigger', JobTrigger::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a project data profile. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->projectDataProfileName('[ORGANIZATION]', '[LOCATION]', '[PROJECT_DATA_PROFILE]'); - * $response = $dlpServiceClient->getProjectDataProfile($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name, for example - * `organizations/12345/locations/us/projectDataProfiles/53234423`. - * @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 \Google\Cloud\Dlp\V2\ProjectDataProfile - * - * @throws ApiException if the remote call fails - */ - public function getProjectDataProfile($name, array $optionalArgs = []) - { - $request = new GetProjectDataProfileRequest(); - $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('GetProjectDataProfile', ProjectDataProfile::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a stored infoType. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - * $response = $dlpServiceClient->getStoredInfoType($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the organization and storedInfoType to be read, - * for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * @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 \Google\Cloud\Dlp\V2\StoredInfoType - * - * @throws ApiException if the remote call fails - */ - public function getStoredInfoType($name, array $optionalArgs = []) - { - $request = new GetStoredInfoTypeRequest(); - $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('GetStoredInfoType', StoredInfoType::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a table data profile. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); - * $response = $dlpServiceClient->getTableDataProfile($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name, for example - * `organizations/12345/locations/us/tableDataProfiles/53234423`. - * @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 \Google\Cloud\Dlp\V2\TableDataProfile - * - * @throws ApiException if the remote call fails - */ - public function getTableDataProfile($name, array $optionalArgs = []) - { - $request = new GetTableDataProfileRequest(); - $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('GetTableDataProfile', TableDataProfile::class, $optionalArgs, $request)->wait(); - } - - /** - * Inspect hybrid content and store findings to a job. - * To review the findings, inspect the job. Inspection will occur - * asynchronously. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - * $response = $dlpServiceClient->hybridInspectDlpJob($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the job to execute a hybrid inspect on, for - * example `projects/dlp-test-project/dlpJob/53234423`. - * @param array $optionalArgs { - * Optional. - * - * @type HybridContentItem $hybridItem - * The item to inspect. - * @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\Cloud\Dlp\V2\HybridInspectResponse - * - * @throws ApiException if the remote call fails - */ - public function hybridInspectDlpJob($name, array $optionalArgs = []) - { - $request = new HybridInspectDlpJobRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['hybridItem'])) { - $request->setHybridItem($optionalArgs['hybridItem']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('HybridInspectDlpJob', HybridInspectResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Inspect hybrid content and store findings to a trigger. The inspection - * will be processed asynchronously. To review the findings monitor the - * jobs within the trigger. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - * $response = $dlpServiceClient->hybridInspectJobTrigger($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the trigger to execute a hybrid inspect on, for - * example `projects/dlp-test-project/jobTriggers/53234423`. - * @param array $optionalArgs { - * Optional. - * - * @type HybridContentItem $hybridItem - * The item to inspect. - * @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\Cloud\Dlp\V2\HybridInspectResponse - * - * @throws ApiException if the remote call fails - */ - public function hybridInspectJobTrigger($name, array $optionalArgs = []) - { - $request = new HybridInspectJobTriggerRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['hybridItem'])) { - $request->setHybridItem($optionalArgs['hybridItem']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('HybridInspectJobTrigger', HybridInspectResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Finds potentially sensitive info in content. - * This method has limits on input size, processing time, and output size. - * - * When no InfoTypes or CustomInfoTypes are specified in this request, the - * system will automatically choose what detectors to run. By default this may - * be all types, but may change over time as detectors are updated. - * - * For how to guides, see - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-images - * and - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-text, - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $response = $dlpServiceClient->inspectContent(); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $parent - * Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @type InspectConfig $inspectConfig - * Configuration for the inspector. What specified here will override - * the template referenced by the inspect_template_name argument. - * @type ContentItem $item - * The item to inspect. - * @type string $inspectTemplateName - * Template to use. Any configuration directly specified in - * inspect_config will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * @type string $locationId - * Deprecated. This field has no effect. - * @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\Cloud\Dlp\V2\InspectContentResponse - * - * @throws ApiException if the remote call fails - */ - public function inspectContent(array $optionalArgs = []) - { - $request = new InspectContentRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['parent'])) { - $request->setParent($optionalArgs['parent']); - $requestParamHeaders['parent'] = $optionalArgs['parent']; - } - - if (isset($optionalArgs['inspectConfig'])) { - $request->setInspectConfig($optionalArgs['inspectConfig']); - } - - if (isset($optionalArgs['item'])) { - $request->setItem($optionalArgs['item']); - } - - if (isset($optionalArgs['inspectTemplateName'])) { - $request->setInspectTemplateName($optionalArgs['inspectTemplateName']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('InspectContent', InspectContentResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists column data profiles for an organization. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dlpServiceClient->listColumnDataProfiles($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dlpServiceClient->listColumnDataProfiles($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the organization or project, for - * example `organizations/433245324/locations/europe` or - * `projects/project-id/locations/asia`. - * @param array $optionalArgs { - * Optional. - * - * @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 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 $orderBy - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * - * Examples: - * * `project_id asc` - * * `table_id` - * * `sensitivity_level desc` - * - * Supported fields are: - * - * - `project_id`: The Google Cloud project ID. - * - `dataset_id`: The ID of a BigQuery dataset. - * - `table_id`: The ID of a BigQuery table. - * - `sensitivity_level`: How sensitive the data in a column is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * @type string $filter - * Allows filtering. - * - * Supported syntax: - * - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `table_data_profile_name` - The name of the related table data - * profile. - * - `project_id` - The Google Cloud project ID. (REQUIRED) - * - `dataset_id` - The BigQuery dataset ID. (REQUIRED) - * - `table_id` - The BigQuery table ID. (REQUIRED) - * - `field_id` - The ID of the BigQuery field. - * - `info_type` - The infotype detected in the resource. - * - `sensitivity_level` - HIGH|MEDIUM|LOW - * - `data_risk_level`: How much risk is associated with this data. - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` for project_id, dataset_id, and table_id. Other - * filters also support `!=`. - * - * Examples: - * - * * project_id = 12345 AND status_code = 1 - * * project_id = 12345 AND sensitivity_level = HIGH - * * project_id = 12345 AND info_type = STREET_ADDRESS - * - * The length of this field should be no more than 500 characters. - * @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 listColumnDataProfiles($parent, array $optionalArgs = []) - { - $request = new ListColumnDataProfilesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListColumnDataProfiles', $optionalArgs, ListColumnDataProfilesResponse::class, $request); - } - - /** - * Lists Connections in a parent. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dlpServiceClient->listConnections($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dlpServiceClient->listConnections($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent name, for example: - * `projects/project-id/locations/global`. - * @param array $optionalArgs { - * Optional. - * - * @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 string $filter - * Optional. Supported field/value: `state` - MISSING|AVAILABLE|ERROR - * @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 listConnections($parent, array $optionalArgs = []) - { - $request = new ListConnectionsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListConnections', $optionalArgs, ListConnectionsResponse::class, $request); - } - - /** - * Lists DeidentifyTemplates. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dlpServiceClient->listDeidentifyTemplates($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dlpServiceClient->listDeidentifyTemplates($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param array $optionalArgs { - * Optional. - * - * @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 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 $orderBy - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * - * Example: `name asc,update_time, create_time desc` - * - * Supported fields are: - * - * - `create_time`: corresponds to the time the template was created. - * - `update_time`: corresponds to the time the template was last updated. - * - `name`: corresponds to the template's name. - * - `display_name`: corresponds to the template's display name. - * @type string $locationId - * Deprecated. This field has no effect. - * @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 listDeidentifyTemplates($parent, array $optionalArgs = []) - { - $request = new ListDeidentifyTemplatesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListDeidentifyTemplates', $optionalArgs, ListDeidentifyTemplatesResponse::class, $request); - } - - /** - * Lists discovery configurations. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dlpServiceClient->listDiscoveryConfigs($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dlpServiceClient->listDiscoveryConfigs($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value is as follows: - * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param array $optionalArgs { - * Optional. - * - * @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 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 $orderBy - * Comma separated list of config fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * - * Example: `name asc,update_time, create_time desc` - * - * Supported fields are: - * - * - `last_run_time`: corresponds to the last time the DiscoveryConfig ran. - * - `name`: corresponds to the DiscoveryConfig's name. - * - `status`: corresponds to DiscoveryConfig's status. - * @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 listDiscoveryConfigs($parent, array $optionalArgs = []) - { - $request = new ListDiscoveryConfigsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListDiscoveryConfigs', $optionalArgs, ListDiscoveryConfigsResponse::class, $request); - } - - /** - * Lists DlpJobs that match the specified filter in the request. - * See - * https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage - * and - * https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->projectName('[PROJECT]'); - * // Iterate over pages of elements - * $pagedResponse = $dlpServiceClient->listDlpJobs($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dlpServiceClient->listDlpJobs($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * Allows filtering. - * - * Supported syntax: - * - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values for inspect jobs: - * - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED - * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - * - `trigger_name` - The name of the trigger that created the job. - * - 'end_time` - Corresponds to the time the job finished. - * - 'start_time` - Corresponds to the time the job finished. - * * Supported fields for risk analysis jobs: - * - `state` - RUNNING|CANCELED|FINISHED|FAILED - * - 'end_time` - Corresponds to the time the job finished. - * - 'start_time` - Corresponds to the time the job finished. - * * The operator must be `=` or `!=`. - * - * Examples: - * - * * inspected_storage = cloud_storage AND state = done - * * inspected_storage = cloud_storage OR inspected_storage = bigquery - * * inspected_storage = cloud_storage AND (state = done OR state = canceled) - * * end_time > \"2017-12-12T00:00:00+00:00\" - * - * The length of this field should be no more than 500 characters. - * @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 int $type - * The type of job. Defaults to `DlpJobType.INSPECT` - * For allowed values, use constants defined on {@see \Google\Cloud\Dlp\V2\DlpJobType} - * @type string $orderBy - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * - * Example: `name asc, end_time asc, create_time desc` - * - * Supported fields are: - * - * - `create_time`: corresponds to the time the job was created. - * - `end_time`: corresponds to the time the job ended. - * - `name`: corresponds to the job's name. - * - `state`: corresponds to `state` - * @type string $locationId - * Deprecated. This field has no effect. - * @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 listDlpJobs($parent, array $optionalArgs = []) - { - $request = new ListDlpJobsRequest(); - $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']); - } - - if (isset($optionalArgs['type'])) { - $request->setType($optionalArgs['type']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListDlpJobs', $optionalArgs, ListDlpJobsResponse::class, $request); - } - - /** - * Returns a list of the sensitive information types that DLP API - * supports. See - * https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $response = $dlpServiceClient->listInfoTypes(); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $parent - * The parent resource name. - * - * The format of this value is as follows: - * - * locations/LOCATION_ID - * @type string $languageCode - * BCP-47 language code for localized infoType friendly - * names. If omitted, or if localized strings are not available, - * en-US strings will be returned. - * @type string $filter - * filter to only return infoTypes supported by certain parts of the - * API. Defaults to supported_by=INSPECT. - * @type string $locationId - * Deprecated. This field has no effect. - * @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\Cloud\Dlp\V2\ListInfoTypesResponse - * - * @throws ApiException if the remote call fails - */ - public function listInfoTypes(array $optionalArgs = []) - { - $request = new ListInfoTypesRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['parent'])) { - $request->setParent($optionalArgs['parent']); - $requestParamHeaders['parent'] = $optionalArgs['parent']; - } - - if (isset($optionalArgs['languageCode'])) { - $request->setLanguageCode($optionalArgs['languageCode']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('ListInfoTypes', ListInfoTypesResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists InspectTemplates. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dlpServiceClient->listInspectTemplates($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dlpServiceClient->listInspectTemplates($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * + Organizations scope, location specified:
- * `organizations/`ORG_ID`/locations/`LOCATION_ID - * + Organizations scope, no location specified (defaults to global):
- * `organizations/`ORG_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param array $optionalArgs { - * Optional. - * - * @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 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 $orderBy - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * - * Example: `name asc,update_time, create_time desc` - * - * Supported fields are: - * - * - `create_time`: corresponds to the time the template was created. - * - `update_time`: corresponds to the time the template was last updated. - * - `name`: corresponds to the template's name. - * - `display_name`: corresponds to the template's display name. - * @type string $locationId - * Deprecated. This field has no effect. - * @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 listInspectTemplates($parent, array $optionalArgs = []) - { - $request = new ListInspectTemplatesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListInspectTemplates', $optionalArgs, ListInspectTemplatesResponse::class, $request); - } - - /** - * Lists job triggers. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->projectName('[PROJECT]'); - * // Iterate over pages of elements - * $pagedResponse = $dlpServiceClient->listJobTriggers($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dlpServiceClient->listJobTriggers($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param array $optionalArgs { - * Optional. - * - * @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 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 $orderBy - * Comma separated list of triggeredJob fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * - * Example: `name asc,update_time, create_time desc` - * - * Supported fields are: - * - * - `create_time`: corresponds to the time the JobTrigger was created. - * - `update_time`: corresponds to the time the JobTrigger was last updated. - * - `last_run_time`: corresponds to the last time the JobTrigger ran. - * - `name`: corresponds to the JobTrigger's name. - * - `display_name`: corresponds to the JobTrigger's display name. - * - `status`: corresponds to JobTrigger's status. - * @type string $filter - * Allows filtering. - * - * Supported syntax: - * - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values for inspect triggers: - * - `status` - HEALTHY|PAUSED|CANCELLED - * - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - * - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by - * quotation marks. Nanoseconds are ignored. - * - 'error_count' - Number of errors that have occurred while running. - * * The operator must be `=` or `!=` for status and inspected_storage. - * - * Examples: - * - * * inspected_storage = cloud_storage AND status = HEALTHY - * * inspected_storage = cloud_storage OR inspected_storage = bigquery - * * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) - * * last_run_time > \"2017-12-12T00:00:00+00:00\" - * - * The length of this field should be no more than 500 characters. - * @type int $type - * The type of jobs. Will use `DlpJobType.INSPECT` if not set. - * For allowed values, use constants defined on {@see \Google\Cloud\Dlp\V2\DlpJobType} - * @type string $locationId - * Deprecated. This field has no effect. - * @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 listJobTriggers($parent, array $optionalArgs = []) - { - $request = new ListJobTriggersRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['type'])) { - $request->setType($optionalArgs['type']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListJobTriggers', $optionalArgs, ListJobTriggersResponse::class, $request); - } - - /** - * Lists project data profiles for an organization. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dlpServiceClient->listProjectDataProfiles($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dlpServiceClient->listProjectDataProfiles($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. organizations/{org_id}/locations/{loc_id} - * @param array $optionalArgs { - * Optional. - * - * @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 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 $orderBy - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * - * Examples: - * * `project_id` - * * `sensitivity_level desc` - * - * Supported fields are: - * - * - `project_id`: Google Cloud project ID - * - `sensitivity_level`: How sensitive the data in a project is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * @type string $filter - * Allows filtering. - * - * Supported syntax: - * - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `sensitivity_level` - HIGH|MODERATE|LOW - * - `data_risk_level` - HIGH|MODERATE|LOW - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` or `!=`. - * - * Examples: - * - * * `project_id = 12345 AND status_code = 1` - * * `project_id = 12345 AND sensitivity_level = HIGH` - * - * The length of this field should be no more than 500 characters. - * @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 listProjectDataProfiles($parent, array $optionalArgs = []) - { - $request = new ListProjectDataProfilesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListProjectDataProfiles', $optionalArgs, ListProjectDataProfilesResponse::class, $request); - } - - /** - * Lists stored infoTypes. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dlpServiceClient->listStoredInfoTypes($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dlpServiceClient->listStoredInfoTypes($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on the scope of the request - * (project or organization) and whether you have [specified a processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param array $optionalArgs { - * Optional. - * - * @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 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 $orderBy - * Comma separated list of fields to order by, - * followed by `asc` or `desc` postfix. This list is case insensitive. The - * default sorting order is ascending. Redundant space characters are - * insignificant. - * - * Example: `name asc, display_name, create_time desc` - * - * Supported fields are: - * - * - `create_time`: corresponds to the time the most recent version of the - * resource was created. - * - `state`: corresponds to the state of the resource. - * - `name`: corresponds to resource name. - * - `display_name`: corresponds to info type's display name. - * @type string $locationId - * Deprecated. This field has no effect. - * @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 listStoredInfoTypes($parent, array $optionalArgs = []) - { - $request = new ListStoredInfoTypesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListStoredInfoTypes', $optionalArgs, ListStoredInfoTypesResponse::class, $request); - } - - /** - * Lists table data profiles for an organization. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dlpServiceClient->listTableDataProfiles($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dlpServiceClient->listTableDataProfiles($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the organization or project, for - * example `organizations/433245324/locations/europe` or - * `projects/project-id/locations/asia`. - * @param array $optionalArgs { - * Optional. - * - * @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 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 $orderBy - * Comma separated list of fields to order by, followed by `asc` or `desc` - * postfix. This list is case insensitive. The default sorting order is - * ascending. Redundant space characters are insignificant. Only one order - * field at a time is allowed. - * - * Examples: - * * `project_id asc` - * * `table_id` - * * `sensitivity_level desc` - * - * Supported fields are: - * - * - `project_id`: The Google Cloud project ID. - * - `dataset_id`: The ID of a BigQuery dataset. - * - `table_id`: The ID of a BigQuery table. - * - `sensitivity_level`: How sensitive the data in a table is, at most. - * - `data_risk_level`: How much risk is associated with this data. - * - `profile_last_generated`: When the profile was last updated in epoch - * seconds. - * - `last_modified`: The last time the resource was modified. - * - `resource_visibility`: Visibility restriction for this resource. - * - `row_count`: Number of rows in this resource. - * @type string $filter - * Allows filtering. - * - * Supported syntax: - * - * * Filter expressions are made up of one or more restrictions. - * * Restrictions can be combined by `AND` or `OR` logical operators. A - * sequence of restrictions implicitly uses `AND`. - * * A restriction has the form of `{field} {operator} {value}`. - * * Supported fields/values: - * - `project_id` - The Google Cloud project ID. - * - `dataset_id` - The BigQuery dataset ID. - * - `table_id` - The ID of the BigQuery table. - * - `sensitivity_level` - HIGH|MODERATE|LOW - * - `data_risk_level` - HIGH|MODERATE|LOW - * - `resource_visibility`: PUBLIC|RESTRICTED - * - `status_code` - an RPC status code as defined in - * https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto - * * The operator must be `=` or `!=`. - * - * Examples: - * - * * `project_id = 12345 AND status_code = 1` - * * `project_id = 12345 AND sensitivity_level = HIGH` - * * `project_id = 12345 AND resource_visibility = PUBLIC` - * - * The length of this field should be no more than 500 characters. - * @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 listTableDataProfiles($parent, array $optionalArgs = []) - { - $request = new ListTableDataProfilesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListTableDataProfiles', $optionalArgs, ListTableDataProfilesResponse::class, $request); - } - - /** - * Redacts potentially sensitive info from an image. - * This method has limits on input size, processing time, and output size. - * See - * https://cloud.google.com/sensitive-data-protection/docs/redacting-sensitive-data-images - * to learn more. - * - * When no InfoTypes or CustomInfoTypes are specified in this request, the - * system will automatically choose what detectors to run. By default this may - * be all types, but may change over time as detectors are updated. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $response = $dlpServiceClient->redactImage(); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $parent - * Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @type string $locationId - * Deprecated. This field has no effect. - * @type InspectConfig $inspectConfig - * Configuration for the inspector. - * @type ImageRedactionConfig[] $imageRedactionConfigs - * The configuration for specifying what content to redact from images. - * @type bool $includeFindings - * Whether the response should include findings along with the redacted - * image. - * @type ByteContentItem $byteItem - * The content must be PNG, JPEG, SVG or BMP. - * @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\Cloud\Dlp\V2\RedactImageResponse - * - * @throws ApiException if the remote call fails - */ - public function redactImage(array $optionalArgs = []) - { - $request = new RedactImageRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['parent'])) { - $request->setParent($optionalArgs['parent']); - $requestParamHeaders['parent'] = $optionalArgs['parent']; - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - if (isset($optionalArgs['inspectConfig'])) { - $request->setInspectConfig($optionalArgs['inspectConfig']); - } - - if (isset($optionalArgs['imageRedactionConfigs'])) { - $request->setImageRedactionConfigs($optionalArgs['imageRedactionConfigs']); - } - - if (isset($optionalArgs['includeFindings'])) { - $request->setIncludeFindings($optionalArgs['includeFindings']); - } - - if (isset($optionalArgs['byteItem'])) { - $request->setByteItem($optionalArgs['byteItem']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('RedactImage', RedactImageResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Re-identifies content that has been de-identified. - * See - * https://cloud.google.com/sensitive-data-protection/docs/pseudonymization#re-identification_in_free_text_code_example - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->projectName('[PROJECT]'); - * $response = $dlpServiceClient->reidentifyContent($formattedParent); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource name. - * - * The format of this value varies depending on whether you have [specified a - * processing - * location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): - * - * + Projects scope, location specified:
- * `projects/`PROJECT_ID`/locations/`LOCATION_ID - * + Projects scope, no location specified (defaults to global):
- * `projects/`PROJECT_ID - * - * The following example `parent` string specifies a parent project with the - * identifier `example-project`, and specifies the `europe-west3` location - * for processing data: - * - * parent=projects/example-project/locations/europe-west3 - * @param array $optionalArgs { - * Optional. - * - * @type DeidentifyConfig $reidentifyConfig - * Configuration for the re-identification of the content item. - * This field shares the same proto message type that is used for - * de-identification, however its usage here is for the reversal of the - * previous de-identification. Re-identification is performed by examining - * the transformations used to de-identify the items and executing the - * reverse. This requires that only reversible transformations - * be provided here. The reversible transformations are: - * - * - `CryptoDeterministicConfig` - * - `CryptoReplaceFfxFpeConfig` - * @type InspectConfig $inspectConfig - * Configuration for the inspector. - * @type ContentItem $item - * The item to re-identify. Will be treated as text. - * @type string $inspectTemplateName - * Template to use. Any configuration directly specified in - * `inspect_config` will override those set in the template. Singular fields - * that are set in this request will replace their corresponding fields in the - * template. Repeated fields are appended. Singular sub-messages and groups - * are recursively merged. - * @type string $reidentifyTemplateName - * Template to use. References an instance of `DeidentifyTemplate`. - * Any configuration directly specified in `reidentify_config` or - * `inspect_config` will override those set in the template. The - * `DeidentifyTemplate` used must include only reversible transformations. - * Singular fields that are set in this request will replace their - * corresponding fields in the template. Repeated fields are appended. - * Singular sub-messages and groups are recursively merged. - * @type string $locationId - * Deprecated. This field has no effect. - * @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\Cloud\Dlp\V2\ReidentifyContentResponse - * - * @throws ApiException if the remote call fails - */ - public function reidentifyContent($parent, array $optionalArgs = []) - { - $request = new ReidentifyContentRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['reidentifyConfig'])) { - $request->setReidentifyConfig($optionalArgs['reidentifyConfig']); - } - - if (isset($optionalArgs['inspectConfig'])) { - $request->setInspectConfig($optionalArgs['inspectConfig']); - } - - if (isset($optionalArgs['item'])) { - $request->setItem($optionalArgs['item']); - } - - if (isset($optionalArgs['inspectTemplateName'])) { - $request->setInspectTemplateName($optionalArgs['inspectTemplateName']); - } - - if (isset($optionalArgs['reidentifyTemplateName'])) { - $request->setReidentifyTemplateName($optionalArgs['reidentifyTemplateName']); - } - - if (isset($optionalArgs['locationId'])) { - $request->setLocationId($optionalArgs['locationId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('ReidentifyContent', ReidentifyContentResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Searches for Connections in a parent. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedParent = $dlpServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dlpServiceClient->searchConnections($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dlpServiceClient->searchConnections($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent name, typically an organization, without location. - * For example: `organizations/12345678`. - * @param array $optionalArgs { - * Optional. - * - * @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 string $filter - * Optional. Supported field/value: - `state` - MISSING|AVAILABLE|ERROR - * @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 searchConnections($parent, array $optionalArgs = []) - { - $request = new SearchConnectionsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('SearchConnections', $optionalArgs, SearchConnectionsResponse::class, $request); - } - - /** - * Update a Connection. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - * $connection = new Connection(); - * $response = $dlpServiceClient->updateConnection($formattedName, $connection); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name in the format: - * `projects/{project}/locations/{location}/connections/{connection}`. - * @param Connection $connection Required. The connection with new values for the relevant fields. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * Optional. Mask to control which fields get updated. - * @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\Cloud\Dlp\V2\Connection - * - * @throws ApiException if the remote call fails - */ - public function updateConnection($name, $connection, array $optionalArgs = []) - { - $request = new UpdateConnectionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $request->setConnection($connection); - $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('UpdateConnection', Connection::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates the DeidentifyTemplate. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - * $response = $dlpServiceClient->updateDeidentifyTemplate($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of organization and deidentify template to be - * updated, for example - * `organizations/433245324/deidentifyTemplates/432452342` or - * projects/project-id/deidentifyTemplates/432452342. - * @param array $optionalArgs { - * Optional. - * - * @type DeidentifyTemplate $deidentifyTemplate - * New DeidentifyTemplate value. - * @type FieldMask $updateMask - * Mask to control which fields get updated. - * @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\Cloud\Dlp\V2\DeidentifyTemplate - * - * @throws ApiException if the remote call fails - */ - public function updateDeidentifyTemplate($name, array $optionalArgs = []) - { - $request = new UpdateDeidentifyTemplateRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['deidentifyTemplate'])) { - $request->setDeidentifyTemplate($optionalArgs['deidentifyTemplate']); - } - - 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('UpdateDeidentifyTemplate', DeidentifyTemplate::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates a discovery configuration. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - * $discoveryConfig = new DiscoveryConfig(); - * $response = $dlpServiceClient->updateDiscoveryConfig($formattedName, $discoveryConfig); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the project and the configuration, for example - * `projects/dlp-test-project/discoveryConfigs/53234423`. - * @param DiscoveryConfig $discoveryConfig Required. New DiscoveryConfig value. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * Mask to control which fields get updated. - * @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\Cloud\Dlp\V2\DiscoveryConfig - * - * @throws ApiException if the remote call fails - */ - public function updateDiscoveryConfig($name, $discoveryConfig, array $optionalArgs = []) - { - $request = new UpdateDiscoveryConfigRequest(); - $requestParamHeaders = []; - $request->setName($name); - $request->setDiscoveryConfig($discoveryConfig); - $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('UpdateDiscoveryConfig', DiscoveryConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates the InspectTemplate. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-templates - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - * $response = $dlpServiceClient->updateInspectTemplate($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of organization and inspectTemplate to be updated, - * for example `organizations/433245324/inspectTemplates/432452342` or - * projects/project-id/inspectTemplates/432452342. - * @param array $optionalArgs { - * Optional. - * - * @type InspectTemplate $inspectTemplate - * New InspectTemplate value. - * @type FieldMask $updateMask - * Mask to control which fields get updated. - * @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\Cloud\Dlp\V2\InspectTemplate - * - * @throws ApiException if the remote call fails - */ - public function updateInspectTemplate($name, array $optionalArgs = []) - { - $request = new UpdateInspectTemplateRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['inspectTemplate'])) { - $request->setInspectTemplate($optionalArgs['inspectTemplate']); - } - - 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('UpdateInspectTemplate', InspectTemplate::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates a job trigger. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - * $response = $dlpServiceClient->updateJobTrigger($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the project and the triggeredJob, for example - * `projects/dlp-test-project/jobTriggers/53234423`. - * @param array $optionalArgs { - * Optional. - * - * @type JobTrigger $jobTrigger - * New JobTrigger value. - * @type FieldMask $updateMask - * Mask to control which fields get updated. - * @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\Cloud\Dlp\V2\JobTrigger - * - * @throws ApiException if the remote call fails - */ - public function updateJobTrigger($name, array $optionalArgs = []) - { - $request = new UpdateJobTriggerRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['jobTrigger'])) { - $request->setJobTrigger($optionalArgs['jobTrigger']); - } - - 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('UpdateJobTrigger', JobTrigger::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates the stored infoType by creating a new version. The existing version - * will continue to be used until the new version is ready. - * See - * https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes - * to learn more. - * - * Sample code: - * ``` - * $dlpServiceClient = new DlpServiceClient(); - * try { - * $formattedName = $dlpServiceClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - * $response = $dlpServiceClient->updateStoredInfoType($formattedName); - * } finally { - * $dlpServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of organization and storedInfoType to be updated, - * for example `organizations/433245324/storedInfoTypes/432452342` or - * projects/project-id/storedInfoTypes/432452342. - * @param array $optionalArgs { - * Optional. - * - * @type StoredInfoTypeConfig $config - * Updated configuration for the storedInfoType. If not provided, a new - * version of the storedInfoType will be created with the existing - * configuration. - * @type FieldMask $updateMask - * Mask to control which fields get updated. - * @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\Cloud\Dlp\V2\StoredInfoType - * - * @throws ApiException if the remote call fails - */ - public function updateStoredInfoType($name, array $optionalArgs = []) - { - $request = new UpdateStoredInfoTypeRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['config'])) { - $request->setConfig($optionalArgs['config']); - } - - 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('UpdateStoredInfoType', StoredInfoType::class, $optionalArgs, $request)->wait(); - } -} diff --git a/owl-bot-staging/Dlp/v2/src/V2/gapic_metadata.json b/owl-bot-staging/Dlp/v2/src/V2/gapic_metadata.json deleted file mode 100644 index 57d81805f598..000000000000 --- a/owl-bot-staging/Dlp/v2/src/V2/gapic_metadata.json +++ /dev/null @@ -1,278 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.privacy.dlp.v2", - "libraryPackage": "Google\\Cloud\\Dlp\\V2", - "services": { - "DlpService": { - "clients": { - "grpc": { - "libraryClient": "DlpServiceGapicClient", - "rpcs": { - "ActivateJobTrigger": { - "methods": [ - "activateJobTrigger" - ] - }, - "CancelDlpJob": { - "methods": [ - "cancelDlpJob" - ] - }, - "CreateConnection": { - "methods": [ - "createConnection" - ] - }, - "CreateDeidentifyTemplate": { - "methods": [ - "createDeidentifyTemplate" - ] - }, - "CreateDiscoveryConfig": { - "methods": [ - "createDiscoveryConfig" - ] - }, - "CreateDlpJob": { - "methods": [ - "createDlpJob" - ] - }, - "CreateInspectTemplate": { - "methods": [ - "createInspectTemplate" - ] - }, - "CreateJobTrigger": { - "methods": [ - "createJobTrigger" - ] - }, - "CreateStoredInfoType": { - "methods": [ - "createStoredInfoType" - ] - }, - "DeidentifyContent": { - "methods": [ - "deidentifyContent" - ] - }, - "DeleteConnection": { - "methods": [ - "deleteConnection" - ] - }, - "DeleteDeidentifyTemplate": { - "methods": [ - "deleteDeidentifyTemplate" - ] - }, - "DeleteDiscoveryConfig": { - "methods": [ - "deleteDiscoveryConfig" - ] - }, - "DeleteDlpJob": { - "methods": [ - "deleteDlpJob" - ] - }, - "DeleteInspectTemplate": { - "methods": [ - "deleteInspectTemplate" - ] - }, - "DeleteJobTrigger": { - "methods": [ - "deleteJobTrigger" - ] - }, - "DeleteStoredInfoType": { - "methods": [ - "deleteStoredInfoType" - ] - }, - "DeleteTableDataProfile": { - "methods": [ - "deleteTableDataProfile" - ] - }, - "FinishDlpJob": { - "methods": [ - "finishDlpJob" - ] - }, - "GetColumnDataProfile": { - "methods": [ - "getColumnDataProfile" - ] - }, - "GetConnection": { - "methods": [ - "getConnection" - ] - }, - "GetDeidentifyTemplate": { - "methods": [ - "getDeidentifyTemplate" - ] - }, - "GetDiscoveryConfig": { - "methods": [ - "getDiscoveryConfig" - ] - }, - "GetDlpJob": { - "methods": [ - "getDlpJob" - ] - }, - "GetInspectTemplate": { - "methods": [ - "getInspectTemplate" - ] - }, - "GetJobTrigger": { - "methods": [ - "getJobTrigger" - ] - }, - "GetProjectDataProfile": { - "methods": [ - "getProjectDataProfile" - ] - }, - "GetStoredInfoType": { - "methods": [ - "getStoredInfoType" - ] - }, - "GetTableDataProfile": { - "methods": [ - "getTableDataProfile" - ] - }, - "HybridInspectDlpJob": { - "methods": [ - "hybridInspectDlpJob" - ] - }, - "HybridInspectJobTrigger": { - "methods": [ - "hybridInspectJobTrigger" - ] - }, - "InspectContent": { - "methods": [ - "inspectContent" - ] - }, - "ListColumnDataProfiles": { - "methods": [ - "listColumnDataProfiles" - ] - }, - "ListConnections": { - "methods": [ - "listConnections" - ] - }, - "ListDeidentifyTemplates": { - "methods": [ - "listDeidentifyTemplates" - ] - }, - "ListDiscoveryConfigs": { - "methods": [ - "listDiscoveryConfigs" - ] - }, - "ListDlpJobs": { - "methods": [ - "listDlpJobs" - ] - }, - "ListInfoTypes": { - "methods": [ - "listInfoTypes" - ] - }, - "ListInspectTemplates": { - "methods": [ - "listInspectTemplates" - ] - }, - "ListJobTriggers": { - "methods": [ - "listJobTriggers" - ] - }, - "ListProjectDataProfiles": { - "methods": [ - "listProjectDataProfiles" - ] - }, - "ListStoredInfoTypes": { - "methods": [ - "listStoredInfoTypes" - ] - }, - "ListTableDataProfiles": { - "methods": [ - "listTableDataProfiles" - ] - }, - "RedactImage": { - "methods": [ - "redactImage" - ] - }, - "ReidentifyContent": { - "methods": [ - "reidentifyContent" - ] - }, - "SearchConnections": { - "methods": [ - "searchConnections" - ] - }, - "UpdateConnection": { - "methods": [ - "updateConnection" - ] - }, - "UpdateDeidentifyTemplate": { - "methods": [ - "updateDeidentifyTemplate" - ] - }, - "UpdateDiscoveryConfig": { - "methods": [ - "updateDiscoveryConfig" - ] - }, - "UpdateInspectTemplate": { - "methods": [ - "updateInspectTemplate" - ] - }, - "UpdateJobTrigger": { - "methods": [ - "updateJobTrigger" - ] - }, - "UpdateStoredInfoType": { - "methods": [ - "updateStoredInfoType" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_client_config.json b/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_client_config.json deleted file mode 100644 index 78363c7bd2aa..000000000000 --- a/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_client_config.json +++ /dev/null @@ -1,305 +0,0 @@ -{ - "interfaces": { - "google.privacy.dlp.v2.DlpService": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "UNAVAILABLE", - "DEADLINE_EXCEEDED" - ], - "no_retry_1_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "retry_policy_1_params": { - "initial_retry_delay_millis": 100, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 60000, - "initial_rpc_timeout_millis": 300000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 300000, - "total_timeout_millis": 300000 - }, - "no_retry_1_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 300000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 300000, - "total_timeout_millis": 300000 - } - }, - "methods": { - "ActivateJobTrigger": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CancelDlpJob": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateConnection": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "CreateDeidentifyTemplate": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateDiscoveryConfig": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateDlpJob": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateInspectTemplate": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateJobTrigger": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateStoredInfoType": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeidentifyContent": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteConnection": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "DeleteDeidentifyTemplate": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteDiscoveryConfig": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteDlpJob": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteInspectTemplate": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteJobTrigger": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteStoredInfoType": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteTableDataProfile": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "FinishDlpJob": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetColumnDataProfile": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetConnection": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetDeidentifyTemplate": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetDiscoveryConfig": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetDlpJob": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetInspectTemplate": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetJobTrigger": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetProjectDataProfile": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetStoredInfoType": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetTableDataProfile": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "HybridInspectDlpJob": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "HybridInspectJobTrigger": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "InspectContent": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListColumnDataProfiles": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListConnections": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListDeidentifyTemplates": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListDiscoveryConfigs": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListDlpJobs": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListInfoTypes": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListInspectTemplates": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListJobTriggers": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListProjectDataProfiles": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListStoredInfoTypes": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListTableDataProfiles": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "RedactImage": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ReidentifyContent": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "SearchConnections": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "UpdateConnection": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "UpdateDeidentifyTemplate": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateDiscoveryConfig": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateInspectTemplate": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateJobTrigger": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateStoredInfoType": { - "timeout_millis": 300000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_descriptor_config.php b/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_descriptor_config.php deleted file mode 100644 index 0ce9d36ad4b5..000000000000 --- a/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_descriptor_config.php +++ /dev/null @@ -1,778 +0,0 @@ - [ - 'google.privacy.dlp.v2.DlpService' => [ - 'ActivateJobTrigger' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\DlpJob', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'CancelDlpJob' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'CreateConnection' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\Connection', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateDeidentifyTemplate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\DeidentifyTemplate', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateDiscoveryConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\DiscoveryConfig', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateDlpJob' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\DlpJob', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateInspectTemplate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\InspectTemplate', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateJobTrigger' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\JobTrigger', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateStoredInfoType' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\StoredInfoType', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeidentifyContent' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\DeidentifyContentResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteConnection' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteDeidentifyTemplate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteDiscoveryConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteDlpJob' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteInspectTemplate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteJobTrigger' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteStoredInfoType' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteTableDataProfile' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'FinishDlpJob' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetColumnDataProfile' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ColumnDataProfile', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetConnection' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\Connection', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetDeidentifyTemplate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\DeidentifyTemplate', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetDiscoveryConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\DiscoveryConfig', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetDlpJob' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\DlpJob', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetInspectTemplate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\InspectTemplate', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetJobTrigger' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\JobTrigger', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetProjectDataProfile' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ProjectDataProfile', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetStoredInfoType' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\StoredInfoType', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetTableDataProfile' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\TableDataProfile', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'HybridInspectDlpJob' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\HybridInspectResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'HybridInspectJobTrigger' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\HybridInspectResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'InspectContent' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\InspectContentResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListColumnDataProfiles' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getColumnDataProfiles', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ListColumnDataProfilesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListConnections' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getConnections', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ListConnectionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListDeidentifyTemplates' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getDeidentifyTemplates', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ListDeidentifyTemplatesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListDiscoveryConfigs' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getDiscoveryConfigs', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ListDiscoveryConfigsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListDlpJobs' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getJobs', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ListDlpJobsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListInfoTypes' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ListInfoTypesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListInspectTemplates' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getInspectTemplates', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ListInspectTemplatesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListJobTriggers' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getJobTriggers', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ListJobTriggersResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListProjectDataProfiles' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getProjectDataProfiles', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ListProjectDataProfilesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListStoredInfoTypes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getStoredInfoTypes', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ListStoredInfoTypesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListTableDataProfiles' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getTableDataProfiles', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ListTableDataProfilesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'RedactImage' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\RedactImageResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ReidentifyContent' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\ReidentifyContentResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'SearchConnections' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getConnections', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\SearchConnectionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'UpdateConnection' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\Connection', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateDeidentifyTemplate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\DeidentifyTemplate', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateDiscoveryConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\DiscoveryConfig', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateInspectTemplate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\InspectTemplate', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateJobTrigger' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\JobTrigger', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateStoredInfoType' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Dlp\V2\StoredInfoType', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'templateMap' => [ - 'columnDataProfile' => 'organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}', - 'connection' => 'projects/{project}/locations/{location}/connections/{connection}', - 'deidentifyTemplate' => 'organizations/{organization}/deidentifyTemplates/{deidentify_template}', - 'discoveryConfig' => 'projects/{project}/locations/{location}/discoveryConfigs/{discovery_config}', - 'dlpJob' => 'projects/{project}/dlpJobs/{dlp_job}', - 'inspectTemplate' => 'organizations/{organization}/inspectTemplates/{inspect_template}', - 'jobTrigger' => 'projects/{project}/jobTriggers/{job_trigger}', - 'location' => 'projects/{project}/locations/{location}', - 'organization' => 'organizations/{organization}', - 'organizationDeidentifyTemplate' => 'organizations/{organization}/deidentifyTemplates/{deidentify_template}', - 'organizationInspectTemplate' => 'organizations/{organization}/inspectTemplates/{inspect_template}', - 'organizationLocation' => 'organizations/{organization}/locations/{location}', - 'organizationLocationColumnDataProfile' => 'organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}', - 'organizationLocationDeidentifyTemplate' => 'organizations/{organization}/locations/{location}/deidentifyTemplates/{deidentify_template}', - 'organizationLocationInspectTemplate' => 'organizations/{organization}/locations/{location}/inspectTemplates/{inspect_template}', - 'organizationLocationProjectDataProfile' => 'organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile}', - 'organizationLocationStoredInfoType' => 'organizations/{organization}/locations/{location}/storedInfoTypes/{stored_info_type}', - 'organizationLocationTableDataProfile' => 'organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile}', - 'organizationStoredInfoType' => 'organizations/{organization}/storedInfoTypes/{stored_info_type}', - 'project' => 'projects/{project}', - 'projectDataProfile' => 'organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile}', - 'projectDeidentifyTemplate' => 'projects/{project}/deidentifyTemplates/{deidentify_template}', - 'projectDlpJob' => 'projects/{project}/dlpJobs/{dlp_job}', - 'projectInspectTemplate' => 'projects/{project}/inspectTemplates/{inspect_template}', - 'projectJobTrigger' => 'projects/{project}/jobTriggers/{job_trigger}', - 'projectLocationColumnDataProfile' => 'projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile}', - 'projectLocationDeidentifyTemplate' => 'projects/{project}/locations/{location}/deidentifyTemplates/{deidentify_template}', - 'projectLocationDlpJob' => 'projects/{project}/locations/{location}/dlpJobs/{dlp_job}', - 'projectLocationInspectTemplate' => 'projects/{project}/locations/{location}/inspectTemplates/{inspect_template}', - 'projectLocationJobTrigger' => 'projects/{project}/locations/{location}/jobTriggers/{job_trigger}', - 'projectLocationProjectDataProfile' => 'projects/{project}/locations/{location}/projectDataProfiles/{project_data_profile}', - 'projectLocationStoredInfoType' => 'projects/{project}/locations/{location}/storedInfoTypes/{stored_info_type}', - 'projectLocationTableDataProfile' => 'projects/{project}/locations/{location}/tableDataProfiles/{table_data_profile}', - 'projectStoredInfoType' => 'projects/{project}/storedInfoTypes/{stored_info_type}', - 'storedInfoType' => 'organizations/{organization}/storedInfoTypes/{stored_info_type}', - 'tableDataProfile' => 'organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile}', - ], - ], - ], -]; diff --git a/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_rest_client_config.php b/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_rest_client_config.php deleted file mode 100644 index e2def05b8c3b..000000000000 --- a/owl-bot-staging/Dlp/v2/src/V2/resources/dlp_service_rest_client_config.php +++ /dev/null @@ -1,1062 +0,0 @@ - [ - 'google.privacy.dlp.v2.DlpService' => [ - 'ActivateJobTrigger' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/jobTriggers/*}:activate', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/jobTriggers/*}:activate', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'CancelDlpJob' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/dlpJobs/*}:cancel', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/dlpJobs/*}:cancel', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'CreateConnection' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/connections', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateDeidentifyTemplate' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*}/deidentifyTemplates', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/deidentifyTemplates', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*}/deidentifyTemplates', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/deidentifyTemplates', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateDiscoveryConfig' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/discoveryConfigs', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/discoveryConfigs', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateDlpJob' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*}/dlpJobs', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/dlpJobs', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateInspectTemplate' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*}/inspectTemplates', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/inspectTemplates', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*}/inspectTemplates', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/inspectTemplates', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateJobTrigger' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*}/jobTriggers', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/jobTriggers', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/jobTriggers', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateStoredInfoType' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*}/storedInfoTypes', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/storedInfoTypes', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*}/storedInfoTypes', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/storedInfoTypes', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeidentifyContent' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*}/content:deidentify', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/content:deidentify', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteConnection' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/connections/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteDeidentifyTemplate' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/deidentifyTemplates/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/deidentifyTemplates/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/deidentifyTemplates/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/deidentifyTemplates/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteDiscoveryConfig' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/discoveryConfigs/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/discoveryConfigs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteDlpJob' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/dlpJobs/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/dlpJobs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteInspectTemplate' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/inspectTemplates/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/inspectTemplates/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/inspectTemplates/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/inspectTemplates/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteJobTrigger' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/jobTriggers/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/jobTriggers/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/jobTriggers/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteStoredInfoType' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/storedInfoTypes/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/storedInfoTypes/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/storedInfoTypes/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/storedInfoTypes/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteTableDataProfile' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/tableDataProfiles/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/tableDataProfiles/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'FinishDlpJob' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/dlpJobs/*}:finish', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetColumnDataProfile' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/columnDataProfiles/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/columnDataProfiles/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetConnection' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/connections/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetDeidentifyTemplate' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/deidentifyTemplates/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/deidentifyTemplates/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/deidentifyTemplates/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/deidentifyTemplates/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetDiscoveryConfig' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/discoveryConfigs/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/discoveryConfigs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetDlpJob' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/dlpJobs/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/dlpJobs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetInspectTemplate' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/inspectTemplates/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/inspectTemplates/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/inspectTemplates/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/inspectTemplates/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetJobTrigger' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/jobTriggers/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/jobTriggers/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/jobTriggers/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetProjectDataProfile' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/projectDataProfiles/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/projectDataProfiles/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetStoredInfoType' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/storedInfoTypes/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/storedInfoTypes/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/storedInfoTypes/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/storedInfoTypes/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetTableDataProfile' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/tableDataProfiles/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/tableDataProfiles/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'HybridInspectDlpJob' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/dlpJobs/*}:hybridInspect', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'HybridInspectJobTrigger' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/jobTriggers/*}:hybridInspect', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'InspectContent' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*}/content:inspect', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/content:inspect', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListColumnDataProfiles' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/columnDataProfiles', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/columnDataProfiles', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListConnections' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/connections', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListDeidentifyTemplates' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*}/deidentifyTemplates', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/deidentifyTemplates', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*}/deidentifyTemplates', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/deidentifyTemplates', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListDiscoveryConfigs' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/discoveryConfigs', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/discoveryConfigs', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListDlpJobs' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*}/dlpJobs', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/dlpJobs', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/dlpJobs', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListInfoTypes' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/infoTypes', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=locations/*}/infoTypes', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListInspectTemplates' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*}/inspectTemplates', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/inspectTemplates', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*}/inspectTemplates', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/inspectTemplates', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListJobTriggers' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*}/jobTriggers', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/jobTriggers', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/jobTriggers', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListProjectDataProfiles' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/projectDataProfiles', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/projectDataProfiles', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListStoredInfoTypes' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*}/storedInfoTypes', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/storedInfoTypes', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*}/storedInfoTypes', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/storedInfoTypes', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListTableDataProfiles' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/tableDataProfiles', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/tableDataProfiles', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'RedactImage' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*}/image:redact', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/image:redact', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ReidentifyContent' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*}/content:reidentify', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/content:reidentify', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'SearchConnections' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/connections:search', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/connections:search', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'UpdateConnection' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/connections/*}', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateDeidentifyTemplate' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=organizations/*/deidentifyTemplates/*}', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/deidentifyTemplates/*}', - 'body' => '*', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=projects/*/deidentifyTemplates/*}', - 'body' => '*', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/deidentifyTemplates/*}', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateDiscoveryConfig' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/discoveryConfigs/*}', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/discoveryConfigs/*}', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateInspectTemplate' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=organizations/*/inspectTemplates/*}', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/inspectTemplates/*}', - 'body' => '*', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=projects/*/inspectTemplates/*}', - 'body' => '*', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/inspectTemplates/*}', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateJobTrigger' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=projects/*/jobTriggers/*}', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/jobTriggers/*}', - 'body' => '*', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/jobTriggers/*}', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateStoredInfoType' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=organizations/*/storedInfoTypes/*}', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/storedInfoTypes/*}', - 'body' => '*', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=projects/*/storedInfoTypes/*}', - 'body' => '*', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/storedInfoTypes/*}', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/Dlp/v2/tests/Unit/V2/Client/DlpServiceClientTest.php b/owl-bot-staging/Dlp/v2/tests/Unit/V2/Client/DlpServiceClientTest.php deleted file mode 100644 index 8679243ae398..000000000000 --- a/owl-bot-staging/Dlp/v2/tests/Unit/V2/Client/DlpServiceClientTest.php +++ /dev/null @@ -1,3672 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return DlpServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new DlpServiceClient($options); - } - - /** @test */ - public function activateJobTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $jobTriggerName = 'jobTriggerName1819490804'; - $expectedResponse = new DlpJob(); - $expectedResponse->setName($name2); - $expectedResponse->setJobTriggerName($jobTriggerName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $request = (new ActivateJobTriggerRequest()) - ->setName($formattedName); - $response = $gapicClient->activateJobTrigger($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ActivateJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function activateJobTriggerExceptionTest() - { - $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $request = (new ActivateJobTriggerRequest()) - ->setName($formattedName); - try { - $gapicClient->activateJobTrigger($request); - // 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 cancelDlpJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $request = (new CancelDlpJobRequest()) - ->setName($formattedName); - $gapicClient->cancelDlpJob($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CancelDlpJob', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function cancelDlpJobExceptionTest() - { - $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $request = (new CancelDlpJobRequest()) - ->setName($formattedName); - try { - $gapicClient->cancelDlpJob($request); - // 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 createConnectionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $expectedResponse = new Connection(); - $expectedResponse->setName($name); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $connection = new Connection(); - $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; - $connection->setState($connectionState); - $request = (new CreateConnectionRequest()) - ->setParent($formattedParent) - ->setConnection($connection); - $response = $gapicClient->createConnection($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateConnection', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getConnection(); - $this->assertProtobufEquals($connection, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createConnectionExceptionTest() - { - $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->locationName('[PROJECT]', '[LOCATION]'); - $connection = new Connection(); - $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; - $connection->setState($connectionState); - $request = (new CreateConnectionRequest()) - ->setParent($formattedParent) - ->setConnection($connection); - try { - $gapicClient->createConnection($request); - // 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 createDeidentifyTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new DeidentifyTemplate(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $deidentifyTemplate = new DeidentifyTemplate(); - $request = (new CreateDeidentifyTemplateRequest()) - ->setParent($formattedParent) - ->setDeidentifyTemplate($deidentifyTemplate); - $response = $gapicClient->createDeidentifyTemplate($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateDeidentifyTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getDeidentifyTemplate(); - $this->assertProtobufEquals($deidentifyTemplate, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createDeidentifyTemplateExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $deidentifyTemplate = new DeidentifyTemplate(); - $request = (new CreateDeidentifyTemplateRequest()) - ->setParent($formattedParent) - ->setDeidentifyTemplate($deidentifyTemplate); - try { - $gapicClient->createDeidentifyTemplate($request); - // 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 createDiscoveryConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $expectedResponse = new DiscoveryConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $discoveryConfig = new DiscoveryConfig(); - $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; - $discoveryConfig->setStatus($discoveryConfigStatus); - $request = (new CreateDiscoveryConfigRequest()) - ->setParent($formattedParent) - ->setDiscoveryConfig($discoveryConfig); - $response = $gapicClient->createDiscoveryConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateDiscoveryConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getDiscoveryConfig(); - $this->assertProtobufEquals($discoveryConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createDiscoveryConfigExceptionTest() - { - $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->locationName('[PROJECT]', '[LOCATION]'); - $discoveryConfig = new DiscoveryConfig(); - $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; - $discoveryConfig->setStatus($discoveryConfigStatus); - $request = (new CreateDiscoveryConfigRequest()) - ->setParent($formattedParent) - ->setDiscoveryConfig($discoveryConfig); - try { - $gapicClient->createDiscoveryConfig($request); - // 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 createDlpJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $jobTriggerName = 'jobTriggerName1819490804'; - $expectedResponse = new DlpJob(); - $expectedResponse->setName($name); - $expectedResponse->setJobTriggerName($jobTriggerName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new CreateDlpJobRequest()) - ->setParent($formattedParent); - $response = $gapicClient->createDlpJob($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateDlpJob', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createDlpJobExceptionTest() - { - $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]'); - $request = (new CreateDlpJobRequest()) - ->setParent($formattedParent); - try { - $gapicClient->createDlpJob($request); - // 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 createInspectTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new InspectTemplate(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $inspectTemplate = new InspectTemplate(); - $request = (new CreateInspectTemplateRequest()) - ->setParent($formattedParent) - ->setInspectTemplate($inspectTemplate); - $response = $gapicClient->createInspectTemplate($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateInspectTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getInspectTemplate(); - $this->assertProtobufEquals($inspectTemplate, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createInspectTemplateExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $inspectTemplate = new InspectTemplate(); - $request = (new CreateInspectTemplateRequest()) - ->setParent($formattedParent) - ->setInspectTemplate($inspectTemplate); - try { - $gapicClient->createInspectTemplate($request); - // 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 createJobTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new JobTrigger(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $jobTrigger = new JobTrigger(); - $jobTriggerStatus = \Google\Cloud\Dlp\V2\JobTrigger\Status::STATUS_UNSPECIFIED; - $jobTrigger->setStatus($jobTriggerStatus); - $request = (new CreateJobTriggerRequest()) - ->setParent($formattedParent) - ->setJobTrigger($jobTrigger); - $response = $gapicClient->createJobTrigger($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getJobTrigger(); - $this->assertProtobufEquals($jobTrigger, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createJobTriggerExceptionTest() - { - $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]'); - $jobTrigger = new JobTrigger(); - $jobTriggerStatus = \Google\Cloud\Dlp\V2\JobTrigger\Status::STATUS_UNSPECIFIED; - $jobTrigger->setStatus($jobTriggerStatus); - $request = (new CreateJobTriggerRequest()) - ->setParent($formattedParent) - ->setJobTrigger($jobTrigger); - try { - $gapicClient->createJobTrigger($request); - // 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 createStoredInfoTypeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $expectedResponse = new StoredInfoType(); - $expectedResponse->setName($name); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $config = new StoredInfoTypeConfig(); - $request = (new CreateStoredInfoTypeRequest()) - ->setParent($formattedParent) - ->setConfig($config); - $response = $gapicClient->createStoredInfoType($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateStoredInfoType', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getConfig(); - $this->assertProtobufEquals($config, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createStoredInfoTypeExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $config = new StoredInfoTypeConfig(); - $request = (new CreateStoredInfoTypeRequest()) - ->setParent($formattedParent) - ->setConfig($config); - try { - $gapicClient->createStoredInfoType($request); - // 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 deidentifyContentTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new DeidentifyContentResponse(); - $transport->addResponse($expectedResponse); - $request = new DeidentifyContentRequest(); - $response = $gapicClient->deidentifyContent($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeidentifyContent', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deidentifyContentExceptionTest() - { - $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); - $request = new DeidentifyContentRequest(); - try { - $gapicClient->deidentifyContent($request); - // 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 deleteConnectionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $request = (new DeleteConnectionRequest()) - ->setName($formattedName); - $gapicClient->deleteConnection($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteConnection', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteConnectionExceptionTest() - { - $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->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $request = (new DeleteConnectionRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteConnection($request); - // 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 deleteDeidentifyTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - $request = (new DeleteDeidentifyTemplateRequest()) - ->setName($formattedName); - $gapicClient->deleteDeidentifyTemplate($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteDeidentifyTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDeidentifyTemplateExceptionTest() - { - $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->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - $request = (new DeleteDeidentifyTemplateRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteDeidentifyTemplate($request); - // 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 deleteDiscoveryConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - $request = (new DeleteDiscoveryConfigRequest()) - ->setName($formattedName); - $gapicClient->deleteDiscoveryConfig($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteDiscoveryConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDiscoveryConfigExceptionTest() - { - $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->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - $request = (new DeleteDiscoveryConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteDiscoveryConfig($request); - // 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 deleteDlpJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $request = (new DeleteDlpJobRequest()) - ->setName($formattedName); - $gapicClient->deleteDlpJob($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteDlpJob', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDlpJobExceptionTest() - { - $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $request = (new DeleteDlpJobRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteDlpJob($request); - // 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 deleteInspectTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - $request = (new DeleteInspectTemplateRequest()) - ->setName($formattedName); - $gapicClient->deleteInspectTemplate($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteInspectTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteInspectTemplateExceptionTest() - { - $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->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - $request = (new DeleteInspectTemplateRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteInspectTemplate($request); - // 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 deleteJobTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $request = (new DeleteJobTriggerRequest()) - ->setName($formattedName); - $gapicClient->deleteJobTrigger($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteJobTriggerExceptionTest() - { - $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $request = (new DeleteJobTriggerRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteJobTrigger($request); - // 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 deleteStoredInfoTypeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - $request = (new DeleteStoredInfoTypeRequest()) - ->setName($formattedName); - $gapicClient->deleteStoredInfoType($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteStoredInfoType', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteStoredInfoTypeExceptionTest() - { - $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->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - $request = (new DeleteStoredInfoTypeRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteStoredInfoType($request); - // 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 deleteTableDataProfileTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); - $request = (new DeleteTableDataProfileRequest()) - ->setName($formattedName); - $gapicClient->deleteTableDataProfile($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteTableDataProfile', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteTableDataProfileExceptionTest() - { - $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->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); - $request = (new DeleteTableDataProfileRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteTableDataProfile($request); - // 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 finishDlpJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $request = (new FinishDlpJobRequest()) - ->setName($formattedName); - $gapicClient->finishDlpJob($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/FinishDlpJob', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function finishDlpJobExceptionTest() - { - $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $request = (new FinishDlpJobRequest()) - ->setName($formattedName); - try { - $gapicClient->finishDlpJob($request); - // 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 getColumnDataProfileTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $tableDataProfile = 'tableDataProfile1230971621'; - $tableFullResource = 'tableFullResource1490522381'; - $datasetProjectId = 'datasetProjectId1943685672'; - $datasetLocation = 'datasetLocation1011262364'; - $datasetId = 'datasetId-2115646910'; - $tableId = 'tableId-895419604'; - $column = 'column-1354837162'; - $freeTextScore = 1.21823761E8; - $expectedResponse = new ColumnDataProfile(); - $expectedResponse->setName($name2); - $expectedResponse->setTableDataProfile($tableDataProfile); - $expectedResponse->setTableFullResource($tableFullResource); - $expectedResponse->setDatasetProjectId($datasetProjectId); - $expectedResponse->setDatasetLocation($datasetLocation); - $expectedResponse->setDatasetId($datasetId); - $expectedResponse->setTableId($tableId); - $expectedResponse->setColumn($column); - $expectedResponse->setFreeTextScore($freeTextScore); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->columnDataProfileName('[ORGANIZATION]', '[LOCATION]', '[COLUMN_DATA_PROFILE]'); - $request = (new GetColumnDataProfileRequest()) - ->setName($formattedName); - $response = $gapicClient->getColumnDataProfile($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetColumnDataProfile', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getColumnDataProfileExceptionTest() - { - $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->columnDataProfileName('[ORGANIZATION]', '[LOCATION]', '[COLUMN_DATA_PROFILE]'); - $request = (new GetColumnDataProfileRequest()) - ->setName($formattedName); - try { - $gapicClient->getColumnDataProfile($request); - // 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 getConnectionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new Connection(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $request = (new GetConnectionRequest()) - ->setName($formattedName); - $response = $gapicClient->getConnection($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetConnection', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getConnectionExceptionTest() - { - $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->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $request = (new GetConnectionRequest()) - ->setName($formattedName); - try { - $gapicClient->getConnection($request); - // 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 getDeidentifyTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new DeidentifyTemplate(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - $request = (new GetDeidentifyTemplateRequest()) - ->setName($formattedName); - $response = $gapicClient->getDeidentifyTemplate($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetDeidentifyTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDeidentifyTemplateExceptionTest() - { - $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->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - $request = (new GetDeidentifyTemplateRequest()) - ->setName($formattedName); - try { - $gapicClient->getDeidentifyTemplate($request); - // 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 getDiscoveryConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $expectedResponse = new DiscoveryConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - $request = (new GetDiscoveryConfigRequest()) - ->setName($formattedName); - $response = $gapicClient->getDiscoveryConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetDiscoveryConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDiscoveryConfigExceptionTest() - { - $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->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - $request = (new GetDiscoveryConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->getDiscoveryConfig($request); - // 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 getDlpJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $jobTriggerName = 'jobTriggerName1819490804'; - $expectedResponse = new DlpJob(); - $expectedResponse->setName($name2); - $expectedResponse->setJobTriggerName($jobTriggerName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $request = (new GetDlpJobRequest()) - ->setName($formattedName); - $response = $gapicClient->getDlpJob($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetDlpJob', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDlpJobExceptionTest() - { - $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $request = (new GetDlpJobRequest()) - ->setName($formattedName); - try { - $gapicClient->getDlpJob($request); - // 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 getInspectTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new InspectTemplate(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - $request = (new GetInspectTemplateRequest()) - ->setName($formattedName); - $response = $gapicClient->getInspectTemplate($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetInspectTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getInspectTemplateExceptionTest() - { - $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->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - $request = (new GetInspectTemplateRequest()) - ->setName($formattedName); - try { - $gapicClient->getInspectTemplate($request); - // 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 getJobTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new JobTrigger(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $request = (new GetJobTriggerRequest()) - ->setName($formattedName); - $response = $gapicClient->getJobTrigger($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getJobTriggerExceptionTest() - { - $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $request = (new GetJobTriggerRequest()) - ->setName($formattedName); - try { - $gapicClient->getJobTrigger($request); - // 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 getProjectDataProfileTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $projectId = 'projectId-1969970175'; - $expectedResponse = new ProjectDataProfile(); - $expectedResponse->setName($name2); - $expectedResponse->setProjectId($projectId); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->projectDataProfileName('[ORGANIZATION]', '[LOCATION]', '[PROJECT_DATA_PROFILE]'); - $request = (new GetProjectDataProfileRequest()) - ->setName($formattedName); - $response = $gapicClient->getProjectDataProfile($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetProjectDataProfile', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getProjectDataProfileExceptionTest() - { - $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->projectDataProfileName('[ORGANIZATION]', '[LOCATION]', '[PROJECT_DATA_PROFILE]'); - $request = (new GetProjectDataProfileRequest()) - ->setName($formattedName); - try { - $gapicClient->getProjectDataProfile($request); - // 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 getStoredInfoTypeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new StoredInfoType(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - $request = (new GetStoredInfoTypeRequest()) - ->setName($formattedName); - $response = $gapicClient->getStoredInfoType($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetStoredInfoType', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getStoredInfoTypeExceptionTest() - { - $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->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - $request = (new GetStoredInfoTypeRequest()) - ->setName($formattedName); - try { - $gapicClient->getStoredInfoType($request); - // 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 getTableDataProfileTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $projectDataProfile = 'projectDataProfile-316045958'; - $datasetProjectId = 'datasetProjectId1943685672'; - $datasetLocation = 'datasetLocation1011262364'; - $datasetId = 'datasetId-2115646910'; - $tableId = 'tableId-895419604'; - $fullResource = 'fullResource1559053246'; - $scannedColumnCount = 787756843; - $failedColumnCount = 706572376; - $tableSizeBytes = 927763390; - $rowCount = 1340416618; - $expectedResponse = new TableDataProfile(); - $expectedResponse->setName($name2); - $expectedResponse->setProjectDataProfile($projectDataProfile); - $expectedResponse->setDatasetProjectId($datasetProjectId); - $expectedResponse->setDatasetLocation($datasetLocation); - $expectedResponse->setDatasetId($datasetId); - $expectedResponse->setTableId($tableId); - $expectedResponse->setFullResource($fullResource); - $expectedResponse->setScannedColumnCount($scannedColumnCount); - $expectedResponse->setFailedColumnCount($failedColumnCount); - $expectedResponse->setTableSizeBytes($tableSizeBytes); - $expectedResponse->setRowCount($rowCount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); - $request = (new GetTableDataProfileRequest()) - ->setName($formattedName); - $response = $gapicClient->getTableDataProfile($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetTableDataProfile', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getTableDataProfileExceptionTest() - { - $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->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); - $request = (new GetTableDataProfileRequest()) - ->setName($formattedName); - try { - $gapicClient->getTableDataProfile($request); - // 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 hybridInspectDlpJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new HybridInspectResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $request = (new HybridInspectDlpJobRequest()) - ->setName($formattedName); - $response = $gapicClient->hybridInspectDlpJob($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/HybridInspectDlpJob', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function hybridInspectDlpJobExceptionTest() - { - $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $request = (new HybridInspectDlpJobRequest()) - ->setName($formattedName); - try { - $gapicClient->hybridInspectDlpJob($request); - // 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 hybridInspectJobTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new HybridInspectResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $request = (new HybridInspectJobTriggerRequest()) - ->setName($formattedName); - $response = $gapicClient->hybridInspectJobTrigger($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/HybridInspectJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function hybridInspectJobTriggerExceptionTest() - { - $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $request = (new HybridInspectJobTriggerRequest()) - ->setName($formattedName); - try { - $gapicClient->hybridInspectJobTrigger($request); - // 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 inspectContentTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new InspectContentResponse(); - $transport->addResponse($expectedResponse); - $request = new InspectContentRequest(); - $response = $gapicClient->inspectContent($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/InspectContent', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function inspectContentExceptionTest() - { - $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); - $request = new InspectContentRequest(); - try { - $gapicClient->inspectContent($request); - // 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 listColumnDataProfilesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $columnDataProfilesElement = new ColumnDataProfile(); - $columnDataProfiles = [ - $columnDataProfilesElement, - ]; - $expectedResponse = new ListColumnDataProfilesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setColumnDataProfiles($columnDataProfiles); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListColumnDataProfilesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listColumnDataProfiles($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getColumnDataProfiles()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListColumnDataProfiles', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listColumnDataProfilesExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListColumnDataProfilesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listColumnDataProfiles($request); - // 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 listConnectionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $connectionsElement = new Connection(); - $connections = [ - $connectionsElement, - ]; - $expectedResponse = new ListConnectionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setConnections($connections); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListConnectionsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listConnections($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getConnections()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListConnections', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listConnectionsExceptionTest() - { - $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->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListConnectionsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listConnections($request); - // 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 listDeidentifyTemplatesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $deidentifyTemplatesElement = new DeidentifyTemplate(); - $deidentifyTemplates = [ - $deidentifyTemplatesElement, - ]; - $expectedResponse = new ListDeidentifyTemplatesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setDeidentifyTemplates($deidentifyTemplates); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListDeidentifyTemplatesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listDeidentifyTemplates($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getDeidentifyTemplates()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListDeidentifyTemplates', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDeidentifyTemplatesExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListDeidentifyTemplatesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listDeidentifyTemplates($request); - // 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 listDiscoveryConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $discoveryConfigsElement = new DiscoveryConfig(); - $discoveryConfigs = [ - $discoveryConfigsElement, - ]; - $expectedResponse = new ListDiscoveryConfigsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setDiscoveryConfigs($discoveryConfigs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListDiscoveryConfigsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listDiscoveryConfigs($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getDiscoveryConfigs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListDiscoveryConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDiscoveryConfigsExceptionTest() - { - $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->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListDiscoveryConfigsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listDiscoveryConfigs($request); - // 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 listDlpJobsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $jobsElement = new DlpJob(); - $jobs = [ - $jobsElement, - ]; - $expectedResponse = new ListDlpJobsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setJobs($jobs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListDlpJobsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listDlpJobs($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getJobs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListDlpJobs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDlpJobsExceptionTest() - { - $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]'); - $request = (new ListDlpJobsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listDlpJobs($request); - // 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 listInfoTypesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new ListInfoTypesResponse(); - $transport->addResponse($expectedResponse); - $request = new ListInfoTypesRequest(); - $response = $gapicClient->listInfoTypes($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListInfoTypes', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listInfoTypesExceptionTest() - { - $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); - $request = new ListInfoTypesRequest(); - try { - $gapicClient->listInfoTypes($request); - // 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 listInspectTemplatesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $inspectTemplatesElement = new InspectTemplate(); - $inspectTemplates = [ - $inspectTemplatesElement, - ]; - $expectedResponse = new ListInspectTemplatesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setInspectTemplates($inspectTemplates); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListInspectTemplatesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listInspectTemplates($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getInspectTemplates()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListInspectTemplates', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listInspectTemplatesExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListInspectTemplatesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listInspectTemplates($request); - // 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 listJobTriggersTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $jobTriggersElement = new JobTrigger(); - $jobTriggers = [ - $jobTriggersElement, - ]; - $expectedResponse = new ListJobTriggersResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setJobTriggers($jobTriggers); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListJobTriggersRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listJobTriggers($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getJobTriggers()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListJobTriggers', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listJobTriggersExceptionTest() - { - $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]'); - $request = (new ListJobTriggersRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listJobTriggers($request); - // 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 listProjectDataProfilesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $projectDataProfilesElement = new ProjectDataProfile(); - $projectDataProfiles = [ - $projectDataProfilesElement, - ]; - $expectedResponse = new ListProjectDataProfilesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setProjectDataProfiles($projectDataProfiles); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListProjectDataProfilesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listProjectDataProfiles($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getProjectDataProfiles()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListProjectDataProfiles', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listProjectDataProfilesExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListProjectDataProfilesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listProjectDataProfiles($request); - // 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 listStoredInfoTypesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $storedInfoTypesElement = new StoredInfoType(); - $storedInfoTypes = [ - $storedInfoTypesElement, - ]; - $expectedResponse = new ListStoredInfoTypesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setStoredInfoTypes($storedInfoTypes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListStoredInfoTypesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listStoredInfoTypes($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getStoredInfoTypes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListStoredInfoTypes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listStoredInfoTypesExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListStoredInfoTypesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listStoredInfoTypes($request); - // 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 listTableDataProfilesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $tableDataProfilesElement = new TableDataProfile(); - $tableDataProfiles = [ - $tableDataProfilesElement, - ]; - $expectedResponse = new ListTableDataProfilesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTableDataProfiles($tableDataProfiles); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListTableDataProfilesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listTableDataProfiles($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getTableDataProfiles()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListTableDataProfiles', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listTableDataProfilesExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListTableDataProfilesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listTableDataProfiles($request); - // 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 redactImageTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $redactedImage = '28'; - $extractedText = 'extractedText998260012'; - $expectedResponse = new RedactImageResponse(); - $expectedResponse->setRedactedImage($redactedImage); - $expectedResponse->setExtractedText($extractedText); - $transport->addResponse($expectedResponse); - $request = new RedactImageRequest(); - $response = $gapicClient->redactImage($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/RedactImage', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function redactImageExceptionTest() - { - $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); - $request = new RedactImageRequest(); - try { - $gapicClient->redactImage($request); - // 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 reidentifyContentTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new ReidentifyContentResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ReidentifyContentRequest()) - ->setParent($formattedParent); - $response = $gapicClient->reidentifyContent($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ReidentifyContent', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function reidentifyContentExceptionTest() - { - $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]'); - $request = (new ReidentifyContentRequest()) - ->setParent($formattedParent); - try { - $gapicClient->reidentifyContent($request); - // 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 searchConnectionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $connectionsElement = new Connection(); - $connections = [ - $connectionsElement, - ]; - $expectedResponse = new SearchConnectionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setConnections($connections); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new SearchConnectionsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->searchConnections($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getConnections()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/SearchConnections', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function searchConnectionsExceptionTest() - { - $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->locationName('[PROJECT]', '[LOCATION]'); - $request = (new SearchConnectionsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->searchConnections($request); - // 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 updateConnectionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new Connection(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $connection = new Connection(); - $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; - $connection->setState($connectionState); - $request = (new UpdateConnectionRequest()) - ->setName($formattedName) - ->setConnection($connection); - $response = $gapicClient->updateConnection($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateConnection', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getConnection(); - $this->assertProtobufEquals($connection, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateConnectionExceptionTest() - { - $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->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $connection = new Connection(); - $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; - $connection->setState($connectionState); - $request = (new UpdateConnectionRequest()) - ->setName($formattedName) - ->setConnection($connection); - try { - $gapicClient->updateConnection($request); - // 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 updateDeidentifyTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new DeidentifyTemplate(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - $request = (new UpdateDeidentifyTemplateRequest()) - ->setName($formattedName); - $response = $gapicClient->updateDeidentifyTemplate($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateDeidentifyTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDeidentifyTemplateExceptionTest() - { - $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->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - $request = (new UpdateDeidentifyTemplateRequest()) - ->setName($formattedName); - try { - $gapicClient->updateDeidentifyTemplate($request); - // 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 updateDiscoveryConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $expectedResponse = new DiscoveryConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - $discoveryConfig = new DiscoveryConfig(); - $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; - $discoveryConfig->setStatus($discoveryConfigStatus); - $request = (new UpdateDiscoveryConfigRequest()) - ->setName($formattedName) - ->setDiscoveryConfig($discoveryConfig); - $response = $gapicClient->updateDiscoveryConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateDiscoveryConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getDiscoveryConfig(); - $this->assertProtobufEquals($discoveryConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDiscoveryConfigExceptionTest() - { - $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->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - $discoveryConfig = new DiscoveryConfig(); - $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; - $discoveryConfig->setStatus($discoveryConfigStatus); - $request = (new UpdateDiscoveryConfigRequest()) - ->setName($formattedName) - ->setDiscoveryConfig($discoveryConfig); - try { - $gapicClient->updateDiscoveryConfig($request); - // 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 updateInspectTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new InspectTemplate(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - $request = (new UpdateInspectTemplateRequest()) - ->setName($formattedName); - $response = $gapicClient->updateInspectTemplate($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateInspectTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateInspectTemplateExceptionTest() - { - $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->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - $request = (new UpdateInspectTemplateRequest()) - ->setName($formattedName); - try { - $gapicClient->updateInspectTemplate($request); - // 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 updateJobTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new JobTrigger(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $request = (new UpdateJobTriggerRequest()) - ->setName($formattedName); - $response = $gapicClient->updateJobTrigger($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateJobTriggerExceptionTest() - { - $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $request = (new UpdateJobTriggerRequest()) - ->setName($formattedName); - try { - $gapicClient->updateJobTrigger($request); - // 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 updateStoredInfoTypeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new StoredInfoType(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - $request = (new UpdateStoredInfoTypeRequest()) - ->setName($formattedName); - $response = $gapicClient->updateStoredInfoType($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateStoredInfoType', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateStoredInfoTypeExceptionTest() - { - $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->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - $request = (new UpdateStoredInfoTypeRequest()) - ->setName($formattedName); - try { - $gapicClient->updateStoredInfoType($request); - // 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 activateJobTriggerAsyncTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $jobTriggerName = 'jobTriggerName1819490804'; - $expectedResponse = new DlpJob(); - $expectedResponse->setName($name2); - $expectedResponse->setJobTriggerName($jobTriggerName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $request = (new ActivateJobTriggerRequest()) - ->setName($formattedName); - $response = $gapicClient->activateJobTriggerAsync($request)->wait(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ActivateJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/Dlp/v2/tests/Unit/V2/DlpServiceClientTest.php b/owl-bot-staging/Dlp/v2/tests/Unit/V2/DlpServiceClientTest.php deleted file mode 100644 index 2944dc62f3d3..000000000000 --- a/owl-bot-staging/Dlp/v2/tests/Unit/V2/DlpServiceClientTest.php +++ /dev/null @@ -1,3373 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return DlpServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new DlpServiceClient($options); - } - - /** @test */ - public function activateJobTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $jobTriggerName = 'jobTriggerName1819490804'; - $expectedResponse = new DlpJob(); - $expectedResponse->setName($name2); - $expectedResponse->setJobTriggerName($jobTriggerName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $response = $gapicClient->activateJobTrigger($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ActivateJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function activateJobTriggerExceptionTest() - { - $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - try { - $gapicClient->activateJobTrigger($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 cancelDlpJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $gapicClient->cancelDlpJob($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CancelDlpJob', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function cancelDlpJobExceptionTest() - { - $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); - try { - $gapicClient->cancelDlpJob($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 createConnectionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $expectedResponse = new Connection(); - $expectedResponse->setName($name); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $connection = new Connection(); - $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; - $connection->setState($connectionState); - $response = $gapicClient->createConnection($formattedParent, $connection); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateConnection', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getConnection(); - $this->assertProtobufEquals($connection, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createConnectionExceptionTest() - { - $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->locationName('[PROJECT]', '[LOCATION]'); - $connection = new Connection(); - $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; - $connection->setState($connectionState); - try { - $gapicClient->createConnection($formattedParent, $connection); - // 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 createDeidentifyTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new DeidentifyTemplate(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $deidentifyTemplate = new DeidentifyTemplate(); - $response = $gapicClient->createDeidentifyTemplate($formattedParent, $deidentifyTemplate); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateDeidentifyTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getDeidentifyTemplate(); - $this->assertProtobufEquals($deidentifyTemplate, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createDeidentifyTemplateExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $deidentifyTemplate = new DeidentifyTemplate(); - try { - $gapicClient->createDeidentifyTemplate($formattedParent, $deidentifyTemplate); - // 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 createDiscoveryConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $expectedResponse = new DiscoveryConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $discoveryConfig = new DiscoveryConfig(); - $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; - $discoveryConfig->setStatus($discoveryConfigStatus); - $response = $gapicClient->createDiscoveryConfig($formattedParent, $discoveryConfig); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateDiscoveryConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getDiscoveryConfig(); - $this->assertProtobufEquals($discoveryConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createDiscoveryConfigExceptionTest() - { - $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->locationName('[PROJECT]', '[LOCATION]'); - $discoveryConfig = new DiscoveryConfig(); - $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; - $discoveryConfig->setStatus($discoveryConfigStatus); - try { - $gapicClient->createDiscoveryConfig($formattedParent, $discoveryConfig); - // 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 createDlpJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $jobTriggerName = 'jobTriggerName1819490804'; - $expectedResponse = new DlpJob(); - $expectedResponse->setName($name); - $expectedResponse->setJobTriggerName($jobTriggerName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->createDlpJob($formattedParent); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateDlpJob', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createDlpJobExceptionTest() - { - $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->createDlpJob($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 createInspectTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new InspectTemplate(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $inspectTemplate = new InspectTemplate(); - $response = $gapicClient->createInspectTemplate($formattedParent, $inspectTemplate); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateInspectTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getInspectTemplate(); - $this->assertProtobufEquals($inspectTemplate, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createInspectTemplateExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $inspectTemplate = new InspectTemplate(); - try { - $gapicClient->createInspectTemplate($formattedParent, $inspectTemplate); - // 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 createJobTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new JobTrigger(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $jobTrigger = new JobTrigger(); - $jobTriggerStatus = \Google\Cloud\Dlp\V2\JobTrigger\Status::STATUS_UNSPECIFIED; - $jobTrigger->setStatus($jobTriggerStatus); - $response = $gapicClient->createJobTrigger($formattedParent, $jobTrigger); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getJobTrigger(); - $this->assertProtobufEquals($jobTrigger, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createJobTriggerExceptionTest() - { - $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]'); - $jobTrigger = new JobTrigger(); - $jobTriggerStatus = \Google\Cloud\Dlp\V2\JobTrigger\Status::STATUS_UNSPECIFIED; - $jobTrigger->setStatus($jobTriggerStatus); - try { - $gapicClient->createJobTrigger($formattedParent, $jobTrigger); - // 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 createStoredInfoTypeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $expectedResponse = new StoredInfoType(); - $expectedResponse->setName($name); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $config = new StoredInfoTypeConfig(); - $response = $gapicClient->createStoredInfoType($formattedParent, $config); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/CreateStoredInfoType', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getConfig(); - $this->assertProtobufEquals($config, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createStoredInfoTypeExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $config = new StoredInfoTypeConfig(); - try { - $gapicClient->createStoredInfoType($formattedParent, $config); - // 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 deidentifyContentTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new DeidentifyContentResponse(); - $transport->addResponse($expectedResponse); - $response = $gapicClient->deidentifyContent(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeidentifyContent', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deidentifyContentExceptionTest() - { - $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); - try { - $gapicClient->deidentifyContent(); - // 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 deleteConnectionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $gapicClient->deleteConnection($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteConnection', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteConnectionExceptionTest() - { - $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->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - try { - $gapicClient->deleteConnection($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 deleteDeidentifyTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - $gapicClient->deleteDeidentifyTemplate($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteDeidentifyTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDeidentifyTemplateExceptionTest() - { - $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->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - try { - $gapicClient->deleteDeidentifyTemplate($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 deleteDiscoveryConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - $gapicClient->deleteDiscoveryConfig($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteDiscoveryConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDiscoveryConfigExceptionTest() - { - $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->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - try { - $gapicClient->deleteDiscoveryConfig($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 deleteDlpJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $gapicClient->deleteDlpJob($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteDlpJob', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDlpJobExceptionTest() - { - $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); - try { - $gapicClient->deleteDlpJob($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 deleteInspectTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - $gapicClient->deleteInspectTemplate($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteInspectTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteInspectTemplateExceptionTest() - { - $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->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - try { - $gapicClient->deleteInspectTemplate($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 deleteJobTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $gapicClient->deleteJobTrigger($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteJobTriggerExceptionTest() - { - $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - try { - $gapicClient->deleteJobTrigger($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 deleteStoredInfoTypeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - $gapicClient->deleteStoredInfoType($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteStoredInfoType', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteStoredInfoTypeExceptionTest() - { - $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->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - try { - $gapicClient->deleteStoredInfoType($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 deleteTableDataProfileTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); - $gapicClient->deleteTableDataProfile($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/DeleteTableDataProfile', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteTableDataProfileExceptionTest() - { - $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->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); - try { - $gapicClient->deleteTableDataProfile($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 finishDlpJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $gapicClient->finishDlpJob($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/FinishDlpJob', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function finishDlpJobExceptionTest() - { - $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); - try { - $gapicClient->finishDlpJob($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 getColumnDataProfileTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $tableDataProfile = 'tableDataProfile1230971621'; - $tableFullResource = 'tableFullResource1490522381'; - $datasetProjectId = 'datasetProjectId1943685672'; - $datasetLocation = 'datasetLocation1011262364'; - $datasetId = 'datasetId-2115646910'; - $tableId = 'tableId-895419604'; - $column = 'column-1354837162'; - $freeTextScore = 1.21823761E8; - $expectedResponse = new ColumnDataProfile(); - $expectedResponse->setName($name2); - $expectedResponse->setTableDataProfile($tableDataProfile); - $expectedResponse->setTableFullResource($tableFullResource); - $expectedResponse->setDatasetProjectId($datasetProjectId); - $expectedResponse->setDatasetLocation($datasetLocation); - $expectedResponse->setDatasetId($datasetId); - $expectedResponse->setTableId($tableId); - $expectedResponse->setColumn($column); - $expectedResponse->setFreeTextScore($freeTextScore); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->columnDataProfileName('[ORGANIZATION]', '[LOCATION]', '[COLUMN_DATA_PROFILE]'); - $response = $gapicClient->getColumnDataProfile($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetColumnDataProfile', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getColumnDataProfileExceptionTest() - { - $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->columnDataProfileName('[ORGANIZATION]', '[LOCATION]', '[COLUMN_DATA_PROFILE]'); - try { - $gapicClient->getColumnDataProfile($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 getConnectionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new Connection(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $response = $gapicClient->getConnection($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetConnection', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getConnectionExceptionTest() - { - $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->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - try { - $gapicClient->getConnection($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 getDeidentifyTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new DeidentifyTemplate(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - $response = $gapicClient->getDeidentifyTemplate($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetDeidentifyTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDeidentifyTemplateExceptionTest() - { - $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->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - try { - $gapicClient->getDeidentifyTemplate($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 getDiscoveryConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $expectedResponse = new DiscoveryConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - $response = $gapicClient->getDiscoveryConfig($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetDiscoveryConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDiscoveryConfigExceptionTest() - { - $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->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - try { - $gapicClient->getDiscoveryConfig($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 getDlpJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $jobTriggerName = 'jobTriggerName1819490804'; - $expectedResponse = new DlpJob(); - $expectedResponse->setName($name2); - $expectedResponse->setJobTriggerName($jobTriggerName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $response = $gapicClient->getDlpJob($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetDlpJob', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDlpJobExceptionTest() - { - $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); - try { - $gapicClient->getDlpJob($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 getInspectTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new InspectTemplate(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - $response = $gapicClient->getInspectTemplate($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetInspectTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getInspectTemplateExceptionTest() - { - $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->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - try { - $gapicClient->getInspectTemplate($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 getJobTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new JobTrigger(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $response = $gapicClient->getJobTrigger($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getJobTriggerExceptionTest() - { - $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - try { - $gapicClient->getJobTrigger($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 getProjectDataProfileTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $projectId = 'projectId-1969970175'; - $expectedResponse = new ProjectDataProfile(); - $expectedResponse->setName($name2); - $expectedResponse->setProjectId($projectId); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->projectDataProfileName('[ORGANIZATION]', '[LOCATION]', '[PROJECT_DATA_PROFILE]'); - $response = $gapicClient->getProjectDataProfile($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetProjectDataProfile', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getProjectDataProfileExceptionTest() - { - $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->projectDataProfileName('[ORGANIZATION]', '[LOCATION]', '[PROJECT_DATA_PROFILE]'); - try { - $gapicClient->getProjectDataProfile($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 getStoredInfoTypeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new StoredInfoType(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - $response = $gapicClient->getStoredInfoType($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetStoredInfoType', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getStoredInfoTypeExceptionTest() - { - $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->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - try { - $gapicClient->getStoredInfoType($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 getTableDataProfileTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $projectDataProfile = 'projectDataProfile-316045958'; - $datasetProjectId = 'datasetProjectId1943685672'; - $datasetLocation = 'datasetLocation1011262364'; - $datasetId = 'datasetId-2115646910'; - $tableId = 'tableId-895419604'; - $fullResource = 'fullResource1559053246'; - $scannedColumnCount = 787756843; - $failedColumnCount = 706572376; - $tableSizeBytes = 927763390; - $rowCount = 1340416618; - $expectedResponse = new TableDataProfile(); - $expectedResponse->setName($name2); - $expectedResponse->setProjectDataProfile($projectDataProfile); - $expectedResponse->setDatasetProjectId($datasetProjectId); - $expectedResponse->setDatasetLocation($datasetLocation); - $expectedResponse->setDatasetId($datasetId); - $expectedResponse->setTableId($tableId); - $expectedResponse->setFullResource($fullResource); - $expectedResponse->setScannedColumnCount($scannedColumnCount); - $expectedResponse->setFailedColumnCount($failedColumnCount); - $expectedResponse->setTableSizeBytes($tableSizeBytes); - $expectedResponse->setRowCount($rowCount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); - $response = $gapicClient->getTableDataProfile($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/GetTableDataProfile', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getTableDataProfileExceptionTest() - { - $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->tableDataProfileName('[ORGANIZATION]', '[LOCATION]', '[TABLE_DATA_PROFILE]'); - try { - $gapicClient->getTableDataProfile($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 hybridInspectDlpJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new HybridInspectResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dlpJobName('[PROJECT]', '[DLP_JOB]'); - $response = $gapicClient->hybridInspectDlpJob($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/HybridInspectDlpJob', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function hybridInspectDlpJobExceptionTest() - { - $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->dlpJobName('[PROJECT]', '[DLP_JOB]'); - try { - $gapicClient->hybridInspectDlpJob($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 hybridInspectJobTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new HybridInspectResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $response = $gapicClient->hybridInspectJobTrigger($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/HybridInspectJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function hybridInspectJobTriggerExceptionTest() - { - $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - try { - $gapicClient->hybridInspectJobTrigger($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 inspectContentTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new InspectContentResponse(); - $transport->addResponse($expectedResponse); - $response = $gapicClient->inspectContent(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/InspectContent', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function inspectContentExceptionTest() - { - $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); - try { - $gapicClient->inspectContent(); - // 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 listColumnDataProfilesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $columnDataProfilesElement = new ColumnDataProfile(); - $columnDataProfiles = [ - $columnDataProfilesElement, - ]; - $expectedResponse = new ListColumnDataProfilesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setColumnDataProfiles($columnDataProfiles); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $response = $gapicClient->listColumnDataProfiles($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getColumnDataProfiles()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListColumnDataProfiles', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listColumnDataProfilesExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - try { - $gapicClient->listColumnDataProfiles($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 listConnectionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $connectionsElement = new Connection(); - $connections = [ - $connectionsElement, - ]; - $expectedResponse = new ListConnectionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setConnections($connections); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listConnections($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getConnections()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListConnections', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listConnectionsExceptionTest() - { - $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->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listConnections($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 listDeidentifyTemplatesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $deidentifyTemplatesElement = new DeidentifyTemplate(); - $deidentifyTemplates = [ - $deidentifyTemplatesElement, - ]; - $expectedResponse = new ListDeidentifyTemplatesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setDeidentifyTemplates($deidentifyTemplates); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $response = $gapicClient->listDeidentifyTemplates($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getDeidentifyTemplates()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListDeidentifyTemplates', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDeidentifyTemplatesExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - try { - $gapicClient->listDeidentifyTemplates($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 listDiscoveryConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $discoveryConfigsElement = new DiscoveryConfig(); - $discoveryConfigs = [ - $discoveryConfigsElement, - ]; - $expectedResponse = new ListDiscoveryConfigsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setDiscoveryConfigs($discoveryConfigs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listDiscoveryConfigs($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getDiscoveryConfigs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListDiscoveryConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDiscoveryConfigsExceptionTest() - { - $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->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listDiscoveryConfigs($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 listDlpJobsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $jobsElement = new DlpJob(); - $jobs = [ - $jobsElement, - ]; - $expectedResponse = new ListDlpJobsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setJobs($jobs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->listDlpJobs($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getJobs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListDlpJobs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDlpJobsExceptionTest() - { - $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->listDlpJobs($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 listInfoTypesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new ListInfoTypesResponse(); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listInfoTypes(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListInfoTypes', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listInfoTypesExceptionTest() - { - $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); - try { - $gapicClient->listInfoTypes(); - // 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 listInspectTemplatesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $inspectTemplatesElement = new InspectTemplate(); - $inspectTemplates = [ - $inspectTemplatesElement, - ]; - $expectedResponse = new ListInspectTemplatesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setInspectTemplates($inspectTemplates); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $response = $gapicClient->listInspectTemplates($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getInspectTemplates()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListInspectTemplates', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listInspectTemplatesExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - try { - $gapicClient->listInspectTemplates($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 listJobTriggersTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $jobTriggersElement = new JobTrigger(); - $jobTriggers = [ - $jobTriggersElement, - ]; - $expectedResponse = new ListJobTriggersResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setJobTriggers($jobTriggers); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->listJobTriggers($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getJobTriggers()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListJobTriggers', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listJobTriggersExceptionTest() - { - $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->listJobTriggers($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 listProjectDataProfilesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $projectDataProfilesElement = new ProjectDataProfile(); - $projectDataProfiles = [ - $projectDataProfilesElement, - ]; - $expectedResponse = new ListProjectDataProfilesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setProjectDataProfiles($projectDataProfiles); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $response = $gapicClient->listProjectDataProfiles($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getProjectDataProfiles()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListProjectDataProfiles', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listProjectDataProfilesExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - try { - $gapicClient->listProjectDataProfiles($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 listStoredInfoTypesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $storedInfoTypesElement = new StoredInfoType(); - $storedInfoTypes = [ - $storedInfoTypesElement, - ]; - $expectedResponse = new ListStoredInfoTypesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setStoredInfoTypes($storedInfoTypes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $response = $gapicClient->listStoredInfoTypes($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getStoredInfoTypes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListStoredInfoTypes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listStoredInfoTypesExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - try { - $gapicClient->listStoredInfoTypes($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 listTableDataProfilesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $tableDataProfilesElement = new TableDataProfile(); - $tableDataProfiles = [ - $tableDataProfilesElement, - ]; - $expectedResponse = new ListTableDataProfilesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTableDataProfiles($tableDataProfiles); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $response = $gapicClient->listTableDataProfiles($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getTableDataProfiles()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ListTableDataProfiles', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listTableDataProfilesExceptionTest() - { - $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->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - try { - $gapicClient->listTableDataProfiles($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 redactImageTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $redactedImage = '28'; - $extractedText = 'extractedText998260012'; - $expectedResponse = new RedactImageResponse(); - $expectedResponse->setRedactedImage($redactedImage); - $expectedResponse->setExtractedText($extractedText); - $transport->addResponse($expectedResponse); - $response = $gapicClient->redactImage(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/RedactImage', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function redactImageExceptionTest() - { - $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); - try { - $gapicClient->redactImage(); - // 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 reidentifyContentTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new ReidentifyContentResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->reidentifyContent($formattedParent); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/ReidentifyContent', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function reidentifyContentExceptionTest() - { - $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->reidentifyContent($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 searchConnectionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $connectionsElement = new Connection(); - $connections = [ - $connectionsElement, - ]; - $expectedResponse = new SearchConnectionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setConnections($connections); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->searchConnections($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getConnections()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/SearchConnections', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function searchConnectionsExceptionTest() - { - $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->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->searchConnections($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 updateConnectionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new Connection(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $connection = new Connection(); - $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; - $connection->setState($connectionState); - $response = $gapicClient->updateConnection($formattedName, $connection); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateConnection', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getConnection(); - $this->assertProtobufEquals($connection, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateConnectionExceptionTest() - { - $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->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $connection = new Connection(); - $connectionState = ConnectionState::CONNECTION_STATE_UNSPECIFIED; - $connection->setState($connectionState); - try { - $gapicClient->updateConnection($formattedName, $connection); - // 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 updateDeidentifyTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new DeidentifyTemplate(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - $response = $gapicClient->updateDeidentifyTemplate($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateDeidentifyTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDeidentifyTemplateExceptionTest() - { - $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->deidentifyTemplateName('[ORGANIZATION]', '[DEIDENTIFY_TEMPLATE]'); - try { - $gapicClient->updateDeidentifyTemplate($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 updateDiscoveryConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $expectedResponse = new DiscoveryConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - $discoveryConfig = new DiscoveryConfig(); - $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; - $discoveryConfig->setStatus($discoveryConfigStatus); - $response = $gapicClient->updateDiscoveryConfig($formattedName, $discoveryConfig); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateDiscoveryConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getDiscoveryConfig(); - $this->assertProtobufEquals($discoveryConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDiscoveryConfigExceptionTest() - { - $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->discoveryConfigName('[PROJECT]', '[LOCATION]', '[DISCOVERY_CONFIG]'); - $discoveryConfig = new DiscoveryConfig(); - $discoveryConfigStatus = Status::STATUS_UNSPECIFIED; - $discoveryConfig->setStatus($discoveryConfigStatus); - try { - $gapicClient->updateDiscoveryConfig($formattedName, $discoveryConfig); - // 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 updateInspectTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new InspectTemplate(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - $response = $gapicClient->updateInspectTemplate($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateInspectTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateInspectTemplateExceptionTest() - { - $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->inspectTemplateName('[ORGANIZATION]', '[INSPECT_TEMPLATE]'); - try { - $gapicClient->updateInspectTemplate($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 updateJobTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new JobTrigger(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - $response = $gapicClient->updateJobTrigger($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateJobTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateJobTriggerExceptionTest() - { - $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->jobTriggerName('[PROJECT]', '[JOB_TRIGGER]'); - try { - $gapicClient->updateJobTrigger($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 updateStoredInfoTypeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new StoredInfoType(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - $response = $gapicClient->updateStoredInfoType($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.privacy.dlp.v2.DlpService/UpdateStoredInfoType', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateStoredInfoTypeExceptionTest() - { - $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->storedInfoTypeName('[ORGANIZATION]', '[STORED_INFO_TYPE]'); - try { - $gapicClient->updateStoredInfoType($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()); - } -}