Class: BabelDiff::ImportFileHandler::PhraseFile
- Inherits:
-
Struct
- Object
- Struct
- BabelDiff::ImportFileHandler::PhraseFile
- Defined in:
- lib/babel_diff/import_file_handler.rb
Instance Attribute Summary collapse
-
#path ⇒ Object
Returns the value of attribute path.
Instance Method Summary collapse
Instance Attribute Details
#path ⇒ Object
Returns the value of attribute path
26 27 28 |
# File 'lib/babel_diff/import_file_handler.rb', line 26 def path @path end |
Instance Method Details
#contents ⇒ Object
32 33 34 |
# File 'lib/babel_diff/import_file_handler.rb', line 32 def contents File.read(path) end |
#language ⇒ Object
28 29 30 |
# File 'lib/babel_diff/import_file_handler.rb', line 28 def language path.split("/").last.match(/phrase.(.*).yml/)[1] end |