Class: Color
- Inherits:
-
TypesafeEnum::Base
- Object
- TypesafeEnum::Base
- Color
- Defined in:
- lib/software_challenge_client/color.rb
Overview
TODO 2022: Replace with bool? Die Spielsteinfarben. BLUE, und RED
Instance Method Summary collapse
-
#to_s ⇒ Object
Gibt den color namen zurück.
-
#to_t ⇒ Object
Gibt das zugehörige Team zurück.
Instance Method Details
#to_s ⇒ Object
Gibt den color namen zurück
14 15 16 |
# File 'lib/software_challenge_client/color.rb', line 14 def to_s self.key.to_s end |
#to_t ⇒ Object
Gibt das zugehörige Team zurück
19 20 21 22 23 24 25 |
# File 'lib/software_challenge_client/color.rb', line 19 def to_t if self.key == :RED Team::ONE else Team::TWO end end |