Class: Astronoby::RiseTransitSetCalculator::PotentialEvent
- Inherits:
-
Object
- Object
- Astronoby::RiseTransitSetCalculator::PotentialEvent
- Defined in:
- lib/astronoby/events/rise_transit_set_calculator.rb
Instance Attribute Summary collapse
-
#can_occur ⇒ Object
readonly
Returns the value of attribute can_occur.
-
#hour_angle ⇒ Object
readonly
Returns the value of attribute hour_angle.
Instance Method Summary collapse
-
#initialize(hour_angle, can_occur) ⇒ PotentialEvent
constructor
A new instance of PotentialEvent.
- #negated ⇒ Object
Constructor Details
#initialize(hour_angle, can_occur) ⇒ PotentialEvent
Returns a new instance of PotentialEvent.
8 9 10 11 |
# File 'lib/astronoby/events/rise_transit_set_calculator.rb', line 8 def initialize(hour_angle, can_occur) @hour_angle = hour_angle @can_occur = can_occur end |
Instance Attribute Details
#can_occur ⇒ Object (readonly)
Returns the value of attribute can_occur.
6 7 8 |
# File 'lib/astronoby/events/rise_transit_set_calculator.rb', line 6 def can_occur @can_occur end |
#hour_angle ⇒ Object (readonly)
Returns the value of attribute hour_angle.
6 7 8 |
# File 'lib/astronoby/events/rise_transit_set_calculator.rb', line 6 def hour_angle @hour_angle end |
Instance Method Details
#negated ⇒ Object
13 14 15 |
# File 'lib/astronoby/events/rise_transit_set_calculator.rb', line 13 def negated self.class.new(-@hour_angle, @can_occur) end |