GuildImpl

class GuildImpl(val yde: YDE, val json: JsonNode, val idAsLong: Long) : Guild(source)

Constructors

Link copied to clipboard
constructor(yde: YDE, json: JsonNode, idAsLong: Long)

Functions

Link copied to clipboard
open fun banMember(member: Member, deleteMessageDuration: Duration = Duration.ZERO, reason: String? = null): CompletableDeferred<NoResult>

Bans a member from the guild.

Link copied to clipboard
open fun banUser(userId: Long, reason: String? = null): CompletableDeferred<NoResult>
open fun banUser(userId: String, reason: String? = null): CompletableDeferred<NoResult>
open fun banUser(user: User, deleteMessageDuration: Duration = Duration.ZERO, reason: String? = null): CompletableDeferred<NoResult>
open fun banUser(userId: Long, deleteMessageDuration: Duration = Duration.ZERO, reason: String? = null): CompletableDeferred<NoResult>
open fun banUser(userId: String, deleteMessageDuration: Duration = Duration.ZERO, reason: String? = null): CompletableDeferred<NoResult>

Bans a user from the guild.

Link copied to clipboard
open fun createDmChannel(user: User): CompletableDeferred<DmChannel>
open fun createDmChannel(userId: String): CompletableDeferred<DmChannel>

Creates a dm channel.

open fun createDmChannel(userId: Long): CompletableDeferred<DmChannel>

Creates a dm channel..

Link copied to clipboard
open fun format(format: String): String

Formats the name of the entity

Link copied to clipboard
open override fun formatTo(formatter: Formatter?, flags: Int, width: Int, precision: Int)

Formats the object using the provided {@link Formatter formatter}.

Link copied to clipboard
open fun getChannelById(channelId: String): GuildChannel?
open override fun getChannelById(channelId: Long): GuildChannel?

The channel by its id.

Link copied to clipboard

The channel getter by its id.

Link copied to clipboard
open fun getMemberById(userId: Long): Member?
open fun getMemberById(userId: String): Member?

The member by its user id.

Link copied to clipboard
open fun getRoleById(roleId: String): Role?
open override fun getRoleById(roleId: Long): Role?

Gets a role from the guild.

Link copied to clipboard
open fun kickMember(member: Member, reason: String? = null): CompletableDeferred<NoResult>
open fun kickMember(userId: Long, reason: String? = null): CompletableDeferred<NoResult>
open fun kickMember(userId: String, reason: String? = null): CompletableDeferred<NoResult>

Kicks a member from the guild.

Link copied to clipboard
open fun requestedAuditLog(): CompletableDeferred<AuditLog>
open fun requestedAuditLog(user: User): CompletableDeferred<AuditLog>
open fun requestedAuditLog(userId: GetterSnowFlake): CompletableDeferred<AuditLog>
open fun requestedAuditLog(user: User, limit: Int): CompletableDeferred<AuditLog>
open fun requestedAuditLog(userId: GetterSnowFlake, limit: Int): CompletableDeferred<AuditLog>
open fun requestedAuditLog(user: User, limit: Int, before: GetterSnowFlake): CompletableDeferred<AuditLog>
open fun requestedAuditLog(userId: GetterSnowFlake, limit: Int, before: GetterSnowFlake): CompletableDeferred<AuditLog>
open fun requestedAuditLog(user: User? = null, limit: Int = 50, before: GetterSnowFlake? = null, actionType: AuditLogType? = null): CompletableDeferred<AuditLog>
open fun requestedAuditLog(userId: GetterSnowFlake? = null, limit: Int = 50, before: GetterSnowFlake? = null, actionType: AuditLogType? = null): CompletableDeferred<AuditLog>

Request the audit log for the guild.

Link copied to clipboard
open fun retrieveMembers(limit: Int): CompletableDeferred<List<Member>>

Gets all the members of the guild.

Link copied to clipboard
open override fun toString(): String

Converts this entity to a string using the io.github.ydwk.ydwk.util.EntityToStringBuilder.

Link copied to clipboard
open fun unbanUser(user: User, reason: String? = null): CompletableDeferred<NoResult>
open fun unbanUser(userId: Long, reason: String? = null): CompletableDeferred<NoResult>
open fun unbanUser(userId: String, reason: String? = null): CompletableDeferred<NoResult>

Unbans a user from the guild.

Properties

Link copied to clipboard
open override var afkChannelId: GetterSnowFlake?

The guild's afk channel id.

Link copied to clipboard
open override var afkTimeout: Int

The guild's afk timeout.

Link copied to clipboard
open override var applicationId: GetterSnowFlake?

The guild's application id.

Link copied to clipboard
open override var approximateMemberCount: Int?

The approximate member count for the guild.

Link copied to clipboard
open override var approximatePresenceCount: Int?

The approximate presence count for the guild.

Link copied to clipboard
open val asIncrement: Long

The increment of this snowflake.

Link copied to clipboard
open val asProcessId: Long

The process id of this snowflake.

Link copied to clipboard
open val asTimestamp: Long

The timestamp of this snowflake. (Milliseconds since Discord Epoch, the first second of 2015 or 1420070400000.)

Link copied to clipboard
open val asWorkerId: Long

The worker id of this snowflake.

Link copied to clipboard
open override var banner: String?

The banner hash for the guild.

Link copied to clipboard
open override val botAsMember: Member

The bot as a member of the guild.

Link copied to clipboard

The guild's default message notification level.

Link copied to clipboard
open override var description: String?

The description for the guild.

Link copied to clipboard
open override var discoverySplash: String?

The guild's discovery splash hash.

Link copied to clipboard
open override var emojis: List<Emoji>

The guild's emojis.

Link copied to clipboard
open val everyoneRole: Role

The @everyone role. This role is always present.

Link copied to clipboard

The guild's explicit content filter level.

Link copied to clipboard
open override var features: Set<GuildFeature>

The guild's features.

Link copied to clipboard

Gets all the categories as sorted list.

Link copied to clipboard

Gets all the channels as sorted list.

Link copied to clipboard

Gets all the text channels as sorted list.

Link copied to clipboard

Gets all the channels as unordered list.

Link copied to clipboard

Gets all the voice channels as sorted list.

Link copied to clipboard
open override var icon: String?

The guild's icon hash.

Link copied to clipboard
open val id: String

The id of this snowflake as a String.

Link copied to clipboard
open override val idAsLong: Long

The id of this snowflake as a Long.

Link copied to clipboard

Gets weather the guild has the boost progress bar enabled.

Link copied to clipboard
open override var isOwner: Boolean?

Checks if this is user is owner of the guild.

Link copied to clipboard
open override var isWidgetEnabled: Boolean?

Checks if the guild's widget is enabled.

Link copied to clipboard
open override val json: JsonNode

The json representation of this entity.

Link copied to clipboard
open override var maxMembers: Int

The maximum number of members for the guild.

Link copied to clipboard
open override var maxPresences: Int?

The maximum number of presences for the guild (null is always returned, apart from the largest of guilds).

Link copied to clipboard
open override var maxVideoChannelUsers: Int?

The maximum amount of users in a video channel.

Link copied to clipboard
open override var mfaLevel: MFALevel

The guild's mfa level.

Link copied to clipboard
open override var name: String
Link copied to clipboard
open override var nsfwLevel: NSFWLeveL

The guild's nsfw level.

Link copied to clipboard
open override var ownerId: GetterSnowFlake

The guild's owner id.

Link copied to clipboard
open override var permissions: String?

The guild's permissions.

Link copied to clipboard
open override var preferredLocale: String

The preferred locale for the guild.

Link copied to clipboard
open override var premiumSubscriptionCount: Int

The premium subscription count for the guild.

Link copied to clipboard
open override var premiumTier: PremiumTier

The premium tier for the guild.

Link copied to clipboard

The public updates channel id for the guild.

Link copied to clipboard
open val requestBans: CompletableDeferred<List<Ban>>

Requests a list of ban's for the guild.

Link copied to clipboard
open val retrieveMembers: CompletableDeferred<List<Member>>

Gets all the members of the guild.

Link copied to clipboard
open override var roles: List<Role>

The guild's roles.

Link copied to clipboard
open override var rulesChannelId: GetterSnowFlake?

The guild's rules channel id.

Link copied to clipboard
open override var splash: String?

The guild's splash hash.

Link copied to clipboard
open override var stickers: List<Sticker>

The guild's custom stickers.

Link copied to clipboard

The guild's system channel flags.

Link copied to clipboard
open override var systemChannelId: GetterSnowFlake?

The guild's system channel id.

Link copied to clipboard
open override var vanityUrlCode: String?

The vanity url code for the guild.

Link copied to clipboard

The guild's verification level.

Link copied to clipboard
open override val voiceStates: List<VoiceState>

All the current voice states for the guild.

Link copied to clipboard
open override var welcomeScreen: WelcomeScreen?

The welcome screen of the guild.

Link copied to clipboard
open override var widgetChannelId: GetterSnowFlake?

The guild's widget channel id.

Link copied to clipboard
open override val yde: YDE

The main YDE instance.