The Gaudi Framework  v30r3 (a5ef0a68)
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 368 of file Analyzer.cpp.

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