Belle II Software development
RelationElement.cc
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8
9#include <framework/dataobjects/RelationElement.h>
10
11#include <framework/logging/Logger.h>
12
13#include <climits>
14
15using namespace std;
16using namespace Belle2;
17
18RelationElement::RelationElement(index_type from, const std::vector<index_type>& to, const std::vector<weight_type>& weights):
19 TObject(),
20 m_from(from),
21 m_to(to.begin(), to.end()),
22 m_weights(weights.begin(), weights.end())
23{
24 if (to.size() != weights.size()) {
25 B2FATAL("Index and weight vector sizes differ!");
26 }
27}
29 TObject(), m_from(UINT_MAX), m_to(), m_weights()
30{
31
32}
RelationElement()
Empty constructor for ROOT.
unsigned int index_type
type used for indices.
Abstract base class for different kinds of events.
STL namespace.