Class: Google::Apis::DriveV2::LabelField
- Inherits:
-
Object
- Object
- Google::Apis::DriveV2::LabelField
- 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 field, which is a typed key-value pair.
Instance Attribute Summary collapse
-
#date_string ⇒ Array<Date>
Only present if valueType is dateString.
-
#id ⇒ String
The identifier of this label field.
-
#integer ⇒ Array<Fixnum>
Only present if
valueType
isinteger
. -
#kind ⇒ String
This is always
drive#labelField
. -
#selection ⇒ Array<String>
Only present if
valueType
isselection
Corresponds to the JSON propertyselection
. -
#text ⇒ Array<String>
Only present if
valueType
istext
. -
#user ⇒ Array<Google::Apis::DriveV2::User>
Only present if
valueType
isuser
. -
#value_type ⇒ String
The field type.
Instance Method Summary collapse
-
#initialize(**args) ⇒ LabelField
constructor
A new instance of LabelField.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ LabelField
Returns a new instance of LabelField.
3291 3292 3293 |
# File 'lib/google/apis/drive_v2/classes.rb', line 3291 def initialize(**args) update!(**args) end |
Instance Attribute Details
#date_string ⇒ Array<Date>
Only present if valueType is dateString. RFC 3339 formatted date: YYYY-MM-DD.
Corresponds to the JSON property dateString
3252 3253 3254 |
# File 'lib/google/apis/drive_v2/classes.rb', line 3252 def date_string @date_string end |
#id ⇒ String
The identifier of this label field.
Corresponds to the JSON property id
3257 3258 3259 |
# File 'lib/google/apis/drive_v2/classes.rb', line 3257 def id @id end |
#integer ⇒ Array<Fixnum>
Only present if valueType
is integer
.
Corresponds to the JSON property integer
3262 3263 3264 |
# File 'lib/google/apis/drive_v2/classes.rb', line 3262 def integer @integer end |
#kind ⇒ String
This is always drive#labelField
.
Corresponds to the JSON property kind
3267 3268 3269 |
# File 'lib/google/apis/drive_v2/classes.rb', line 3267 def kind @kind end |
#selection ⇒ Array<String>
Only present if valueType
is selection
Corresponds to the JSON property selection
3272 3273 3274 |
# File 'lib/google/apis/drive_v2/classes.rb', line 3272 def selection @selection end |
#text ⇒ Array<String>
Only present if valueType
is text
.
Corresponds to the JSON property text
3277 3278 3279 |
# File 'lib/google/apis/drive_v2/classes.rb', line 3277 def text @text end |
#user ⇒ Array<Google::Apis::DriveV2::User>
Only present if valueType
is user
.
Corresponds to the JSON property user
3282 3283 3284 |
# File 'lib/google/apis/drive_v2/classes.rb', line 3282 def user @user end |
#value_type ⇒ String
The field type. While new values may be supported in the future, the following
are currently allowed: * dateString
* integer
* selection
* text
*
user
Corresponds to the JSON property valueType
3289 3290 3291 |
# File 'lib/google/apis/drive_v2/classes.rb', line 3289 def value_type @value_type end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 |
# File 'lib/google/apis/drive_v2/classes.rb', line 3296 def update!(**args) @date_string = args[:date_string] if args.key?(:date_string) @id = args[:id] if args.key?(:id) @integer = args[:integer] if args.key?(:integer) @kind = args[:kind] if args.key?(:kind) @selection = args[:selection] if args.key?(:selection) @text = args[:text] if args.key?(:text) @user = args[:user] if args.key?(:user) @value_type = args[:value_type] if args.key?(:value_type) end |