String tableOfDatabases(DatabasesPage page) { UITableBuilder out = UITableBuilder.of(); out.add(row(header("Database"), header("Tables"))); for (Database database : page.databases) { out.add( row( detail(database.linkTo().toString(), CSS.DATABASE), detail(tablesOn(page, database), CSS.TABLE))); } return out.build().toString(); }
/** Return a string to go in a database name cell. */ String nameCell(Database database) { log.args(database); Label text = Label.of(database.name); URIObject target = database.linkTo().getTarget(); return "Database : " + Link.textTarget(text, target).toString(); }