The Gaudi Framework  v32r0 (3325bb39)
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

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

Definition at line 355 of file Analyzer.cpp.

355  {
356  bool unreference_result = true;
357  for ( auto& client : catalog ) {
358  for ( auto& current : client.second ) {
359  if ( current.IsReference() ) {
360  gp::PropertyValue& value = current.property_value();
361  const std::vector<std::string>& names = value.Vector();
362  gp::Property* property = catalog.Find( names[0], names[1] );
363  if ( !property ) {
364  messages->AddError( value.position(), "Could not unreference " + current.ValueAsString() );
365  unreference_result = false;
366  } else {
367  value = property->property_value();
368  }
369  }
370  }
371  }
372  return unreference_result;
373 }
Gaudi::Details::PropertyBase * property(const std::string &name) const
Gaudi::Details::PropertyBase Property
backward compatibility hack for old Property base class
Definition: PropertyFwd.h:25