Java Question java.util.function.Consumer ?

DonManfred

Expert
Licensed User
Longtime User
I am writing a wrapper for a Discord Bot Api using JDA (JavaDiscordApi).
When adding JDA Utilities there is a Consumer<Objecttype> and BiConsumer<ObjectType> involved which i need to set.

Java:
    /**
     * Sets the consumer to run as the bot's help command.
     * Setting it to {@code null} or not setting this at all will cause the bot to
     * use the default help builder.
     */
    public CommandClientBuilderwrapper setHelpConsumer(java.util.function.Consumer<CommandEvent> helpConsumer) {
        getObject().setHelpConsumer(helpConsumer);
        return this;
    }

I never saw such thing... What do i need to "build" such a Consumer which i could use here?? Any hints/tips/example are highly wecome ;-)
 
Top