| 1154 | } |
| 1155 | |
| 1156 | void HandleNSClientShowTable(const std::vector<std::string>& parts, |
| 1157 | ::fedb::client::NsClient* client) { |
| 1158 | std::string name; |
| 1159 | if (parts.size() >= 2) { |
| 1160 | name = parts[1]; |
| 1161 | } |
| 1162 | std::vector<::fedb::nameserver::TableInfo> tables; |
| 1163 | std::string msg; |
| 1164 | bool ret = client->ShowTable(name, tables, msg); |
| 1165 | if (!ret) { |
| 1166 | std::cout << "failed to showtable. error msg: " << msg << std::endl; |
| 1167 | return; |
| 1168 | } |
| 1169 | ::fedb::cmd::PrintTableInfo(tables); |
| 1170 | } |
| 1171 | |
| 1172 | void HandleNSClientShowSchema(const std::vector<std::string>& parts, |
| 1173 | ::fedb::client::NsClient* client) { |
no test coverage detected