Record Class MethodBuildContext
java.lang.Object
java.lang.Record
com.github.kaktushose.jda.commands.definitions.interactions.MethodBuildContext
@Internal
public record MethodBuildContext(@NotNull com.github.kaktushose.jda.commands.dispatching.validation.internal.Validators validators, @NotNull LocalizationFunction localizationFunction, @NotNull Interaction interaction, @NotNull Set<String> permissions, @Nullable SlashCommandDefinition.CooldownDefinition cooldownDefinition, @NotNull ClassDescription clazz, @NotNull MethodDescription method, @NotNull Collection<AutoCompleteDefinition> autoCompleteDefinitions)
extends Record
Holds all objects needed to create an
InteractionDefinition
.-
Constructor Summary
ConstructorDescriptionMethodBuildContext
(@NotNull com.github.kaktushose.jda.commands.dispatching.validation.internal.Validators validators, @NotNull LocalizationFunction localizationFunction, @NotNull Interaction interaction, @NotNull Set<String> permissions, @Nullable SlashCommandDefinition.CooldownDefinition cooldownDefinition, @NotNull ClassDescription clazz, @NotNull MethodDescription method, @NotNull Collection<AutoCompleteDefinition> autoCompleteDefinitions) Creates an instance of aMethodBuildContext
record class. -
Method Summary
Modifier and TypeMethodDescription@NotNull Collection
<AutoCompleteDefinition> Returns the value of theautoCompleteDefinitions
record component.@NotNull ClassDescription
clazz()
Returns the value of theclazz
record component.Returns the value of thecooldownDefinition
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.@NotNull Interaction
Returns the value of theinteraction
record component.@NotNull LocalizationFunction
Returns the value of thelocalizationFunction
record component.@NotNull MethodDescription
method()
Returns the value of themethod
record component.Returns the value of thepermissions
record component.final String
toString()
Returns a string representation of this record class.@NotNull com.github.kaktushose.jda.commands.dispatching.validation.internal.Validators
Returns the value of thevalidators
record component.
-
Constructor Details
-
MethodBuildContext
public MethodBuildContext(@NotNull @NotNull com.github.kaktushose.jda.commands.dispatching.validation.internal.Validators validators, @NotNull @NotNull LocalizationFunction localizationFunction, @NotNull @NotNull Interaction interaction, @NotNull @NotNull Set<String> permissions, @Nullable @Nullable SlashCommandDefinition.CooldownDefinition cooldownDefinition, @NotNull @NotNull ClassDescription clazz, @NotNull @NotNull MethodDescription method, @NotNull @NotNull Collection<AutoCompleteDefinition> autoCompleteDefinitions) Creates an instance of aMethodBuildContext
record class.- Parameters:
validators
- the value for thevalidators
record componentlocalizationFunction
- the value for thelocalizationFunction
record componentinteraction
- the value for theinteraction
record componentpermissions
- the value for thepermissions
record componentcooldownDefinition
- the value for thecooldownDefinition
record componentclazz
- the value for theclazz
record componentmethod
- the value for themethod
record componentautoCompleteDefinitions
- the value for theautoCompleteDefinitions
record component
-
-
Method Details
-
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)
. -
validators
@NotNull public @NotNull com.github.kaktushose.jda.commands.dispatching.validation.internal.Validators validators()Returns the value of thevalidators
record component.- Returns:
- the value of the
validators
record component
-
localizationFunction
Returns the value of thelocalizationFunction
record component.- Returns:
- the value of the
localizationFunction
record component
-
interaction
Returns the value of theinteraction
record component.- Returns:
- the value of the
interaction
record component
-
permissions
-
cooldownDefinition
Returns the value of thecooldownDefinition
record component.- Returns:
- the value of the
cooldownDefinition
record component
-
clazz
Returns the value of theclazz
record component.- Returns:
- the value of the
clazz
record component
-
method
Returns the value of themethod
record component.- Returns:
- the value of the
method
record component
-
autoCompleteDefinitions
Returns the value of theautoCompleteDefinitions
record component.- Returns:
- the value of the
autoCompleteDefinitions
record component
-