Class: Google::Cloud::Compute::V1::FixedOrPercent
- Inherits:
-
Object
- Object
- Google::Cloud::Compute::V1::FixedOrPercent
- Extended by:
- Protobuf::MessageExts::ClassMethods
- Includes:
- Protobuf::MessageExts
- Defined in:
- proto_docs/google/cloud/compute/v1/compute.rb
Overview
Encapsulates numeric value that can be either absolute or relative.
Instance Attribute Summary collapse
-
#calculated ⇒ ::Integer
Output only.
-
#fixed ⇒ ::Integer
Specifies a fixed number of VM instances.
-
#percent ⇒ ::Integer
Specifies a percentage of instances between 0 to 100%, inclusive.
Instance Attribute Details
#calculated ⇒ ::Integer
Returns Output only. [Output Only] Absolute value of VM instances calculated based on the specific mode.
- If the value is fixed, then the calculated
value is equal to the fixed value.
- If the value is a percent, then the
calculated
value is percent/100 * targetSize. For example,
the calculated value of a 80% of a managed instance group
with 150 instances would be (80/100 * 150) = 120 VM instances. If there
is a remainder, the number is rounded.
20494 20495 20496 20497 |
# File 'proto_docs/google/cloud/compute/v1/compute.rb', line 20494 class FixedOrPercent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end |
#fixed ⇒ ::Integer
Returns Specifies a fixed number of VM instances. This must be a positive integer.
20494 20495 20496 20497 |
# File 'proto_docs/google/cloud/compute/v1/compute.rb', line 20494 class FixedOrPercent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end |
#percent ⇒ ::Integer
Returns Specifies a percentage of instances between 0 to 100%, inclusive. For example, specify 80 for 80%.
20494 20495 20496 20497 |
# File 'proto_docs/google/cloud/compute/v1/compute.rb', line 20494 class FixedOrPercent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end |