ROOT
git-r3/HEAD
Reference Guide
Loading...
Searching...
No Matches
RNTupleItem.hxx
Go to the documentation of this file.
1
/*************************************************************************
2
* Copyright (C) 1995-2025, Rene Brun and Fons Rademakers. *
3
* All rights reserved. *
4
* *
5
* For the licensing terms see $ROOTSYS/LICENSE. *
6
* For the list of contributors see $ROOTSYS/README/CREDITS. *
7
*************************************************************************/
8
9
#ifndef ROOT7_Browsable_RNTupleItem
10
#define ROOT7_Browsable_RNTupleItem
11
12
#include <
ROOT/Browsable/RItem.hxx
>
13
14
namespace
ROOT
{
15
namespace
Browsable
{
16
17
/** \class RNTupleItem
18
\ingroup rbrowser
19
\brief Representation of an RNTuple item in the browser
20
\author Patryk Tymoteusz Pilichowski
21
*/
22
23
class
RNTupleItem
:
public
RItem
{
24
public
:
25
enum
ECategory
{
26
kField
,
27
kVisualization
28
};
29
30
RNTupleItem
() =
default
;
31
RNTupleItem
(
const
std::string &_name,
int
_nchilds = 0,
const
std::string &_icon =
""
,
ECategory
_category =
kField
)
32
:
RItem
(_name, _nchilds, _icon),
category
(_category)
33
{
34
}
35
// must be here, one needs virtual table for correct streaming of sub-classes
36
virtual
~RNTupleItem
() =
default
;
37
38
bool
IsVisualization
()
const
{
return
category
==
kVisualization
; }
39
bool
IsField
()
const
{
return
category
==
kField
; }
40
41
bool
Compare
(
const
RItem
*
b
,
const
std::string &s)
const override
42
{
43
auto
tuple_b =
dynamic_cast<
const
RNTupleItem
*
>
(
b
);
44
if
(tuple_b !=
nullptr
&& (
IsVisualization
() || tuple_b->IsVisualization()))
45
return
IsVisualization
();
46
return
RItem::Compare
(
b
, s);
47
}
48
49
protected
:
50
ECategory
category
{
kField
};
51
};
52
53
}
// namespace Browsable
54
}
// namespace ROOT
55
56
#endif
RItem.hxx
b
#define b(i)
Definition
RSha256.hxx:100
ROOT::Browsable::RItem::Compare
virtual bool Compare(const RItem *b, const std::string &) const
Definition
RItem.hxx:73
ROOT::Browsable::RItem::RItem
RItem()=default
ROOT::Browsable::RNTupleItem::~RNTupleItem
virtual ~RNTupleItem()=default
ROOT::Browsable::RNTupleItem::IsVisualization
bool IsVisualization() const
Definition
RNTupleItem.hxx:38
ROOT::Browsable::RNTupleItem::RNTupleItem
RNTupleItem(const std::string &_name, int _nchilds=0, const std::string &_icon="", ECategory _category=kField)
Definition
RNTupleItem.hxx:31
ROOT::Browsable::RNTupleItem::RNTupleItem
RNTupleItem()=default
ROOT::Browsable::RNTupleItem::category
ECategory category
Definition
RNTupleItem.hxx:50
ROOT::Browsable::RNTupleItem::ECategory
ECategory
Definition
RNTupleItem.hxx:25
ROOT::Browsable::RNTupleItem::kField
@ kField
Definition
RNTupleItem.hxx:26
ROOT::Browsable::RNTupleItem::kVisualization
@ kVisualization
Definition
RNTupleItem.hxx:27
ROOT::Browsable::RNTupleItem::Compare
bool Compare(const RItem *b, const std::string &s) const override
Definition
RNTupleItem.hxx:41
ROOT::Browsable::RNTupleItem::IsField
bool IsField() const
Definition
RNTupleItem.hxx:39
ROOT::Browsable
Definition
RAnyObjectHolder.hxx:15
ROOT
Definition
EExecutionPolicy.hxx:4
gui
browsable
inc
ROOT
Browsable
RNTupleItem.hxx
ROOTgit-r3/HEAD - Reference Guide Generated on
(GVA Time) using Doxygen 1.16.1