class Net::IMAP::BodyTypeBasic - net-imap: Ruby Standard Library Documentation

# class Net::IMAP::BodyTypeBasic

`Net::IMAP::BodyTypeBasic` represents basic body structures of messages and message parts, unless they have a `Content-Type` that is handled by `BodyTypeText`, `BodyTypeMessage`, or `BodyTypeMultipart`.

See [IMAP4rev1] §7.4.2 and [IMAP4rev2] §7.5.2 for full description of all `BODYSTRUCTURE` fields, and also Message envelope and body structure at `Net::IMAP` for other relevant RFCs.

### Public Instance Methods

content_id → string click to toggle source

Returns a string giving the content id as defined in [MIME-IMB] §7.

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 857

description → string click to toggle source

Returns a string giving the content description as defined in [MIME-IMB] §8.

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 865

disposition → ContentDisposition click to toggle source

Returns a `ContentDisposition` object giving the content disposition, as defined by [DISPOSITION].

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 894

encoding → string click to toggle source

Returns a string giving the content transfer encoding as defined in [MIME-IMB] §6.

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 873

extension → string click to toggle source

Returns extension data. The `BODYSTRUCTURE` fetch attribute contains extension data, but `BODY` does not.

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 919

language → string click to toggle source

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

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 902

md5 → string click to toggle source

Returns a string giving the body MD5 value as defined in [MD5].

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 887

media_subtype → subtype click to toggle source

> Obsolete

>   Use `subtype` instead. Calling this will generate a warning message to `stderr`, then return the value of `subtype`.

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 943
    def media_subtype
      warn("media_subtype is obsolete, use subtype instead.\n",
           uplevel: 1, category: :deprecated)
      return subtype
    end

media_type → string click to toggle source

The top-level media type as defined in [MIME-IMB].

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 836

multipart? → false click to toggle source

`BodyTypeBasic` is not used for multipart MIME parts.

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 929
    def multipart?
      return false
    end

param → string click to toggle source

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

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 850

size → integer click to toggle source

Returns a number giving the size of the body in octets.

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 881

subtype → string click to toggle source

The media subtype name as defined in [MIME-IMB].

    # File net-imap-0.5.4/lib/net/imap/response_data.rb, line 843