Class: Souls::SoulsQuery
- Inherits:
-
GraphQL::Schema::Resolver
- Object
- GraphQL::Schema::Resolver
- Souls::SoulsQuery
- Defined in:
- lib/souls/app/graphql/souls_query.rb
Class Attribute Summary collapse
-
.schedule ⇒ Object
Returns the value of attribute schedule.
Class Method Summary collapse
Class Attribute Details
.schedule ⇒ Object
Returns the value of attribute schedule.
5 6 7 |
# File 'lib/souls/app/graphql/souls_query.rb', line 5 def schedule @schedule end |
Class Method Details
.all_schedules ⇒ Object
12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/souls/app/graphql/souls_query.rb', line 12 def self.all_schedules schedule_list = {} Queries.constants.select { |c| Queries.const_get(c).is_a?(Class) } .each do |clname| next if clname == :BaseQuery job_schedule = Queries.const_get(clname).schedule schedule_list[clname] = job_schedule unless job_schedule.nil? end schedule_list end |
.cron(schedule) ⇒ Object
8 9 10 |
# File 'lib/souls/app/graphql/souls_query.rb', line 8 def self.cron(schedule) self.schedule = schedule end |