123456789_123456789_123456789_123456789_123456789_

Class: Net::IMAP::BodyTypeMultipart

Relationships & Source Files
Super Chains via Extension / Inclusion / Inheritance
Class Chain:
self, Struct
Instance Chain:
self, BodyStructure, Struct
Inherits: Struct
  • Object
Defined in: lib/net/imap/response_data.rb

Overview

BodyTypeMultipart represents body structures of messages and message parts, when Content-Type is multipart/*.

Instance Attribute Summary

Instance Method Summary

Instance Attribute Details

#dispositionContentDisposition (rw)

Returns a ContentDisposition object giving the content disposition.

[ GitHub ]

  
# File 'lib/net/imap/response_data.rb', line 1116

class BodyTypeMultipart < Struct.new(:media_type, :subtype,
:parts,
:param, :disposition, :language,
:location,
:extension)

#extensionArray (rw)

Returns extension data as an array of numbers strings, and nested arrays (of numbers, strings, etc).

[ GitHub ]

  
# File 'lib/net/imap/response_data.rb', line 1116

class BodyTypeMultipart < Struct.new(:media_type, :subtype,
:parts,
:param, :disposition, :language,
:location,
:extension)

#languageString (rw)

Returns a string or an array of strings giving the body language value as defined in [LANGUAGE-TAGS].

[ GitHub ]

  
# File 'lib/net/imap/response_data.rb', line 1116

class BodyTypeMultipart < Struct.new(:media_type, :subtype,
:parts,
:param, :disposition, :language,
:location,
:extension)

#location (rw)

BodyTypeMultipart represents body structures of messages and message parts, when Content-Type is multipart/*.

[ GitHub ]

  
# File 'lib/net/imap/response_data.rb', line 1116

class BodyTypeMultipart < Struct.new(:media_type, :subtype,
:parts,
:param, :disposition, :language,
:location,
:extension)

#media_type ⇒ "multipart" (rw)

BodyTypeMultipart is only used with multipart/* media types.

[ GitHub ]

  
# File 'lib/net/imap/response_data.rb', line 1116

class BodyTypeMultipart < Struct.new(:media_type, :subtype,
:parts,
:param, :disposition, :language,
:location,
:extension)

#multipart?Boolean (readonly)

BodyTypeMultipart is used for multipart MIME parts.

[ GitHub ]

  
# File 'lib/net/imap/response_data.rb', line 1176

def multipart?
  return true
end

#paramHash (rw)

Returns a hash that represents parameters as defined in [MIME-IMB].

[ GitHub ]

  
# File 'lib/net/imap/response_data.rb', line 1116

class BodyTypeMultipart < Struct.new(:media_type, :subtype,
:parts,
:param, :disposition, :language,
:location,
:extension)

#partsarray of BodyStructure objects (rw)

Returns an array with a BodyStructure object for each part contained in this part.

[ GitHub ]

  
# File 'lib/net/imap/response_data.rb', line 1116

class BodyTypeMultipart < Struct.new(:media_type, :subtype,
:parts,
:param, :disposition, :language,
:location,
:extension)

#subtypeString (rw)

Returns the content subtype name as defined in [MIME-IMB].

[ GitHub ]

  
# File 'lib/net/imap/response_data.rb', line 1116

class BodyTypeMultipart < Struct.new(:media_type, :subtype,
:parts,
:param, :disposition, :language,
:location,
:extension)

Instance Method Details

#media_subtype

Obsolete: use #subtype instead. Calling this will generate a warning message to stderr, then return the value of #subtype.

[ GitHub ]

  
# File 'lib/net/imap/response_data.rb', line 1184

def media_subtype
  warn("media_subtype is obsolete, use subtype instead.\n",
       uplevel: 1, category: :deprecated)
  return subtype
end