public interface Environment
| 限定符和类型 | 方法和说明 |
|---|---|
default boolean |
containsProperty(String name)
Return whether this
PropertySource contains the given name. |
Optional<Object> |
getProperty(String name)
Return the value associated with the given name, or
null if not found. |
default boolean containsProperty(String name)
PropertySource contains the given name.
This implementation simply checks for a null return value
from getProperty(String). Subclasses may wish to implement
a more efficient algorithm if possible.
name - the property name to findCopyright © 2021. All rights reserved.