Class: AdLocalize::ViewModels::TranslationViewModel

Inherits:
Object
  • Object
show all
Defined in:
lib/ad_localize/view_models/translation_view_model.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(label:, key:, value:, comment:) ⇒ TranslationViewModel

Returns a new instance of TranslationViewModel.



11
12
13
14
15
16
# File 'lib/ad_localize/view_models/translation_view_model.rb', line 11

def initialize(label:, key:, value:, comment:)
  @label = label
  @key = key
  @value = value
  @comment = comment
end

Instance Attribute Details

#commentObject (readonly)

Returns the value of attribute comment.



4
5
6
# File 'lib/ad_localize/view_models/translation_view_model.rb', line 4

def comment
  @comment
end

#keyObject (readonly)

Returns the value of attribute key.



4
5
6
# File 'lib/ad_localize/view_models/translation_view_model.rb', line 4

def key
  @key
end

#labelObject (readonly)

Returns the value of attribute label.



4
5
6
# File 'lib/ad_localize/view_models/translation_view_model.rb', line 4

def label
  @label
end

#valueObject (readonly)

Returns the value of attribute value.



4
5
6
# File 'lib/ad_localize/view_models/translation_view_model.rb', line 4

def value
  @value
end