 |
Belle II Software
release-05-01-25
|
1 #include <mdst/dataobjects/KlId.h>
2 #include <mdst/dataobjects/ECLCluster.h>
3 #include <mdst/dataobjects/KLMCluster.h>
4 #include <framework/datastore/StoreArray.h>
5 #include <gtest/gtest.h>
26 DataStore::Instance().setInitializeActive(
true);
28 eclClusters.registerInDataStore();
30 klmClusters.registerInDataStore();
32 klids.registerInDataStore();
41 EXPECT_FALSE(klid->
isECL());
42 EXPECT_FALSE(klid->
isKLM());
43 EXPECT_TRUE(std::isnan(klid->
getKlId()));
48 EXPECT_TRUE(klid->
isECL());
49 EXPECT_TRUE(klid->
isKLM());
50 EXPECT_EQ(0.5, klid->
getKlId());
T * appendNew()
Construct a new T object at the end of the array.
bool registerRelationTo(const StoreArray< TO > &toArray, DataStore::EDurability durability=DataStore::c_Event, DataStore::EStoreFlags storeFlags=DataStore::c_WriteOut, const std::string &namedRelation="") const
Register a relation to the given StoreArray.
Helper functions for all klid modules to improve readability of the code.
void addRelationTo(const RelationsInterface< BASE > *object, float weight=1.0, const std::string &namedRelation="") const
Add a relation from this object to another object (with caching).
TEST_F(KlIdTest, SettersAndGetters)
Test setter and getter.
Abstract base class for different kinds of events.
double getKlId() const
get the klong classifier output
Test class for the KlId object.
bool isKLM() const
is this ID originally a KLM Cluster ?
Accessor to arrays stored in the data store.
bool isECL() const
is this ID originally a ECL Cluster ?