From ab296d42041aeb7a7c690655a81e743bd5ae6335 Mon Sep 17 00:00:00 2001 From: Eric Torrence <eric.torrence@cern.ch> Date: Tue, 9 Mar 2021 14:40:50 -0800 Subject: [PATCH] Add waveform data types as xAOD --- xAOD/xAODFaserWaveform/CMakeLists.txt | 26 +++++++++ .../Root/WaveformClockAuxInfo_v1.cxx | 18 ++++++ .../Root/WaveformClock_v1.cxx | 35 ++++++++++++ .../Root/WaveformHitAuxContainer_v1.cxx | 19 +++++++ .../xAODFaserWaveform/Root/WaveformHit_v1.cxx | 32 +++++++++++ .../Root/xAODFaserWaveformCLIDs.cxx | 10 ++++ .../xAODFaserWaveform/WaveformClock.h | 22 ++++++++ .../xAODFaserWaveform/WaveformClockAuxInfo.h | 22 ++++++++ .../xAODFaserWaveform/WaveformHit.h | 22 ++++++++ .../WaveformHitAuxContainer.h | 22 ++++++++ .../xAODFaserWaveform/WaveformHitContainer.h | 22 ++++++++ .../xAODFaserWaveform/selection.xml | 24 ++++++++ .../versions/WaveformClockAuxInfo_v1.h | 45 +++++++++++++++ .../versions/WaveformClock_v1.h | 55 +++++++++++++++++++ .../versions/WaveformHitAuxContainer_v1.h | 43 +++++++++++++++ .../versions/WaveformHitContainer_v1.h | 26 +++++++++ .../versions/WaveformHit_v1.h | 47 ++++++++++++++++ .../xAODFaserWaveform/xAODFaserWaveformDict.h | 33 +++++++++++ 18 files changed, 523 insertions(+) create mode 100644 xAOD/xAODFaserWaveform/CMakeLists.txt create mode 100644 xAOD/xAODFaserWaveform/Root/WaveformClockAuxInfo_v1.cxx create mode 100644 xAOD/xAODFaserWaveform/Root/WaveformClock_v1.cxx create mode 100644 xAOD/xAODFaserWaveform/Root/WaveformHitAuxContainer_v1.cxx create mode 100644 xAOD/xAODFaserWaveform/Root/WaveformHit_v1.cxx create mode 100644 xAOD/xAODFaserWaveform/Root/xAODFaserWaveformCLIDs.cxx create mode 100644 xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformClock.h create mode 100644 xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformClockAuxInfo.h create mode 100644 xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformHit.h create mode 100644 xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformHitAuxContainer.h create mode 100644 xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformHitContainer.h create mode 100644 xAOD/xAODFaserWaveform/xAODFaserWaveform/selection.xml create mode 100644 xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformClockAuxInfo_v1.h create mode 100644 xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformClock_v1.h create mode 100644 xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformHitAuxContainer_v1.h create mode 100644 xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformHitContainer_v1.h create mode 100644 xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformHit_v1.h create mode 100644 xAOD/xAODFaserWaveform/xAODFaserWaveform/xAODFaserWaveformDict.h diff --git a/xAOD/xAODFaserWaveform/CMakeLists.txt b/xAOD/xAODFaserWaveform/CMakeLists.txt new file mode 100644 index 00000000..11852511 --- /dev/null +++ b/xAOD/xAODFaserWaveform/CMakeLists.txt @@ -0,0 +1,26 @@ +# Copyright (C) 2020 CERN for the benefit of the FASER collaboration + +# Declare the package name. +atlas_subdir( xAODFaserWaveform ) + +# External dependencies. +find_package( xAODUtilities ) + +# Component(s) in the package. +atlas_add_library( xAODFaserWaveform + xAODFaserWaveform/*.h xAODFaserWaveform/versions/*.h Root/*.cxx + PUBLIC_HEADERS xAODFaserWaveform + LINK_LIBRARIES xAODCore ) + +atlas_add_xaod_smart_pointer_dicts( + INPUT xAODFaserWaveform/selection.xml + OUTPUT _selectionFile + OBJECTS "xAOD::WaveformClock_v1" + CONTAINERS "xAOD::WaveformHitContainer_v1") + +atlas_add_dictionary( xAODFaserWaveformDict + xAODFaserWaveform/xAODFaserWaveformDict.h + ${_selectionFile} + LINK_LIBRARIES xAODCore xAODFaserWaveform + EXTRA_FILES Root/dict/*.cxx ) + diff --git a/xAOD/xAODFaserWaveform/Root/WaveformClockAuxInfo_v1.cxx b/xAOD/xAODFaserWaveform/Root/WaveformClockAuxInfo_v1.cxx new file mode 100644 index 00000000..c6be98a7 --- /dev/null +++ b/xAOD/xAODFaserWaveform/Root/WaveformClockAuxInfo_v1.cxx @@ -0,0 +1,18 @@ +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +// Local include(s): +#include "xAODFaserWaveform/versions/WaveformClockAuxInfo_v1.h" + +namespace xAOD { + + WaveformClockAuxInfo_v1::WaveformClockAuxInfo_v1() + : AuxInfoBase(), + frequency(0), phase(0), offset(0), amplitude(0) { + AUX_VARIABLE( frequency ); + AUX_VARIABLE( phase ); + AUX_VARIABLE( offset ); + AUX_VARIABLE( amplitude ); + } +} // namespace xAOD diff --git a/xAOD/xAODFaserWaveform/Root/WaveformClock_v1.cxx b/xAOD/xAODFaserWaveform/Root/WaveformClock_v1.cxx new file mode 100644 index 00000000..6a3128d0 --- /dev/null +++ b/xAOD/xAODFaserWaveform/Root/WaveformClock_v1.cxx @@ -0,0 +1,35 @@ +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +// EDM include(s): +#include "xAODCore/AuxStoreAccessorMacros.h" + +// Local include(s): +#include "xAODFaserWaveform/versions/WaveformClock_v1.h" + +namespace xAOD { + + WaveformClock_v1::WaveformClock_v1() : SG::AuxElement() { + } + + AUXSTORE_PRIMITIVE_SETTER_AND_GETTER( WaveformClock_v1, double, frequency, set_frequency ) + + AUXSTORE_PRIMITIVE_SETTER_AND_GETTER( WaveformClock_v1, double, phase, set_phase ) + + AUXSTORE_PRIMITIVE_SETTER_AND_GETTER( WaveformClock_v1, double, offset, set_offset ) + + AUXSTORE_PRIMITIVE_SETTER_AND_GETTER( WaveformClock_v1, double, amplitude, set_amplitude ) + +} // namespace xAOD + +namespace xAOD { + + std::ostream& operator<<(std::ostream& s, const xAOD::WaveformClock_v1& clk) { + s << "xAODWaveformClock: frequency=" << clk.frequency() + << std::endl; + + return s; + } + +} // namespace xAOD diff --git a/xAOD/xAODFaserWaveform/Root/WaveformHitAuxContainer_v1.cxx b/xAOD/xAODFaserWaveform/Root/WaveformHitAuxContainer_v1.cxx new file mode 100644 index 00000000..300fa4d8 --- /dev/null +++ b/xAOD/xAODFaserWaveform/Root/WaveformHitAuxContainer_v1.cxx @@ -0,0 +1,19 @@ +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +// Local include(s): +#include "xAODFaserWaveform/versions/WaveformHitAuxContainer_v1.h" + +namespace xAOD { + + WaveformHitAuxContainer_v1::WaveformHitAuxContainer_v1() + : AuxContainerBase() { + + AUX_VARIABLE(baseline_mean); + AUX_VARIABLE(baseline_rms); + + } + +} // namespace xAOD + diff --git a/xAOD/xAODFaserWaveform/Root/WaveformHit_v1.cxx b/xAOD/xAODFaserWaveform/Root/WaveformHit_v1.cxx new file mode 100644 index 00000000..080946b0 --- /dev/null +++ b/xAOD/xAODFaserWaveform/Root/WaveformHit_v1.cxx @@ -0,0 +1,32 @@ +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +// EDM include(s): +#include "xAODCore/AuxStoreAccessorMacros.h" + +// Local include(s): +#include "xAODFaserWaveform/versions/WaveformHit_v1.h" + +namespace xAOD { + + WaveformHit_v1::WaveformHit_v1() : SG::AuxElement() { + } + + AUXSTORE_PRIMITIVE_SETTER_AND_GETTER( WaveformHit_v1, float, baseline_mean, set_baseline_mean ) + + AUXSTORE_PRIMITIVE_SETTER_AND_GETTER( WaveformHit_v1, float, baseline_rms, set_baseline_rms ) + +} // namespace xAOD + +namespace xAOD { + + std::ostream& operator<<(std::ostream& s, const xAOD::WaveformHit_v1& hit) { + s << "xAODWaveformHit: baseline=" << hit.baseline_mean() + << " rms=" << hit.baseline_rms() + << std::endl; + + return s; + } + +} // namespace xAOD diff --git a/xAOD/xAODFaserWaveform/Root/xAODFaserWaveformCLIDs.cxx b/xAOD/xAODFaserWaveform/Root/xAODFaserWaveformCLIDs.cxx new file mode 100644 index 00000000..acd57bce --- /dev/null +++ b/xAOD/xAODFaserWaveform/Root/xAODFaserWaveformCLIDs.cxx @@ -0,0 +1,10 @@ +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +//simple includes to force the CLASS_DEF etc to be encountered during compile + +#include "xAODFaserWaveform/WaveformHitContainer.h" +#include "xAODFaserWaveform/WaveformHitAuxContainer.h" +#include "xAODFaserWaveform/WaveformClock.h" +#include "xAODFaserWaveform/WaveformClockAuxInfo.h" diff --git a/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformClock.h b/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformClock.h new file mode 100644 index 00000000..951d21a7 --- /dev/null +++ b/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformClock.h @@ -0,0 +1,22 @@ +// Dear emacs, this is -*- c++ -*- + +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +#ifndef XAODFASERWAVEFORM_WAVEFORMCLOCK_H +#define XAODFASERWAVEFORM_WAVEFORMCLOCK_H + +// Local include(s): +#include "xAODFaserWaveform/versions/WaveformClock_v1.h" + +namespace xAOD { + /// Declare the latest version of the class + typedef WaveformClock_v1 WaveformClock; +} + +// Set up a CLID for the container: +#include "xAODCore/CLASS_DEF.h" +CLASS_DEF( xAOD::WaveformClock, 58376762, 1 ) + +#endif // XAODFASERWAVEFORM_WAVEFORMCLOCK_H diff --git a/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformClockAuxInfo.h b/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformClockAuxInfo.h new file mode 100644 index 00000000..5cdc5294 --- /dev/null +++ b/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformClockAuxInfo.h @@ -0,0 +1,22 @@ +// Dear emacs, this is -*- c++ -*- + +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +#ifndef XAODFASERWAVEFORM_WAVEFORMCLOCKAUXINFO_H +#define XAODFASERWAVEFORM_WAVEFORMCLOCKAUXINFO_H + +// Local include(s): +#include "xAODFaserWaveform/versions/WaveformClockAuxInfo_v1.h" + +namespace xAOD { + /// Declare the latest version of the class + typedef WaveformClockAuxInfo_v1 WaveformClockAuxInfo; +} + +// Set up a CLID for the container: +#include "xAODCore/CLASS_DEF.h" +CLASS_DEF( xAOD::WaveformClockAuxInfo, 150155999, 1 ) + +#endif // XAODFASERWAVEFORM_WAVEFORMCLOCKAUXINFO_H diff --git a/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformHit.h b/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformHit.h new file mode 100644 index 00000000..6f01f4fc --- /dev/null +++ b/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformHit.h @@ -0,0 +1,22 @@ +// Dear emacs, this is -*- c++ -*- + +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +#ifndef XAODFASERWAVEFORM_WAVEFORMHIT_H +#define XAODFASERWAVEFORM_WAVEFORMHIT_H + +// Local include(s): +#include "xAODFaserWaveform/versions/WaveformHit_v1.h" + +namespace xAOD { + /// Declare the latest version of the class + typedef WaveformHit_v1 WaveformHit; +} + +// Set up a CLID for the container: +#include "xAODCore/CLASS_DEF.h" +CLASS_DEF( xAOD::WaveformHit, 131600577, 1 ) + +#endif // XAODFASERWAVEFORM_WAVEFORMHIT_H diff --git a/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformHitAuxContainer.h b/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformHitAuxContainer.h new file mode 100644 index 00000000..014da4c0 --- /dev/null +++ b/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformHitAuxContainer.h @@ -0,0 +1,22 @@ +// Dear emacs, this is -*- c++ -*- + +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +#ifndef XAODFASERWAVEFORM_WAVEFORMHITAUXCONTAINER_H +#define XAODFASERWAVEFORM_WAVEFORMHITAUXCONTAINER_H + +// Local include(s): +#include "xAODFaserWaveform/versions/WaveformHitAuxContainer_v1.h" + +namespace xAOD { + /// Declare the latest version of the class + typedef WaveformHitAuxContainer_v1 WaveformHitAuxContainer; +} + +// Set up a CLID for the container: +#include "xAODCore/CLASS_DEF.h" +CLASS_DEF( xAOD::WaveformHitAuxContainer, 1262669778, 1 ) + +#endif // XAODFASERWAVEFORM_WAVEFORMHITAUXCONTAINER_H diff --git a/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformHitContainer.h b/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformHitContainer.h new file mode 100644 index 00000000..41de79d2 --- /dev/null +++ b/xAOD/xAODFaserWaveform/xAODFaserWaveform/WaveformHitContainer.h @@ -0,0 +1,22 @@ +// Dear emacs, this is -*- c++ -*- + +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +#ifndef XAODFASERWAVEFORM_WAVEFORMHITCONTAINER_H +#define XAODFASERWAVEFORM_WAVEFORMHITCONTAINER_H + +// Local include(s): +#include "xAODFaserWaveform/versions/WaveformHitContainer_v1.h" + +namespace xAOD { + /// Declare the latest version of the class + typedef WaveformHitContainer_v1 WaveformHitContainer; +} + +// Set up a CLID for the container: +#include "xAODCore/CLASS_DEF.h" +CLASS_DEF( xAOD::WaveformHitContainer, 1156844391, 1 ) + +#endif // XAODFASERWAVEFORM_WAVEFORMHITCONTAINER_H diff --git a/xAOD/xAODFaserWaveform/xAODFaserWaveform/selection.xml b/xAOD/xAODFaserWaveform/xAODFaserWaveform/selection.xml new file mode 100644 index 00000000..44146cd5 --- /dev/null +++ b/xAOD/xAODFaserWaveform/xAODFaserWaveform/selection.xml @@ -0,0 +1,24 @@ +<!-- Copyright (C) 2020 CERN for the benefit of the FASER collaboration --> +<lcgdict> + + <class name="xAOD::WaveformHit_v1" /> + <typedef name="xAOD::WaveformHit" /> + + <class name="xAOD::WaveformHitContainer_v1" + id="fb49e082-7130-462f-9500-de9a2aef8a24" /> + <typedef name="xAOD::WaveformHitContainer" /> + + <class name="xAOD::WaveformHitAuxContainer_v1" + id="091007bd-f4ab-4862-b905-1a0ed96c962f" /> + <typedef name="xAOD::WaveformHitAuxContainer" /> + + <class name="xAOD::WaveformClock_v1" + id="461aa5ca-6c72-46ee-b5d5-5bd6df4e2848" /> + <typedef name="xAOD::WaveformClock" /> + + <class name="xAOD::WaveformClockAuxInfo_v1" + id="fe0600cc-f2f3-4be5-9723-257646dbb8f7" /> + <typedef name="xAOD::WaveformClockAuxInfo" /> + + +</lcgdict> diff --git a/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformClockAuxInfo_v1.h b/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformClockAuxInfo_v1.h new file mode 100644 index 00000000..74a98b62 --- /dev/null +++ b/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformClockAuxInfo_v1.h @@ -0,0 +1,45 @@ +// Dear emacs, this is -*- c++ -*- + +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +#ifndef XAODFASERWAVEFORM_VERSIONS_WAVEFORMCLOCKAUXINFO_V1_H +#define XAODFASERWAVEFORM_VERSIONS_WAVEFORMCLOCKAUXINFO_V1_H + +// System include(s): +extern "C" { +# include "stdint.h" +} + +// xAOD include(s): +#include "xAODCore/AuxInfoBase.h" + +namespace xAOD { + + /// Class holding the data handled by WaveformClock_v1 + + class WaveformClockAuxInfo_v1 : public AuxInfoBase { + + public: + /// Default constructor + WaveformClockAuxInfo_v1(); + + private: + /// @name Basic variables + ///@ { + double frequency; + double phase; + double offset; + double amplitude; + ///@} + + }; // class WaveformClockAuxInfo_v1 + +} // namespace xAOD + +// Set up a CLID and StoreGate inheritance for the class: +#include "xAODCore/BaseInfo.h" +SG_BASE( xAOD::WaveformClockAuxInfo_v1, xAOD::AuxInfoBase ); + +#endif // XAODFASERWAVEFORM_VERSIONS_WAVEFORMCLOCKAUXINFO_V1_H diff --git a/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformClock_v1.h b/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformClock_v1.h new file mode 100644 index 00000000..2d70b976 --- /dev/null +++ b/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformClock_v1.h @@ -0,0 +1,55 @@ +// Dear emacs, this is -*- c++ -*- + +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +#ifndef XAODFASERWAVEFORM_VERSIONS_WAVEFORMCLOCK_V1_H +#define XAODFASERWAVEFORM_VERSIONS_WAVEFORMCLOCK_V1_H + +// System include(s): +extern "C" { +# include "stdint.h" +} + +// Core EDM include(s): +#include "AthContainers/AuxElement.h" + +namespace xAOD { + + // Cllss describing pulses in the waveform digitizer + class WaveformClock_v1 : public SG::AuxElement { + + public: + /// Defaullt constructor + WaveformClock_v1(); + + /// @name Access WaveformClock elements + /// @{ + + /// Clock Frequency (in MHz) + double frequency() const; + void set_frequency(double value); + + /// Clock Phase (in Radians) + double phase() const; + void set_phase(double value); + + /// DC Clock offset + double offset() const; + void set_offset(double value); + + /// Amplitude of primary freq. component + double amplitude() const; + void set_amplitude(double value); + /// @} + + }; // class WaveformClock_v1 + +} + +// Declare the inheritance of the type: +#include "xAODCore/BaseInfo.h" +SG_BASE( xAOD::WaveformClock_v1, SG::AuxElement ); + +#endif // XAODFASERWAVEFORM_VERSIONS_WAVEFORMCLOCK_V1_H diff --git a/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformHitAuxContainer_v1.h b/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformHitAuxContainer_v1.h new file mode 100644 index 00000000..d4a28ac5 --- /dev/null +++ b/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformHitAuxContainer_v1.h @@ -0,0 +1,43 @@ +// Dear emacs, this is -*- c++ -*- + +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +#ifndef XAODFASERWAVEFORM_VERSIONS_WAVEFORMHITAUXCONTAINER_V1_H +#define XAODFASERWAVEFORM_VERSIONS_WAVEFORMHITAUXCONTAINER_V1_H + +// STL include(s): +#include <vector> + +// EDM include(s): +#include "xAODCore/AuxContainerBase.h" + +namespace xAOD { + + /// Auxiliary container for WaveformHit containers + + class WaveformHitAuxContainer_v1 : public AuxContainerBase { + + public: + /// Default constructor + WaveformHitAuxContainer_v1(); + /// Destructor + ~WaveformHitAuxContainer_v1() {} + + private: + /// @name Basic variables + ///@ { + std::vector<float> baseline_mean; + std::vector<float> baseline_rms; + ///@} + + }; // class WaveformHitAuxContainer_v1 + +} // namespace xAOD + +// Set up a CLID and StoreGate inheritance for the class: +#include "xAODCore/BaseInfo.h" +SG_BASE( xAOD::WaveformHitAuxContainer_v1, xAOD::AuxContainerBase ); + +#endif // XAODFASERWAVEFORM_VERSIONS_WAVEFORMHITAUXCONTAINER_V1_H diff --git a/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformHitContainer_v1.h b/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformHitContainer_v1.h new file mode 100644 index 00000000..180cf971 --- /dev/null +++ b/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformHitContainer_v1.h @@ -0,0 +1,26 @@ +// Dear emacs, this is -*- c++ -*- + +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +#ifndef XAODFASERWAVEFORM_VERSIONS_WAVEFORMHITCONTAINER_V1_H +#define XAODFASERWAVEFORM_VERSIONS_WAVEFORMHITCONTAINER_V1_H + +// System include(s): +extern "C" { +# include "stdint.h" +} + +// EDM include(s): +#include "AthContainers/DataVector.h" + +// Local includes: +#include "xAODFaserWaveform/versions/WaveformHit_v1.h" + +namespace xAOD { + // Define the container as a simple DataVector + typedef DataVector<WaveformHit_v1> WaveformHitContainer_v1; +} + +#endif // XAODFASERWAVEFORM_VERSIONS_WAVEFORMHITCONTAINER_V1_H diff --git a/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformHit_v1.h b/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformHit_v1.h new file mode 100644 index 00000000..355b5685 --- /dev/null +++ b/xAOD/xAODFaserWaveform/xAODFaserWaveform/versions/WaveformHit_v1.h @@ -0,0 +1,47 @@ +// Dear emacs, this is -*- c++ -*- + +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +#ifndef XAODFASERWAVEFORM_VERSIONS_WAVEFORMHIT_V1_H +#define XAODFASERWAVEFORM_VERSIONS_WAVEFORMHIT_V1_H + +// System include(s): +extern "C" { +# include "stdint.h" +} + +// Core EDM include(s): +#include "AthContainers/AuxElement.h" + +namespace xAOD { + + // Cllss describing pulses in the waveform digitizer + class WaveformHit_v1 : public SG::AuxElement { + + public: + /// Defaullt constructor + WaveformHit_v1(); + + /// @name Access WaveformHit elements + /// @{ + + /// Bsaeline mean + float baseline_mean() const; + void set_baseline_mean(float value); + + /// Baseline rms + float baseline_rms() const; + void set_baseline_rms(float value); + + }; // class WaveformHit_v1 + +} + +// Declare the inheritance of the type: +#include "xAODCore/BaseInfo.h" +SG_BASE( xAOD::WaveformHit_v1, SG::AuxElement ); + + +#endif // XAODFASERWAVEFORM_VERSIONS_WAVEFORMHIT_V1_H diff --git a/xAOD/xAODFaserWaveform/xAODFaserWaveform/xAODFaserWaveformDict.h b/xAOD/xAODFaserWaveform/xAODFaserWaveform/xAODFaserWaveformDict.h new file mode 100644 index 00000000..6ba4a1ab --- /dev/null +++ b/xAOD/xAODFaserWaveform/xAODFaserWaveform/xAODFaserWaveformDict.h @@ -0,0 +1,33 @@ +/* + Copyright (C) 2020 CERN for the benefit of the FASER collaboration +*/ + +#ifndef XAODFASERWAVEFORM_XAODFASERWAVEFORMDICT_H +#define XAODFASERWAVEFORM_XAODFASERWAVEFORMDICT_H + +// Local includes +#include "xAODFaserWaveform/WaveformHit.h" +#include "xAODFaserWaveform/WaveformHitContainer.h" +#include "xAODFaserWaveform/WaveformHitAuxContainer.h" + +#include "xAODFaserWaveform/WaveformClock.h" +#include "xAODFaserWaveform/WaveformClockAuxInfo.h" + +#include "xAODFaserWaveform/versions/WaveformHit_v1.h" +#include "xAODFaserWaveform/versions/WaveformHitContainer_v1.h" +#include "xAODFaserWaveform/versions/WaveformHitAuxContainer_v1.h" + +#include "xAODFaserWaveform/versions/WaveformClock_v1.h" +#include "xAODFaserWaveform/versions/WaveformClockAuxInfo_v1.h" + +// EDM include(s). +#include "xAODCore/tools/DictHelpers.h" + +namespace { + struct GCCXML_DUMMY_INSTANTIATION_XAODFASERWAVEFORM { + XAOD_INSTANTIATE_NS_CONTAINER_TYPES( xAOD, WaveformHitContainer_v1 ); + XAOD_INSTANTIATE_NS_OBJECT_TYPES( xAOD, WaveformClock_v1 ); + } +} + +#endif // XAODFASERWAVEFORM_XAODFASERWAVEFORMDICT_H -- GitLab