Package net.dv8tion.jda.api.managers
Interface EmoteManager
-
- All Superinterfaces:
AuditableRestAction<java.lang.Void>,Manager<EmoteManager>,RestAction<java.lang.Void>
public interface EmoteManager extends Manager<EmoteManager>
Manager providing functionality to update one or more fields for anEmote.Example
manager.setName("minn") .setRoles(null) .queue(); manager.reset(EmoteManager.NAME | EmoteManager.ROLES) .setName("dv8") .setRoles(roles) .queue();- See Also:
Emote.getManager()
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description EmotegetEmote()The targetEmotethat will be modified by this Managerdefault GuildgetGuild()EmoteManagerreset(long fields)Resets the fields specified by the provided bit-flag pattern.EmoteManagerreset(long... fields)Resets the fields specified by the provided bit-flag pattern.EmoteManagersetName(java.lang.String name)Sets the name of the selectedEmote.EmoteManagersetRoles(java.util.Set<Role> roles)Sets the restriction roles of the selectedEmote.-
Methods inherited from interface net.dv8tion.jda.api.requests.restaction.AuditableRestAction
reason
-
Methods inherited from interface net.dv8tion.jda.api.managers.Manager
deadline, reset, setCheck, timeout
-
Methods inherited from interface net.dv8tion.jda.api.requests.RestAction
addCheck, and, and, complete, complete, completeAfter, delay, delay, delay, delay, flatMap, flatMap, getCheck, getJDA, map, mapToResult, onErrorFlatMap, onErrorFlatMap, onErrorMap, onErrorMap, queue, queue, queue, queueAfter, queueAfter, queueAfter, queueAfter, queueAfter, queueAfter, submit, submit, submitAfter, submitAfter, zip
-
-
-
-
Field Detail
-
NAME
static final long NAME
Used to reset the name field- See Also:
- Constant Field Values
-
ROLES
static final long ROLES
Used to reset the roles field- See Also:
- Constant Field Values
-
-
Method Detail
-
reset
@Nonnull EmoteManager reset(long fields)
Resets the fields specified by the provided bit-flag pattern. You can specify a combination by using a bitwise OR concat of the flag constants.
Example:manager.reset(EmoteManager.NAME | EmoteManager.ROLES);Flag Constants:
- Specified by:
resetin interfaceManager<EmoteManager>- Parameters:
fields- Integer value containing the flags to reset.- Returns:
- EmoteManager for chaining convenience
-
reset
@Nonnull EmoteManager reset(long... fields)
Resets the fields specified by the provided bit-flag pattern. You can specify a combination by using a bitwise OR concat of the flag constants.
Example:manager.reset(EmoteManager.NAME, EmoteManager.ROLES);Flag Constants:
- Specified by:
resetin interfaceManager<EmoteManager>- Parameters:
fields- Integer values containing the flags to reset.- Returns:
- EmoteManager for chaining convenience
-
getEmote
@Nonnull Emote getEmote()
The targetEmotethat will be modified by this Manager- Returns:
- The target Emote
-
setName
@Nonnull @CheckReturnValue EmoteManager setName(@Nonnull java.lang.String name)
Sets the name of the selectedEmote.An emote name must be between 2-32 characters long!
Emote names may only be populated with alphanumeric (with underscore and dash).Example:
tatDaborfmgSUP- Parameters:
name- The new name for the selectedEmote- Returns:
- EmoteManager for chaining convenience
- Throws:
java.lang.IllegalArgumentException- If the provided name isnullor not between 2-32 characters long
-
setRoles
@Nonnull @CheckReturnValue EmoteManager setRoles(@Nullable java.util.Set<Role> roles)
Sets the restriction roles of the selectedEmote.
If these are empty the Emote will be available to everyone otherwise only available to the specified roles.An emote's restriction roles must not contain
null!
-
-