All Downloads are FREE. Search and download functionalities are using the official Maven repository.

it.auties.whatsapp.model.message.button.InteractiveResponseMessageBuilder Maven / Gradle / Ivy

package it.auties.whatsapp.model.message.button;

public class InteractiveResponseMessageBuilder {
    private it.auties.whatsapp.model.button.interactive.InteractiveBody body;
    private it.auties.whatsapp.model.message.button.NativeFlowResponseMessage nativeFlowResponseMessage;
    private java.util.Optional contextInfo;

    public InteractiveResponseMessageBuilder() {
        body = null;
        nativeFlowResponseMessage = null;
        contextInfo = java.util.Optional.empty();
    }

    public InteractiveResponseMessageBuilder body(it.auties.whatsapp.model.button.interactive.InteractiveBody body) {
        this.body = body;
        return this;
    }
    public InteractiveResponseMessageBuilder nativeFlowResponseMessage(it.auties.whatsapp.model.message.button.NativeFlowResponseMessage nativeFlowResponseMessage) {
        this.nativeFlowResponseMessage = nativeFlowResponseMessage;
        return this;
    }
    public InteractiveResponseMessageBuilder contextInfo(java.util.Optional contextInfo) {
        this.contextInfo = contextInfo;
        return this;
    }
    public InteractiveResponseMessageBuilder contextInfo(it.auties.whatsapp.model.info.ContextInfo contextInfo) {
        this.contextInfo = java.util.Optional.ofNullable(contextInfo);
        return this;
    }

    public it.auties.whatsapp.model.message.button.InteractiveResponseMessage build() {
        return new it.auties.whatsapp.model.message.button.InteractiveResponseMessage(body, nativeFlowResponseMessage, contextInfo);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy