Package com.nirro.konfi.repository
Class RepositoryImpl
java.lang.Object
com.nirro.konfi.repository.RepositoryImpl
- All Implemented Interfaces:
Repository
Thread safe repository that replace the properties
on every refresh
-
Constructor Summary
ConstructorsConstructorDescriptionRepositoryImpl
(PropertiesSource propertiesSource) Construct a new Repository -
Method Summary
Modifier and TypeMethodDescriptiongetProperty
(String key) get propertyvoid
refresh()
refresh the repository.
-
Constructor Details
-
RepositoryImpl
Construct a new Repository- Parameters:
propertiesSource
- properties source
-
-
Method Details
-
refresh
public void refresh()Description copied from interface:Repository
refresh the repository.- Specified by:
refresh
in interfaceRepository
-
getProperty
Description copied from interface:Repository
get property- Specified by:
getProperty
in interfaceRepository
- Parameters:
key
- property key- Returns:
- value associated with the key if exists, null otherwise
-