Class: TeamBattlesSdk::Generated::Models::ApiObjective
- Inherits:
-
Object
- Object
- TeamBattlesSdk::Generated::Models::ApiObjective
- Includes:
- MicrosoftKiotaAbstractions::Parsable
- Defined in:
- lib/teambattles_sdk/generated/models/api_objective.rb
Overview
Server-safe objective DTO. UI icon components are intentionally omitted.
Class Method Summary collapse
-
.create_from_discriminator_value(parse_node) ⇒ Object
Creates a new instance of the appropriate class based on discriminator value.
Instance Method Summary collapse
-
#completion_rule ⇒ Object
Gets the completionRule property value.
-
#completion_rule=(value) ⇒ Object
Sets the completionRule property value.
-
#description_key ⇒ Object
Gets the descriptionKey property value.
-
#description_key=(value) ⇒ Object
Sets the descriptionKey property value.
-
#exp ⇒ Object
Gets the exp property value.
-
#exp=(value) ⇒ Object
Sets the exp property value.
-
#get_field_deserializers ⇒ Object
The deserialization information for the current model.
-
#id ⇒ Object
Gets the id property value.
-
#id=(value) ⇒ Object
Sets the id property value.
-
#scope ⇒ Object
Gets the scope property value.
-
#scope=(value) ⇒ Object
Sets the scope property value.
-
#serialize(writer) ⇒ Object
Serializes information the current object.
-
#title_key ⇒ Object
Gets the titleKey property value.
-
#title_key=(value) ⇒ Object
Sets the titleKey property value.
Class Method Details
.create_from_discriminator_value(parse_node) ⇒ Object
Creates a new instance of the appropriate class based on discriminator value
50 51 52 53 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 50 def self.create_from_discriminator_value(parse_node) raise StandardError, 'parse_node cannot be null' if parse_node.nil? return ApiObjective.new end |
Instance Method Details
#completion_rule ⇒ Object
Gets the completionRule property value. Machine-readable completion rule.
34 35 36 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 34 def completion_rule return @completion_rule end |
#completion_rule=(value) ⇒ Object
Sets the completionRule property value. Machine-readable completion rule.
42 43 44 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 42 def completion_rule=(value) @completion_rule = value end |
#description_key ⇒ Object
Gets the descriptionKey property value. i18n key for the objective description.
58 59 60 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 58 def description_key return @description_key end |
#description_key=(value) ⇒ Object
Sets the descriptionKey property value. i18n key for the objective description.
66 67 68 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 66 def description_key=(value) @description_key = value end |
#exp ⇒ Object
Gets the exp property value. Experience awarded by this objective.
73 74 75 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 73 def exp return @exp end |
#exp=(value) ⇒ Object
Sets the exp property value. Experience awarded by this objective.
81 82 83 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 81 def exp=(value) @exp = value end |
#get_field_deserializers ⇒ Object
The deserialization information for the current model
88 89 90 91 92 93 94 95 96 97 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 88 def get_field_deserializers() return { "completionRule" => lambda {|n| @completion_rule = n.get_string_value() }, "descriptionKey" => lambda {|n| @description_key = n.get_string_value() }, "exp" => lambda {|n| @exp = n.get_object_value(lambda {|pn| Double.create_from_discriminator_value(pn) }) }, "id" => lambda {|n| @id = n.get_string_value() }, "scope" => lambda {|n| @scope = n.get_string_value() }, "titleKey" => lambda {|n| @title_key = n.get_string_value() }, } end |
#id ⇒ Object
Gets the id property value. Objective definition ID.
102 103 104 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 102 def id return @id end |
#id=(value) ⇒ Object
Sets the id property value. Objective definition ID.
110 111 112 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 110 def id=(value) @id = value end |
#scope ⇒ Object
Gets the scope property value. Objective completion scope.
117 118 119 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 117 def scope return @scope end |
#scope=(value) ⇒ Object
Sets the scope property value. Objective completion scope.
125 126 127 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 125 def scope=(value) @scope = value end |
#serialize(writer) ⇒ Object
Serializes information the current object
133 134 135 136 137 138 139 140 141 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 133 def serialize(writer) raise StandardError, 'writer cannot be null' if writer.nil? writer.write_string_value("completionRule", @completion_rule) writer.write_string_value("descriptionKey", @description_key) writer.write_object_value("exp", @exp) writer.write_string_value("id", @id) writer.write_string_value("scope", @scope) writer.write_string_value("titleKey", @title_key) end |
#title_key ⇒ Object
Gets the titleKey property value. i18n key for the objective title.
146 147 148 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 146 def title_key return @title_key end |
#title_key=(value) ⇒ Object
Sets the titleKey property value. i18n key for the objective title.
154 155 156 |
# File 'lib/teambattles_sdk/generated/models/api_objective.rb', line 154 def title_key=(value) @title_key = value end |