lib/phrase/models/key_create_parameters.rb in phrase-3.6.0 vs lib/phrase/models/key_create_parameters.rb in phrase-3.7.0
- old
+ new
@@ -36,10 +36,13 @@
attr_accessor :unformatted
# Creates a translation in the default locale with the specified content
attr_accessor :default_translation_content
+ # Indicates whether the key should be autotranslated to other locales based on the copy provided in `default_translation_content`.
+ attr_accessor :autotranslate
+
# Indicates whether the key should be exported with \"xml:space=preserve\". Supported by several XML-based formats.
attr_accessor :xml_space_preserve
# Original file attribute. Used in some formats, e.g. XLIFF.
attr_accessor :original_file
@@ -66,10 +69,11 @@
:'max_characters_allowed' => :'max_characters_allowed',
:'screenshot' => :'screenshot',
:'remove_screenshot' => :'remove_screenshot',
:'unformatted' => :'unformatted',
:'default_translation_content' => :'default_translation_content',
+ :'autotranslate' => :'autotranslate',
:'xml_space_preserve' => :'xml_space_preserve',
:'original_file' => :'original_file',
:'localized_format_string' => :'localized_format_string',
:'localized_format_key' => :'localized_format_key',
:'custom_metadata' => :'custom_metadata'
@@ -89,10 +93,11 @@
:'max_characters_allowed' => :'Integer',
:'screenshot' => :'File',
:'remove_screenshot' => :'Boolean',
:'unformatted' => :'Boolean',
:'default_translation_content' => :'String',
+ :'autotranslate' => :'Boolean',
:'xml_space_preserve' => :'Boolean',
:'original_file' => :'String',
:'localized_format_string' => :'String',
:'localized_format_key' => :'String',
:'custom_metadata' => :'Object'
@@ -166,10 +171,14 @@
if attributes.key?(:'default_translation_content')
self.default_translation_content = attributes[:'default_translation_content']
end
+ if attributes.key?(:'autotranslate')
+ self.autotranslate = attributes[:'autotranslate']
+ end
+
if attributes.key?(:'xml_space_preserve')
self.xml_space_preserve = attributes[:'xml_space_preserve']
end
if attributes.key?(:'original_file')
@@ -222,10 +231,11 @@
max_characters_allowed == o.max_characters_allowed &&
screenshot == o.screenshot &&
remove_screenshot == o.remove_screenshot &&
unformatted == o.unformatted &&
default_translation_content == o.default_translation_content &&
+ autotranslate == o.autotranslate &&
xml_space_preserve == o.xml_space_preserve &&
original_file == o.original_file &&
localized_format_string == o.localized_format_string &&
localized_format_key == o.localized_format_key &&
custom_metadata == o.custom_metadata
@@ -238,10 +248,10 @@
end
# Calculates hash code according to all attributes.
# @return [Integer] Hash code
def hash
- [branch, name, description, plural, name_plural, data_type, tags, max_characters_allowed, screenshot, remove_screenshot, unformatted, default_translation_content, xml_space_preserve, original_file, localized_format_string, localized_format_key, custom_metadata].hash
+ [branch, name, description, plural, name_plural, data_type, tags, max_characters_allowed, screenshot, remove_screenshot, unformatted, default_translation_content, autotranslate, xml_space_preserve, original_file, localized_format_string, localized_format_key, custom_metadata].hash
end
# Builds the object from hash
# @param [Hash] attributes Model attributes in the form of hash
# @return [Object] Returns the model itself