Class: GoogleTranslateScraper::Models::Translation

Inherits:
Object
  • Object
show all
Defined in:
lib/google_translate_scraper/models/translation.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(arguments = {}) ⇒ Translation

Returns a new instance of Translation.



8
9
10
11
12
# File 'lib/google_translate_scraper/models/translation.rb', line 8

def initialize(arguments = {})
  arguments.each do |key, value|
    instance_variable_set("@#{key}", value)
  end
end

Instance Attribute Details

#search_textObject

Returns the value of attribute search_text.



6
7
8
# File 'lib/google_translate_scraper/models/translation.rb', line 6

def search_text
  @search_text
end

#source_languageObject

Returns the value of attribute source_language.



6
7
8
# File 'lib/google_translate_scraper/models/translation.rb', line 6

def source_language
  @source_language
end

#target_languageObject

Returns the value of attribute target_language.



6
7
8
# File 'lib/google_translate_scraper/models/translation.rb', line 6

def target_language
  @target_language
end

#translated_textObject

Returns the value of attribute translated_text.



6
7
8
# File 'lib/google_translate_scraper/models/translation.rb', line 6

def translated_text
  @translated_text
end