public class ApplicationManager
extends java.lang.Object
ApplicationManagerUpdatable instance.
This decoration allows to modify a single field by automatically building an update RestAction
| Constructor and Description |
|---|
ApplicationManager(net.dv8tion.jda.client.entities.impl.ApplicationImpl application) |
| Modifier and Type | Method and Description |
|---|---|
Application |
getApplication()
The
Application that will
be modified by this Manager instance |
JDA |
getJDA()
The
JDA instance of this Manager |
RestAction<java.lang.Void> |
setDescription(java.lang.String description)
Sets the description of the selected
Application. |
RestAction<java.lang.Void> |
setDoesBotRequireCodeGrant(boolean requireCodeGrant)
Sets the code grant state of the selected
Application's bot. |
RestAction<java.lang.Void> |
setIcon(Icon icon)
Sets the icon of the selected
Application. |
RestAction<java.lang.Void> |
setIsBotPublic(boolean botPublic)
Sets the public state of the selected
Application's bot. |
RestAction<java.lang.Void> |
setName(java.lang.String name)
Sets the name of the selected
Application. |
RestAction<java.lang.Void> |
setRedirectUris(java.util.List<java.lang.String> redirectUris)
Sets the redirect uris of the selected
Application. |
public ApplicationManager(net.dv8tion.jda.client.entities.impl.ApplicationImpl application)
public Application getApplication()
Application that will
be modified by this Manager instanceApplication@CheckReturnValue public RestAction<java.lang.Void> setDescription(java.lang.String description)
Application.
ApplicationManagerUpdatable#getDescriptionField().
A description must not be than 400 characters long!
description - The new description for the selected ApplicationRestAction
#update()java.lang.IllegalArgumentException - If the provided description is more than 400 characters longApplicationManagerUpdatable.getDescriptionField(),
ApplicationManagerUpdatable.update()@CheckReturnValue public RestAction<java.lang.Void> setDoesBotRequireCodeGrant(boolean requireCodeGrant)
Application's bot.
ApplicationManagerUpdatable#getDoesBotRequireCodeGrantField().requireCodeGrant - The new state for the selected Application's botRestAction
#update()ApplicationManagerUpdatable.getDoesBotRequireCodeGrantField(),
ApplicationManagerUpdatable.update()@CheckReturnValue public RestAction<java.lang.Void> setIcon(Icon icon)
icon - The new Icon
for the selected ApplicationRestAction
#update()ApplicationManagerUpdatable.getIconField(),
ApplicationManagerUpdatable.update()@CheckReturnValue public RestAction<java.lang.Void> setIsBotPublic(boolean botPublic)
Application's bot.
ApplicationManagerUpdatable#getIsBotPublicField().botPublic - The new state for the selected Application's botRestAction
#update()ApplicationManagerUpdatable.getIsBotPublicField(),
ApplicationManagerUpdatable.update()@CheckReturnValue public RestAction<java.lang.Void> setName(java.lang.String name)
Application.
ApplicationManagerUpdatable#getNameField().
A name must not be null nor less than 2 characters or more than 32 characters long!
name - The new name for the selected ApplicationRestAction
#update()java.lang.IllegalArgumentException - If the provided name is null, less than 2 or more than 32 characters longApplicationManagerUpdatable.getNameField(),
ApplicationManagerUpdatable.update()@CheckReturnValue public RestAction<java.lang.Void> setRedirectUris(java.util.List<java.lang.String> redirectUris)
Application.
ApplicationManagerUpdatable#getRedirectUrisField().
The List as well as all redirect uris must not be null!
redirectUris - The new redirect uris
for the selected ApplicationRestAction
#update()java.lang.IllegalArgumentException - If either the provided List or one of the uris is nullApplicationManagerUpdatable.getIconField(),
ApplicationManagerUpdatable.update()