docs
docs copied to clipboard
Adjusted documentation of tableList command (Java)
- provided the correct return type
- extended the example
Reason for the change
I tried to simply get the list of table names in a database and the current documentation is not helpful in that regard. The specified return type is wrong and the array with table names had to be extracted from the Result<Object>.
Description I corrected the return type and added a useful example that shows how to really get the table names.
Checklist
- [x] I have read and agreed to the RethinkDB Contributor License Agreement
This might also be a viable example:
try (Result<Object> result = r.db(DEFAULT_DB_NAME).tableList().run(connection)) {
result.forEach(list -> {
((List<?>) list).forEach(System.out::println);
});
}