Skip to content
Snippets Groups Projects
Commit db7340da authored by Marco Clemencic's avatar Marco Clemencic
Browse files

Restored setProperties method for backward compatibility

parent 71dc3748
No related branches found
No related tags found
No related merge requests found
......@@ -120,6 +120,13 @@ public:
/// The standard ToolSvc service, Return a pointer to the service if present
IToolSvc* toolSvc() const;
[[deprecated( "use setPropertiesFrom(const OptionsSvc&)" )]] StatusCode setProperties()
{
if ( !serviceLocator() ) return StatusCode::FAILURE;
setPropertiesFrom( serviceLocator()->getOptsSvc() );
return StatusCode::SUCCESS;
}
/** Access a service by name,
* creating it if it doesn't already exist.
*/
......
......@@ -354,6 +354,13 @@ public:
/// List of sub-algorithms. Returns a pointer to a vector of (sub) Algorithms
std::vector<Algorithm*>* subAlgorithms();
[[deprecated( "use setPropertiesFrom(const OptionsSvc&)" )]] StatusCode setProperties()
{
if ( !serviceLocator() ) return StatusCode::FAILURE;
setPropertiesFrom( serviceLocator()->getOptsSvc() );
return StatusCode::SUCCESS;
}
// ==========================================================================
using PropertyHolderImpl::declareProperty;
......
......@@ -124,6 +124,13 @@ public:
return serviceLocator()->service<T>( name, createIf );
}
[[deprecated( "use setPropertiesFrom(const OptionsSvc&)" )]] StatusCode setProperties()
{
if ( !serviceLocator() ) return StatusCode::FAILURE;
setPropertiesFrom( serviceLocator()->getOptsSvc() );
return StatusCode::SUCCESS;
}
private:
std::string m_name; ///< Auditor's name for identification
......
......@@ -74,6 +74,13 @@ public:
/** Retrieve pointer to service locator */
SmartIF<ISvcLocator>& serviceLocator() const override;
[[deprecated( "use setPropertiesFrom(const OptionsSvc&)" )]] StatusCode setProperties()
{
if ( !serviceLocator() ) return StatusCode::FAILURE;
setPropertiesFrom( serviceLocator()->getOptsSvc() );
return StatusCode::SUCCESS;
}
/** Access a service by name, creating it if it doesn't already exist.
*/
template <class T>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment