Class: FtcApiV3Client::ApiV3FFPointsDetail
- Inherits:
-
ApiModelBase
- Object
- ApiModelBase
- FtcApiV3Client::ApiV3FFPointsDetail
- Defined in:
- lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb
Instance Attribute Summary collapse
-
#adjust_points ⇒ Object
Used to indicate the winner in double-red-card playoff matches.
-
#auto_bonus_points ⇒ Object
Returns the value of attribute auto_bonus_points.
-
#auto_freight_points ⇒ Object
Returns the value of attribute auto_freight_points.
-
#auto_points ⇒ Object
Returns the value of attribute auto_points.
-
#balanced_points ⇒ Object
Returns the value of attribute balanced_points.
-
#capping_points ⇒ Object
Returns the value of attribute capping_points.
-
#carousel_points ⇒ Object
Returns the value of attribute carousel_points.
-
#dc_hub_points ⇒ Object
Returns the value of attribute dc_hub_points.
-
#dc_points ⇒ Object
Returns the value of attribute dc_points.
-
#dc_shared_points ⇒ Object
Returns the value of attribute dc_shared_points.
-
#dc_storage_points ⇒ Object
Returns the value of attribute dc_storage_points.
-
#eg_delivery_points ⇒ Object
Returns the value of attribute eg_delivery_points.
-
#endgame_points ⇒ Object
Returns the value of attribute endgame_points.
-
#navigation_points ⇒ Object
Returns the value of attribute navigation_points.
-
#parking_points ⇒ Object
Returns the value of attribute parking_points.
-
#penalty_points ⇒ Object
Returns the value of attribute penalty_points.
-
#scored_points ⇒ Object
Returns the value of attribute scored_points.
-
#tipped_points ⇒ Object
Returns the value of attribute tipped_points.
-
#total_points ⇒ Object
Returns the value of attribute total_points.
Class Method Summary collapse
-
.acceptable_attribute_map ⇒ Object
Returns attribute mapping this model knows about.
-
.acceptable_attributes ⇒ Object
Returns all the JSON keys this model knows about.
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.build_from_hash(attributes) ⇒ Object
Builds the object from hash.
-
.openapi_nullable ⇒ Object
List of attributes with nullable: true.
-
.openapi_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(o) ⇒ Object
Checks equality by comparing each attribute.
- #eql?(o) ⇒ Boolean
-
#hash ⇒ Integer
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ ApiV3FFPointsDetail
constructor
Initializes the object.
-
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons.
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid.
Methods inherited from ApiModelBase
_deserialize, #_to_hash, #to_body, #to_s
Constructor Details
#initialize(attributes = {}) ⇒ ApiV3FFPointsDetail
Initializes the object
125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 125 def initialize(attributes = {}) if (!attributes.is_a?(Hash)) fail ArgumentError, "The input argument (attributes) must be a hash in `FtcApiV3Client::ApiV3FFPointsDetail` initialize method" end # check to see if the attribute exists and convert string to symbol for hash key acceptable_attribute_map = self.class.acceptable_attribute_map attributes = attributes.each_with_object({}) { |(k, v), h| if (!acceptable_attribute_map.key?(k.to_sym)) fail ArgumentError, "`#{k}` is not a valid attribute in `FtcApiV3Client::ApiV3FFPointsDetail`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect end h[k.to_sym] = v } if attributes.key?(:'carousel_points') self.carousel_points = attributes[:'carousel_points'] else self.carousel_points = nil end if attributes.key?(:'navigation_points') self. = attributes[:'navigation_points'] else self. = nil end if attributes.key?(:'auto_freight_points') self.auto_freight_points = attributes[:'auto_freight_points'] else self.auto_freight_points = nil end if attributes.key?(:'auto_bonus_points') self.auto_bonus_points = attributes[:'auto_bonus_points'] else self.auto_bonus_points = nil end if attributes.key?(:'dc_hub_points') self.dc_hub_points = attributes[:'dc_hub_points'] else self.dc_hub_points = nil end if attributes.key?(:'dc_shared_points') self.dc_shared_points = attributes[:'dc_shared_points'] else self.dc_shared_points = nil end if attributes.key?(:'dc_storage_points') self.dc_storage_points = attributes[:'dc_storage_points'] else self.dc_storage_points = nil end if attributes.key?(:'eg_delivery_points') self.eg_delivery_points = attributes[:'eg_delivery_points'] else self.eg_delivery_points = nil end if attributes.key?(:'balanced_points') self.balanced_points = attributes[:'balanced_points'] else self.balanced_points = nil end if attributes.key?(:'tipped_points') self.tipped_points = attributes[:'tipped_points'] else self.tipped_points = nil end if attributes.key?(:'parking_points') self.parking_points = attributes[:'parking_points'] else self.parking_points = nil end if attributes.key?(:'capping_points') self.capping_points = attributes[:'capping_points'] else self.capping_points = nil end if attributes.key?(:'auto_points') self.auto_points = attributes[:'auto_points'] else self.auto_points = nil end if attributes.key?(:'dc_points') self.dc_points = attributes[:'dc_points'] else self.dc_points = nil end if attributes.key?(:'endgame_points') self.endgame_points = attributes[:'endgame_points'] else self.endgame_points = nil end if attributes.key?(:'penalty_points') self.penalty_points = attributes[:'penalty_points'] else self.penalty_points = nil end if attributes.key?(:'scored_points') self.scored_points = attributes[:'scored_points'] else self.scored_points = nil end if attributes.key?(:'total_points') self.total_points = attributes[:'total_points'] else self.total_points = nil end if attributes.key?(:'adjust_points') self.adjust_points = attributes[:'adjust_points'] else self.adjust_points = nil end end |
Instance Attribute Details
#adjust_points ⇒ Object
Used to indicate the winner in double-red-card playoff matches
55 56 57 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 55 def adjust_points @adjust_points end |
#auto_bonus_points ⇒ Object
Returns the value of attribute auto_bonus_points.
24 25 26 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 24 def auto_bonus_points @auto_bonus_points end |
#auto_freight_points ⇒ Object
Returns the value of attribute auto_freight_points.
22 23 24 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 22 def auto_freight_points @auto_freight_points end |
#auto_points ⇒ Object
Returns the value of attribute auto_points.
42 43 44 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 42 def auto_points @auto_points end |
#balanced_points ⇒ Object
Returns the value of attribute balanced_points.
34 35 36 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 34 def balanced_points @balanced_points end |
#capping_points ⇒ Object
Returns the value of attribute capping_points.
40 41 42 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 40 def capping_points @capping_points end |
#carousel_points ⇒ Object
Returns the value of attribute carousel_points.
18 19 20 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 18 def carousel_points @carousel_points end |
#dc_hub_points ⇒ Object
Returns the value of attribute dc_hub_points.
26 27 28 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 26 def dc_hub_points @dc_hub_points end |
#dc_points ⇒ Object
Returns the value of attribute dc_points.
44 45 46 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 44 def dc_points @dc_points end |
#dc_shared_points ⇒ Object
Returns the value of attribute dc_shared_points.
28 29 30 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 28 def dc_shared_points @dc_shared_points end |
#dc_storage_points ⇒ Object
Returns the value of attribute dc_storage_points.
30 31 32 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 30 def dc_storage_points @dc_storage_points end |
#eg_delivery_points ⇒ Object
Returns the value of attribute eg_delivery_points.
32 33 34 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 32 def eg_delivery_points @eg_delivery_points end |
#endgame_points ⇒ Object
Returns the value of attribute endgame_points.
46 47 48 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 46 def endgame_points @endgame_points end |
#navigation_points ⇒ Object
Returns the value of attribute navigation_points.
20 21 22 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 20 def @navigation_points end |
#parking_points ⇒ Object
Returns the value of attribute parking_points.
38 39 40 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 38 def parking_points @parking_points end |
#penalty_points ⇒ Object
Returns the value of attribute penalty_points.
48 49 50 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 48 def penalty_points @penalty_points end |
#scored_points ⇒ Object
Returns the value of attribute scored_points.
50 51 52 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 50 def scored_points @scored_points end |
#tipped_points ⇒ Object
Returns the value of attribute tipped_points.
36 37 38 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 36 def tipped_points @tipped_points end |
#total_points ⇒ Object
Returns the value of attribute total_points.
52 53 54 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 52 def total_points @total_points end |
Class Method Details
.acceptable_attribute_map ⇒ Object
Returns attribute mapping this model knows about
83 84 85 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 83 def self.acceptable_attribute_map attribute_map end |
.acceptable_attributes ⇒ Object
Returns all the JSON keys this model knows about
88 89 90 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 88 def self.acceptable_attributes acceptable_attribute_map.values end |
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 58 def self.attribute_map { :'carousel_points' => :'carouselPoints', :'navigation_points' => :'navigationPoints', :'auto_freight_points' => :'autoFreightPoints', :'auto_bonus_points' => :'autoBonusPoints', :'dc_hub_points' => :'dcHubPoints', :'dc_shared_points' => :'dcSharedPoints', :'dc_storage_points' => :'dcStoragePoints', :'eg_delivery_points' => :'egDeliveryPoints', :'balanced_points' => :'balancedPoints', :'tipped_points' => :'tippedPoints', :'parking_points' => :'parkingPoints', :'capping_points' => :'cappingPoints', :'auto_points' => :'autoPoints', :'dc_points' => :'dcPoints', :'endgame_points' => :'endgamePoints', :'penalty_points' => :'penaltyPoints', :'scored_points' => :'scoredPoints', :'total_points' => :'totalPoints', :'adjust_points' => :'adjustPoints' } end |
.build_from_hash(attributes) ⇒ Object
Builds the object from hash
595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 595 def self.build_from_hash(attributes) return nil unless attributes.is_a?(Hash) attributes = attributes.transform_keys(&:to_sym) transformed_hash = {} openapi_types.each_pair do |key, type| if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil? transformed_hash["#{key}"] = nil elsif type =~ /\AArray<(.*)>/i # check to ensure the input is an array given that the attribute # is documented as an array but the input is not if attributes[attribute_map[key]].is_a?(Array) transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) } end elsif !attributes[attribute_map[key]].nil? transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]]) end end new(transformed_hash) end |
.openapi_nullable ⇒ Object
List of attributes with nullable: true
118 119 120 121 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 118 def self.openapi_nullable Set.new([ ]) end |
.openapi_types ⇒ Object
Attribute type mapping.
93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 93 def self.openapi_types { :'carousel_points' => :'Integer', :'navigation_points' => :'Integer', :'auto_freight_points' => :'Integer', :'auto_bonus_points' => :'Integer', :'dc_hub_points' => :'Integer', :'dc_shared_points' => :'Integer', :'dc_storage_points' => :'Integer', :'eg_delivery_points' => :'Integer', :'balanced_points' => :'Integer', :'tipped_points' => :'Integer', :'parking_points' => :'Integer', :'capping_points' => :'Integer', :'auto_points' => :'Integer', :'dc_points' => :'Integer', :'endgame_points' => :'Integer', :'penalty_points' => :'Integer', :'scored_points' => :'Integer', :'total_points' => :'Integer', :'adjust_points' => :'Integer' } end |
Instance Method Details
#==(o) ⇒ Object
Checks equality by comparing each attribute.
556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 556 def ==(o) return true if self.equal?(o) self.class == o.class && carousel_points == o.carousel_points && == o. && auto_freight_points == o.auto_freight_points && auto_bonus_points == o.auto_bonus_points && dc_hub_points == o.dc_hub_points && dc_shared_points == o.dc_shared_points && dc_storage_points == o.dc_storage_points && eg_delivery_points == o.eg_delivery_points && balanced_points == o.balanced_points && tipped_points == o.tipped_points && parking_points == o.parking_points && capping_points == o.capping_points && auto_points == o.auto_points && dc_points == o.dc_points && endgame_points == o.endgame_points && penalty_points == o.penalty_points && scored_points == o.scored_points && total_points == o.total_points && adjust_points == o.adjust_points end |
#eql?(o) ⇒ Boolean
582 583 584 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 582 def eql?(o) self == o end |
#hash ⇒ Integer
Calculates hash code according to all attributes.
588 589 590 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 588 def hash [carousel_points, , auto_freight_points, auto_bonus_points, dc_hub_points, dc_shared_points, dc_storage_points, eg_delivery_points, balanced_points, tipped_points, parking_points, capping_points, auto_points, dc_points, endgame_points, penalty_points, scored_points, total_points, adjust_points].hash end |
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons. Usually used together with valid?
256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 256 def list_invalid_properties warn '[DEPRECATED] the `list_invalid_properties` method is obsolete' invalid_properties = Array.new if @carousel_points.nil? invalid_properties.push('invalid value for "carousel_points", carousel_points cannot be nil.') end if @navigation_points.nil? invalid_properties.push('invalid value for "navigation_points", navigation_points cannot be nil.') end if @auto_freight_points.nil? invalid_properties.push('invalid value for "auto_freight_points", auto_freight_points cannot be nil.') end if @auto_bonus_points.nil? invalid_properties.push('invalid value for "auto_bonus_points", auto_bonus_points cannot be nil.') end if @dc_hub_points.nil? invalid_properties.push('invalid value for "dc_hub_points", dc_hub_points cannot be nil.') end if @dc_shared_points.nil? invalid_properties.push('invalid value for "dc_shared_points", dc_shared_points cannot be nil.') end if @dc_storage_points.nil? invalid_properties.push('invalid value for "dc_storage_points", dc_storage_points cannot be nil.') end if @eg_delivery_points.nil? invalid_properties.push('invalid value for "eg_delivery_points", eg_delivery_points cannot be nil.') end if @balanced_points.nil? invalid_properties.push('invalid value for "balanced_points", balanced_points cannot be nil.') end if @tipped_points.nil? invalid_properties.push('invalid value for "tipped_points", tipped_points cannot be nil.') end if @parking_points.nil? invalid_properties.push('invalid value for "parking_points", parking_points cannot be nil.') end if @capping_points.nil? invalid_properties.push('invalid value for "capping_points", capping_points cannot be nil.') end if @auto_points.nil? invalid_properties.push('invalid value for "auto_points", auto_points cannot be nil.') end if @dc_points.nil? invalid_properties.push('invalid value for "dc_points", dc_points cannot be nil.') end if @endgame_points.nil? invalid_properties.push('invalid value for "endgame_points", endgame_points cannot be nil.') end if @penalty_points.nil? invalid_properties.push('invalid value for "penalty_points", penalty_points cannot be nil.') end if @scored_points.nil? invalid_properties.push('invalid value for "scored_points", scored_points cannot be nil.') end if @total_points.nil? invalid_properties.push('invalid value for "total_points", total_points cannot be nil.') end if @adjust_points.nil? invalid_properties.push('invalid value for "adjust_points", adjust_points cannot be nil.') end invalid_properties end |
#to_hash ⇒ Hash
Returns the object in the form of hash
617 618 619 620 621 622 623 624 625 626 627 628 629 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 617 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = self.send(attr) if value.nil? is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end hash[param] = _to_hash(value) end hash end |
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid
340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 |
# File 'lib/ftc_api_v3_client/models/api_v3_ff_points_detail.rb', line 340 def valid? warn '[DEPRECATED] the `valid?` method is obsolete' return false if @carousel_points.nil? return false if @navigation_points.nil? return false if @auto_freight_points.nil? return false if @auto_bonus_points.nil? return false if @dc_hub_points.nil? return false if @dc_shared_points.nil? return false if @dc_storage_points.nil? return false if @eg_delivery_points.nil? return false if @balanced_points.nil? return false if @tipped_points.nil? return false if @parking_points.nil? return false if @capping_points.nil? return false if @auto_points.nil? return false if @dc_points.nil? return false if @endgame_points.nil? return false if @penalty_points.nil? return false if @scored_points.nil? return false if @total_points.nil? return false if @adjust_points.nil? true end |