Reference documentation and code samples for the Data Loss Prevention V2 Client class FixedSizeBucketingConfig.
Buckets values based on fixed size ranges. The
Bucketing transformation can provide all of this functionality,
but requires more configuration. This message is provided as a convenience to
the user for simple bucketing strategies.
The transformed value will be a hyphenated string of
{lower_bound}-{upper_bound}. For example, if lower_bound = 10 and upper_bound
= 20, all values that are within this bucket will be replaced with "10-20".
This can be used on data of type: double, long.
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.
Seehttps://cloud.google.com/sensitive-data-protection/docs/concepts-bucketingto
learn more.
Generated from protobuf messagegoogle.privacy.dlp.v2.FixedSizeBucketingConfig
Required. Lower bound value of buckets. All values less thanlower_boundare grouped together into a single bucket; for example iflower_bound= 10, then all values less than 10 are replaced with the value "-10".
Required. Upper bound value of buckets. All values greater than upper_bound are grouped together into a single bucket; for example ifupper_bound= 89, then all values greater than 89 are replaced with the value "89+".
↳ bucket_size
float
Required. Size of each bucket (except for minimum and maximum buckets). So iflower_bound= 10,upper_bound= 89, andbucket_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.
getLowerBound
Required. Lower bound value of buckets. All values less thanlower_boundare grouped together into a single bucket; for example iflower_bound=
10, then all values less than 10 are replaced with the value "-10".
Required. Lower bound value of buckets. All values less thanlower_boundare grouped together into a single bucket; for example iflower_bound=
10, then all values less than 10 are replaced with the value "-10".
Required. Upper bound value of buckets. All values greater than upper_bound
are grouped together into a single bucket; for example ifupper_bound=
89, then all values greater than 89 are replaced with the value "89+".
Required. Upper bound value of buckets. All values greater than upper_bound
are grouped together into a single bucket; for example ifupper_bound=
89, then all values greater than 89 are replaced with the value "89+".
Required. Size of each bucket (except for minimum and maximum buckets). So
iflower_bound= 10,upper_bound= 89, andbucket_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.
Returns
Type
Description
float
setBucketSize
Required. Size of each bucket (except for minimum and maximum buckets). So
iflower_bound= 10,upper_bound= 89, andbucket_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.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# Data Loss Prevention V2 Client - Class FixedSizeBucketingConfig (2.6.1)\n\nVersion latestkeyboard_arrow_down\n\n- [2.6.1 (latest)](/php/docs/reference/cloud-dlp/latest/V2.FixedSizeBucketingConfig)\n- [2.6.0](/php/docs/reference/cloud-dlp/2.6.0/V2.FixedSizeBucketingConfig)\n- [2.4.1](/php/docs/reference/cloud-dlp/2.4.1/V2.FixedSizeBucketingConfig)\n- [2.3.0](/php/docs/reference/cloud-dlp/2.3.0/V2.FixedSizeBucketingConfig)\n- [2.2.3](/php/docs/reference/cloud-dlp/2.2.3/V2.FixedSizeBucketingConfig)\n- [2.1.0](/php/docs/reference/cloud-dlp/2.1.0/V2.FixedSizeBucketingConfig)\n- [2.0.0](/php/docs/reference/cloud-dlp/2.0.0/V2.FixedSizeBucketingConfig)\n- [1.19.0](/php/docs/reference/cloud-dlp/1.19.0/V2.FixedSizeBucketingConfig)\n- [1.18.0](/php/docs/reference/cloud-dlp/1.18.0/V2.FixedSizeBucketingConfig)\n- [1.17.0](/php/docs/reference/cloud-dlp/1.17.0/V2.FixedSizeBucketingConfig)\n- [1.16.0](/php/docs/reference/cloud-dlp/1.16.0/V2.FixedSizeBucketingConfig)\n- [1.15.1](/php/docs/reference/cloud-dlp/1.15.1/V2.FixedSizeBucketingConfig)\n- [1.14.0](/php/docs/reference/cloud-dlp/1.14.0/V2.FixedSizeBucketingConfig)\n- [1.13.2](/php/docs/reference/cloud-dlp/1.13.2/V2.FixedSizeBucketingConfig)\n- [1.12.0](/php/docs/reference/cloud-dlp/1.12.0/V2.FixedSizeBucketingConfig)\n- [1.11.0](/php/docs/reference/cloud-dlp/1.11.0/V2.FixedSizeBucketingConfig)\n- [1.10.2](/php/docs/reference/cloud-dlp/1.10.2/V2.FixedSizeBucketingConfig)\n- [1.9.0](/php/docs/reference/cloud-dlp/1.9.0/V2.FixedSizeBucketingConfig)\n- [1.8.6](/php/docs/reference/cloud-dlp/1.8.6/V2.FixedSizeBucketingConfig) \nReference documentation and code samples for the Data Loss Prevention V2 Client class FixedSizeBucketingConfig.\n\nBuckets values based on fixed size ranges. The\nBucketing transformation can provide all of this functionality,\nbut requires more configuration. This message is provided as a convenience to\nthe user for simple bucketing strategies.\n\nThe transformed value will be a hyphenated string of\n{lower_bound}-{upper_bound}. For example, if lower_bound = 10 and upper_bound\n= 20, all values that are within this bucket will be replaced with \"10-20\".\nThis can be used on data of type: double, long.\nIf the bound Value type differs from the type of data\nbeing transformed, we will first attempt converting the type of the data to\nbe transformed to match the type of the bound before comparing.\nSee\n\u003chttps://cloud.google.com/sensitive-data-protection/docs/concepts-bucketing\u003e to\nlearn more.\n\nGenerated from protobuf message `google.privacy.dlp.v2.FixedSizeBucketingConfig`\n\nNamespace\n---------\n\nGoogle \\\\ Cloud \\\\ Dlp \\\\ V2\n\nMethods\n-------\n\n### __construct\n\nConstructor.\n\n### getLowerBound\n\nRequired. Lower bound value of buckets. All values less than `lower_bound`\nare grouped together into a single bucket; for example if `lower_bound` =\n10, then all values less than 10 are replaced with the value \"-10\".\n\n### hasLowerBound\n\n### clearLowerBound\n\n### setLowerBound\n\nRequired. Lower bound value of buckets. All values less than `lower_bound`\nare grouped together into a single bucket; for example if `lower_bound` =\n10, then all values less than 10 are replaced with the value \"-10\".\n\n### getUpperBound\n\nRequired. Upper bound value of buckets. All values greater than upper_bound\nare grouped together into a single bucket; for example if `upper_bound` =\n89, then all values greater than 89 are replaced with the value \"89+\".\n\n### hasUpperBound\n\n### clearUpperBound\n\n### setUpperBound\n\nRequired. Upper bound value of buckets. All values greater than upper_bound\nare grouped together into a single bucket; for example if `upper_bound` =\n89, then all values greater than 89 are replaced with the value \"89+\".\n\n### getBucketSize\n\nRequired. Size of each bucket (except for minimum and maximum buckets). So\nif `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the\nfollowing buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60,\n60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works.\n\n### setBucketSize\n\nRequired. Size of each bucket (except for minimum and maximum buckets). So\nif `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the\nfollowing buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60,\n60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works."]]