Package discord4j.core.object.command
Class ResolvedChannel
java.lang.Object
discord4j.core.object.command.ResolvedChannel
- All Implemented Interfaces:
DiscordObject
A Discord channel that was resolved in a command.
-
Constructor Summary
ConstructorDescriptionResolvedChannel
(GatewayDiscordClient gateway, discord4j.discordjson.json.ResolvedChannelData data) Constructs aResolvedChannel
with an associatedGatewayDiscordClient
and Discord data. -
Method Summary
Modifier and TypeMethodDescriptionRetrieves the fullChannel
instance corresponding to this resolved channel.asFullChannel
(EntityRetrievalStrategy retrievalStrategy) Retrieves the fullChannel
instance corresponding to this resolved channel, using the given retrieval strategy.Returns theGatewayDiscordClient
that created this object.discord4j.discordjson.json.ResolvedChannelData
getData()
Returns the raw data as represented by Discord.Gets the computed permissions for the invoking user in the channel, including overwrites.getId()
Gets the id of the channel.getName()
Gets the name of the channel.getType()
Gets the type of the channel.toString()
-
Constructor Details
-
ResolvedChannel
public ResolvedChannel(GatewayDiscordClient gateway, discord4j.discordjson.json.ResolvedChannelData data) Constructs aResolvedChannel
with an associatedGatewayDiscordClient
and Discord data.- Parameters:
gateway
- TheGatewayDiscordClient
associated to this object, must be non-null.data
- The raw data as represented by Discord, must be non-null.
-
-
Method Details
-
getData
public discord4j.discordjson.json.ResolvedChannelData getData()Returns the raw data as represented by Discord.- Returns:
- the raw data
-
getId
Gets the id of the channel.- Returns:
- The id of the channel.
-
getName
Gets the name of the channel.- Returns:
- The name of the channel.
-
getType
Gets the type of the channel.- Returns:
- The type of the channel.
-
getEffectivePermissions
Gets the computed permissions for the invoking user in the channel, including overwrites.- Returns:
- The permissions of the channel.
-
asFullChannel
Retrieves the fullChannel
instance corresponding to this resolved channel. -
asFullChannel
Retrieves the fullChannel
instance corresponding to this resolved channel, using the given retrieval strategy. -
getClient
Description copied from interface:DiscordObject
Returns theGatewayDiscordClient
that created this object. Methods in it are exclusively based on the entity cache orStore
in use. Refer to callinggetClient().rest()
to access aDiscordClient
that is capable of requesting entities directly from the REST API.- Specified by:
getClient
in interfaceDiscordObject
- Returns:
- The
GatewayDiscordClient
associated to this object.
-
toString
-