Class: PhraseApp::RequestParams::TranslationUpdateParams
- Inherits:
-
OpenStruct
- Object
- OpenStruct
- PhraseApp::RequestParams::TranslationUpdateParams
- Defined in:
- lib/phraseapp-ruby.rb
Overview
TranslationUpdateParams
Parameters:
- branch
specify the branch to use
- content
Translation content
- excluded
Indicates whether translation is excluded.
- plural_suffix
Plural suffix. Can be one of: zero, one, two, few, many, other. Must be specified if the key associated to the translation is pluralized.
- unverified
Indicates whether translation is unverified. Part of the Advanced Workflows feature.
Instance Method Summary collapse
- #branch=(val) ⇒ Object
- #content=(val) ⇒ Object
- #excluded=(val) ⇒ Object
- #plural_suffix=(val) ⇒ Object
- #unverified=(val) ⇒ Object
- #validate ⇒ Object
Instance Method Details
#branch=(val) ⇒ Object
3048 3049 3050 |
# File 'lib/phraseapp-ruby.rb', line 3048 def branch=(val) super(val) end |
#content=(val) ⇒ Object
3052 3053 3054 |
# File 'lib/phraseapp-ruby.rb', line 3052 def content=(val) super(val) end |
#excluded=(val) ⇒ Object
3056 3057 3058 3059 3060 3061 3062 3063 3064 |
# File 'lib/phraseapp-ruby.rb', line 3056 def excluded=(val) if val.is_a?(TrueClass) super(true) elsif val.is_a?(FalseClass) return else PhraseApp::ParamsHelpers::ParamsValidationError.new("invalid value #{val}") end end |
#plural_suffix=(val) ⇒ Object
3066 3067 3068 |
# File 'lib/phraseapp-ruby.rb', line 3066 def plural_suffix=(val) super(val) end |
#unverified=(val) ⇒ Object
3070 3071 3072 3073 3074 3075 3076 3077 3078 |
# File 'lib/phraseapp-ruby.rb', line 3070 def unverified=(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
3080 3081 3082 3083 3084 3085 |
# File 'lib/phraseapp-ruby.rb', line 3080 def validate if content == nil || content == "" raise PhraseApp::ParamsHelpers::ParamsValidationError.new("Required parameter \"content\" of \"translation_updateParams\" not set") end end |