Class: Rubirai::FlashImageMessage

Inherits:
Message
  • Object
show all
Defined in:
lib/rubirai/messages/message.rb

Overview

The flash image message type

Instance Attribute Summary collapse

Attributes inherited from Message

#bot, #type

Class Method Summary collapse

Methods inherited from Message

all_types, check_type, #to_h, to_message

Instance Attribute Details

#image_idString? (readonly)

Returns the image id from mirai.

Returns:

  • (String, nil)

    the image id from mirai



350
# File 'lib/rubirai/messages/message.rb', line 350

set_message :FlashImage, :image_id, :url, :path

#pathString? (readonly)

Returns the local path of the image.

Returns:

  • (String, nil)

    the local path of the image



350
# File 'lib/rubirai/messages/message.rb', line 350

set_message :FlashImage, :image_id, :url, :path

#urlString? (readonly)

Returns the url of the image.

Returns:

  • (String, nil)

    the url of the image



350
# File 'lib/rubirai/messages/message.rb', line 350

set_message :FlashImage, :image_id, :url, :path

Class Method Details

.from(**kwargs) ⇒ Rubirai::FlashImageMessage

Form a Rubirai::FlashImageMessage. Only needs to give one of the three arguments.

Options Hash (**kwargs):

  • :image_id (String)

    the image id

  • :url (String)

    the url of the image

  • :path (String)

    the local path of the image

Returns:



350
# File 'lib/rubirai/messages/message.rb', line 350

set_message :FlashImage, :image_id, :url, :path