Package dev.sympho.bot_utils.event.reply
Class ReplyEditSpec
java.lang.Object
dev.sympho.bot_utils.event.reply.ReplyEditSpec
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
@CheckReturnValue
public final class ReplyEditSpec
extends Object
Specification for editing a previosly sent event reply.
- Since:
- 1.0
- Version:
- 1.0
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptiondiscord4j.discordjson.possible.Possible<Optional<discord4j.rest.util.AllowedMentions>>The new allowed mentions.discord4j.rest.util.AllowedMentionsallowedMentionsOrElse(discord4j.rest.util.AllowedMentions defaultValue) discord4j.discordjson.possible.Possible<Optional<List<Attachment>>>The new attachments.attachmentsOrElse(List<Attachment> defaultValue) static ReplyEditSpec.Builderbuilder()Creates a builder forReplyEditSpec.discord4j.discordjson.possible.Possible<Optional<List<LayoutComponent>>>The new message components.componentsOrElse(List<LayoutComponent> defaultValue) content()The new reply message content.contentOrElse(String defaultValue) discord4j.discordjson.possible.Possible<Optional<List<EmbedCreateSpec>>>embeds()The new reply embeds.embedsOrElse(List<EmbedCreateSpec> defaultValue) booleanThis instance is equal to all instances ofReplyEditSpecthat have equal attribute values.files()The new attached files.The new spoiler-tagged attached files.inthashCode()Computes a hash code from attributes:content,embeds,files,fileSpoilers,allowedMentions,components,attachments.booleanbooleanbooleanbooleanbooleandefault InteractionReplyEditSpecConverts this spec into an interaction reply edit spec.default MessageEditSpecConverts this spec into a message edit spec.toString()Prints the immutable valueReplyEditSpecwith attribute values.withAllowedMentions(discord4j.discordjson.possible.Possible<Optional<discord4j.rest.util.AllowedMentions>> value) withAllowedMentions(discord4j.rest.util.AllowedMentions value) Deprecated.withAllowedMentionsOrNull(discord4j.rest.util.AllowedMentions value) final ReplyEditSpecwithAttachments(Attachment... elements) withAttachments(discord4j.discordjson.possible.Possible<? extends Optional<? extends List<? extends Attachment>>> possible) withAttachments(Iterable<Attachment> elements) Deprecated.withAttachmentsOrNull(Iterable<? extends Attachment> elements) final ReplyEditSpecwithComponents(LayoutComponent... elements) withComponents(discord4j.discordjson.possible.Possible<? extends Optional<? extends List<? extends LayoutComponent>>> possible) withComponents(Iterable<LayoutComponent> elements) Deprecated.withComponentsOrNull(Iterable<? extends LayoutComponent> elements) withContent(discord4j.discordjson.possible.Possible<Optional<String>> value) withContent(String value) Deprecated.withContentOrNull(String value) final ReplyEditSpecwithEmbeds(EmbedCreateSpec... elements) withEmbeds(discord4j.discordjson.possible.Possible<? extends Optional<? extends List<? extends EmbedCreateSpec>>> possible) withEmbeds(Iterable<EmbedCreateSpec> elements) Deprecated.withEmbedsOrNull(Iterable<? extends EmbedCreateSpec> elements) withFiles(MessageCreateFields.File... elements) withFiles(Iterable<? extends MessageCreateFields.File> elements) withFileSpoilers(MessageCreateFields.FileSpoiler... elements) withFileSpoilers(Iterable<? extends MessageCreateFields.FileSpoiler> elements)
-
Method Details
-
content
The new reply message content.- Returns:
- The value.
-
embeds
The new reply embeds.- Returns:
- The value.
-
files
The new attached files.- Returns:
- The value.
-
fileSpoilers
The new spoiler-tagged attached files.- Returns:
- The value.
-
allowedMentions
public discord4j.discordjson.possible.Possible<Optional<discord4j.rest.util.AllowedMentions>> allowedMentions()The new allowed mentions.- Returns:
- The value.
-
components
The new message components.- Returns:
- The value.
-
attachments
The new attachments.- Returns:
- The value.
-
withContent
-
withContent
Deprecated. -
withContentOrNull
-
withEmbeds
public ReplyEditSpec withEmbeds(discord4j.discordjson.possible.Possible<? extends Optional<? extends List<? extends EmbedCreateSpec>>> possible) -
withEmbeds
Deprecated. -
withEmbedsOrNull
-
withEmbeds
-
withFiles
-
withFiles
-
withFileSpoilers
-
withFileSpoilers
-
withAllowedMentions
public ReplyEditSpec withAllowedMentions(discord4j.discordjson.possible.Possible<Optional<discord4j.rest.util.AllowedMentions>> value) -
withAllowedMentions
@Deprecated public ReplyEditSpec withAllowedMentions(@Nullable discord4j.rest.util.AllowedMentions value) Deprecated. -
withAllowedMentionsOrNull
-
withComponents
public ReplyEditSpec withComponents(discord4j.discordjson.possible.Possible<? extends Optional<? extends List<? extends LayoutComponent>>> possible) -
withComponents
Deprecated. -
withComponentsOrNull
-
withComponents
-
withAttachments
public ReplyEditSpec withAttachments(discord4j.discordjson.possible.Possible<? extends Optional<? extends List<? extends Attachment>>> possible) -
withAttachments
Deprecated. -
withAttachmentsOrNull
-
withAttachments
-
equals
This instance is equal to all instances ofReplyEditSpecthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:content,embeds,files,fileSpoilers,allowedMentions,components,attachments. -
toString
Prints the immutable valueReplyEditSpecwith attribute values. -
isContentPresent
public boolean isContentPresent() -
contentOrElse
-
isEmbedsPresent
public boolean isEmbedsPresent() -
embedsOrElse
-
isAllowedMentionsPresent
public boolean isAllowedMentionsPresent() -
allowedMentionsOrElse
public discord4j.rest.util.AllowedMentions allowedMentionsOrElse(discord4j.rest.util.AllowedMentions defaultValue) -
isComponentsPresent
public boolean isComponentsPresent() -
componentsOrElse
-
isAttachmentsPresent
public boolean isAttachmentsPresent() -
attachmentsOrElse
-
builder
Creates a builder forReplyEditSpec.ReplyEditSpec.builder() .content(discord4j.discordjson.possible.Possible<Optional<String>>) //content.embeds(discord4j.discordjson.possible.Possible<Optional<List<discord4j.core.spec.EmbedCreateSpec>>>) //embeds.files(List<discord4j.core.spec.MessageCreateFields.File>) //files.fileSpoilers(List<discord4j.core.spec.MessageCreateFields.FileSpoiler>) //fileSpoilers.allowedMentions(discord4j.discordjson.possible.Possible<Optional<discord4j.rest.util.AllowedMentions>>) //allowedMentions.components(discord4j.discordjson.possible.Possible<Optional<List<discord4j.core.object.component.LayoutComponent>>>) //components.attachments(discord4j.discordjson.possible.Possible<Optional<List<discord4j.core.object.entity.Attachment>>>) //attachments.build();- Returns:
- A new ReplyEditSpec builder
-
toMessage
Converts this spec into a message edit spec.- Returns:
- The converted spec.
-
toInteraction
Converts this spec into an interaction reply edit spec.- Returns:
- The converted spec.
-