Class: Rosetta::Phrase
- Inherits:
-
Object
- Object
- Rosetta::Phrase
- Defined in:
- lib/rosetta/phrase.rb
Instance Attribute Summary collapse
-
#keys ⇒ Object
readonly
Returns the value of attribute keys.
-
#repository_link ⇒ Object
readonly
Returns the value of attribute repository_link.
-
#text ⇒ Object
readonly
Returns the value of attribute text.
Instance Method Summary collapse
- #code ⇒ Object
-
#initialize(keys, text, repository_link) ⇒ Phrase
constructor
A new instance of Phrase.
Constructor Details
#initialize(keys, text, repository_link) ⇒ Phrase
Returns a new instance of Phrase.
6 7 8 9 10 |
# File 'lib/rosetta/phrase.rb', line 6 def initialize(keys, text, repository_link) @keys = keys @text = text @repository_link = repository_link end |
Instance Attribute Details
#keys ⇒ Object (readonly)
Returns the value of attribute keys.
4 5 6 |
# File 'lib/rosetta/phrase.rb', line 4 def keys @keys end |
#repository_link ⇒ Object (readonly)
Returns the value of attribute repository_link.
4 5 6 |
# File 'lib/rosetta/phrase.rb', line 4 def repository_link @repository_link end |
#text ⇒ Object (readonly)
Returns the value of attribute text.
4 5 6 |
# File 'lib/rosetta/phrase.rb', line 4 def text @text end |
Instance Method Details
#code ⇒ Object
12 13 14 |
# File 'lib/rosetta/phrase.rb', line 12 def code @keys.join('.') end |