Package-level declarations

Types

Link copied to clipboard
@KordPreview
abstract class AbstractLiveKordEntity(val kord: Kord, coroutineScope: CoroutineScope = kord + SupervisorJob(kord.coroutineContext.job)) : LiveKordEntity, CoroutineScope
Link copied to clipboard
@KordPreview
class LiveGuild(guild: Guild, coroutineScope: CoroutineScope = guild.kord + SupervisorJob(guild.kord.coroutineContext.job)) : AbstractLiveKordEntity, KordEntity
Link copied to clipboard
@KordPreview
interface LiveKordEntity : KordEntity, CoroutineScope

A Discord entity that only emits events related to this entity.

Link copied to clipboard
@KordPreview
class LiveMember(member: Member, coroutineScope: CoroutineScope = member.kord + SupervisorJob(member.kord.coroutineContext.job)) : AbstractLiveKordEntity, KordEntity
Link copied to clipboard
@KordPreview
class LiveMessage(message: Message, val guildId: Snowflake?, coroutineScope: CoroutineScope = message.kord + SupervisorJob(message.kord.coroutineContext.job)) : AbstractLiveKordEntity, KordEntity
Link copied to clipboard
@KordPreview
class LiveRole(role: Role, coroutineScope: CoroutineScope = role.kord + SupervisorJob(role.kord.coroutineContext.job)) : AbstractLiveKordEntity, KordEntity
Link copied to clipboard
@KordPreview
class LiveUser(user: User, coroutineScope: CoroutineScope = user.kord + SupervisorJob(user.kord.coroutineContext.job)) : AbstractLiveKordEntity, KordEntity

Functions

Link copied to clipboard
@KordPreview
fun Guild.live(coroutineScope: CoroutineScope = kord + SupervisorJob(kord.coroutineContext.job)): LiveGuild
@KordPreview
fun Member.live(coroutineScope: CoroutineScope = kord + SupervisorJob(kord.coroutineContext.job)): LiveMember
@KordPreview
suspend fun Message.live(coroutineScope: CoroutineScope = kord + SupervisorJob(kord.coroutineContext.job)): LiveMessage
@KordPreview
fun Role.live(coroutineScope: CoroutineScope = kord + SupervisorJob(kord.coroutineContext.job)): LiveRole
@KordPreview
fun User.live(coroutineScope: CoroutineScope = kord + SupervisorJob(kord.coroutineContext.job)): LiveUser
@KordPreview
inline fun Guild.live(coroutineScope: CoroutineScope = kord + SupervisorJob(kord.coroutineContext.job), block: LiveGuild.() -> Unit): LiveGuild
@KordPreview
inline fun Member.live(coroutineScope: CoroutineScope = kord + SupervisorJob(kord.coroutineContext.job), block: LiveMember.() -> Unit): LiveMember
@KordPreview
suspend fun Message.live(coroutineScope: CoroutineScope = kord + SupervisorJob(kord.coroutineContext.job), block: LiveMessage.() -> Unit): LiveMessage
@KordPreview
inline fun Role.live(coroutineScope: CoroutineScope = kord + SupervisorJob(kord.coroutineContext.job), block: LiveRole.() -> Unit): LiveRole
@KordPreview
inline fun User.live(coroutineScope: CoroutineScope = kord + SupervisorJob(kord.coroutineContext.job), block: LiveUser.() -> Unit): LiveUser
Link copied to clipboard
@KordPreview
inline fun <T : Event> LiveKordEntity.on(scope: CoroutineScope = this, noinline consumer: suspend (T) -> Unit): Job

Convenience method that will invoke the consumer on every event T, the consumer is launched in the given scope or Kord by default and will not propagate any exceptions.

Link copied to clipboard
@KordPreview
fun LiveGuild.onBanAdd(scope: CoroutineScope = this, block: suspend (BanAddEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onBanRemove(scope: CoroutineScope = this, block: suspend (BanRemoveEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onChannelCreate(scope: CoroutineScope = this, block: suspend (ChannelCreateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onChannelDelete(scope: CoroutineScope = this, block: suspend (ChannelDeleteEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onChannelUpdate(scope: CoroutineScope = this, block: suspend (ChannelUpdateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onEmojisUpdate(scope: CoroutineScope = this, block: suspend (EmojisUpdateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onGuildCreate(scope: CoroutineScope = this, block: suspend (GuildCreateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onGuildUpdate(scope: CoroutineScope = this, block: suspend (GuildUpdateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onIntegrationsUpdate(scope: CoroutineScope = this, block: suspend (IntegrationsUpdateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onMemberJoin(scope: CoroutineScope = this, block: suspend (MemberJoinEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onMemberLeave(scope: CoroutineScope = this, block: suspend (MemberLeaveEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onMemberUpdate(scope: CoroutineScope = this, block: suspend (MemberUpdateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onMessageCreate(scope: CoroutineScope = this, block: suspend (MessageCreateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onMessageDelete(scope: CoroutineScope = this, block: suspend (MessageDeleteEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onMessageUpdate(scope: CoroutineScope = this, block: suspend (MessageUpdateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onPresenceUpdate(scope: CoroutineScope = this, block: suspend (PresenceUpdateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onReactionAdd(scope: CoroutineScope = this, block: suspend (ReactionAddEvent) -> Unit): Job
@KordPreview
fun LiveMessage.onReactionAdd(scope: CoroutineScope = this, block: suspend (ReactionAddEvent) -> Unit): Job
@KordPreview
inline fun LiveGuild.onReactionAdd(reaction: ReactionEmoji, scope: CoroutineScope = this, crossinline block: suspend (ReactionAddEvent) -> Unit): Job
@KordPreview
inline fun LiveMessage.onReactionAdd(reaction: ReactionEmoji, scope: CoroutineScope = this, crossinline block: suspend (ReactionAddEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onReactionRemove(scope: CoroutineScope = this, block: suspend (ReactionRemoveEvent) -> Unit): Job
@KordPreview
fun LiveMessage.onReactionRemove(scope: CoroutineScope = this, block: suspend (ReactionRemoveEvent) -> Unit): Job
@KordPreview
inline fun LiveGuild.onReactionRemove(reaction: ReactionEmoji, scope: CoroutineScope = this, crossinline block: suspend (ReactionRemoveEvent) -> Unit): Job
@KordPreview
inline fun LiveMessage.onReactionRemove(reaction: ReactionEmoji, scope: CoroutineScope = this, crossinline block: suspend (ReactionRemoveEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onReactionRemoveAll(scope: CoroutineScope = this, block: suspend (ReactionRemoveAllEvent) -> Unit): Job
@KordPreview
fun LiveMessage.onReactionRemoveAll(scope: CoroutineScope = this, block: suspend (ReactionRemoveAllEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onRoleCreate(scope: CoroutineScope = this, block: suspend (RoleCreateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onRoleDelete(scope: CoroutineScope = this, block: suspend (RoleDeleteEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onRoleUpdate(scope: CoroutineScope = this, block: suspend (RoleUpdateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveMember.onUpdate(scope: CoroutineScope = this, block: suspend (MemberUpdateEvent) -> Unit): Job
@KordPreview
fun LiveMessage.onUpdate(scope: CoroutineScope = this, block: suspend (MessageUpdateEvent) -> Unit): Job
@KordPreview
fun LiveRole.onUpdate(scope: CoroutineScope = this, block: suspend (RoleUpdateEvent) -> Unit): Job
@KordPreview
fun LiveUser.onUpdate(scope: CoroutineScope = this, block: suspend (UserUpdateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onVoiceServerUpdate(scope: CoroutineScope = this, block: suspend (VoiceServerUpdateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onVoiceStateUpdate(scope: CoroutineScope = this, block: suspend (VoiceStateUpdateEvent) -> Unit): Job
Link copied to clipboard
@KordPreview
fun LiveGuild.onWebhookUpdate(scope: CoroutineScope = this, block: suspend (WebhookUpdateEvent) -> Unit): Job