Class: PhraseApp::RequestParams::TranslationOrderParams
- Inherits:
-
OpenStruct
- Object
- OpenStruct
- PhraseApp::RequestParams::TranslationOrderParams
- Defined in:
- lib/phraseapp-ruby.rb
Overview
TranslationOrderParams
Parameters:
- category
-
Category to use (required for orders processed by TextMaster).
- include_untranslated_keys
-
Order translations for keys with untranslated content in the selected target locales.
- include_unverified_translations
-
Order translations for keys with unverified content in the selected target locales.
- lsp
-
Name of the LSP that should process this order. Can be one of gengo, textmaster.
- message
-
Message that is displayed to the translators for description.
- priority
-
Indicates whether the priority option should be ordered which decreases turnaround time by 30%. Available only for orders processed by TextMaster.
- quality
-
Extra proofreading option to ensure consistency in vocabulary and style. Only available for orders processed by TextMaster.
- source_locale_id
-
Source locale for the order. Can be the name or public id of the source locale. Preferred is the public id.
- styleguide_id
-
Style guide for translators to be sent with the order.
- tag
-
Tag you want to order translations for.
- target_locale_ids
-
List of target locales you want the source content translate to. Can be the name or public id of the target locales. Preferred is the public id.
- translation_type
-
Name of the quality level, availability depends on the LSP. Can be one of: standard, pro (for orders processed by Gengo) and one of regular, premium, enterprise (for orders processed by TextMaster)
- unverify_translations_upon_delivery
-
Unverify translations upon delivery.
Instance Method Summary collapse
- #category=(val) ⇒ Object
- #include_untranslated_keys=(val) ⇒ Object
- #include_unverified_translations=(val) ⇒ Object
- #lsp=(val) ⇒ Object
- #message=(val) ⇒ Object
- #priority=(val) ⇒ Object
- #quality=(val) ⇒ Object
- #source_locale_id=(val) ⇒ Object
- #styleguide_id=(val) ⇒ Object
- #tag=(val) ⇒ Object
- #target_locale_ids=(val) ⇒ Object
- #translation_type=(val) ⇒ Object
- #unverify_translations_upon_delivery=(val) ⇒ Object
- #validate ⇒ Object
Instance Method Details
#category=(val) ⇒ Object
1005 1006 1007 |
# File 'lib/phraseapp-ruby.rb', line 1005 def category=(val) super(val) end |
#include_untranslated_keys=(val) ⇒ Object
1009 1010 1011 1012 1013 1014 1015 1016 1017 |
# File 'lib/phraseapp-ruby.rb', line 1009 def include_untranslated_keys=(val) if val.is_a?(TrueClass) super(true) elsif val.is_a?(FalseClass) return else PhraseApp::ParamsHelpers::ParamsValidationError.new("invalid value #{val}") end end |
#include_unverified_translations=(val) ⇒ Object
1019 1020 1021 1022 1023 1024 1025 1026 1027 |
# File 'lib/phraseapp-ruby.rb', line 1019 def include_unverified_translations=(val) if val.is_a?(TrueClass) super(true) elsif val.is_a?(FalseClass) return else PhraseApp::ParamsHelpers::ParamsValidationError.new("invalid value #{val}") end end |
#lsp=(val) ⇒ Object
1029 1030 1031 |
# File 'lib/phraseapp-ruby.rb', line 1029 def lsp=(val) super(val) end |
#message=(val) ⇒ Object
1033 1034 1035 |
# File 'lib/phraseapp-ruby.rb', line 1033 def (val) super(val) end |
#priority=(val) ⇒ Object
1037 1038 1039 1040 1041 1042 1043 1044 1045 |
# File 'lib/phraseapp-ruby.rb', line 1037 def priority=(val) if val.is_a?(TrueClass) super(true) elsif val.is_a?(FalseClass) return else PhraseApp::ParamsHelpers::ParamsValidationError.new("invalid value #{val}") end end |
#quality=(val) ⇒ Object
1047 1048 1049 1050 1051 1052 1053 1054 1055 |
# File 'lib/phraseapp-ruby.rb', line 1047 def quality=(val) if val.is_a?(TrueClass) super(true) elsif val.is_a?(FalseClass) return else PhraseApp::ParamsHelpers::ParamsValidationError.new("invalid value #{val}") end end |
#source_locale_id=(val) ⇒ Object
1057 1058 1059 |
# File 'lib/phraseapp-ruby.rb', line 1057 def source_locale_id=(val) super(val) end |
#styleguide_id=(val) ⇒ Object
1061 1062 1063 |
# File 'lib/phraseapp-ruby.rb', line 1061 def styleguide_id=(val) super(val) end |
#tag=(val) ⇒ Object
1065 1066 1067 |
# File 'lib/phraseapp-ruby.rb', line 1065 def tag=(val) super(val) end |
#target_locale_ids=(val) ⇒ Object
1069 1070 1071 |
# File 'lib/phraseapp-ruby.rb', line 1069 def target_locale_ids=(val) super(val.split(',')) end |
#translation_type=(val) ⇒ Object
1073 1074 1075 |
# File 'lib/phraseapp-ruby.rb', line 1073 def translation_type=(val) super(val) end |
#unverify_translations_upon_delivery=(val) ⇒ Object
1077 1078 1079 1080 1081 1082 1083 1084 1085 |
# File 'lib/phraseapp-ruby.rb', line 1077 def unverify_translations_upon_delivery=(val) if val.is_a?(TrueClass) super(true) elsif val.is_a?(FalseClass) return else PhraseApp::ParamsHelpers::ParamsValidationError.new("invalid value #{val}") end end |
#validate ⇒ Object
1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 |
# File 'lib/phraseapp-ruby.rb', line 1087 def validate if category == nil || category == "" raise PhraseApp::ParamsHelpers::ParamsValidationError.new("Required parameter \"category\" of \"TranslationOrderParams\" not set") end if lsp == nil || lsp == "" raise PhraseApp::ParamsHelpers::ParamsValidationError.new("Required parameter \"lsp\" of \"TranslationOrderParams\" not set") end if source_locale_id == nil raise PhraseApp::ParamsHelpers::ParamsValidationError.new("Required parameter \"source_locale_id\" of \"TranslationOrderParams\" not set") end if target_locale_ids == nil raise PhraseApp::ParamsHelpers::ParamsValidationError.new("Required parameter \"target_locale_ids\" of \"TranslationOrderParams\" not set") end if translation_type == nil || translation_type == "" raise PhraseApp::ParamsHelpers::ParamsValidationError.new("Required parameter \"translation_type\" of \"TranslationOrderParams\" not set") end end |