Class: FlatApi::ScoreDetails

Inherits:
Object
  • Object
show all
Defined in:
lib/flat_api/models/score_details.rb

Overview

The score and all its details

Defined Under Namespace

Classes: EnumAttributeValidator

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ ScoreDetails

Initializes the object

Parameters:

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

    Model attributes in the form of hash



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
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
# File 'lib/flat_api/models/score_details.rb', line 241

def initialize(attributes = {})
  if (!attributes.is_a?(Hash))
    fail ArgumentError, "The input argument (attributes) must be a hash in `FlatApi::ScoreDetails` 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 `FlatApi::ScoreDetails`. 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?(:'id')
    self.id = attributes[:'id']
  else
    self.id = nil
  end

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

  if attributes.key?(:'title')
    self.title = attributes[:'title']
  else
    self.title = nil
  end

  if attributes.key?(:'privacy')
    self.privacy = attributes[:'privacy']
  else
    self.privacy = 'private'
  end

  if attributes.key?(:'user')
    self.user = attributes[:'user']
  else
    self.user = nil
  end

  if attributes.key?(:'html_url')
    self.html_url = attributes[:'html_url']
  else
    self.html_url = nil
  end

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

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

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

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

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

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

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

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

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

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

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

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

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

  if attributes.key?(:'rights')
    self.rights = attributes[:'rights']
  else
    self.rights = nil
  end

  if attributes.key?(:'collaborators')
    if (value = attributes[:'collaborators']).is_a?(Array)
      self.collaborators = value
    end
  else
    self.collaborators = nil
  end

  if attributes.key?(:'creation_date')
    self.creation_date = attributes[:'creation_date']
  else
    self.creation_date = nil
  end

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

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

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

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

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

  if attributes.key?(:'instruments')
    if (value = attributes[:'instruments']).is_a?(Array)
      self.instruments = value
    end
  else
    self.instruments = nil
  end

  if attributes.key?(:'samples')
    if (value = attributes[:'samples']).is_a?(Array)
      self.samples = value
    end
  else
    self.samples = nil
  end

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

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

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

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

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

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

Instance Attribute Details

#arrangerObject

Arranger of the score



42
43
44
# File 'lib/flat_api/models/score_details.rb', line 42

def arranger
  @arranger
end

#collaboratorsObject

The list of the collaborators of the score



75
76
77
# File 'lib/flat_api/models/score_details.rb', line 75

def collaborators
  @collaborators
end

#collectionsObject

The List of parent collections, which includes all the collections this score is included. Please note that you might not have access to all of them.



113
114
115
# File 'lib/flat_api/models/score_details.rb', line 113

def collections
  @collections
end

#commentsObject

Returns the value of attribute comments.



106
107
108
# File 'lib/flat_api/models/score_details.rb', line 106

def comments
  @comments
end

#composerObject

Composer of the score



45
46
47
# File 'lib/flat_api/models/score_details.rb', line 45

def composer
  @composer
end

#creation_dateObject

The date when the score was created



78
79
80
# File 'lib/flat_api/models/score_details.rb', line 78

def creation_date
  @creation_date
end

#creation_typeObject

Returns the value of attribute creation_type.



53
54
55
# File 'lib/flat_api/models/score_details.rb', line 53

def creation_type
  @creation_type
end

#descriptionObject

Description of the creation



48
49
50
# File 'lib/flat_api/models/score_details.rb', line 48

def description
  @description
end

#duration_timeObject

In seconds, an approximative duration of the score



61
62
63
# File 'lib/flat_api/models/score_details.rb', line 61

def duration_time
  @duration_time
end

#google_drive_file_idObject

If the user uses Google Drive and the score exists on Google Drive, this field will contain the unique identifier of the Flat score on Google Drive. You can access the document using the url: ‘drive.google.com/open?id=googleDriveFileId`



102
103
104
# File 'lib/flat_api/models/score_details.rb', line 102

def google_drive_file_id
  @google_drive_file_id
end

#highlighted_dateObject

The date when the score was highlighted (featured) on our community



87
88
89
# File 'lib/flat_api/models/score_details.rb', line 87

def highlighted_date
  @highlighted_date
end

#html_urlObject

The url where the score can be viewed in a web browser



33
34
35
# File 'lib/flat_api/models/score_details.rb', line 33

def html_url
  @html_url
end

#idObject

The unique identifier of the score



20
21
22
# File 'lib/flat_api/models/score_details.rb', line 20

def id
  @id
end

#instrumentsObject

An array of the instrument identifiers used in the last version of the score. This is mainly used to display a list of the instruments in the Flat’s UI or instruments icons. The format of the strings is ‘instrument-group.instrument-id`.



96
97
98
# File 'lib/flat_api/models/score_details.rb', line 96

def instruments
  @instruments
end

#licenseObject

Returns the value of attribute license.



55
56
57
# File 'lib/flat_api/models/score_details.rb', line 55

def license
  @license
end

#license_textObject

Additional license text written on the exported/printed score



58
59
60
# File 'lib/flat_api/models/score_details.rb', line 58

def license_text
  @license_text
end

#likesObject

Returns the value of attribute likes.



104
105
106
# File 'lib/flat_api/models/score_details.rb', line 104

def likes
  @likes
end

#lyricistObject

Lyricist of the score



39
40
41
# File 'lib/flat_api/models/score_details.rb', line 39

def lyricist
  @lyricist
end

#main_key_signatureObject

The main key signature of the score (expressed between -7 and 7).



70
71
72
# File 'lib/flat_api/models/score_details.rb', line 70

def main_key_signature
  @main_key_signature
end

#main_tempo_qpmObject

The main tempo of the score (in QPM)



67
68
69
# File 'lib/flat_api/models/score_details.rb', line 67

def main_tempo_qpm
  @main_tempo_qpm
end

#modification_dateObject

The date of the last revision of the score



81
82
83
# File 'lib/flat_api/models/score_details.rb', line 81

def modification_date
  @modification_date
end

#number_measuresObject

The number of measures in the score



64
65
66
# File 'lib/flat_api/models/score_details.rb', line 64

def number_measures
  @number_measures
end

#organizationObject

If the score has been created in an organization, the identifier of this organization. This property is especially used with the score privacy ‘organizationPublic`.



90
91
92
# File 'lib/flat_api/models/score_details.rb', line 90

def organization
  @organization
end

#parent_scoreObject

If the score has been forked, the unique identifier of the parent score.



93
94
95
# File 'lib/flat_api/models/score_details.rb', line 93

def parent_score
  @parent_score
end

#playsObject

Returns the value of attribute plays.



110
111
112
# File 'lib/flat_api/models/score_details.rb', line 110

def plays
  @plays
end

#privacyObject

Returns the value of attribute privacy.



28
29
30
# File 'lib/flat_api/models/score_details.rb', line 28

def privacy
  @privacy
end

#publication_dateObject

The date when the score was published on Flat



84
85
86
# File 'lib/flat_api/models/score_details.rb', line 84

def publication_date
  @publication_date
end

#rightsObject

Returns the value of attribute rights.



72
73
74
# File 'lib/flat_api/models/score_details.rb', line 72

def rights
  @rights
end

#samplesObject

An array of the audio samples identifiers used the different score parts. The format of the strings is ‘instrument-group.sample-id`.



99
100
101
# File 'lib/flat_api/models/score_details.rb', line 99

def samples
  @samples
end

#sharing_keyObject

The private sharing key of the score (available when the ‘privacy` mode is set to `privateLink`)



23
24
25
# File 'lib/flat_api/models/score_details.rb', line 23

def sharing_key
  @sharing_key
end

#subtitleObject

Subtitle of the score



36
37
38
# File 'lib/flat_api/models/score_details.rb', line 36

def subtitle
  @subtitle
end

#tagsObject

Tags describing the score



51
52
53
# File 'lib/flat_api/models/score_details.rb', line 51

def tags
  @tags
end

#titleObject

The title of the score



26
27
28
# File 'lib/flat_api/models/score_details.rb', line 26

def title
  @title
end

#userObject

Returns the value of attribute user.



30
31
32
# File 'lib/flat_api/models/score_details.rb', line 30

def user
  @user
end

#viewsObject

Returns the value of attribute views.



108
109
110
# File 'lib/flat_api/models/score_details.rb', line 108

def views
  @views
end

Class Method Details

._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



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
# File 'lib/flat_api/models/score_details.rb', line 571

def self._deserialize(type, value)
  case type.to_sym
  when :Time
    Time.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
    # models (e.g. Pet) or oneOf
    klass = FlatApi.const_get(type)
    klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
  end
end

.acceptable_attributesObject

Returns all the JSON keys this model knows about



179
180
181
# File 'lib/flat_api/models/score_details.rb', line 179

def self.acceptable_attributes
  attribute_map.values
end

.attribute_mapObject

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



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
# File 'lib/flat_api/models/score_details.rb', line 138

def self.attribute_map
  {
    :'id' => :'id',
    :'sharing_key' => :'sharingKey',
    :'title' => :'title',
    :'privacy' => :'privacy',
    :'user' => :'user',
    :'html_url' => :'htmlUrl',
    :'subtitle' => :'subtitle',
    :'lyricist' => :'lyricist',
    :'arranger' => :'arranger',
    :'composer' => :'composer',
    :'description' => :'description',
    :'tags' => :'tags',
    :'creation_type' => :'creationType',
    :'license' => :'license',
    :'license_text' => :'licenseText',
    :'duration_time' => :'durationTime',
    :'number_measures' => :'numberMeasures',
    :'main_tempo_qpm' => :'mainTempoQpm',
    :'main_key_signature' => :'mainKeySignature',
    :'rights' => :'rights',
    :'collaborators' => :'collaborators',
    :'creation_date' => :'creationDate',
    :'modification_date' => :'modificationDate',
    :'publication_date' => :'publicationDate',
    :'highlighted_date' => :'highlightedDate',
    :'organization' => :'organization',
    :'parent_score' => :'parentScore',
    :'instruments' => :'instruments',
    :'samples' => :'samples',
    :'google_drive_file_id' => :'googleDriveFileId',
    :'likes' => :'likes',
    :'comments' => :'comments',
    :'views' => :'views',
    :'plays' => :'plays',
    :'collections' => :'collections'
  }
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



547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
# File 'lib/flat_api/models/score_details.rb', line 547

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_all_ofObject

List of class defined in allOf (OpenAPI v3)



233
234
235
236
237
# File 'lib/flat_api/models/score_details.rb', line 233

def self.openapi_all_of
  [
  :'ScoreSummary'
  ]
end

.openapi_nullableObject

List of attributes with nullable: true



225
226
227
228
229
230
# File 'lib/flat_api/models/score_details.rb', line 225

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

.openapi_typesObject

Attribute type mapping.



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
# File 'lib/flat_api/models/score_details.rb', line 184

def self.openapi_types
  {
    :'id' => :'String',
    :'sharing_key' => :'String',
    :'title' => :'String',
    :'privacy' => :'ScorePrivacy',
    :'user' => :'UserPublic',
    :'html_url' => :'String',
    :'subtitle' => :'String',
    :'lyricist' => :'String',
    :'arranger' => :'String',
    :'composer' => :'String',
    :'description' => :'String',
    :'tags' => :'Array<String>',
    :'creation_type' => :'ScoreCreationType',
    :'license' => :'ScoreLicense',
    :'license_text' => :'String',
    :'duration_time' => :'Float',
    :'number_measures' => :'Integer',
    :'main_tempo_qpm' => :'Float',
    :'main_key_signature' => :'Float',
    :'rights' => :'ResourceRights',
    :'collaborators' => :'Array<ResourceCollaborator>',
    :'creation_date' => :'Time',
    :'modification_date' => :'Time',
    :'publication_date' => :'Time',
    :'highlighted_date' => :'Time',
    :'organization' => :'String',
    :'parent_score' => :'String',
    :'instruments' => :'Array<String>',
    :'samples' => :'Array<String>',
    :'google_drive_file_id' => :'String',
    :'likes' => :'ScoreLikesCounts',
    :'comments' => :'ScoreCommentsCounts',
    :'views' => :'ScoreViewsCounts',
    :'plays' => :'ScorePlaysCounts',
    :'collections' => :'Array<String>'
  }
end

Instance Method Details

#==(o) ⇒ Object

Checks equality by comparing each attribute.

Parameters:

  • Object (Object)

    to be compared



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
# File 'lib/flat_api/models/score_details.rb', line 492

def ==(o)
  return true if self.equal?(o)
  self.class == o.class &&
      id == o.id &&
      sharing_key == o.sharing_key &&
      title == o.title &&
      privacy == o.privacy &&
      user == o.user &&
      html_url == o.html_url &&
      subtitle == o.subtitle &&
      lyricist == o.lyricist &&
      arranger == o.arranger &&
      composer == o.composer &&
      description == o.description &&
      tags == o.tags &&
      creation_type == o.creation_type &&
      license == o.license &&
      license_text == o.license_text &&
      duration_time == o.duration_time &&
      number_measures == o.number_measures &&
      main_tempo_qpm == o.main_tempo_qpm &&
      main_key_signature == o.main_key_signature &&
      rights == o.rights &&
      collaborators == o.collaborators &&
      creation_date == o.creation_date &&
      modification_date == o.modification_date &&
      publication_date == o.publication_date &&
      highlighted_date == o.highlighted_date &&
      organization == o.organization &&
      parent_score == o.parent_score &&
      instruments == o.instruments &&
      samples == o.samples &&
      google_drive_file_id == o.google_drive_file_id &&
      likes == o.likes &&
      comments == o.comments &&
      views == o.views &&
      plays == o.plays &&
      collections == o.collections
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



642
643
644
645
646
647
648
649
650
651
652
653
654
# File 'lib/flat_api/models/score_details.rb', line 642

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

#eql?(o) ⇒ Boolean

Parameters:

  • Object (Object)

    to be compared

Returns:

  • (Boolean)

See Also:

  • `==` method


534
535
536
# File 'lib/flat_api/models/score_details.rb', line 534

def eql?(o)
  self == o
end

#hashInteger

Calculates hash code according to all attributes.

Returns:

  • (Integer)

    Hash code



540
541
542
# File 'lib/flat_api/models/score_details.rb', line 540

def hash
  [id, sharing_key, title, privacy, user, html_url, subtitle, lyricist, arranger, composer, description, tags, creation_type, license, license_text, duration_time, number_measures, main_tempo_qpm, main_key_signature, rights, collaborators, creation_date, modification_date, publication_date, highlighted_date, organization, parent_score, instruments, samples, google_drive_file_id, likes, comments, views, plays, collections].hash
end

#list_invalid_propertiesObject

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

Returns:

  • Array for valid properties with the reasons



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
# File 'lib/flat_api/models/score_details.rb', line 427

def list_invalid_properties
  warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
  invalid_properties = Array.new
  if @id.nil?
    invalid_properties.push('invalid value for "id", id cannot be nil.')
  end

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

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

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

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

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

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

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

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

  if @samples.nil?
    invalid_properties.push('invalid value for "samples", samples 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



618
619
620
# File 'lib/flat_api/models/score_details.rb', line 618

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



624
625
626
627
628
629
630
631
632
633
634
635
636
# File 'lib/flat_api/models/score_details.rb', line 624

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



612
613
614
# File 'lib/flat_api/models/score_details.rb', line 612

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



475
476
477
478
479
480
481
482
483
484
485
486
487
488
# File 'lib/flat_api/models/score_details.rb', line 475

def valid?
  warn '[DEPRECATED] the `valid?` method is obsolete'
  return false if @id.nil?
  return false if @title.nil?
  return false if @privacy.nil?
  return false if @user.nil?
  return false if @html_url.nil?
  return false if @rights.nil?
  return false if @collaborators.nil?
  return false if @creation_date.nil?
  return false if @instruments.nil?
  return false if @samples.nil?
  true
end