ChannelSubCommand

abstract class ChannelSubCommand(plugin: LunaticChat, channelManager: ChannelManager, membershipManager: ChannelMembershipManager) : LunaticSubCommand(source)

A subcommand of /lc channel.

The moderation subcommands all open with the same sequence - resolve the sender's active channel, check their role, resolve the named target - once written out in full in each of them. These helpers name each step, and derive their message keys from literal so a subcommand cannot accidentally report another one's text.

Inheritors

Constructors

Link copied to clipboard
constructor(plugin: LunaticChat, channelManager: ChannelManager, membershipManager: ChannelMembershipManager)

Properties

Link copied to clipboard
abstract val literal: String

The literal this subcommand is typed as. Parents use it to look up help text, so it must be the same string build passes to Commands.literal.

Functions

Link copied to clipboard
abstract fun build(): LiteralArgumentBuilder<CommandSourceStack>

Builds the primary subcommand node, without the permission gate.

Link copied to clipboard
fun buildAll(): List<LiteralArgumentBuilder<CommandSourceStack>>

Builds the primary node and its aliases, each gated on permissionNode.