Class: Google::Apis::PrivatecaV1beta1::GoogleApiServicecontrolV1LinearBuckets

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

Overview

Describing buckets with constant width.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleApiServicecontrolV1LinearBuckets

Returns a new instance of GoogleApiServicecontrolV1LinearBuckets.



1476
1477
1478
# File 'lib/google/apis/privateca_v1beta1/classes.rb', line 1476

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

Instance Attribute Details

#num_finite_bucketsFixnum

The number of finite buckets. With the underflow and overflow buckets, the total number of buckets is num_finite_buckets + 2. See comments on bucket_options for details. Corresponds to the JSON property numFiniteBuckets

Returns:

  • (Fixnum)


1461
1462
1463
# File 'lib/google/apis/privateca_v1beta1/classes.rb', line 1461

def num_finite_buckets
  @num_finite_buckets
end

#offsetFloat

The i'th linear bucket covers the interval [offset + (i-1) * width, offset + i

  • width) where i ranges from 1 to num_finite_buckets, inclusive. Corresponds to the JSON property offset

Returns:

  • (Float)


1467
1468
1469
# File 'lib/google/apis/privateca_v1beta1/classes.rb', line 1467

def offset
  @offset
end

#widthFloat

The i'th linear bucket covers the interval [offset + (i-1) * width, offset + i

  • width) where i ranges from 1 to num_finite_buckets, inclusive. Must be strictly positive. Corresponds to the JSON property width

Returns:

  • (Float)


1474
1475
1476
# File 'lib/google/apis/privateca_v1beta1/classes.rb', line 1474

def width
  @width
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1481
1482
1483
1484
1485
# File 'lib/google/apis/privateca_v1beta1/classes.rb', line 1481

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