Skip to content
Snippets Groups Projects
ConfigService.cpp 32.4 KiB
Newer Older
  std::string defFacility = getString("default.facility");
  if (defFacility.empty())
     @param observer :: Reference to the observer to add
 */
void ConfigServiceImpl::addObserver(const Poco::AbstractObserver& observer)const
{
    m_notificationCenter.addObserver(observer);
}

/**  Remove an observer
     @param observer :: Reference to the observer to remove
 */
void ConfigServiceImpl::removeObserver(const Poco::AbstractObserver& observer)const
{
    m_notificationCenter.removeObserver(observer);
}


 * @return the facility information object
 * @throw NotFoundException if the facility is not found
 */
const FacilityInfo& ConfigServiceImpl::Facility(const std::string& fName) const
{
  std::vector<FacilityInfo*>::const_iterator it = m_facilities.begin();
  for (; it != m_facilities.end(); ++it)
  g_log.error("Facility " + fName + " not found");
  throw Exception::NotFoundError("Facilities", fName);
}

/// \cond TEMPLATE
template DLLExport int ConfigServiceImpl::getValue(const std::string&, double&);
template DLLExport int ConfigServiceImpl::getValue(const std::string&, std::string&);
template DLLExport int ConfigServiceImpl::getValue(const std::string&, int&);
/// \endcond TEMPLATE

} // namespace Kernel
} // namespace Mantid