Class: Google::Apis::DriveV2::Label

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/drive_v2/classes.rb,
lib/google/apis/drive_v2/representations.rb,
lib/google/apis/drive_v2/representations.rb

Overview

Representation of a label and label fields.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Label

Returns a new instance of Label.



3396
3397
3398
# File 'lib/google/apis/drive_v2/classes.rb', line 3396

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#fieldsHash<String,Google::Apis::DriveV2::LabelField>

A map of the fields on the label, keyed by the field's ID. Corresponds to the JSON property fields

Returns:



3379
3380
3381
# File 'lib/google/apis/drive_v2/classes.rb', line 3379

def fields
  @fields
end

#idString

The ID of the label. Corresponds to the JSON property id

Returns:

  • (String)


3384
3385
3386
# File 'lib/google/apis/drive_v2/classes.rb', line 3384

def id
  @id
end

#kindString

This is always drive#label Corresponds to the JSON property kind

Returns:

  • (String)


3389
3390
3391
# File 'lib/google/apis/drive_v2/classes.rb', line 3389

def kind
  @kind
end

#revision_idString

The revision ID of the label. Corresponds to the JSON property revisionId

Returns:

  • (String)


3394
3395
3396
# File 'lib/google/apis/drive_v2/classes.rb', line 3394

def revision_id
  @revision_id
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



3401
3402
3403
3404
3405
3406
# File 'lib/google/apis/drive_v2/classes.rb', line 3401

def update!(**args)
  @fields = args[:fields] if args.key?(:fields)
  @id = args[:id] if args.key?(:id)
  @kind = args[:kind] if args.key?(:kind)
  @revision_id = args[:revision_id] if args.key?(:revision_id)
end