Back to home page

EIC code displayed by LXR

 
 

    


Warning, file /include/root/TRootSnifferFull.h was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 // $Id$
0002 // Author: Sergey Linev   23/02/2018
0003 
0004 /*************************************************************************
0005  * Copyright (C) 1995-2018, Rene Brun and Fons Rademakers.               *
0006  * All rights reserved.                                                  *
0007  *                                                                       *
0008  * For the licensing terms see $ROOTSYS/LICENSE.                         *
0009  * For the list of contributors see $ROOTSYS/README/CREDITS.             *
0010  *************************************************************************/
0011 
0012 #ifndef ROOT_TRootSnifferFull
0013 #define ROOT_TRootSnifferFull
0014 
0015 #include "TRootSniffer.h"
0016 #include <string>
0017 
0018 class TMemFile;
0019 
0020 class TRootSnifferFull : public TRootSniffer {
0021 protected:
0022    TMemFile *fMemFile{nullptr}; ///<! file used to manage streamer infos
0023    TList *fSinfo{nullptr};      ///<! last produced streamer info
0024 
0025    void ScanObjectProperties(TRootSnifferScanRec &rec, TObject *obj) override;
0026 
0027    void ScanKeyProperties(TRootSnifferScanRec &rec, TKey *key, TObject *&obj, TClass *&obj_class) override;
0028 
0029    void ScanObjectChilds(TRootSnifferScanRec &rec, TObject *obj) override;
0030 
0031    void CreateMemFile();
0032 
0033    Bool_t CanDrawClass(TClass *cl) override { return IsDrawableClass(cl); }
0034 
0035    Bool_t HasStreamerInfo() const override { return kTRUE; }
0036 
0037    Bool_t ProduceBinary(const std::string &path, const std::string &options, std::string &res) override;
0038 
0039    Bool_t ProduceRootFile(const std::string &path, const std::string &options, std::string &res) override;
0040 
0041    Bool_t ProduceImage(Int_t kind, const std::string &path, const std::string &options, std::string &res) override;
0042 
0043    Bool_t ProduceXml(const std::string &path, const std::string &options, std::string &res) override;
0044 
0045    Bool_t ProduceExe(const std::string &path, const std::string &options, Int_t reskind, std::string &res) override;
0046 
0047    Bool_t CallProduceImage(const std::string &kind, const std::string &path, const std::string &options, std::string &res) override;
0048 
0049 public:
0050    TRootSnifferFull(const char *name = "sniff", const char *objpath = "Objects");
0051    virtual ~TRootSnifferFull();
0052 
0053    static Bool_t IsDrawableClass(TClass *cl);
0054 
0055    Bool_t IsStreamerInfoItem(const char *itemname) override;
0056 
0057    ULong_t GetStreamerInfoHash() override;
0058 
0059    ULong_t GetItemHash(const char *itemname) override;
0060 
0061    void *FindInHierarchy(const char *path, TClass **cl = nullptr, TDataMember **member = nullptr, Int_t *chld = nullptr) override;
0062 
0063    ClassDefOverride(TRootSnifferFull, 0) // Sniffer for many ROOT classes, including histograms, graphs, pads and tree
0064 };
0065 
0066 #endif