class BotFramework::Attachment

Attributes

content[RW]

Embedded content

content_type[RW]

mimetype/Contenttype for the file

content_url[RW]

Content Url

name[RW]

(OPTIONAL) The name of the attachment

thumbnail_url[RW]

(OPTIONAL) Thumbnail associated with attachment

Public Class Methods

new(attributes = {}) click to toggle source

Initializes the object @param [Hash] attributes Model attributes in the form of hash

# File lib/bot_framework/models/attachment.rb, line 31
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.key?(:contentType)
    self.content_type = attributes[:contentType]
  end

  self.content_url = attributes[:contentUrl] if attributes.key?(:contentUrl)

  self.content = attributes[:content] if attributes.key?(:content)

  self.name = attributes[:name] if attributes.key?(:name)

  if attributes.key?(:thumbnailUrl)
    self.thumbnail_url = attributes[:thumbnailUrl]
  end
end
swagger_types() click to toggle source

Attribute type mapping.

# File lib/bot_framework/models/attachment.rb, line 19
def self.swagger_types
  {
    content_type: :String,
    content_url: :String,
    content: :Object,
    name: :String,
    thumbnail_url: :String
  }
end