Class SelfUpdateAvatarEvent
java.lang.Object
net.dv8tion.jda.api.events.Event
net.dv8tion.jda.api.events.self.GenericSelfUpdateEvent<String>
net.dv8tion.jda.api.events.self.SelfUpdateAvatarEvent
- All Implemented Interfaces:
GenericEvent, UpdateEvent<SelfUser,String>
Indicates that the avatar of the current user changed.
Can be used to retrieve the old avatar.
Identifier: avatar
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns anImageProxyfor this bot's new avatar image.getNewAvatar(ImageFormat format) Returns anImageProxyfor this bot's new avatar image.The new avatar idThe new avatar urlgetNewAvatarUrl(ImageFormat format) The new avatar urlReturns anImageProxyfor this bot's new avatar image.getOldAvatar(ImageFormat format) Returns anImageProxyfor this bot's new avatar image.The old avatar idThe old avatar urlgetOldAvatarUrl(ImageFormat format) The old avatar urlMethods inherited from class GenericSelfUpdateEvent
getEntity, getNewValue, getOldValue, getPropertyIdentifier, getSelfUserMethods inherited from class Event
getJDA, getRawData, getResponseNumber, toStringMethods inherited from interface GenericEvent
getJDA, getRawData, getResponseNumberMethods inherited from interface UpdateEvent
getEntityType
-
Field Details
-
IDENTIFIER
- See Also:
-
-
Constructor Details
-
SelfUpdateAvatarEvent
-
-
Method Details
-
getOldAvatarId
-
getOldAvatarUrl
-
getOldAvatarUrl
The old avatar url- Parameters:
format- The format in which the image should be- Returns:
- The old avatar url
- Throws:
IllegalArgumentException- If the format isnull- See Also:
-
getOldAvatar
Returns anImageProxyfor this bot's new avatar image.Note: the old avatar may not always be downloadable as it might have been removed from Discord.
- Returns:
- Possibly-null
ImageProxyof this bot's new avatar image - See Also:
-
getOldAvatar
Returns anImageProxyfor this bot's new avatar image.Note: the old avatar may not always be downloadable as it might have been removed from Discord.
- Parameters:
format- The format in which the image should be- Returns:
- Possibly-null
ImageProxyof this bot's new avatar image - Throws:
IllegalArgumentException- If the format isnull- See Also:
-
getNewAvatarId
-
getNewAvatarUrl
-
getNewAvatarUrl
The new avatar url- Parameters:
format- The format in which the image should be- Returns:
- The new avatar url
- Throws:
IllegalArgumentException- If the format isnull- See Also:
-
getNewAvatar
Returns anImageProxyfor this bot's new avatar image.- Returns:
- Possibly-null
ImageProxyof this bot's new avatar image - See Also:
-
getNewAvatar
Returns anImageProxyfor this bot's new avatar image.- Parameters:
format- The format in which the image should be- Returns:
- Possibly-null
ImageProxyof this bot's new avatar image - Throws:
IllegalArgumentException- If the format isnull- See Also:
-