public class DirConfigSource extends Object implements ConfigSource
ConfigSource.
Such as ${jetty.base} or and --include-jetty-dir=[path] sources.
| Constructor and Description |
|---|
DirConfigSource(String id,
Path dir,
int weight,
boolean canHaveArgs)
Create DirConfigSource with specified identifier and directory.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
RawArgs |
getArgs()
The list of Arguments for this ConfigSource
|
Path |
getDir() |
String |
getId()
The identifier for this source.
|
String |
getProperty(String key)
Return the value of the specified property.
|
Props |
getProps()
The properties for this ConfigSource
|
int |
getWeight()
The weight of this source, used for proper ordering of the config source search order.
|
int |
hashCode() |
boolean |
isPropertyBased() |
String |
toString() |
public DirConfigSource(String id, Path dir, int weight, boolean canHaveArgs) throws IOException
id - the identifier for this ConfigSourcedir - the directory for this ConfigSourceweight - the configuration weight (used for search order)canHaveArgs - true if this directory can have start.ini or start.d entries. (false for directories like ${jetty.home}, for example)IOException - if unable to load the configuration argspublic RawArgs getArgs()
ConfigSourcegetArgs in interface ConfigSourcepublic Path getDir()
public String getId()
ConfigSourceUsed in end-user display of the source.
getId in interface ConfigSourcepublic String getProperty(String key)
ConfigSourcegetProperty in interface ConfigSourcekey - the key to lookuppublic Props getProps()
ConfigSourcegetProps in interface ConfigSourcepublic int getWeight()
ConfigSourceRecommended Weights:
-1 = the command line
0 = the ${jetty.base} source
[1..n] = include-jetty-dir entries from command line
[n+1..n] = include-jetty-dir entries from start.ini (or start.d/*.ini)
9999999 = the ${jetty.home} source
getWeight in interface ConfigSourcepublic boolean isPropertyBased()
Copyright © 1995-2015 Webtide. All Rights Reserved.