Class: Google::Apis::RedisV1beta1::TypedValue

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

Overview

TypedValue represents the value of a metric type. It can either be a double, an int64, a string or a bool.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ TypedValue

Returns a new instance of TypedValue.



4781
4782
4783
# File 'lib/google/apis/redis_v1beta1/classes.rb', line 4781

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

Instance Attribute Details

#bool_valueBoolean Also known as: bool_value?

For boolean value Corresponds to the JSON property boolValue

Returns:

  • (Boolean)


4763
4764
4765
# File 'lib/google/apis/redis_v1beta1/classes.rb', line 4763

def bool_value
  @bool_value
end

#double_valueFloat

For double value Corresponds to the JSON property doubleValue

Returns:

  • (Float)


4769
4770
4771
# File 'lib/google/apis/redis_v1beta1/classes.rb', line 4769

def double_value
  @double_value
end

#int64_valueFixnum

For integer value Corresponds to the JSON property int64Value

Returns:

  • (Fixnum)


4774
4775
4776
# File 'lib/google/apis/redis_v1beta1/classes.rb', line 4774

def int64_value
  @int64_value
end

#string_valueString

For string value Corresponds to the JSON property stringValue

Returns:

  • (String)


4779
4780
4781
# File 'lib/google/apis/redis_v1beta1/classes.rb', line 4779

def string_value
  @string_value
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



4786
4787
4788
4789
4790
4791
# File 'lib/google/apis/redis_v1beta1/classes.rb', line 4786

def update!(**args)
  @bool_value = args[:bool_value] if args.key?(:bool_value)
  @double_value = args[:double_value] if args.key?(:double_value)
  @int64_value = args[:int64_value] if args.key?(:int64_value)
  @string_value = args[:string_value] if args.key?(:string_value)
end