Reference documentation and code samples for the Cloud Logging V2 API class Google::Api::Distribution::BucketOptions::Linear.
Specifies a linear sequence of buckets that all have the same width
(except overflow and underflow). Each bucket represents a constant
absolute uncertainty on the specific value in the bucket.
There are num_finite_buckets + 2 (= N) buckets. Bucket i has the
following boundaries:
Upper bound (0 <= i < N-1): offset + (width * i).
Lower bound (1 <= i < N): offset + (width * (i - 1)).
Inherits
Object
Extended By
Google::Protobuf::MessageExts::ClassMethods
Includes
Google::Protobuf::MessageExts
Methods
#num_finite_buckets
defnum_finite_buckets()->::Integer
Returns
(::Integer) — Must be greater than 0.
#num_finite_buckets=
defnum_finite_buckets=(value)->::Integer
Parameter
value (::Integer) — Must be greater than 0.
Returns
(::Integer) — Must be greater than 0.
#offset
defoffset()->::Float
Returns
(::Float) — Lower bound of the first bucket.
#offset=
defoffset=(value)->::Float
Parameter
value (::Float) — Lower bound of the first bucket.
[[["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-08-28 UTC."],[],[],null,["# Cloud Logging V2 API - Class Google::Api::Distribution::BucketOptions::Linear (v1.3.0)\n\nVersion latestkeyboard_arrow_down\n\n- [1.3.0 (latest)](/ruby/docs/reference/google-cloud-logging-v2/latest/Google-Api-Distribution-BucketOptions-Linear)\n- [1.2.1](/ruby/docs/reference/google-cloud-logging-v2/1.2.1/Google-Api-Distribution-BucketOptions-Linear)\n- [1.1.0](/ruby/docs/reference/google-cloud-logging-v2/1.1.0/Google-Api-Distribution-BucketOptions-Linear)\n- [1.0.1](/ruby/docs/reference/google-cloud-logging-v2/1.0.1/Google-Api-Distribution-BucketOptions-Linear)\n- [0.13.0](/ruby/docs/reference/google-cloud-logging-v2/0.13.0/Google-Api-Distribution-BucketOptions-Linear)\n- [0.12.2](/ruby/docs/reference/google-cloud-logging-v2/0.12.2/Google-Api-Distribution-BucketOptions-Linear)\n- [0.11.0](/ruby/docs/reference/google-cloud-logging-v2/0.11.0/Google-Api-Distribution-BucketOptions-Linear)\n- [0.10.1](/ruby/docs/reference/google-cloud-logging-v2/0.10.1/Google-Api-Distribution-BucketOptions-Linear)\n- [0.9.0](/ruby/docs/reference/google-cloud-logging-v2/0.9.0/Google-Api-Distribution-BucketOptions-Linear)\n- [0.8.1](/ruby/docs/reference/google-cloud-logging-v2/0.8.1/Google-Api-Distribution-BucketOptions-Linear)\n- [0.7.0](/ruby/docs/reference/google-cloud-logging-v2/0.7.0/Google-Api-Distribution-BucketOptions-Linear)\n- [0.6.0](/ruby/docs/reference/google-cloud-logging-v2/0.6.0/Google-Api-Distribution-BucketOptions-Linear)\n- [0.5.6](/ruby/docs/reference/google-cloud-logging-v2/0.5.6/Google-Api-Distribution-BucketOptions-Linear) \nReference documentation and code samples for the Cloud Logging V2 API class Google::Api::Distribution::BucketOptions::Linear.\n\nSpecifies a linear sequence of buckets that all have the same width\n(except overflow and underflow). Each bucket represents a constant\nabsolute uncertainty on the specific value in the bucket.\n\n\nThere are `num_finite_buckets + 2` (= N) buckets. Bucket `i` has the\nfollowing boundaries:\n\nUpper bound (0 \\\u003c= i \\\u003c N-1): offset + (width \\* i).\n\n\u003cbr /\u003e\n\nLower bound (1 \\\u003c= i \\\u003c N): offset + (width \\* (i - 1)). \n\nInherits\n--------\n\n- Object \n\nExtended By\n-----------\n\n- Google::Protobuf::MessageExts::ClassMethods \n\nIncludes\n--------\n\n- Google::Protobuf::MessageExts\n\nMethods\n-------\n\n### #num_finite_buckets\n\n def num_finite_buckets() -\u003e ::Integer\n\n**Returns**\n\n- (::Integer) --- Must be greater than 0.\n\n### #num_finite_buckets=\n\n def num_finite_buckets=(value) -\u003e ::Integer\n\n**Parameter**\n\n- **value** (::Integer) --- Must be greater than 0. \n**Returns**\n\n- (::Integer) --- Must be greater than 0.\n\n### #offset\n\n def offset() -\u003e ::Float\n\n**Returns**\n\n- (::Float) --- Lower bound of the first bucket.\n\n### #offset=\n\n def offset=(value) -\u003e ::Float\n\n**Parameter**\n\n- **value** (::Float) --- Lower bound of the first bucket. \n**Returns**\n\n- (::Float) --- Lower bound of the first bucket.\n\n### #width\n\n def width() -\u003e ::Float\n\n**Returns**\n\n- (::Float) --- Must be greater than 0.\n\n### #width=\n\n def width=(value) -\u003e ::Float\n\n**Parameter**\n\n- **value** (::Float) --- Must be greater than 0. \n**Returns**\n\n- (::Float) --- Must be greater than 0."]]