# HG changeset patch # User František Kučera # Date 1439629670 -7200 # Node ID b5148f646278e11137d6e9f802bad39ded5456ee # Parent f8aa3686d5129dc87520baf63bae0f43a5434414 property annotations: dummy InfoLister table diff -r f8aa3686d512 -r b5148f646278 java/sql-dk/src/info/globalcode/sql/dk/InfoLister.java --- a/java/sql-dk/src/info/globalcode/sql/dk/InfoLister.java Sat Aug 15 10:53:35 2015 +0200 +++ b/java/sql-dk/src/info/globalcode/sql/dk/InfoLister.java Sat Aug 15 11:07:50 2015 +0200 @@ -177,12 +177,32 @@ } } - private void listFormatterProperties() { - for (String name : options.getFormatterNamesToListProperties()) { - log.log(Level.SEVERE, "TODO: list formatter properties for {0}", name); + private void listFormatterProperties() throws FormatterException, ConfigurationException { + for (String formatterName : options.getFormatterNamesToListProperties()) { + listFormatterProperties(formatterName); } } + private void listFormatterProperties(String formatterName) throws FormatterException, ConfigurationException { + ColumnsHeader header = constructHeader( + new HeaderField("name", SQLType.VARCHAR), + new HeaderField("type", SQLType.VARCHAR), + new HeaderField("default", SQLType.VARCHAR), + new HeaderField("description", SQLType.VARCHAR) + ); + List data = new ArrayList<>(); + + data.add(new Object[]{"TODO", "a", "b", "c"}); + data.add(new Object[]{"TODO", "a", "b", "c"}); + data.add(new Object[]{"TODO", "a", "b", "c"}); + data.add(new Object[]{"TODO", "a", "b", "c"}); + + List parameters = new ArrayList<>(); + parameters.add(new NamedParameter("formatter", formatterName, SQLType.VARCHAR)); + + printTable(formatter, header, "-- formatter properties", parameters, data); + } + private void listTypes() throws FormatterException, ConfigurationException { ColumnsHeader header = constructHeader(new HeaderField("name", SQLType.VARCHAR), new HeaderField("code", SQLType.INTEGER)); List data = new ArrayList<>();