Copy to ClipboardCopied!Toggle word wrapToggle overflow
ChatBotLogic 是可实施通用字符串到字符串方法的简单 bean。
public class ChatBotLogic {
public String chatBotProcess(String message) {
if( "do-not-reply".equals(message) ) {
return null; // no response in the chat
}
return "echo from the bot: " + message; // echoes the message
}
}
public class ChatBotLogic {
public String chatBotProcess(String message) {
if( "do-not-reply".equals(message) ) {
return null; // no response in the chat
}
return "echo from the bot: " + message; // echoes the message
}
}
Copy to ClipboardCopied!Toggle word wrapToggle overflow