Class: FtcEventsClient::ScoreDetailAllianceModel2021

Inherits:
Object
  • Object
show all
Defined in:
lib/ftc_events_client/models/score_detail_alliance_model_2021.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ ScoreDetailAllianceModel2021

Initializes the object

Parameters:

  • attributes (Hash) (defaults to: {})

    Model attributes in the form of hash



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
253
254
255
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
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 205

def initialize(attributes = {})
  if (!attributes.is_a?(Hash))
    fail ArgumentError, "The input argument (attributes) must be a hash in `FtcEventsClient::ScoreDetailAllianceModel2021` initialize method"
  end

  # check to see if the attribute exists and convert string to symbol for hash key
  attributes = attributes.each_with_object({}) { |(k, v), h|
    if (!self.class.attribute_map.key?(k.to_sym))
      fail ArgumentError, "`#{k}` is not a valid attribute in `FtcEventsClient::ScoreDetailAllianceModel2021`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
    end
    h[k.to_sym] = v
  }

  if attributes.key?(:'alliance')
    self.alliance = attributes[:'alliance']
  end

  if attributes.key?(:'barcode_element1')
    self.barcode_element1 = attributes[:'barcode_element1']
  end

  if attributes.key?(:'barcode_element2')
    self.barcode_element2 = attributes[:'barcode_element2']
  end

  if attributes.key?(:'carousel')
    self.carousel = attributes[:'carousel']
  end

  if attributes.key?(:'auto_navigated1')
    self.auto_navigated1 = attributes[:'auto_navigated1']
  end

  if attributes.key?(:'auto_navigated2')
    self.auto_navigated2 = attributes[:'auto_navigated2']
  end

  if attributes.key?(:'auto_bonus1')
    self.auto_bonus1 = attributes[:'auto_bonus1']
  end

  if attributes.key?(:'auto_bonus2')
    self.auto_bonus2 = attributes[:'auto_bonus2']
  end

  if attributes.key?(:'auto_storage_freight')
    self.auto_storage_freight = attributes[:'auto_storage_freight']
  end

  if attributes.key?(:'auto_freight1')
    self.auto_freight1 = attributes[:'auto_freight1']
  end

  if attributes.key?(:'auto_freight2')
    self.auto_freight2 = attributes[:'auto_freight2']
  end

  if attributes.key?(:'auto_freight3')
    self.auto_freight3 = attributes[:'auto_freight3']
  end

  if attributes.key?(:'driver_controlled_storage_freight')
    self.driver_controlled_storage_freight = attributes[:'driver_controlled_storage_freight']
  end

  if attributes.key?(:'driver_controlled_freight1')
    self.driver_controlled_freight1 = attributes[:'driver_controlled_freight1']
  end

  if attributes.key?(:'driver_controlled_freight2')
    self.driver_controlled_freight2 = attributes[:'driver_controlled_freight2']
  end

  if attributes.key?(:'driver_controlled_freight3')
    self.driver_controlled_freight3 = attributes[:'driver_controlled_freight3']
  end

  if attributes.key?(:'shared_freight')
    self.shared_freight = attributes[:'shared_freight']
  end

  if attributes.key?(:'endgame_delivered')
    self.endgame_delivered = attributes[:'endgame_delivered']
  end

  if attributes.key?(:'alliance_balanced')
    self.alliance_balanced = attributes[:'alliance_balanced']
  end

  if attributes.key?(:'shared_unbalanced')
    self.shared_unbalanced = attributes[:'shared_unbalanced']
  end

  if attributes.key?(:'endgame_parked1')
    self.endgame_parked1 = attributes[:'endgame_parked1']
  end

  if attributes.key?(:'endgame_parked2')
    self.endgame_parked2 = attributes[:'endgame_parked2']
  end

  if attributes.key?(:'capped')
    self.capped = attributes[:'capped']
  end

  if attributes.key?(:'minor_penalties')
    self.minor_penalties = attributes[:'minor_penalties']
  end

  if attributes.key?(:'major_penalties')
    self.major_penalties = attributes[:'major_penalties']
  end

  if attributes.key?(:'carousel_points')
    self.carousel_points = attributes[:'carousel_points']
  end

  if attributes.key?(:'auto_navigation_points')
    self.auto_navigation_points = attributes[:'auto_navigation_points']
  end

  if attributes.key?(:'auto_freight_points')
    self.auto_freight_points = attributes[:'auto_freight_points']
  end

  if attributes.key?(:'auto_bonus_points')
    self.auto_bonus_points = attributes[:'auto_bonus_points']
  end

  if attributes.key?(:'driver_controlled_alliance_hub_points')
    self.driver_controlled_alliance_hub_points = attributes[:'driver_controlled_alliance_hub_points']
  end

  if attributes.key?(:'driver_controlled_shared_hub_points')
    self.driver_controlled_shared_hub_points = attributes[:'driver_controlled_shared_hub_points']
  end

  if attributes.key?(:'driver_controlled_storage_points')
    self.driver_controlled_storage_points = attributes[:'driver_controlled_storage_points']
  end

  if attributes.key?(:'endgame_delivery_points')
    self.endgame_delivery_points = attributes[:'endgame_delivery_points']
  end

  if attributes.key?(:'alliance_balanced_points')
    self.alliance_balanced_points = attributes[:'alliance_balanced_points']
  end

  if attributes.key?(:'shared_unbalanced_points')
    self.shared_unbalanced_points = attributes[:'shared_unbalanced_points']
  end

  if attributes.key?(:'endgame_parking_points')
    self.endgame_parking_points = attributes[:'endgame_parking_points']
  end

  if attributes.key?(:'capping_points')
    self.capping_points = attributes[:'capping_points']
  end

  if attributes.key?(:'auto_points')
    self.auto_points = attributes[:'auto_points']
  end

  if attributes.key?(:'driver_controlled_points')
    self.driver_controlled_points = attributes[:'driver_controlled_points']
  end

  if attributes.key?(:'endgame_points')
    self.endgame_points = attributes[:'endgame_points']
  end

  if attributes.key?(:'penalty_points')
    self.penalty_points = attributes[:'penalty_points']
  end

  if attributes.key?(:'total_points')
    self.total_points = attributes[:'total_points']
  end
end

Instance Attribute Details

#allianceObject

Returns the value of attribute alliance.



16
17
18
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 16

def alliance
  @alliance
end

#alliance_balancedObject

Returns the value of attribute alliance_balanced.



52
53
54
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 52

def alliance_balanced
  @alliance_balanced
end

#alliance_balanced_pointsObject

Returns the value of attribute alliance_balanced_points.



82
83
84
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 82

def alliance_balanced_points
  @alliance_balanced_points
end

#auto_bonus1Object

Returns the value of attribute auto_bonus1.



28
29
30
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 28

def auto_bonus1
  @auto_bonus1
end

#auto_bonus2Object

Returns the value of attribute auto_bonus2.



30
31
32
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 30

def auto_bonus2
  @auto_bonus2
end

#auto_bonus_pointsObject

Returns the value of attribute auto_bonus_points.



72
73
74
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 72

def auto_bonus_points
  @auto_bonus_points
end

#auto_freight1Object

Returns the value of attribute auto_freight1.



34
35
36
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 34

def auto_freight1
  @auto_freight1
end

#auto_freight2Object

Returns the value of attribute auto_freight2.



36
37
38
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 36

def auto_freight2
  @auto_freight2
end

#auto_freight3Object

Returns the value of attribute auto_freight3.



38
39
40
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 38

def auto_freight3
  @auto_freight3
end

#auto_freight_pointsObject

Returns the value of attribute auto_freight_points.



70
71
72
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 70

def auto_freight_points
  @auto_freight_points
end

#auto_navigated1Object

Returns the value of attribute auto_navigated1.



24
25
26
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 24

def auto_navigated1
  @auto_navigated1
end

#auto_navigated2Object

Returns the value of attribute auto_navigated2.



26
27
28
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 26

def auto_navigated2
  @auto_navigated2
end

#auto_navigation_pointsObject

Returns the value of attribute auto_navigation_points.



68
69
70
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 68

def auto_navigation_points
  @auto_navigation_points
end

#auto_pointsObject

Returns the value of attribute auto_points.



90
91
92
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 90

def auto_points
  @auto_points
end

#auto_storage_freightObject

Returns the value of attribute auto_storage_freight.



32
33
34
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 32

def auto_storage_freight
  @auto_storage_freight
end

#barcode_element1Object

Returns the value of attribute barcode_element1.



18
19
20
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 18

def barcode_element1
  @barcode_element1
end

#barcode_element2Object

Returns the value of attribute barcode_element2.



20
21
22
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 20

def barcode_element2
  @barcode_element2
end

#cappedObject

Returns the value of attribute capped.



60
61
62
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 60

def capped
  @capped
end

#capping_pointsObject

Returns the value of attribute capping_points.



88
89
90
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 88

def capping_points
  @capping_points
end

Returns the value of attribute carousel.



22
23
24
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 22

def carousel
  @carousel
end

Returns the value of attribute carousel_points.



66
67
68
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 66

def carousel_points
  @carousel_points
end

#driver_controlled_alliance_hub_pointsObject

Returns the value of attribute driver_controlled_alliance_hub_points.



74
75
76
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 74

def driver_controlled_alliance_hub_points
  @driver_controlled_alliance_hub_points
end

#driver_controlled_freight1Object

Returns the value of attribute driver_controlled_freight1.



42
43
44
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 42

def driver_controlled_freight1
  @driver_controlled_freight1
end

#driver_controlled_freight2Object

Returns the value of attribute driver_controlled_freight2.



44
45
46
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 44

def driver_controlled_freight2
  @driver_controlled_freight2
end

#driver_controlled_freight3Object

Returns the value of attribute driver_controlled_freight3.



46
47
48
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 46

def driver_controlled_freight3
  @driver_controlled_freight3
end

#driver_controlled_pointsObject

Returns the value of attribute driver_controlled_points.



92
93
94
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 92

def driver_controlled_points
  @driver_controlled_points
end

#driver_controlled_shared_hub_pointsObject

Returns the value of attribute driver_controlled_shared_hub_points.



76
77
78
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 76

def driver_controlled_shared_hub_points
  @driver_controlled_shared_hub_points
end

#driver_controlled_storage_freightObject

Returns the value of attribute driver_controlled_storage_freight.



40
41
42
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 40

def driver_controlled_storage_freight
  @driver_controlled_storage_freight
end

#driver_controlled_storage_pointsObject

Returns the value of attribute driver_controlled_storage_points.



78
79
80
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 78

def driver_controlled_storage_points
  @driver_controlled_storage_points
end

#endgame_deliveredObject

Returns the value of attribute endgame_delivered.



50
51
52
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 50

def endgame_delivered
  @endgame_delivered
end

#endgame_delivery_pointsObject

Returns the value of attribute endgame_delivery_points.



80
81
82
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 80

def endgame_delivery_points
  @endgame_delivery_points
end

#endgame_parked1Object

Returns the value of attribute endgame_parked1.



56
57
58
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 56

def endgame_parked1
  @endgame_parked1
end

#endgame_parked2Object

Returns the value of attribute endgame_parked2.



58
59
60
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 58

def endgame_parked2
  @endgame_parked2
end

#endgame_parking_pointsObject

Returns the value of attribute endgame_parking_points.



86
87
88
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 86

def endgame_parking_points
  @endgame_parking_points
end

#endgame_pointsObject

Returns the value of attribute endgame_points.



94
95
96
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 94

def endgame_points
  @endgame_points
end

#major_penaltiesObject

Returns the value of attribute major_penalties.



64
65
66
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 64

def major_penalties
  @major_penalties
end

#minor_penaltiesObject

Returns the value of attribute minor_penalties.



62
63
64
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 62

def minor_penalties
  @minor_penalties
end

#penalty_pointsObject

Returns the value of attribute penalty_points.



96
97
98
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 96

def penalty_points
  @penalty_points
end

#shared_freightObject

Returns the value of attribute shared_freight.



48
49
50
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 48

def shared_freight
  @shared_freight
end

#shared_unbalancedObject

Returns the value of attribute shared_unbalanced.



54
55
56
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 54

def shared_unbalanced
  @shared_unbalanced
end

#shared_unbalanced_pointsObject

Returns the value of attribute shared_unbalanced_points.



84
85
86
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 84

def shared_unbalanced_points
  @shared_unbalanced_points
end

#total_pointsObject

Returns the value of attribute total_points.



98
99
100
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 98

def total_points
  @total_points
end

Class Method Details

.attribute_mapObject

Attribute mapping from ruby-style variable name to JSON key.



101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 101

def self.attribute_map
  {
    :'alliance' => :'alliance',
    :'barcode_element1' => :'barcodeElement1',
    :'barcode_element2' => :'barcodeElement2',
    :'carousel' => :'carousel',
    :'auto_navigated1' => :'autoNavigated1',
    :'auto_navigated2' => :'autoNavigated2',
    :'auto_bonus1' => :'autoBonus1',
    :'auto_bonus2' => :'autoBonus2',
    :'auto_storage_freight' => :'autoStorageFreight',
    :'auto_freight1' => :'autoFreight1',
    :'auto_freight2' => :'autoFreight2',
    :'auto_freight3' => :'autoFreight3',
    :'driver_controlled_storage_freight' => :'driverControlledStorageFreight',
    :'driver_controlled_freight1' => :'driverControlledFreight1',
    :'driver_controlled_freight2' => :'driverControlledFreight2',
    :'driver_controlled_freight3' => :'driverControlledFreight3',
    :'shared_freight' => :'sharedFreight',
    :'endgame_delivered' => :'endgameDelivered',
    :'alliance_balanced' => :'allianceBalanced',
    :'shared_unbalanced' => :'sharedUnbalanced',
    :'endgame_parked1' => :'endgameParked1',
    :'endgame_parked2' => :'endgameParked2',
    :'capped' => :'capped',
    :'minor_penalties' => :'minorPenalties',
    :'major_penalties' => :'majorPenalties',
    :'carousel_points' => :'carouselPoints',
    :'auto_navigation_points' => :'autoNavigationPoints',
    :'auto_freight_points' => :'autoFreightPoints',
    :'auto_bonus_points' => :'autoBonusPoints',
    :'driver_controlled_alliance_hub_points' => :'driverControlledAllianceHubPoints',
    :'driver_controlled_shared_hub_points' => :'driverControlledSharedHubPoints',
    :'driver_controlled_storage_points' => :'driverControlledStoragePoints',
    :'endgame_delivery_points' => :'endgameDeliveryPoints',
    :'alliance_balanced_points' => :'allianceBalancedPoints',
    :'shared_unbalanced_points' => :'sharedUnbalancedPoints',
    :'endgame_parking_points' => :'endgameParkingPoints',
    :'capping_points' => :'cappingPoints',
    :'auto_points' => :'autoPoints',
    :'driver_controlled_points' => :'driverControlledPoints',
    :'endgame_points' => :'endgamePoints',
    :'penalty_points' => :'penaltyPoints',
    :'total_points' => :'totalPoints'
  }
end

.build_from_hash(attributes) ⇒ Object

Builds the object from hash

Parameters:

  • attributes (Hash)

    Model attributes in the form of hash

Returns:

  • (Object)

    Returns the model itself



464
465
466
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 464

def self.build_from_hash(attributes)
  new.build_from_hash(attributes)
end

.openapi_nullableObject

List of attributes with nullable: true



197
198
199
200
201
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 197

def self.openapi_nullable
  Set.new([
    :'alliance',
  ])
end

.openapi_typesObject

Attribute type mapping.



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
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 149

def self.openapi_types
  {
    :'alliance' => :'Object',
    :'barcode_element1' => :'Object',
    :'barcode_element2' => :'Object',
    :'carousel' => :'Object',
    :'auto_navigated1' => :'Object',
    :'auto_navigated2' => :'Object',
    :'auto_bonus1' => :'Object',
    :'auto_bonus2' => :'Object',
    :'auto_storage_freight' => :'Object',
    :'auto_freight1' => :'Object',
    :'auto_freight2' => :'Object',
    :'auto_freight3' => :'Object',
    :'driver_controlled_storage_freight' => :'Object',
    :'driver_controlled_freight1' => :'Object',
    :'driver_controlled_freight2' => :'Object',
    :'driver_controlled_freight3' => :'Object',
    :'shared_freight' => :'Object',
    :'endgame_delivered' => :'Object',
    :'alliance_balanced' => :'Object',
    :'shared_unbalanced' => :'Object',
    :'endgame_parked1' => :'Object',
    :'endgame_parked2' => :'Object',
    :'capped' => :'Object',
    :'minor_penalties' => :'Object',
    :'major_penalties' => :'Object',
    :'carousel_points' => :'Object',
    :'auto_navigation_points' => :'Object',
    :'auto_freight_points' => :'Object',
    :'auto_bonus_points' => :'Object',
    :'driver_controlled_alliance_hub_points' => :'Object',
    :'driver_controlled_shared_hub_points' => :'Object',
    :'driver_controlled_storage_points' => :'Object',
    :'endgame_delivery_points' => :'Object',
    :'alliance_balanced_points' => :'Object',
    :'shared_unbalanced_points' => :'Object',
    :'endgame_parking_points' => :'Object',
    :'capping_points' => :'Object',
    :'auto_points' => :'Object',
    :'driver_controlled_points' => :'Object',
    :'endgame_points' => :'Object',
    :'penalty_points' => :'Object',
    :'total_points' => :'Object'
  }
end

Instance Method Details

#==(o) ⇒ Object

Checks equality by comparing each attribute.

Parameters:

  • Object (Object)

    to be compared



402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 402

def ==(o)
  return true if self.equal?(o)
  self.class == o.class &&
      alliance == o.alliance &&
      barcode_element1 == o.barcode_element1 &&
      barcode_element2 == o.barcode_element2 &&
      carousel == o.carousel &&
      auto_navigated1 == o.auto_navigated1 &&
      auto_navigated2 == o.auto_navigated2 &&
      auto_bonus1 == o.auto_bonus1 &&
      auto_bonus2 == o.auto_bonus2 &&
      auto_storage_freight == o.auto_storage_freight &&
      auto_freight1 == o.auto_freight1 &&
      auto_freight2 == o.auto_freight2 &&
      auto_freight3 == o.auto_freight3 &&
      driver_controlled_storage_freight == o.driver_controlled_storage_freight &&
      driver_controlled_freight1 == o.driver_controlled_freight1 &&
      driver_controlled_freight2 == o.driver_controlled_freight2 &&
      driver_controlled_freight3 == o.driver_controlled_freight3 &&
      shared_freight == o.shared_freight &&
      endgame_delivered == o.endgame_delivered &&
      alliance_balanced == o.alliance_balanced &&
      shared_unbalanced == o.shared_unbalanced &&
      endgame_parked1 == o.endgame_parked1 &&
      endgame_parked2 == o.endgame_parked2 &&
      capped == o.capped &&
      minor_penalties == o.minor_penalties &&
      major_penalties == o.major_penalties &&
      carousel_points == o.carousel_points &&
      auto_navigation_points == o.auto_navigation_points &&
      auto_freight_points == o.auto_freight_points &&
      auto_bonus_points == o.auto_bonus_points &&
      driver_controlled_alliance_hub_points == o.driver_controlled_alliance_hub_points &&
      driver_controlled_shared_hub_points == o.driver_controlled_shared_hub_points &&
      driver_controlled_storage_points == o.driver_controlled_storage_points &&
      endgame_delivery_points == o.endgame_delivery_points &&
      alliance_balanced_points == o.alliance_balanced_points &&
      shared_unbalanced_points == o.shared_unbalanced_points &&
      endgame_parking_points == o.endgame_parking_points &&
      capping_points == o.capping_points &&
      auto_points == o.auto_points &&
      driver_controlled_points == o.driver_controlled_points &&
      endgame_points == o.endgame_points &&
      penalty_points == o.penalty_points &&
      total_points == o.total_points
end

#_deserialize(type, value) ⇒ Object

Deserializes the data based on type

Parameters:

  • string

    type Data type

  • string

    value Value to be deserialized

Returns:

  • (Object)

    Deserialized data



494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 494

def _deserialize(type, value)
  case type.to_sym
  when :DateTime
    DateTime.parse(value)
  when :Date
    Date.parse(value)
  when :String
    value.to_s
  when :Integer
    value.to_i
  when :Float
    value.to_f
  when :Boolean
    if value.to_s =~ /\A(true|t|yes|y|1)\z/i
      true
    else
      false
    end
  when :Object
    # generic object (usually a Hash), return directly
    value
  when /\AArray<(?<inner_type>.+)>\z/
    inner_type = Regexp.last_match[:inner_type]
    value.map { |v| _deserialize(inner_type, v) }
  when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
    k_type = Regexp.last_match[:k_type]
    v_type = Regexp.last_match[:v_type]
    {}.tap do |hash|
      value.each do |k, v|
        hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
      end
    end
  else # model
    FtcEventsClient.const_get(type).build_from_hash(value)
  end
end

#_to_hash(value) ⇒ Hash

Outputs non-array value in the form of hash For object, use to_hash. Otherwise, just return the value

Parameters:

  • value (Object)

    Any valid value

Returns:

  • (Hash)

    Returns the value in the form of hash



563
564
565
566
567
568
569
570
571
572
573
574
575
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 563

def _to_hash(value)
  if value.is_a?(Array)
    value.compact.map { |v| _to_hash(v) }
  elsif value.is_a?(Hash)
    {}.tap do |hash|
      value.each { |k, v| hash[k] = _to_hash(v) }
    end
  elsif value.respond_to? :to_hash
    value.to_hash
  else
    value
  end
end

#build_from_hash(attributes) ⇒ Object

Builds the object from hash

Parameters:

  • attributes (Hash)

    Model attributes in the form of hash

Returns:

  • (Object)

    Returns the model itself



471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 471

def build_from_hash(attributes)
  return nil unless attributes.is_a?(Hash)
  self.class.openapi_types.each_pair do |key, type|
    if 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[self.class.attribute_map[key]].is_a?(Array)
        self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
      end
    elsif !attributes[self.class.attribute_map[key]].nil?
      self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
    elsif attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
      self.send("#{key}=", nil)
    end
  end

  self
end

#eql?(o) ⇒ Boolean

Parameters:

  • Object (Object)

    to be compared

Returns:

  • (Boolean)

See Also:

  • `==` method


451
452
453
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 451

def eql?(o)
  self == o
end

#hashInteger

Calculates hash code according to all attributes.

Returns:

  • (Integer)

    Hash code



457
458
459
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 457

def hash
  [alliance, barcode_element1, barcode_element2, carousel, auto_navigated1, auto_navigated2, auto_bonus1, auto_bonus2, auto_storage_freight, auto_freight1, auto_freight2, auto_freight3, driver_controlled_storage_freight, driver_controlled_freight1, driver_controlled_freight2, driver_controlled_freight3, shared_freight, endgame_delivered, alliance_balanced, shared_unbalanced, endgame_parked1, endgame_parked2, capped, minor_penalties, major_penalties, carousel_points, auto_navigation_points, auto_freight_points, auto_bonus_points, driver_controlled_alliance_hub_points, driver_controlled_shared_hub_points, driver_controlled_storage_points, endgame_delivery_points, alliance_balanced_points, shared_unbalanced_points, endgame_parking_points, capping_points, auto_points, driver_controlled_points, endgame_points, penalty_points, total_points].hash
end

#list_invalid_propertiesObject

Show invalid properties with the reasons. Usually used together with valid?

Returns:

  • Array for valid properties with the reasons



389
390
391
392
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 389

def list_invalid_properties
  invalid_properties = Array.new
  invalid_properties
end

#to_bodyHash

to_body is an alias to to_hash (backward compatibility)

Returns:

  • (Hash)

    Returns the object in the form of hash



539
540
541
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 539

def to_body
  to_hash
end

#to_hashHash

Returns the object in the form of hash

Returns:

  • (Hash)

    Returns the object in the form of hash



545
546
547
548
549
550
551
552
553
554
555
556
557
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 545

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

#to_sString

Returns the string representation of the object

Returns:

  • (String)

    String presentation of the object



533
534
535
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 533

def to_s
  to_hash.to_s
end

#valid?Boolean

Check to see if the all the properties in the model are valid

Returns:

  • (Boolean)

    true if the model is valid



396
397
398
# File 'lib/ftc_events_client/models/score_detail_alliance_model_2021.rb', line 396

def valid?
  true
end