Class: Opsgenie::TimelineRotation

Inherits:
Object
  • Object
show all
Defined in:
lib/opsgenie/timeline_rotation.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id:, name:, periods:) ⇒ TimelineRotation

Returns a new instance of TimelineRotation.



5
6
7
8
9
# File 'lib/opsgenie/timeline_rotation.rb', line 5

def initialize(id:, name:, periods:)
  @id = id
  @name = name
  @periods = periods.map { |p| TimelinePeriod.new(p) }
end

Instance Attribute Details

#idObject (readonly)

Returns the value of attribute id.



3
4
5
# File 'lib/opsgenie/timeline_rotation.rb', line 3

def id
  @id
end

#nameObject (readonly)

Returns the value of attribute name.



3
4
5
# File 'lib/opsgenie/timeline_rotation.rb', line 3

def name
  @name
end

#periodsObject (readonly)

Returns the value of attribute periods.



3
4
5
# File 'lib/opsgenie/timeline_rotation.rb', line 3

def periods
  @periods
end