Record Class PollMetadata<L extends LocalizationSetting>
java.lang.Object
java.lang.Record
net.flectone.pulse.module.command.poll.model.PollMetadata<L>
- All Implemented Interfaces:
EventMetadata<L>
public record PollMetadata<L extends LocalizationSetting>(@NonNull BaseEventMetadata<L extends LocalizationSetting> base, @NonNull Poll poll, @NonNull PollModule.Status status, @NonNull PollModule.Action action)
extends Record
implements EventMetadata<L>
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classNested classes/interfaces inherited from interface EventMetadata
EventMetadata.Builder<L> -
Constructor Summary
ConstructorsConstructorDescriptionPollMetadata(@NonNull BaseEventMetadata<L> base, @NonNull Poll poll, @NonNull PollModule.Status status, @NonNull PollModule.Action action) Creates an instance of aPollMetadatarecord class. -
Method Summary
Modifier and TypeMethodDescription@NonNull PollModule.Actionaction()Returns the value of theactionrecord component.@NonNull BaseEventMetadata<L> base()Returns the value of thebaserecord component.static <L extends LocalizationSetting>
PollMetadata.PollMetadataBuilder<L> builder()final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.@NonNull Pollpoll()Returns the value of thepollrecord component.@NonNull PollModule.Statusstatus()Returns the value of thestatusrecord component.final StringtoString()Returns a string representation of this record class.withAction(@NonNull PollModule.Action action) withBase(@NonNull BaseEventMetadata<L> base) withStatus(@NonNull PollModule.Status status) Methods inherited from interface EventMetadata
destination, filter, flags, format, integrationMetadata, message, proxy, range, receivers, resolveFormat, resolveTags, sender, sound, tagResolvers, uuid
-
Constructor Details
-
PollMetadata
public PollMetadata(@NonNull BaseEventMetadata<L> base, @NonNull Poll poll, @NonNull PollModule.Status status, @NonNull PollModule.Action action) Creates an instance of aPollMetadatarecord class.- Parameters:
base- the value for thebaserecord componentpoll- the value for thepollrecord componentstatus- the value for thestatusrecord componentaction- the value for theactionrecord component
-
-
Method Details
-
builder
-
withBase
- Specified by:
withBasein interfaceEventMetadata<L extends LocalizationSetting>- Returns:
- a clone of this object, except with this updated property (returns
thisif an identical value is passed).
-
withPoll
- Returns:
- a clone of this object, except with this updated property (returns
thisif an identical value is passed).
-
withStatus
- Returns:
- a clone of this object, except with this updated property (returns
thisif an identical value is passed).
-
withAction
- Returns:
- a clone of this object, except with this updated property (returns
thisif an identical value is passed).
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
base
Returns the value of thebaserecord component.- Specified by:
basein interfaceEventMetadata<L extends LocalizationSetting>- Returns:
- the value of the
baserecord component
-
poll
Returns the value of thepollrecord component.- Returns:
- the value of the
pollrecord component
-
status
Returns the value of thestatusrecord component.- Returns:
- the value of the
statusrecord component
-
action
Returns the value of theactionrecord component.- Returns:
- the value of the
actionrecord component
-