Record Class DispatchingContext
java.lang.Object
java.lang.Record
com.github.kaktushose.jda.commands.dispatching.handling.DispatchingContext
@Internal
public record DispatchingContext(Middlewares middlewares, ErrorMessageFactory errorMessageFactory, InteractionRegistry registry, TypeAdapters adapterRegistry, ExpirationStrategy expirationStrategy, DependencyInjector dependencyInjector, InteractionDefinition.ReplyConfig globalReplyConfig)
extends Record
A collection of classes relevant for
EventHandler
s.-
Constructor Summary
ConstructorsConstructorDescriptionDispatchingContext
(Middlewares middlewares, ErrorMessageFactory errorMessageFactory, InteractionRegistry registry, TypeAdapters adapterRegistry, ExpirationStrategy expirationStrategy, DependencyInjector dependencyInjector, InteractionDefinition.ReplyConfig globalReplyConfig) Creates an instance of aDispatchingContext
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theadapterRegistry
record component.Returns the value of thedependencyInjector
record component.final boolean
Indicates whether some other object is "equal to" this one.Returns the value of theerrorMessageFactory
record component.Returns the value of theexpirationStrategy
record component.Returns the value of theglobalReplyConfig
record component.final int
hashCode()
Returns a hash code value for this object.Returns the value of themiddlewares
record component.registry()
Returns the value of theregistry
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
DispatchingContext
public DispatchingContext(Middlewares middlewares, ErrorMessageFactory errorMessageFactory, InteractionRegistry registry, TypeAdapters adapterRegistry, ExpirationStrategy expirationStrategy, DependencyInjector dependencyInjector, InteractionDefinition.ReplyConfig globalReplyConfig) Creates an instance of aDispatchingContext
record class.- Parameters:
middlewares
- the value for themiddlewares
record componenterrorMessageFactory
- the value for theerrorMessageFactory
record componentregistry
- the value for theregistry
record componentadapterRegistry
- the value for theadapterRegistry
record componentexpirationStrategy
- the value for theexpirationStrategy
record componentdependencyInjector
- the value for thedependencyInjector
record componentglobalReplyConfig
- the value for theglobalReplyConfig
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)
. -
middlewares
Returns the value of themiddlewares
record component.- Returns:
- the value of the
middlewares
record component
-
errorMessageFactory
Returns the value of theerrorMessageFactory
record component.- Returns:
- the value of the
errorMessageFactory
record component
-
registry
Returns the value of theregistry
record component.- Returns:
- the value of the
registry
record component
-
adapterRegistry
Returns the value of theadapterRegistry
record component.- Returns:
- the value of the
adapterRegistry
record component
-
expirationStrategy
Returns the value of theexpirationStrategy
record component.- Returns:
- the value of the
expirationStrategy
record component
-
dependencyInjector
Returns the value of thedependencyInjector
record component.- Returns:
- the value of the
dependencyInjector
record component
-
globalReplyConfig
Returns the value of theglobalReplyConfig
record component.- Returns:
- the value of the
globalReplyConfig
record component
-