public class PropertyConfigurator extends Object implements Consumer<BaseProject<?>>
Constructor and Description |
---|
PropertyConfigurator(Map<String,String> edit)
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
void |
accept(BaseProject<?> project) |
static PropertyConfigurator |
nothing()
Returns a NO-OP configurator.
|
static PropertyConfigurator |
of(Enumeration<? extends URL> resources)
Returns a configurator which edits the given URL of properties.
|
static PropertyConfigurator |
of(Map<String,String> properties)
Returns a configurator which edits the given properties.
|
static PropertyConfigurator |
of(Optional<? extends URL> resource)
Returns a configurator which edits the given URL of properties.
|
static PropertyConfigurator |
of(Properties properties)
Returns a configurator which edits the given properties.
|
static PropertyConfigurator |
of(String key,
Path path)
Returns a configurator which edits the given property.
|
static PropertyConfigurator |
of(String key,
String value)
Returns a configurator which edits the given property.
|
static PropertyConfigurator |
of(URL resource)
Returns a configurator which edits the given URL of properties.
|
static PropertyConfigurator |
system()
Returns a system
PropertyConfigurator . |
public static PropertyConfigurator nothing()
public static PropertyConfigurator system()
PropertyConfigurator
.PropertyConfigurator
public static PropertyConfigurator of(String key, String value)
key
- the property namevalue
- the property valuepublic static PropertyConfigurator of(String key, Path path)
key
- the property namepath
- the target path (nullable)public static PropertyConfigurator of(Map<String,String> properties)
properties
- the propertiespublic static PropertyConfigurator of(Properties properties)
properties
- the propertiespublic static PropertyConfigurator of(URL resource)
resource
- the resource URLpublic static PropertyConfigurator of(Optional<? extends URL> resource)
resource
- the resource URLpublic static PropertyConfigurator of(Enumeration<? extends URL> resources)
resources
- the enumeration of resource URLspublic void accept(BaseProject<?> project)
accept
in interface Consumer<BaseProject<?>>
Copyright © 2011–2019 Asakusa Framework Team. All rights reserved.