Class: Google::Apis::ComputeV1::ReservationBlock

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

Overview

Represents a reservation block resource.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ReservationBlock

Returns a new instance of ReservationBlock.



42577
42578
42579
# File 'lib/google/apis/compute_v1/classes.rb', line 42577

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

Instance Attribute Details

#countFixnum

Output only. [Output Only] The number of resources that are allocated in this reservation block. Corresponds to the JSON property count

Returns:

  • (Fixnum)


42483
42484
42485
# File 'lib/google/apis/compute_v1/classes.rb', line 42483

def count
  @count
end

#creation_timestampString

Output only. [Output Only] Creation timestamp inRFC3339 text format. Corresponds to the JSON property creationTimestamp

Returns:

  • (String)


42488
42489
42490
# File 'lib/google/apis/compute_v1/classes.rb', line 42488

def creation_timestamp
  @creation_timestamp
end

#health_infoGoogle::Apis::ComputeV1::ReservationBlockHealthInfo

Health information for the reservation block. Corresponds to the JSON property healthInfo



42493
42494
42495
# File 'lib/google/apis/compute_v1/classes.rb', line 42493

def health_info
  @health_info
end

#idFixnum

Output only. [Output Only] The unique identifier for the resource. This identifier is defined by the server. Corresponds to the JSON property id

Returns:

  • (Fixnum)


42500
42501
42502
# File 'lib/google/apis/compute_v1/classes.rb', line 42500

def id
  @id
end

#in_use_countFixnum

Output only. [Output Only] The number of instances that are currently in use on this reservation block. Corresponds to the JSON property inUseCount

Returns:

  • (Fixnum)


42507
42508
42509
# File 'lib/google/apis/compute_v1/classes.rb', line 42507

def in_use_count
  @in_use_count
end

#in_use_host_countFixnum

Output only. Number of hosts currently in use. If there is one or more Instances running on the host, it is considered in use. Corresponds to the JSON property inUseHostCount

Returns:

  • (Fixnum)


42514
42515
42516
# File 'lib/google/apis/compute_v1/classes.rb', line 42514

def in_use_host_count
  @in_use_host_count
end

#kindString

Output only. [Output Only] Type of the resource. Alwayscompute# reservationBlock for reservation blocks. Corresponds to the JSON property kind

Returns:

  • (String)


42520
42521
42522
# File 'lib/google/apis/compute_v1/classes.rb', line 42520

def kind
  @kind
end

#nameString

Output only. [Output Only] The name of this reservation block generated by Google Compute Engine. The name must be 1-63 characters long, and comply with RFC1035 @pattern a-z? Corresponds to the JSON property name

Returns:

  • (String)


42528
42529
42530
# File 'lib/google/apis/compute_v1/classes.rb', line 42528

def name
  @name
end

#physical_topologyGoogle::Apis::ComputeV1::ReservationBlockPhysicalTopology

Output only. [Output Only] The physical topology of the reservation block. Corresponds to the JSON property physicalTopology



42533
42534
42535
# File 'lib/google/apis/compute_v1/classes.rb', line 42533

def physical_topology
  @physical_topology
end

#reservation_maintenanceGoogle::Apis::ComputeV1::GroupMaintenanceInfo

Maintenance Info for ReservationBlocks. Corresponds to the JSON property reservationMaintenance



42538
42539
42540
# File 'lib/google/apis/compute_v1/classes.rb', line 42538

def reservation_maintenance
  @reservation_maintenance
end

#reservation_sub_block_countFixnum

Output only. [Output Only] The number of reservation subBlocks associated with this reservation block. Corresponds to the JSON property reservationSubBlockCount

Returns:

  • (Fixnum)


42545
42546
42547
# File 'lib/google/apis/compute_v1/classes.rb', line 42545

def reservation_sub_block_count
  @reservation_sub_block_count
end

#reservation_sub_block_in_use_countFixnum

Output only. [Output Only] The number of in-use reservation subBlocks associated with this reservation block. If at least one VM is running on a subBlock, it is considered in-use. Corresponds to the JSON property reservationSubBlockInUseCount

Returns:

  • (Fixnum)


42553
42554
42555
# File 'lib/google/apis/compute_v1/classes.rb', line 42553

def reservation_sub_block_in_use_count
  @reservation_sub_block_in_use_count
end

Output only. [Output Only] Server-defined fully-qualified URL for this resource. Corresponds to the JSON property selfLink

Returns:

  • (String)


42559
42560
42561
# File 'lib/google/apis/compute_v1/classes.rb', line 42559

def self_link
  @self_link
end

Output only. [Output Only] Server-defined URL for this resource with the resource id. Corresponds to the JSON property selfLinkWithId

Returns:

  • (String)


42565
42566
42567
# File 'lib/google/apis/compute_v1/classes.rb', line 42565

def self_link_with_id
  @self_link_with_id
end

#statusString

Output only. [Output Only] Status of the reservation block. Corresponds to the JSON property status

Returns:

  • (String)


42570
42571
42572
# File 'lib/google/apis/compute_v1/classes.rb', line 42570

def status
  @status
end

#zoneString

Output only. [Output Only] Zone in which the reservation block resides. Corresponds to the JSON property zone

Returns:

  • (String)


42575
42576
42577
# File 'lib/google/apis/compute_v1/classes.rb', line 42575

def zone
  @zone
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



42582
42583
42584
42585
42586
42587
42588
42589
42590
42591
42592
42593
42594
42595
42596
42597
42598
42599
# File 'lib/google/apis/compute_v1/classes.rb', line 42582

def update!(**args)
  @count = args[:count] if args.key?(:count)
  @creation_timestamp = args[:creation_timestamp] if args.key?(:creation_timestamp)
  @health_info = args[:health_info] if args.key?(:health_info)
  @id = args[:id] if args.key?(:id)
  @in_use_count = args[:in_use_count] if args.key?(:in_use_count)
  @in_use_host_count = args[:in_use_host_count] if args.key?(:in_use_host_count)
  @kind = args[:kind] if args.key?(:kind)
  @name = args[:name] if args.key?(:name)
  @physical_topology = args[:physical_topology] if args.key?(:physical_topology)
  @reservation_maintenance = args[:reservation_maintenance] if args.key?(:reservation_maintenance)
  @reservation_sub_block_count = args[:reservation_sub_block_count] if args.key?(:reservation_sub_block_count)
  @reservation_sub_block_in_use_count = args[:reservation_sub_block_in_use_count] if args.key?(:reservation_sub_block_in_use_count)
  @self_link = args[:self_link] if args.key?(:self_link)
  @self_link_with_id = args[:self_link_with_id] if args.key?(:self_link_with_id)
  @status = args[:status] if args.key?(:status)
  @zone = args[:zone] if args.key?(:zone)
end