Class: Google::Apis::DiscoveryengineV1alpha::GoogleApiDistributionBucketOptionsLinear

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/discoveryengine_v1alpha/classes.rb,
lib/google/apis/discoveryengine_v1alpha/representations.rb,
lib/google/apis/discoveryengine_v1alpha/representations.rb

Overview

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. Bucketi` has the following boundaries: Upper bound (0 <= i < N-1): offset + (width * i). Lower bound (1 <= i < N): offset + (width * (i
  • 1)).

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleApiDistributionBucketOptionsLinear

Returns a new instance of GoogleApiDistributionBucketOptionsLinear.



261
262
263
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 261

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#num_finite_bucketsFixnum

Must be greater than 0. Corresponds to the JSON property numFiniteBuckets

Returns:

  • (Fixnum)


249
250
251
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 249

def num_finite_buckets
  @num_finite_buckets
end

#offsetFloat

Lower bound of the first bucket. Corresponds to the JSON property offset

Returns:

  • (Float)


254
255
256
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 254

def offset
  @offset
end

#widthFloat

Must be greater than 0. Corresponds to the JSON property width

Returns:

  • (Float)


259
260
261
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 259

def width
  @width
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



266
267
268
269
270
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 266

def update!(**args)
  @num_finite_buckets = args[:num_finite_buckets] if args.key?(:num_finite_buckets)
  @offset = args[:offset] if args.key?(:offset)
  @width = args[:width] if args.key?(:width)
end