Class: Prdigest::Clock::Window
- Inherits:
-
Data
- Object
- Data
- Prdigest::Clock::Window
- Defined in:
- lib/prdigest/clock.rb
Instance Attribute Summary collapse
-
#end_time ⇒ Object
readonly
Returns the value of attribute end_time.
-
#local_date ⇒ Object
readonly
Returns the value of attribute local_date.
-
#start_time ⇒ Object
readonly
Returns the value of attribute start_time.
Instance Method Summary collapse
Instance Attribute Details
#end_time ⇒ Object (readonly)
Returns the value of attribute end_time
9 10 11 |
# File 'lib/prdigest/clock.rb', line 9 def end_time @end_time end |
#local_date ⇒ Object (readonly)
Returns the value of attribute local_date
9 10 11 |
# File 'lib/prdigest/clock.rb', line 9 def local_date @local_date end |
#start_time ⇒ Object (readonly)
Returns the value of attribute start_time
9 10 11 |
# File 'lib/prdigest/clock.rb', line 9 def start_time @start_time end |
Instance Method Details
#cover?(time) ⇒ Boolean
10 11 12 |
# File 'lib/prdigest/clock.rb', line 10 def cover?(time) time >= start_time && time < end_time end |
#zero_length? ⇒ Boolean
14 15 16 |
# File 'lib/prdigest/clock.rb', line 14 def zero_length? start_time == end_time end |