The Gaudi Framework  v33r1 (b1225454)
Analyzer.cpp File Reference
#include <iostream>
#include <memory>
#include <boost/format.hpp>
#include "Analyzer.h"
#include "Catalog.h"
#include "IncludedFiles.h"
#include "Messages.h"
#include "Node.h"
#include "Parser.h"
#include "PragmaOptions.h"
#include "PropertyName.h"
#include "PropertyValue.h"
#include "Units.h"
#include "GaudiKernel/Environment.h"
Include dependency graph for Analyzer.cpp:

Go to the source code of this file.

Functions

bool Unreference (gp::Catalog &catalog, gp::Messages *messages)
 

Function Documentation

◆ Unreference()

bool Unreference ( gp::Catalog &  catalog,
gp::Messages *  messages 
)

Definition at line 366 of file Analyzer.cpp.

366  {
367  bool unreference_result = true;
368  for ( auto& client : catalog ) {
369  for ( auto& current : client.second ) {
370  if ( current.IsReference() ) {
371  gp::PropertyValue& value = current.property_value();
372  const std::vector<std::string>& names = value.Vector();
373  gp::Property* property = catalog.Find( names[0], names[1] );
374  if ( !property ) {
375  messages->AddError( value.position(), "Could not unreference " + current.ValueAsString() );
376  unreference_result = false;
377  } else {
378  value = property->property_value();
379  }
380  }
381  }
382  }
383  return unreference_result;
384 }
Gaudi::Details::PropertyBase Property
\fixme backward compatibility hack for old Property base class
Definition: PropertyFwd.h:35