Class RepositoryImpl

java.lang.Object
com.nirro.konfi.repository.RepositoryImpl
All Implemented Interfaces:
Repository

public class RepositoryImpl extends Object implements Repository
Thread safe repository that replace the properties on every refresh
  • Constructor Details

    • RepositoryImpl

      public RepositoryImpl(PropertiesSource propertiesSource)
      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 interface Repository
    • getProperty

      public String getProperty(String key)
      Description copied from interface: Repository
      get property
      Specified by:
      getProperty in interface Repository
      Parameters:
      key - property key
      Returns:
      value associated with the key if exists, null otherwise