pub fn list_tables(config: Config) -> Option<Vec<String>> {
    let database = get_connection(config);
    let collections = database.list_collection_names(None).expect("Error!");

    if collections.is_empty() {
        return Option::from(vec![]);
    }

    return Option::from(collections);
}
/// List all tables for given database
List all tables for given database
List all tables for given database
pub fn list_tables(config: Config) -> Option<Vec<String>> {
    let database = get_connection(config);
    let collections = database.list_collection_names(None).expect("Error!");
    if collections.is_empty() {
        return Option::from(vec![]);
    }
    return Option::from(collections);
}
pub fn list_tables ( config : Config ) -> Option < Vec < String > > { let database = get_connection ( config ) ; let collections = database . list_collection_names ( None ) . expect ( " " ) ; if collections . is_empty ( ) { return Option :: from ( vec ! [ ] ) ; } return Option :: from ( collections ) ; }
List all tables for given database
List all tables for given database
config
Config
config
Config