From 7d3b01dbfd5ca261a6f582527bb6151a79c0d8c3 Mon Sep 17 00:00:00 2001
From: James Catmore <james.catmore@cern.ch>
Date: Thu, 9 Jan 2014 16:51:46 +0100
Subject: [PATCH] For release 19 - turning entire package into a dummy - no
 longer used (BPhysTagTools-00-00-26)

---
 .../BPhysTagTools/BPhysTagTool.h              | 50 ++++++++++++
 .../BPhys/BPhysTagTools/cmt/requirements      | 17 ++++
 .../BPhys/BPhysTagTools/doc/mainpage.h        | 27 +++++++
 .../share/BPhysTagTool_jobOptions.py          | 13 ++++
 .../BPhys/BPhysTagTools/src/BPhysTagTool.cxx  | 78 +++++++++++++++++++
 .../src/components/BPhysTagTools_entries.cxx  | 12 +++
 .../src/components/BPhysTagTools_load.cxx     |  7 ++
 7 files changed, 204 insertions(+)
 create mode 100755 PhysicsAnalysis/BPhys/BPhysTagTools/BPhysTagTools/BPhysTagTool.h
 create mode 100755 PhysicsAnalysis/BPhys/BPhysTagTools/cmt/requirements
 create mode 100755 PhysicsAnalysis/BPhys/BPhysTagTools/doc/mainpage.h
 create mode 100755 PhysicsAnalysis/BPhys/BPhysTagTools/share/BPhysTagTool_jobOptions.py
 create mode 100755 PhysicsAnalysis/BPhys/BPhysTagTools/src/BPhysTagTool.cxx
 create mode 100755 PhysicsAnalysis/BPhys/BPhysTagTools/src/components/BPhysTagTools_entries.cxx
 create mode 100755 PhysicsAnalysis/BPhys/BPhysTagTools/src/components/BPhysTagTools_load.cxx

diff --git a/PhysicsAnalysis/BPhys/BPhysTagTools/BPhysTagTools/BPhysTagTool.h b/PhysicsAnalysis/BPhys/BPhysTagTools/BPhysTagTools/BPhysTagTool.h
new file mode 100755
index 00000000000..6fe28185483
--- /dev/null
+++ b/PhysicsAnalysis/BPhys/BPhysTagTools/BPhysTagTools/BPhysTagTool.h
@@ -0,0 +1,50 @@
+/*
+  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
+*/
+
+// BPhysTagTools.h
+// Author: James Catmore (James.Catmore@cern.ch), Pavel Reznicek (Pavel.Reznicek@cern.ch),
+// This is B-Physics TAG-word filling algorithm
+// AS OF RELEASE 19 THIS IS NOW A DUMMY AND IS NOT DOING ANYTHING
+
+#ifndef BPHYSTAGTOOL_H
+#define BPHYSTAGTOOL_H
+
+#include <string>
+#include <map>
+
+#include "GaudiKernel/AlgTool.h"
+#include "StoreGate/StoreGateSvc.h"
+#include "TagEvent/TagFragmentCollection.h"
+#include "AthenaPoolUtilities/AthenaAttributeSpecification.h"
+
+///////////////////////////////////////////////////////////////////////////////
+
+
+// Interface ID for BPhysTagTool
+static const InterfaceID IID_BPhysTagTool("BPhysTagTool", 1, 0);
+
+class BPhysTagTool : public AlgTool {
+
+public:
+
+  // Standard Constructor
+  BPhysTagTool(const std::string&, const std::string&, const IInterface*);
+
+  // AlgTool and IAlgTool interface methods
+  static const InterfaceID& interfaceID() { return IID_BPhysTagTool; };
+
+  // Overriding initialize, finalize and execute
+  virtual StatusCode initialize();
+  virtual StatusCode attributeSpecification(std::map<std::string,AthenaAttributeType>&, const int);
+  virtual StatusCode execute(TagFragmentCollection&, const int);
+  virtual StatusCode finalize();
+
+protected:
+
+  // Standard destructor
+  virtual ~BPhysTagTool();
+
+};
+
+#endif // BPHYSTAGTOOL_H
diff --git a/PhysicsAnalysis/BPhys/BPhysTagTools/cmt/requirements b/PhysicsAnalysis/BPhys/BPhysTagTools/cmt/requirements
new file mode 100755
index 00000000000..98a179d4bf5
--- /dev/null
+++ b/PhysicsAnalysis/BPhys/BPhysTagTools/cmt/requirements
@@ -0,0 +1,17 @@
+package BPhysTagTools
+
+author Pavel Reznicek <Pavel.Reznicek@cern.ch>
+
+use AtlasPolicy          AtlasPolicy-*
+use AthenaPoolUtilities	 AthenaPoolUtilities-*      	Database/AthenaPOOL
+use GaudiInterface       GaudiInterface-*	External
+use StoreGate            StoreGate-*            Control
+use TagEvent             TagEvent-*             PhysicsAnalysis/EventTag
+
+private
+
+
+apply_pattern dual_use_library files=*.cxx
+
+apply_pattern declare_joboptions files="*.py"
+
diff --git a/PhysicsAnalysis/BPhys/BPhysTagTools/doc/mainpage.h b/PhysicsAnalysis/BPhys/BPhysTagTools/doc/mainpage.h
new file mode 100755
index 00000000000..464eb82c90c
--- /dev/null
+++ b/PhysicsAnalysis/BPhys/BPhysTagTools/doc/mainpage.h
@@ -0,0 +1,27 @@
+/*
+  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
+*/
+
+/**
+\mainpage BPhysTagTools
+
+\section introductionBPhysTagTools Introduction
+This package contains the alg tools for building the TAG fragment for B-Physics analysis: the results of various 
+exclusive yes/no hypotheses, for example, can be encode into a TAG word.
+
+\section packagecontentBPhysTagTools Package Contents
+BPhysTagTools contains the following tools:
+
+- BPhysTagTool ... tool for B-Physics Analysis TAG - for example the results of exclusive hypotheses
+
+- for questions and comments: ketevi@bnl.gov
+
+\section used_packagesBPhysTagTools Used packages
+@htmlinclude used_packages.html
+
+\section requirementsBPhysTagTools Requirements
+@include requirements
+
+*/
+
+
diff --git a/PhysicsAnalysis/BPhys/BPhysTagTools/share/BPhysTagTool_jobOptions.py b/PhysicsAnalysis/BPhys/BPhysTagTools/share/BPhysTagTool_jobOptions.py
new file mode 100755
index 00000000000..33dac02bf13
--- /dev/null
+++ b/PhysicsAnalysis/BPhys/BPhysTagTools/share/BPhysTagTool_jobOptions.py
@@ -0,0 +1,13 @@
+include.block ("BPhysTagTools/BPhysTagTool_jobOptions.py")
+
+from EventTagAlgs.EventTagGlobal import EventTagGlobal
+
+if not EventTagGlobal.InitEventTagBuilder:
+    raise RunTimeError('EventTagBuilder has not been initialized')
+
+########### BPhysics analysis Tag options ################
+
+from BPhysTagTools.BPhysTagToolsConf import BPhysTagTool as ConfiguredBPhysTagTool
+BPhysTagTool = ConfiguredBPhysTagTool(
+	)     
+ToolSvc += BPhysTagTool
diff --git a/PhysicsAnalysis/BPhys/BPhysTagTools/src/BPhysTagTool.cxx b/PhysicsAnalysis/BPhys/BPhysTagTools/src/BPhysTagTool.cxx
new file mode 100755
index 00000000000..b9df2baeb81
--- /dev/null
+++ b/PhysicsAnalysis/BPhys/BPhysTagTools/src/BPhysTagTool.cxx
@@ -0,0 +1,78 @@
+/*
+  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
+*/
+
+// BPhysTagTools
+// Author: James Catmore (James.Catmore@cern.ch), Pavel Reznicek (Pavel.Reznicek@cern.ch),
+// This is B-Physics TAG-word filling algorithm
+// AS OF RELEASE 19 THIS IS NOW A DUMMY AND IS NOT DOING ANYTHING
+
+#include "BPhysTagTools/BPhysTagTool.h"
+#include "GaudiKernel/IToolSvc.h"
+#include "TagEvent/BPhysAttributeNames.h"
+#include "AthenaPoolUtilities/AthenaAttributeSpecification.h"
+
+///////////////////////////////////////////////////////////////////////////////
+
+BPhysTagTool::BPhysTagTool(const std::string& type, const std::string& name, const IInterface* parent) :
+  AlgTool(type, name, parent) {
+
+  declareInterface<BPhysTagTool>(this);
+}
+
+///////////////////////////////////////////////////////////////////////////////
+
+BPhysTagTool::~BPhysTagTool() {}
+
+///////////////////////////////////////////////////////////////////////////////
+
+StatusCode BPhysTagTool::initialize() {
+
+  // Athena message stream
+  MsgStream log(msgSvc(),name());
+  log << MSG::DEBUG << "In intialize()" << endreq;
+  return StatusCode::SUCCESS;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+
+StatusCode BPhysTagTool::attributeSpecification(std::map<std::string,AthenaAttributeType>& attrMap, const int /*max*/) {
+
+  MsgStream log(msgSvc(),name());
+  log << MSG::DEBUG << "In attributeSpecification()" << endreq;
+
+  // Build the attribute list - called in initialize and specify the BPhys the attributes
+  attrMap[ BPhysAttributeNames[0] ] =AthenaAttributeType(std::string("unsigned int"),  BPhysAttributeUnitNames[0], BPhysAttributeGroupNames[0]);
+
+  return StatusCode::SUCCESS;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+
+StatusCode BPhysTagTool::execute(TagFragmentCollection& bphysTagColl, const int /*max*/) {
+
+  MsgStream log(msgSvc(),name());
+  log << MSG::DEBUG << "In execute()" << endreq;
+
+  //=============================================================================
+  // Fill the B-physics TAG word ================================================
+  //=============================================================================
+
+  // The B-physics word (32 bits)
+  unsigned int bphysWord = 0x0;
+
+  // Finally write the B-physics word to the TAG file
+  bphysTagColl.insert(BPhysAttributeNames[0],bphysWord);
+
+  return StatusCode::SUCCESS;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+
+StatusCode BPhysTagTool::finalize() {
+
+  MsgStream log(msgSvc(),name());
+  log << MSG::DEBUG << "In finalize()" << endreq;
+
+  return StatusCode::SUCCESS;
+}
diff --git a/PhysicsAnalysis/BPhys/BPhysTagTools/src/components/BPhysTagTools_entries.cxx b/PhysicsAnalysis/BPhys/BPhysTagTools/src/components/BPhysTagTools_entries.cxx
new file mode 100755
index 00000000000..785467c6787
--- /dev/null
+++ b/PhysicsAnalysis/BPhys/BPhysTagTools/src/components/BPhysTagTools_entries.cxx
@@ -0,0 +1,12 @@
+#include "BPhysTagTools/BPhysTagTool.h"
+
+#include "GaudiKernel/DeclareFactoryEntries.h"
+ 
+DECLARE_TOOL_FACTORY( BPhysTagTool )
+ 
+DECLARE_FACTORY_ENTRIES( BPhysTagTools ) {
+  DECLARE_TOOL( BPhysTagTool )
+}
+
+
+
diff --git a/PhysicsAnalysis/BPhys/BPhysTagTools/src/components/BPhysTagTools_load.cxx b/PhysicsAnalysis/BPhys/BPhysTagTools/src/components/BPhysTagTools_load.cxx
new file mode 100755
index 00000000000..23d439ebef4
--- /dev/null
+++ b/PhysicsAnalysis/BPhys/BPhysTagTools/src/components/BPhysTagTools_load.cxx
@@ -0,0 +1,7 @@
+#include "GaudiKernel/LoadFactoryEntries.h"
+ 
+LOAD_FACTORY_ENTRIES ( BPhysTagTools )
+
+
+
+
-- 
GitLab