Sha256: d6561133fd8e4356fabc467f45a10e578a861c542646b9f171e4c81af912fc44

Contents?: true

Size: 1.25 KB

Versions: 2

Compression:

Stored size: 1.25 KB

Contents

module Discorb
  #
  # Represents a voice channel.
  class VoiceChannel < Discorb::GuildChannel
    include Discorb::Connectable
    include Discorb::Messageable

    #
    # Edit the voice channel.
    # @async
    # @macro edit
    #
    # @param [String] name The name of the voice channel.
    # @param [Integer] position The position of the voice channel.
    # @param [Integer] bitrate The bitrate of the voice channel.
    # @param [Integer] user_limit The user limit of the voice channel.
    # @param [Symbol] rtc_region The region of the voice channel.
    # @param [String] reason The reason of editing the voice channel.
    #
    # @return [Async::Task<self>] The edited voice channel.
    def edit: (
      ?name: String,
      ?position: Integer,
      ?bitrate: Integer,
      ?user_limit: Integer,
      ?rtc_region: Symbol,
      ?reason: String?
    ) -> Async::Task[self]

    def voice_states: -> Array[Discorb::VoiceState]

    def members: -> Array[Discorb::Member]

    # @return [Integer] The bitrate of the voice channel.
    attr_reader bitrate: Integer

    # @return [Integer] The user limit of the voice channel.
    # @return [nil] If the user limit is not set.
    attr_reader user_limit: Integer?
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
discorb-0.18.1 sig/discorb/channel/voice.rbs
discorb-0.18.0 sig/discorb/channel/voice.rbs