@Nullable List<URL> libPropertyUrls, @Nullable List<String> libPropertyFilePaths, List<URL> productPropertyUrls) { bind(AdsApiConfiguration.class).to(apiConfigurationClass).asEagerSingleton(); bind(AdsLibConfiguration.class).to(adsLibConfigurationClass).asEagerSingleton(); bind(Configuration.class).annotatedWith(Names.named("api")).toProvider( new ConfigurationProvider(ConfigurationHelper.newList(apiPropertyUrls, false), ConfigurationHelper.newList(apiPropertyFilePaths, true))); bind(Configuration.class).annotatedWith(Names.named("lib")).toProvider( new ConfigurationProvider(ConfigurationHelper.newList(libPropertyUrls, false), getFilePathConfigurationListWithDefault(libPropertyFilePaths, Builder.DEFAULT_CONFIGURATION_FILENAME))); bind(Configuration.class).annotatedWith(Names.named("build")).toProvider( new ConfigurationProvider(ConfigurationHelper.newList( Lists.newArrayList(ConfigurationModule.class.getResource(BUILD_PROPERTIES)), false), null)); bind(Configuration.class).annotatedWith(Names.named("product")).toProvider( new ConfigurationProvider(ConfigurationHelper.newList(productPropertyUrls, false), null));
@Nullable List<URL> libPropertyUrls, @Nullable List<String> libPropertyFilePaths, List<URL> productPropertyUrls) { bind(AdsApiConfiguration.class).to(apiConfigurationClass).asEagerSingleton(); bind(AdsLibConfiguration.class).to(adsLibConfigurationClass).asEagerSingleton(); bind(Configuration.class).annotatedWith(Names.named("api")).toProvider( new ConfigurationProvider(ConfigurationHelper.newList(apiPropertyUrls, false), ConfigurationHelper.newList(apiPropertyFilePaths, true))); bind(Configuration.class).annotatedWith(Names.named("lib")).toProvider( new ConfigurationProvider(ConfigurationHelper.newList(libPropertyUrls, false), getFilePathConfigurationListWithDefault(libPropertyFilePaths, Builder.DEFAULT_CONFIGURATION_FILENAME))); bind(Configuration.class).annotatedWith(Names.named("build")).toProvider( new ConfigurationProvider(ConfigurationHelper.newList( Lists.newArrayList(ConfigurationModule.class.getResource(BUILD_PROPERTIES)), false), null)); bind(Configuration.class).annotatedWith(Names.named("product")).toProvider( new ConfigurationProvider(ConfigurationHelper.newList(productPropertyUrls, false), null));