Class: Google::Apis::WorkspaceeventsV1::FilePart

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

Overview

FilePart represents the different ways files can be provided. If files are small, directly feeding the bytes is supported via file_with_bytes. If the file is large, the agent should read the content as appropriate directly from the file_with_uri source.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ FilePart

Returns a new instance of FilePart.



212
213
214
# File 'lib/google/apis/workspaceevents_v1/classes.rb', line 212

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

Instance Attribute Details

#file_with_bytesString

Corresponds to the JSON property fileWithBytes NOTE: Values are automatically base64 encoded/decoded in the client library.

Returns:

  • (String)


195
196
197
# File 'lib/google/apis/workspaceevents_v1/classes.rb', line 195

def file_with_bytes
  @file_with_bytes
end

#file_with_uriString

Corresponds to the JSON property fileWithUri

Returns:

  • (String)


200
201
202
# File 'lib/google/apis/workspaceevents_v1/classes.rb', line 200

def file_with_uri
  @file_with_uri
end

#mime_typeString

Corresponds to the JSON property mimeType

Returns:

  • (String)


205
206
207
# File 'lib/google/apis/workspaceevents_v1/classes.rb', line 205

def mime_type
  @mime_type
end

#nameString

Corresponds to the JSON property name

Returns:

  • (String)


210
211
212
# File 'lib/google/apis/workspaceevents_v1/classes.rb', line 210

def name
  @name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



217
218
219
220
221
222
# File 'lib/google/apis/workspaceevents_v1/classes.rb', line 217

def update!(**args)
  @file_with_bytes = args[:file_with_bytes] if args.key?(:file_with_bytes)
  @file_with_uri = args[:file_with_uri] if args.key?(:file_with_uri)
  @mime_type = args[:mime_type] if args.key?(:mime_type)
  @name = args[:name] if args.key?(:name)
end