Class: Google::Apis::VmwareengineV1::Constraints

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

Overview

Constraints to be applied while editing a schedule. These constraints ensure that Upgrade specific requirements are met.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Constraints

Returns a new instance of Constraints.



537
538
539
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 537

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

Instance Attribute Details

#disallowed_intervalsArray<Google::Apis::VmwareengineV1::WeeklyTimeInterval>

Output only. Output Only. A list of intervals in which maintenance windows are not allowed. Any time window that overlaps with any of these intervals will be considered invalid. Corresponds to the JSON property disallowedIntervals



513
514
515
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 513

def disallowed_intervals
  @disallowed_intervals
end

#min_hours_dayFixnum

Output only. Minimum number of hours must be allotted for the upgrade activities for each selected day. This is a minimum; the upgrade schedule can allot more hours for the given day. Corresponds to the JSON property minHoursDay

Returns:

  • (Fixnum)


520
521
522
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 520

def min_hours_day
  @min_hours_day
end

#min_hours_weekFixnum

Output only. The minimum number of weekly hours must be allotted for the upgrade activities. This is just a minimum; the schedule can assign more weekly hours. Corresponds to the JSON property minHoursWeek

Returns:

  • (Fixnum)


527
528
529
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 527

def min_hours_week
  @min_hours_week
end

#reschedule_date_rangeGoogle::Apis::VmwareengineV1::Interval

Represents a time interval, encoded as a Timestamp start (inclusive) and a Timestamp end (exclusive). The start must be less than or equal to the end. When the start equals the end, the interval is empty (matches no time). When both start and end are unspecified, the interval matches any time. Corresponds to the JSON property rescheduleDateRange



535
536
537
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 535

def reschedule_date_range
  @reschedule_date_range
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



542
543
544
545
546
547
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 542

def update!(**args)
  @disallowed_intervals = args[:disallowed_intervals] if args.key?(:disallowed_intervals)
  @min_hours_day = args[:min_hours_day] if args.key?(:min_hours_day)
  @min_hours_week = args[:min_hours_week] if args.key?(:min_hours_week)
  @reschedule_date_range = args[:reschedule_date_range] if args.key?(:reschedule_date_range)
end