Class: DateTimeStepWith::CronListMatcher
- Inherits:
-
Object
- Object
- DateTimeStepWith::CronListMatcher
- Defined in:
- lib/date_time_step_with/cron_matcher.rb
Instance Method Summary collapse
- #=~(value) ⇒ Object
-
#initialize(cron_expression) ⇒ CronListMatcher
constructor
A new instance of CronListMatcher.
Constructor Details
#initialize(cron_expression) ⇒ CronListMatcher
Returns a new instance of CronListMatcher.
25 26 27 |
# File 'lib/date_time_step_with/cron_matcher.rb', line 25 def initialize(cron_expression) @list = cron_expression.split(",") end |
Instance Method Details
#=~(value) ⇒ Object
29 30 31 |
# File 'lib/date_time_step_with/cron_matcher.rb', line 29 def =~(value) @list.include? value end |