Added constructor for setting keyboard in the ReplyKeyboard types

This commit is contained in:
recursiveribbons 2019-12-25 19:15:40 +01:00
parent f58def6326
commit 59958c57c0
2 changed files with 10 additions and 0 deletions

View File

@ -29,6 +29,11 @@ public class InlineKeyboardMarkup implements ReplyKeyboard {
keyboard = new ArrayList<>();
}
public InlineKeyboardMarkup(List<List<InlineKeyboardButton>> keyboard) {
super();
this.keyboard = keyboard;
}
public List<List<InlineKeyboardButton>> getKeyboard() {
return keyboard;
}

View File

@ -43,6 +43,11 @@ public class ReplyKeyboardMarkup implements ReplyKeyboard {
keyboard = new ArrayList<>();
}
public ReplyKeyboardMarkup(List<KeyboardRow> keyboard) {
super();
this.keyboard = keyboard;
}
public List<KeyboardRow> getKeyboard() {
return keyboard;
}