Class: Zizq::Resources::CronGroup

Inherits:
Resource
  • Object
show all
Defined in:
lib/zizq/resources/cron_group.rb

Overview

Typed wrapper around a cron group response hash.

Instance Attribute Summary

Attributes inherited from Resource

#client

Instance Method Summary collapse

Methods inherited from Resource

#initialize, #inspect, #to_h

Constructor Details

This class inherits a constructor from Zizq::Resources::Resource

Instance Method Details

#entriesObject

Returns the entries in this group as typed resources.



18
19
20
# File 'lib/zizq/resources/cron_group.rb', line 18

def entries #: () -> Array[CronEntry]
  (@data["entries"] || []).map { |e| CronEntry.new(client, e) }
end

#nameObject

: () -> String



11
# File 'lib/zizq/resources/cron_group.rb', line 11

def name        = @data["name"]        #: () -> String

#pausedObject

: () -> bool



12
# File 'lib/zizq/resources/cron_group.rb', line 12

def paused      = @data["paused"]      #: () -> bool

#paused?Boolean

: () -> bool

Returns:

  • (Boolean)


13
# File 'lib/zizq/resources/cron_group.rb', line 13

def paused?     = paused               #: () -> bool

#paused_atObject

: () -> Float?



14
# File 'lib/zizq/resources/cron_group.rb', line 14

def paused_at   = ms_to_seconds(@data["paused_at"])   #: () -> Float?

#resumed_atObject

: () -> Float?



15
# File 'lib/zizq/resources/cron_group.rb', line 15

def resumed_at  = ms_to_seconds(@data["resumed_at"])  #: () -> Float?