Interface WebhookBuilderDelegate
-
public interface WebhookBuilderDelegateThis class is internally used by theWebhookBuilderto create webhooks. You usually don't want to interact with this object.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description CompletableFuture<Webhook>create()Creates the webhook.voidsetAuditLogReason(String reason)Sets the reason for this update.voidsetAvatar(byte[] avatar)Sets the avatar.voidsetAvatar(byte[] avatar, String fileType)Sets the avatar.voidsetAvatar(BufferedImage avatar)Sets the avatar.voidsetAvatar(BufferedImage avatar, String fileType)Sets the avatar.voidsetAvatar(File avatar)Sets the avatar.voidsetAvatar(InputStream avatar)Sets the avatar.voidsetAvatar(InputStream avatar, String fileType)Sets the avatar.voidsetAvatar(URL avatar)Sets the avatar.voidsetAvatar(Icon avatar)Sets the avatar.voidsetName(String name)Sets the name.
-
-
-
Method Detail
-
setAuditLogReason
void setAuditLogReason(String reason)
Sets the reason for this update. This reason will be visible in the audit log entry(s).- Parameters:
reason- The reason for this update.
-
setName
void setName(String name)
Sets the name.- Parameters:
name- The new name of the webhook.
-
setAvatar
void setAvatar(BufferedImage avatar)
Sets the avatar. This method assumes the file type is "png"!- Parameters:
avatar- The avatar to set.
-
setAvatar
void setAvatar(BufferedImage avatar, String fileType)
Sets the avatar.- Parameters:
avatar- The avatar to set.fileType- The type of the avatar, e.g. "png" or "jpg".
-
setAvatar
void setAvatar(File avatar)
Sets the avatar.- Parameters:
avatar- The avatar to set.
-
setAvatar
void setAvatar(Icon avatar)
Sets the avatar.- Parameters:
avatar- The avatar to set.
-
setAvatar
void setAvatar(URL avatar)
Sets the avatar.- Parameters:
avatar- The avatar to set.
-
setAvatar
void setAvatar(byte[] avatar)
Sets the avatar. This method assumes the file type is "png"!- Parameters:
avatar- The avatar to set.
-
setAvatar
void setAvatar(byte[] avatar, String fileType)Sets the avatar.- Parameters:
avatar- The avatar to set.fileType- The type of the avatar, e.g. "png" or "jpg".
-
setAvatar
void setAvatar(InputStream avatar)
Sets the avatar. This method assumes the file type is "png"!- Parameters:
avatar- The avatar to set.
-
setAvatar
void setAvatar(InputStream avatar, String fileType)
Sets the avatar.- Parameters:
avatar- The avatar to set.fileType- The type of the avatar, e.g. "png" or "jpg".
-
create
CompletableFuture<Webhook> create()
Creates the webhook.- Returns:
- The created webhook.
-
-