Example usage for org.apache.commons.configuration2.builder.fluent PropertiesBuilderParameters setListDelimiterHandler

List of usage examples for org.apache.commons.configuration2.builder.fluent PropertiesBuilderParameters setListDelimiterHandler

Introduction

In this page you can find the example usage for org.apache.commons.configuration2.builder.fluent PropertiesBuilderParameters setListDelimiterHandler.

Prototype

T setListDelimiterHandler(ListDelimiterHandler handler);

Source Link

Document

Sets the value of the listDelimiterHandler property.

Usage

From source file:hd3gtv.as5kpc.MainClass.java

static FileBasedConfiguration loadConf(String file) throws ConfigurationException {
    org.apache.commons.configuration2.builder.fluent.Parameters params = new org.apache.commons.configuration2.builder.fluent.Parameters();
    PropertiesBuilderParameters pbp = params.properties().setFileName(file);
    pbp.setListDelimiterHandler(new DefaultListDelimiterHandler(','));

    FileBasedConfigurationBuilder<FileBasedConfiguration> builder = new FileBasedConfigurationBuilder<FileBasedConfiguration>(
            PropertiesConfiguration.class);
    builder.configure(pbp);/*from ww  w  . j a va 2 s .  c o  m*/
    return builder.getConfiguration();
}