static class PropertySource.ComparisonPropertySource extends PropertySource.StubPropertySource
PropertySource.named(String)
PropertySource.ComparisonPropertySource, PropertySource.StubPropertySource
Modifier and Type | Field and Description |
---|---|
private static java.lang.String |
USAGE_ERROR |
logger, name, source
Constructor and Description |
---|
PropertySource.ComparisonPropertySource(java.lang.String name) |
Modifier and Type | Method and Description |
---|---|
boolean |
containsProperty(java.lang.String name)
Return whether this
PropertySource contains the given name. |
java.lang.String |
getProperty(java.lang.String name)
Always return
null . |
java.lang.Object |
getSource()
Return the underlying source object for this
PropertySource . |
java.lang.String |
toString()
Produce concise output (type and name) if the current log level does not include
debug.
|
equals, getName, hashCode, named
private static final java.lang.String USAGE_ERROR
public PropertySource.ComparisonPropertySource(java.lang.String name)
public java.lang.Object getSource()
PropertySource
PropertySource
.getSource
in class PropertySource<java.lang.Object>
public boolean containsProperty(java.lang.String name)
PropertySource
PropertySource
contains the given name.
This implementation simply checks for a null return value
from PropertySource.getProperty(String)
. Subclasses may wish to
implement a more efficient algorithm if possible.
containsProperty
in class PropertySource<java.lang.Object>
name
- the property name to findpublic java.lang.String getProperty(java.lang.String name)
PropertySource.StubPropertySource
null
.getProperty
in class PropertySource.StubPropertySource
name
- the property to findPropertyResolver.getRequiredProperty(String)
public java.lang.String toString()
PropertySource
toString
in class PropertySource<java.lang.Object>
Log#isDebugEnabled()