Logo ROOT  
Reference Guide
REveDataSimpleProxyBuilder.hxx
Go to the documentation of this file.
1// @(#)root/eve7:$Id$
2// Authors: Matevz Tadel & Alja Mrak-Tadel, 2019
3
4/*************************************************************************
5 * Copyright (C) 1995-2019, Rene Brun and Fons Rademakers. *
6 * All rights reserved. *
7 * *
8 * For the licensing terms see $ROOTSYS/LICENSE. *
9 * For the list of contributors see $ROOTSYS/README/CREDITS. *
10 *************************************************************************/
11
12#ifndef ROOT7_REveDataProxySimpleBuilder
13#define ROOT7_REveDataProxySimpleBuilder
14
15#include<list>
17
18namespace ROOT {
19namespace Experimental {
20
21class REveDataCollection;
22class REveElement;
23
24class REveCollectionCompound : public REveCompound // ?? Should this be in as REveDataSimpleProxyBuilder.hxx ?????
25{
26private:
28public:
31 virtual REveElement *GetSelectionMaster() override;
32};
33
34//
35//____________________________________________________________________________________
36//
38{
39
40public:
44 struct SPBProduct {
45 std::map<int, REveCollectionCompound*> map;
47 };
48
49 typedef std::map<REveElement*, std::unique_ptr<SPBProduct*> > EProductMap_t;
50
51 virtual REveElement* CreateProduct(const std::string& viewType, const REveViewContext*) override;
52
53protected:
54 void Build(const REveDataCollection* iCollection, REveElement* product, const REveViewContext*) override;
55
56 void BuildViewType(const REveDataCollection* iCollection, REveElement* product, const std::string& viewType, const REveViewContext*) override;
57
58 // Called once for every item in collection, the void* points to the
59 // item properly offset in memory.
60 virtual void Build(const void* data, int index, REveElement* iCollectionHolder, const REveViewContext*) = 0;
61 virtual void BuildViewType(const void* data, int index, REveElement* iCollectionHolder, const std::string& viewType, const REveViewContext*) = 0;
62
63 void ModelChanges(const REveDataCollection::Ids_t& iIds, Product* p) override;
64 void FillImpliedSelected(REveElement::Set_t& impSet, Product* p) override;
65 void Clean() override; // Utility
66 REveCollectionCompound* CreateCompound(bool set_color=true, bool propagate_color_to_all_children=false);
67
68 //int GetItemIdxForCompound() const;
69 bool VisibilityModelChanges(int idx, REveElement*, const std::string& viewType, const REveViewContext*) override;
70
71 std::map<REveElement*, SPBProduct*> fProductMap;
72 REveCompound* GetHolder(REveElement *product, int idx);
73
74private:
76
78};
79//==============================================================================
80
81
82} // namespace Experimental
83} // namespace ROOT
84
85#endif
#define c(i)
Definition: RSha256.hxx:101
Base class for REveUtil visualization elements, providing hierarchy management, rendering control and...
virtual REveElement * GetSelectionMaster() override
Returns the master element - that is:
virtual REveElement * CreateProduct(const std::string &viewType, const REveViewContext *) override
void BuildViewType(const REveDataCollection *iCollection, REveElement *product, const std::string &viewType, const REveViewContext *) override
void FillImpliedSelected(REveElement::Set_t &impSet, Product *p) override
REveCompound * GetHolder(REveElement *product, int idx)
std::map< REveElement *, std::unique_ptr< SPBProduct * > > EProductMap_t
virtual void Build(const void *data, int index, REveElement *iCollectionHolder, const REveViewContext *)=0
bool VisibilityModelChanges(int idx, REveElement *, const std::string &viewType, const REveViewContext *) override
REveDataSimpleProxyBuilder(const REveDataSimpleProxyBuilder &)
std::map< REveElement *, SPBProduct * > fProductMap
void ModelChanges(const REveDataCollection::Ids_t &iIds, Product *p) override
REveCollectionCompound * CreateCompound(bool set_color=true, bool propagate_color_to_all_children=false)
virtual void BuildViewType(const void *data, int index, REveElement *iCollectionHolder, const std::string &viewType, const REveViewContext *)=0
const REveDataSimpleProxyBuilder & operator=(const REveDataSimpleProxyBuilder &)
std::set< REveElement * > Set_t
Definition: REveElement.hxx:64
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...