| 126 | } |
| 127 | |
| 128 | virtual CommandResult Names() { |
| 129 | auto data = CallbackContext{ |
| 130 | .name = "", |
| 131 | .sticker_type = sticker_type, |
| 132 | .response = response, |
| 133 | .is_song = StringIsEqual("song", sticker_type) |
| 134 | }; |
| 135 | |
| 136 | auto callback = [](const char *found_value, void *user_data) { |
| 137 | auto context = reinterpret_cast<CallbackContext *>(user_data); |
| 138 | context->response.Fmt("name: {}\n", found_value); |
| 139 | }; |
| 140 | |
| 141 | sticker_database.Names(callback, &data); |
| 142 | |
| 143 | return CommandResult::OK; |
| 144 | } |
| 145 | |
| 146 | CommandResult NamesTypes(const char *type) { |
| 147 | auto data = CallbackContext{ |
no outgoing calls
no test coverage detected