
com.freya02.botcommands.internal.commands.application.slash.SlashCommandParameter.kt Maven / Gradle / Ivy
package com.freya02.botcommands.internal.commands.application.slash
import com.freya02.botcommands.api.commands.application.slash.builder.SlashCommandOptionAggregateBuilder
import com.freya02.botcommands.api.commands.application.slash.builder.SlashCommandOptionBuilder
import com.freya02.botcommands.api.parameters.SlashParameterResolver
import com.freya02.botcommands.internal.transform
class SlashCommandParameter(
slashCommandInfo: SlashCommandInfo,
slashCmdOptionAggregateBuilders: Map,
optionAggregateBuilder: SlashCommandOptionAggregateBuilder
) : AbstractSlashCommandParameter(slashCommandInfo, slashCmdOptionAggregateBuilders, optionAggregateBuilder) {
override val nestedAggregatedParameters = optionAggregateBuilder.nestedAggregates.transform {
SlashCommandParameter(slashCommandInfo, slashCmdOptionAggregateBuilders, it)
}
override fun constructOption(
slashCommandInfo: SlashCommandInfo,
optionAggregateBuilders: Map,
optionBuilder: SlashCommandOptionBuilder,
resolver: SlashParameterResolver<*, *>
) = SlashCommandOption(slashCommandInfo, optionAggregateBuilders, optionBuilder, resolver)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy