Skip to content
Snippets Groups Projects
Commit 57554df7 authored by Charles Leggett's avatar Charles Leggett
Browse files

fixed a few more proxies

parent cc3813e5
No related branches found
No related tags found
No related merge requests found
...@@ -9,6 +9,7 @@ ...@@ -9,6 +9,7 @@
#include <iostream> #include <iostream>
#include "AthenaKernel/ExtendedEventContext.h"
#include "AthenaBaseComps/AthAlgorithm.h" #include "AthenaBaseComps/AthAlgorithm.h"
#include "AthContainers/ConstDataVector.h" #include "AthContainers/ConstDataVector.h"
#include "StoreGate/ReadHandle.h" #include "StoreGate/ReadHandle.h"
...@@ -29,16 +30,15 @@ namespace SchedulerProxy { ...@@ -29,16 +30,15 @@ namespace SchedulerProxy {
{ {
SG::ReadHandle<ConstDataVector<TrigRoiDescriptorCollection> > rois("RegionOfReco"); SG::ReadHandle<ConstDataVector<TrigRoiDescriptorCollection> > rois("RegionOfReco");
CHECK(rois.setProxyDict(context.proxy())); CHECK(rois.setProxyDict(context.getExtension<Atlas::ExtendedEventContext>()->proxy()));
SG::WriteHandle< TestClusterContainer > clusterContainer("Clusters"); SG::WriteHandle< TestClusterContainer > clusterContainer("Clusters");
CHECK(clusterContainer.setProxyDict(context.proxy())); CHECK(clusterContainer.setProxyDict(context.getExtension<Atlas::ExtendedEventContext>()->proxy()));
clusterContainer = CxxUtils::make_unique< TestClusterContainer >(); clusterContainer = CxxUtils::make_unique< TestClusterContainer >();
ATH_CHECK(clusterContainer.commit()); ATH_CHECK(clusterContainer.commit());
SG::WriteHandle< TestClusterAuxContainer > clusterContainerAux("ClustersAux."); SG::WriteHandle< TestClusterAuxContainer > clusterContainerAux("ClustersAux.");
CHECK(clusterContainerAux.setProxyDict(context.proxy())); CHECK(clusterContainerAux.setProxyDict(context.getExtension<Atlas::ExtendedEventContext>()->proxy()));
clusterContainerAux = CxxUtils::make_unique< TestClusterAuxContainer>(); clusterContainerAux = CxxUtils::make_unique< TestClusterAuxContainer>();
ATH_CHECK(clusterContainerAux.commit()); ATH_CHECK(clusterContainerAux.commit());
clusterContainer->setStore(clusterContainerAux.ptr()); clusterContainer->setStore(clusterContainerAux.ptr());
......
...@@ -5,6 +5,7 @@ ...@@ -5,6 +5,7 @@
#include <iostream> #include <iostream>
#include "CxxUtils/make_unique.h" #include "CxxUtils/make_unique.h"
#include "AthViews/View.h" #include "AthViews/View.h"
#include "AthenaKernel/ExtendedEventContext.h"
#include "./SchedulerProxyAlg.h" #include "./SchedulerProxyAlg.h"
SchedulerProxyAlg::SchedulerProxyAlg(const std::string& name, ISvcLocator* pSvcLocator) SchedulerProxyAlg::SchedulerProxyAlg(const std::string& name, ISvcLocator* pSvcLocator)
...@@ -26,7 +27,7 @@ StatusCode SchedulerProxyAlg::initialize() ...@@ -26,7 +27,7 @@ StatusCode SchedulerProxyAlg::initialize()
StatusCode SchedulerProxyAlg::execute() { StatusCode SchedulerProxyAlg::execute() {
auto proxyPtr = getContext().proxy(); auto proxyPtr = getContext().getExtension<Atlas::ExtendedEventContext>()->proxy();
auto viewPtr = dynamic_cast<SG::View*>(proxyPtr); auto viewPtr = dynamic_cast<SG::View*>(proxyPtr);
if ( viewPtr != nullptr ) { if ( viewPtr != nullptr ) {
ATH_MSG_DEBUG( ".. The alg operates on the view " << viewPtr->impl()->name() ); ATH_MSG_DEBUG( ".. The alg operates on the view " << viewPtr->impl()->name() );
......
...@@ -4,6 +4,7 @@ ...@@ -4,6 +4,7 @@
#include <sstream> #include <sstream>
#include "CxxUtils/make_unique.h" #include "CxxUtils/make_unique.h"
#include "AthenaKernel/ExtendedEventContext.h"
#include "AthContainers/ConstDataVector.h" #include "AthContainers/ConstDataVector.h"
#include "GaudiKernel/ThreadLocalContext.h" #include "GaudiKernel/ThreadLocalContext.h"
#include "AthViews/ViewHelper.h" #include "AthViews/ViewHelper.h"
...@@ -56,7 +57,7 @@ StatusCode TestViewDriver::execute( ) { ...@@ -56,7 +57,7 @@ StatusCode TestViewDriver::execute( ) {
contexts.push_back( getContext( ) ); contexts.push_back( getContext( ) );
viewVector->push_back( ViewHelper::makeView( name( )+"_view", viewCounter++ ) ); viewVector->push_back( ViewHelper::makeView( name( )+"_view", viewCounter++ ) );
contexts.back( ).setProxy( viewVector->back( ) ); contexts.back( ).setExtension( Atlas::ExtendedEventContext( viewVector->back( ) ));
auto oneRoIColl = std::make_unique< ConstDataVector<TrigRoiDescriptorCollection> >( ); auto oneRoIColl = std::make_unique< ConstDataVector<TrigRoiDescriptorCollection> >( );
......
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