Class: CloudsmithApi::VagrantPackageUpload

Inherits:
Object
  • Object
show all
Defined in:
lib/cloudsmith-api/models/vagrant_package_upload.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ VagrantPackageUpload

Initializes the object

Parameters:

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

    Model attributes in the form of hash



366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
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
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
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
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 366

def initialize(attributes = {})
  return unless attributes.is_a?(Hash)

  # convert string to symbol for hash key
  attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }

  if attributes.has_key?(:'architectures')
    if (value = attributes[:'architectures']).is_a?(Array)
      self.architectures = value
    end
  end

  if attributes.has_key?(:'cdn_url')
    self.cdn_url = attributes[:'cdn_url']
  end

  if attributes.has_key?(:'checksum_md5')
    self.checksum_md5 = attributes[:'checksum_md5']
  end

  if attributes.has_key?(:'checksum_sha1')
    self.checksum_sha1 = attributes[:'checksum_sha1']
  end

  if attributes.has_key?(:'checksum_sha256')
    self.checksum_sha256 = attributes[:'checksum_sha256']
  end

  if attributes.has_key?(:'checksum_sha512')
    self.checksum_sha512 = attributes[:'checksum_sha512']
  end

  if attributes.has_key?(:'dependencies_checksum_md5')
    self.dependencies_checksum_md5 = attributes[:'dependencies_checksum_md5']
  end

  if attributes.has_key?(:'dependencies_url')
    self.dependencies_url = attributes[:'dependencies_url']
  end

  if attributes.has_key?(:'description')
    self.description = attributes[:'description']
  end

  if attributes.has_key?(:'distro')
    self.distro = attributes[:'distro']
  end

  if attributes.has_key?(:'distro_version')
    self.distro_version = attributes[:'distro_version']
  end

  if attributes.has_key?(:'downloads')
    self.downloads = attributes[:'downloads']
  end

  if attributes.has_key?(:'epoch')
    self.epoch = attributes[:'epoch']
  end

  if attributes.has_key?(:'extension')
    self.extension = attributes[:'extension']
  end

  if attributes.has_key?(:'filename')
    self.filename = attributes[:'filename']
  end

  if attributes.has_key?(:'files')
    if (value = attributes[:'files']).is_a?(Array)
      self.files = value
    end
  end

  if attributes.has_key?(:'format')
    self.format = attributes[:'format']
  end

  if attributes.has_key?(:'format_url')
    self.format_url = attributes[:'format_url']
  end

  if attributes.has_key?(:'identifier_perm')
    self.identifier_perm = attributes[:'identifier_perm']
  end

  if attributes.has_key?(:'indexed')
    self.indexed = attributes[:'indexed']
  end

  if attributes.has_key?(:'is_downloadable')
    self.is_downloadable = attributes[:'is_downloadable']
  end

  if attributes.has_key?(:'is_quarantined')
    self.is_quarantined = attributes[:'is_quarantined']
  end

  if attributes.has_key?(:'is_sync_awaiting')
    self.is_sync_awaiting = attributes[:'is_sync_awaiting']
  end

  if attributes.has_key?(:'is_sync_completed')
    self.is_sync_completed = attributes[:'is_sync_completed']
  end

  if attributes.has_key?(:'is_sync_failed')
    self.is_sync_failed = attributes[:'is_sync_failed']
  end

  if attributes.has_key?(:'is_sync_in_flight')
    self.is_sync_in_flight = attributes[:'is_sync_in_flight']
  end

  if attributes.has_key?(:'is_sync_in_progress')
    self.is_sync_in_progress = attributes[:'is_sync_in_progress']
  end

  if attributes.has_key?(:'license')
    self.license = attributes[:'license']
  end

  if attributes.has_key?(:'name')
    self.name = attributes[:'name']
  end

  if attributes.has_key?(:'namespace')
    self.namespace = attributes[:'namespace']
  end

  if attributes.has_key?(:'namespace_url')
    self.namespace_url = attributes[:'namespace_url']
  end

  if attributes.has_key?(:'num_files')
    self.num_files = attributes[:'num_files']
  end

  if attributes.has_key?(:'package_type')
    self.package_type = attributes[:'package_type']
  end

  if attributes.has_key?(:'provider')
    self.provider = attributes[:'provider']
  end

  if attributes.has_key?(:'release')
    self.release = attributes[:'release']
  end

  if attributes.has_key?(:'repository')
    self.repository = attributes[:'repository']
  end

  if attributes.has_key?(:'repository_url')
    self.repository_url = attributes[:'repository_url']
  end

  if attributes.has_key?(:'security_scan_completed_at')
    self.security_scan_completed_at = attributes[:'security_scan_completed_at']
  end

  if attributes.has_key?(:'security_scan_started_at')
    self.security_scan_started_at = attributes[:'security_scan_started_at']
  end

  if attributes.has_key?(:'security_scan_status')
    self.security_scan_status = attributes[:'security_scan_status']
  end

  if attributes.has_key?(:'security_scan_status_updated_at')
    self.security_scan_status_updated_at = attributes[:'security_scan_status_updated_at']
  end

  if attributes.has_key?(:'self_html_url')
    self.self_html_url = attributes[:'self_html_url']
  end

  if attributes.has_key?(:'self_url')
    self.self_url = attributes[:'self_url']
  end

  if attributes.has_key?(:'signature_url')
    self.signature_url = attributes[:'signature_url']
  end

  if attributes.has_key?(:'size')
    self.size = attributes[:'size']
  end

  if attributes.has_key?(:'slug')
    self.slug = attributes[:'slug']
  end

  if attributes.has_key?(:'slug_perm')
    self.slug_perm = attributes[:'slug_perm']
  end

  if attributes.has_key?(:'stage')
    self.stage = attributes[:'stage']
  end

  if attributes.has_key?(:'stage_str')
    self.stage_str = attributes[:'stage_str']
  end

  if attributes.has_key?(:'stage_updated_at')
    self.stage_updated_at = attributes[:'stage_updated_at']
  end

  if attributes.has_key?(:'status')
    self.status = attributes[:'status']
  end

  if attributes.has_key?(:'status_reason')
    self.status_reason = attributes[:'status_reason']
  end

  if attributes.has_key?(:'status_str')
    self.status_str = attributes[:'status_str']
  end

  if attributes.has_key?(:'status_updated_at')
    self.status_updated_at = attributes[:'status_updated_at']
  end

  if attributes.has_key?(:'status_url')
    self.status_url = attributes[:'status_url']
  end

  if attributes.has_key?(:'subtype')
    self.subtype = attributes[:'subtype']
  end

  if attributes.has_key?(:'summary')
    self.summary = attributes[:'summary']
  end

  if attributes.has_key?(:'sync_finished_at')
    self.sync_finished_at = attributes[:'sync_finished_at']
  end

  if attributes.has_key?(:'sync_progress')
    self.sync_progress = attributes[:'sync_progress']
  end

  if attributes.has_key?(:'tags_immutable')
    self.tags_immutable = attributes[:'tags_immutable']
  end

  if attributes.has_key?(:'type_display')
    self.type_display = attributes[:'type_display']
  end

  if attributes.has_key?(:'uploaded_at')
    self.uploaded_at = attributes[:'uploaded_at']
  end

  if attributes.has_key?(:'uploader')
    self.uploader = attributes[:'uploader']
  end

  if attributes.has_key?(:'uploader_url')
    self.uploader_url = attributes[:'uploader_url']
  end

  if attributes.has_key?(:'version')
    self.version = attributes[:'version']
  end

  if attributes.has_key?(:'version_orig')
    self.version_orig = attributes[:'version_orig']
  end

  if attributes.has_key?(:'vulnerability_scan_results_url')
    self.vulnerability_scan_results_url = attributes[:'vulnerability_scan_results_url']
  end
end

Instance Attribute Details

#architecturesObject

Returns the value of attribute architectures.



18
19
20
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 18

def architectures
  @architectures
end

#cdn_urlObject

Returns the value of attribute cdn_url.



21
22
23
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 21

def cdn_url
  @cdn_url
end

#checksum_md5Object

Returns the value of attribute checksum_md5.



24
25
26
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 24

def checksum_md5
  @checksum_md5
end

#checksum_sha1Object

Returns the value of attribute checksum_sha1.



27
28
29
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 27

def checksum_sha1
  @checksum_sha1
end

#checksum_sha256Object

Returns the value of attribute checksum_sha256.



30
31
32
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 30

def checksum_sha256
  @checksum_sha256
end

#checksum_sha512Object

Returns the value of attribute checksum_sha512.



33
34
35
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 33

def checksum_sha512
  @checksum_sha512
end

#dependencies_checksum_md5Object

A checksum of all of the package’s dependencies.



36
37
38
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 36

def dependencies_checksum_md5
  @dependencies_checksum_md5
end

#dependencies_urlObject

Returns the value of attribute dependencies_url.



39
40
41
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 39

def dependencies_url
  @dependencies_url
end

#descriptionObject

A textual description of this package.



42
43
44
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 42

def description
  @description
end

#distroObject

Returns the value of attribute distro.



45
46
47
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 45

def distro
  @distro
end

#distro_versionObject

Returns the value of attribute distro_version.



48
49
50
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 48

def distro_version
  @distro_version
end

#downloadsObject

Returns the value of attribute downloads.



51
52
53
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 51

def downloads
  @downloads
end

#epochObject

The epoch of the package version (if any).



54
55
56
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 54

def epoch
  @epoch
end

#extensionObject

Returns the value of attribute extension.



57
58
59
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 57

def extension
  @extension
end

#filenameObject

Returns the value of attribute filename.



60
61
62
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 60

def filename
  @filename
end

#filesObject

Returns the value of attribute files.



63
64
65
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 63

def files
  @files
end

#formatObject

Returns the value of attribute format.



66
67
68
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 66

def format
  @format
end

#format_urlObject

Returns the value of attribute format_url.



69
70
71
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 69

def format_url
  @format_url
end

#identifier_permObject

Unique and permanent identifier for the package.



72
73
74
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 72

def identifier_perm
  @identifier_perm
end

#indexedObject

Returns the value of attribute indexed.



75
76
77
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 75

def indexed
  @indexed
end

#is_downloadableObject

Returns the value of attribute is_downloadable.



78
79
80
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 78

def is_downloadable
  @is_downloadable
end

#is_quarantinedObject

Returns the value of attribute is_quarantined.



81
82
83
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 81

def is_quarantined
  @is_quarantined
end

#is_sync_awaitingObject

Returns the value of attribute is_sync_awaiting.



84
85
86
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 84

def is_sync_awaiting
  @is_sync_awaiting
end

#is_sync_completedObject

Returns the value of attribute is_sync_completed.



87
88
89
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 87

def is_sync_completed
  @is_sync_completed
end

#is_sync_failedObject

Returns the value of attribute is_sync_failed.



90
91
92
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 90

def is_sync_failed
  @is_sync_failed
end

#is_sync_in_flightObject

Returns the value of attribute is_sync_in_flight.



93
94
95
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 93

def is_sync_in_flight
  @is_sync_in_flight
end

#is_sync_in_progressObject

Returns the value of attribute is_sync_in_progress.



96
97
98
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 96

def is_sync_in_progress
  @is_sync_in_progress
end

#licenseObject

The license of this package.



99
100
101
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 99

def license
  @license
end

#nameObject

The name of this package.



102
103
104
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 102

def name
  @name
end

#namespaceObject

Returns the value of attribute namespace.



105
106
107
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 105

def namespace
  @namespace
end

#namespace_urlObject

Returns the value of attribute namespace_url.



108
109
110
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 108

def namespace_url
  @namespace_url
end

#num_filesObject

Returns the value of attribute num_files.



111
112
113
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 111

def num_files
  @num_files
end

#package_typeObject

The type of package contents.



114
115
116
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 114

def package_type
  @package_type
end

#providerObject

The virtual machine provider for the box.



117
118
119
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 117

def provider
  @provider
end

#releaseObject

The release of the package version (if any).



120
121
122
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 120

def release
  @release
end

#repositoryObject

Returns the value of attribute repository.



123
124
125
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 123

def repository
  @repository
end

#repository_urlObject

Returns the value of attribute repository_url.



126
127
128
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 126

def repository_url
  @repository_url
end

#security_scan_completed_atObject

The datetime the security scanning was completed.



129
130
131
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 129

def security_scan_completed_at
  @security_scan_completed_at
end

#security_scan_started_atObject

The datetime the security scanning was started.



132
133
134
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 132

def security_scan_started_at
  @security_scan_started_at
end

#security_scan_statusObject

Returns the value of attribute security_scan_status.



135
136
137
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 135

def security_scan_status
  @security_scan_status
end

#security_scan_status_updated_atObject

The datetime the security scanning status was updated.



138
139
140
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 138

def security_scan_status_updated_at
  @security_scan_status_updated_at
end

#self_html_urlObject

Returns the value of attribute self_html_url.



141
142
143
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 141

def self_html_url
  @self_html_url
end

#self_urlObject

Returns the value of attribute self_url.



144
145
146
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 144

def self_url
  @self_url
end

#signature_urlObject

Returns the value of attribute signature_url.



147
148
149
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 147

def signature_url
  @signature_url
end

#sizeObject

The calculated size of the package.



150
151
152
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 150

def size
  @size
end

#slugObject

The public unique identifier for the package.



153
154
155
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 153

def slug
  @slug
end

#slug_permObject

Returns the value of attribute slug_perm.



156
157
158
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 156

def slug_perm
  @slug_perm
end

#stageObject

The synchronisation (in progress) stage of the package.



159
160
161
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 159

def stage
  @stage
end

#stage_strObject

Returns the value of attribute stage_str.



162
163
164
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 162

def stage_str
  @stage_str
end

#stage_updated_atObject

The datetime the package stage was updated at.



165
166
167
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 165

def stage_updated_at
  @stage_updated_at
end

#statusObject

The synchronisation status of the package.



168
169
170
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 168

def status
  @status
end

#status_reasonObject

A textual description for the synchronous status reason (if any



171
172
173
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 171

def status_reason
  @status_reason
end

#status_strObject

Returns the value of attribute status_str.



174
175
176
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 174

def status_str
  @status_str
end

#status_updated_atObject

The datetime the package status was updated at.



177
178
179
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 177

def status_updated_at
  @status_updated_at
end

#status_urlObject

Returns the value of attribute status_url.



180
181
182
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 180

def status_url
  @status_url
end

#subtypeObject

Returns the value of attribute subtype.



183
184
185
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 183

def subtype
  @subtype
end

#summaryObject

A one-liner synopsis of this package.



186
187
188
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 186

def summary
  @summary
end

#sync_finished_atObject

The datetime the package sync was finished at.



189
190
191
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 189

def sync_finished_at
  @sync_finished_at
end

#sync_progressObject

Synchronisation progress (from 0-100)



192
193
194
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 192

def sync_progress
  @sync_progress
end

#tags_immutableObject

All immutable tags on the package, grouped by tag type. Immutable tags cannot be (easily) deleted.



195
196
197
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 195

def tags_immutable
  @tags_immutable
end

#type_displayObject

Returns the value of attribute type_display.



198
199
200
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 198

def type_display
  @type_display
end

#uploaded_atObject

The date this package was uploaded.



201
202
203
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 201

def uploaded_at
  @uploaded_at
end

#uploaderObject

Returns the value of attribute uploader.



204
205
206
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 204

def uploader
  @uploader
end

#uploader_urlObject

Returns the value of attribute uploader_url.



207
208
209
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 207

def uploader_url
  @uploader_url
end

#versionObject

The raw version for this package.



210
211
212
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 210

def version
  @version
end

#version_origObject

Returns the value of attribute version_orig.



213
214
215
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 213

def version_orig
  @version_orig
end

#vulnerability_scan_results_urlObject

Returns the value of attribute vulnerability_scan_results_url.



216
217
218
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 216

def vulnerability_scan_results_url
  @vulnerability_scan_results_url
end

Class Method Details

.attribute_mapObject

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



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
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 219

def self.attribute_map
  {
    :'architectures' => :'architectures',
    :'cdn_url' => :'cdn_url',
    :'checksum_md5' => :'checksum_md5',
    :'checksum_sha1' => :'checksum_sha1',
    :'checksum_sha256' => :'checksum_sha256',
    :'checksum_sha512' => :'checksum_sha512',
    :'dependencies_checksum_md5' => :'dependencies_checksum_md5',
    :'dependencies_url' => :'dependencies_url',
    :'description' => :'description',
    :'distro' => :'distro',
    :'distro_version' => :'distro_version',
    :'downloads' => :'downloads',
    :'epoch' => :'epoch',
    :'extension' => :'extension',
    :'filename' => :'filename',
    :'files' => :'files',
    :'format' => :'format',
    :'format_url' => :'format_url',
    :'identifier_perm' => :'identifier_perm',
    :'indexed' => :'indexed',
    :'is_downloadable' => :'is_downloadable',
    :'is_quarantined' => :'is_quarantined',
    :'is_sync_awaiting' => :'is_sync_awaiting',
    :'is_sync_completed' => :'is_sync_completed',
    :'is_sync_failed' => :'is_sync_failed',
    :'is_sync_in_flight' => :'is_sync_in_flight',
    :'is_sync_in_progress' => :'is_sync_in_progress',
    :'license' => :'license',
    :'name' => :'name',
    :'namespace' => :'namespace',
    :'namespace_url' => :'namespace_url',
    :'num_files' => :'num_files',
    :'package_type' => :'package_type',
    :'provider' => :'provider',
    :'release' => :'release',
    :'repository' => :'repository',
    :'repository_url' => :'repository_url',
    :'security_scan_completed_at' => :'security_scan_completed_at',
    :'security_scan_started_at' => :'security_scan_started_at',
    :'security_scan_status' => :'security_scan_status',
    :'security_scan_status_updated_at' => :'security_scan_status_updated_at',
    :'self_html_url' => :'self_html_url',
    :'self_url' => :'self_url',
    :'signature_url' => :'signature_url',
    :'size' => :'size',
    :'slug' => :'slug',
    :'slug_perm' => :'slug_perm',
    :'stage' => :'stage',
    :'stage_str' => :'stage_str',
    :'stage_updated_at' => :'stage_updated_at',
    :'status' => :'status',
    :'status_reason' => :'status_reason',
    :'status_str' => :'status_str',
    :'status_updated_at' => :'status_updated_at',
    :'status_url' => :'status_url',
    :'subtype' => :'subtype',
    :'summary' => :'summary',
    :'sync_finished_at' => :'sync_finished_at',
    :'sync_progress' => :'sync_progress',
    :'tags_immutable' => :'tags_immutable',
    :'type_display' => :'type_display',
    :'uploaded_at' => :'uploaded_at',
    :'uploader' => :'uploader',
    :'uploader_url' => :'uploader_url',
    :'version' => :'version',
    :'version_orig' => :'version_orig',
    :'vulnerability_scan_results_url' => :'vulnerability_scan_results_url'
  }
end

.swagger_typesObject

Attribute type mapping.



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
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 292

def self.swagger_types
  {
    :'architectures' => :'Array<PackagesownerrepoArchitectures>',
    :'cdn_url' => :'String',
    :'checksum_md5' => :'String',
    :'checksum_sha1' => :'String',
    :'checksum_sha256' => :'String',
    :'checksum_sha512' => :'String',
    :'dependencies_checksum_md5' => :'String',
    :'dependencies_url' => :'String',
    :'description' => :'String',
    :'distro' => :'Object',
    :'distro_version' => :'Object',
    :'downloads' => :'Integer',
    :'epoch' => :'Integer',
    :'extension' => :'String',
    :'filename' => :'String',
    :'files' => :'Array<PackagesownerrepoFiles>',
    :'format' => :'String',
    :'format_url' => :'String',
    :'identifier_perm' => :'String',
    :'indexed' => :'BOOLEAN',
    :'is_downloadable' => :'BOOLEAN',
    :'is_quarantined' => :'BOOLEAN',
    :'is_sync_awaiting' => :'BOOLEAN',
    :'is_sync_completed' => :'BOOLEAN',
    :'is_sync_failed' => :'BOOLEAN',
    :'is_sync_in_flight' => :'BOOLEAN',
    :'is_sync_in_progress' => :'BOOLEAN',
    :'license' => :'String',
    :'name' => :'String',
    :'namespace' => :'String',
    :'namespace_url' => :'String',
    :'num_files' => :'Integer',
    :'package_type' => :'Integer',
    :'provider' => :'String',
    :'release' => :'String',
    :'repository' => :'String',
    :'repository_url' => :'String',
    :'security_scan_completed_at' => :'String',
    :'security_scan_started_at' => :'String',
    :'security_scan_status' => :'String',
    :'security_scan_status_updated_at' => :'String',
    :'self_html_url' => :'String',
    :'self_url' => :'String',
    :'signature_url' => :'String',
    :'size' => :'Integer',
    :'slug' => :'String',
    :'slug_perm' => :'String',
    :'stage' => :'Integer',
    :'stage_str' => :'String',
    :'stage_updated_at' => :'String',
    :'status' => :'Integer',
    :'status_reason' => :'String',
    :'status_str' => :'String',
    :'status_updated_at' => :'String',
    :'status_url' => :'String',
    :'subtype' => :'String',
    :'summary' => :'String',
    :'sync_finished_at' => :'String',
    :'sync_progress' => :'Integer',
    :'tags_immutable' => :'Object',
    :'type_display' => :'String',
    :'uploaded_at' => :'String',
    :'uploader' => :'String',
    :'uploader_url' => :'String',
    :'version' => :'String',
    :'version_orig' => :'String',
    :'vulnerability_scan_results_url' => :'String'
  }
end

Instance Method Details

#==(o) ⇒ Object

Checks equality by comparing each attribute.

Parameters:

  • Object (Object)

    to be compared



675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 675

def ==(o)
  return true if self.equal?(o)
  self.class == o.class &&
      architectures == o.architectures &&
      cdn_url == o.cdn_url &&
      checksum_md5 == o.checksum_md5 &&
      checksum_sha1 == o.checksum_sha1 &&
      checksum_sha256 == o.checksum_sha256 &&
      checksum_sha512 == o.checksum_sha512 &&
      dependencies_checksum_md5 == o.dependencies_checksum_md5 &&
      dependencies_url == o.dependencies_url &&
      description == o.description &&
      distro == o.distro &&
      distro_version == o.distro_version &&
      downloads == o.downloads &&
      epoch == o.epoch &&
      extension == o.extension &&
      filename == o.filename &&
      files == o.files &&
      format == o.format &&
      format_url == o.format_url &&
      identifier_perm == o.identifier_perm &&
      indexed == o.indexed &&
      is_downloadable == o.is_downloadable &&
      is_quarantined == o.is_quarantined &&
      is_sync_awaiting == o.is_sync_awaiting &&
      is_sync_completed == o.is_sync_completed &&
      is_sync_failed == o.is_sync_failed &&
      is_sync_in_flight == o.is_sync_in_flight &&
      is_sync_in_progress == o.is_sync_in_progress &&
      license == o.license &&
      name == o.name &&
      namespace == o.namespace &&
      namespace_url == o.namespace_url &&
      num_files == o.num_files &&
      package_type == o.package_type &&
      provider == o.provider &&
      release == o.release &&
      repository == o.repository &&
      repository_url == o.repository_url &&
      security_scan_completed_at == o.security_scan_completed_at &&
      security_scan_started_at == o.security_scan_started_at &&
      security_scan_status == o.security_scan_status &&
      security_scan_status_updated_at == o.security_scan_status_updated_at &&
      self_html_url == o.self_html_url &&
      self_url == o.self_url &&
      signature_url == o.signature_url &&
      size == o.size &&
      slug == o.slug &&
      slug_perm == o.slug_perm &&
      stage == o.stage &&
      stage_str == o.stage_str &&
      stage_updated_at == o.stage_updated_at &&
      status == o.status &&
      status_reason == o.status_reason &&
      status_str == o.status_str &&
      status_updated_at == o.status_updated_at &&
      status_url == o.status_url &&
      subtype == o.subtype &&
      summary == o.summary &&
      sync_finished_at == o.sync_finished_at &&
      sync_progress == o.sync_progress &&
      tags_immutable == o.tags_immutable &&
      type_display == o.type_display &&
      uploaded_at == o.uploaded_at &&
      uploader == o.uploader &&
      uploader_url == o.uploader_url &&
      version == o.version &&
      version_orig == o.version_orig &&
      vulnerability_scan_results_url == o.vulnerability_scan_results_url
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



783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 783

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
    temp_model = CloudsmithApi.const_get(type).new
    temp_model.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



849
850
851
852
853
854
855
856
857
858
859
860
861
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 849

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



762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 762

def build_from_hash(attributes)
  return nil unless attributes.is_a?(Hash)
  self.class.swagger_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]]))
    end # or else data not found in attributes(hash), not an issue as the data can be optional
  end

  self
end

#eql?(o) ⇒ Boolean

Parameters:

  • Object (Object)

    to be compared

Returns:

  • (Boolean)

See Also:

  • `==` method


749
750
751
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 749

def eql?(o)
  self == o
end

#hashFixnum

Calculates hash code according to all attributes.

Returns:

  • (Fixnum)

    Hash code



755
756
757
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 755

def hash
  [architectures, cdn_url, checksum_md5, checksum_sha1, checksum_sha256, checksum_sha512, dependencies_checksum_md5, dependencies_url, description, distro, distro_version, downloads, epoch, extension, filename, files, format, format_url, identifier_perm, indexed, is_downloadable, is_quarantined, is_sync_awaiting, is_sync_completed, is_sync_failed, is_sync_in_flight, is_sync_in_progress, license, name, namespace, namespace_url, num_files, package_type, provider, release, repository, repository_url, security_scan_completed_at, security_scan_started_at, security_scan_status, security_scan_status_updated_at, self_html_url, self_url, signature_url, size, slug, slug_perm, stage, stage_str, stage_updated_at, status, status_reason, status_str, status_updated_at, status_url, subtype, summary, sync_finished_at, sync_progress, tags_immutable, type_display, uploaded_at, uploader, uploader_url, version, version_orig, vulnerability_scan_results_url].hash
end

#list_invalid_propertiesObject

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

Returns:

  • Array for valid properties with the reasons



647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 647

def list_invalid_properties
  invalid_properties = Array.new
  if @name.nil?
    invalid_properties.push('invalid value for "name", name cannot be nil.')
  end

  if @provider.nil?
    invalid_properties.push('invalid value for "provider", provider cannot be nil.')
  end

  if @version.nil?
    invalid_properties.push('invalid value for "version", version cannot be nil.')
  end

  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



829
830
831
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 829

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



835
836
837
838
839
840
841
842
843
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 835

def to_hash
  hash = {}
  self.class.attribute_map.each_pair do |attr, param|
    value = self.send(attr)
    next if value.nil?
    hash[param] = _to_hash(value)
  end
  hash
end

#to_sString

Returns the string representation of the object

Returns:

  • (String)

    String presentation of the object



823
824
825
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 823

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



666
667
668
669
670
671
# File 'lib/cloudsmith-api/models/vagrant_package_upload.rb', line 666

def valid?
  return false if @name.nil?
  return false if @provider.nil?
  return false if @version.nil?
  true
end