use of io.airlift.configuration.ConfigurationInspector.ConfigAttribute in project airlift by airlift.
the class Bootstrap method makePrinterForConfiguration.
private static ColumnPrinter makePrinterForConfiguration(ConfigurationFactory configurationFactory) {
ConfigurationInspector configurationInspector = new ConfigurationInspector();
ColumnPrinter columnPrinter = new ColumnPrinter("PROPERTY", "DEFAULT", "RUNTIME", "DESCRIPTION");
for (ConfigRecord<?> record : configurationInspector.inspect(configurationFactory)) {
for (ConfigAttribute attribute : record.getAttributes()) {
columnPrinter.addValues(attribute.getPropertyName(), attribute.getDefaultValue(), attribute.getCurrentValue(), attribute.getDescription());
}
}
return columnPrinter;
}
Aggregations