library: libXMLIO #include "TXMLSetup.h"

# TXMLSetup

class description - source file - inheritance tree (.pdf)

## class TXMLSetup

| Inheritance Chart:
`TXMLSetup` |
<- |
`TBufferXML` |
`TXMLFile` |

        protected:

                Int_t AtoI(const char* sbuf, Int_t def = 0, const char* errinfo = "0")
          const char* GetElItemName(TStreamerElement* el) const
               Bool_t IsValidXmlSetup(const char* setupstr)
               Bool_t ReadSetupFromStr(const char* setupstr)
              TClass* XmlDefineClass(const char* xmlClassName)

        public:

                                TXMLSetup()
                                TXMLSetup(const char* opt)
                                TXMLSetup(const TXMLSetup& src)
                        virtual ~TXMLSetup()
                 static TClass* Class()
                 static TString DefaultXmlSetup()
                          Int_t GetNextRefCounter()
                        TString GetSetupAsString()
          TXMLSetup::EXMLLayout GetXmlLayout() const
                virtual TClass* IsA() const
                         Bool_t IsStoreStreamerInfos() const
                         Bool_t IsUseDtd() const
                         Bool_t IsUseNamespaces() const
                     TXMLSetup& operator=(const TXMLSetup&)
                           void PrintSetup()
                    static void SetNameSpaceBase(const char* namespacebase)
                   virtual void SetStoreStreamerInfos(Bool_t iConvert = kTRUE)
                   virtual void SetUsedDtd(Bool_t use = kTRUE)
                   virtual void SetUseNamespaces(Bool_t iUseNamespaces = kTRUE)
                   virtual void SetXmlLayout(TXMLSetup::EXMLLayout layout)
                   virtual void ShowMembers(TMemberInspector& insp, char* parent)
                   virtual void Streamer(TBuffer& b)
                           void StreamerNVirtual(TBuffer& b)
                    const char* XmlClassNameSpaceRef(const TClass* cl) const
                    const char* XmlConvertClassName(const char* name) const
                    const char* XmlGetElementName(const TStreamerElement* el) const

### Data Members

        protected:

          TXMLSetup::EXMLLayout fXmlLayout
                         Bool_t fStoreStreamerInfos
                         Bool_t fUseDtd
                         Bool_t fUseNamespaces
                          Int_t fRefCounter          !  counter , used to build id of xml references
                        TString fStrBuf              !  buffer, used in XmlDefineClass() function
                 static TString fNameSpaceBase

        public:

          static const TXMLSetup::EXMLLayout kSpecialized
          static const TXMLSetup::EXMLLayout kGeneralized

## Class Description

     Class TXMLSetup is used as storage of settings, relevant for storing data
     in xml file. This class is used in TXMLFile and in TXmlBuffer classes.
     Xml settings can be codded via a string in following format

       "2xoo"
        ||| \ .
        || \ usage of name spaces.
        | \ usage of DTD;
         \ storage of TStreamerInfo objects in file;
          layout of xml file (= 2 - specialized (default), = 3 - generic)

     For last three boolean parameters "x" means true, "o" - false

     Such string can be set as argument of TXMLFile constructor. In that
     case new TXMLFile with such parameters will be created.
     These settings automatically stored in xml file.

TString DefaultXmlSetup()

void SetNameSpaceBase(const char* namespacebase)

TXMLSetup() : fXmlLayout(kSpecialized), fStoreStreamerInfos(kTRUE), fUseDtd(kFALSE), fUseNamespaces(kFALSE), fRefCounter(0)

TXMLSetup(const char* opt) : fRefCounter(0)

TXMLSetup(const TXMLSetup& src) : fXmlLayout(src.fXmlLayout), fStoreStreamerInfos(src.fStoreStreamerInfos), fUseDtd(src.fUseDtd), fUseNamespaces(src.fUseNamespaces), fRefCounter(0)

~TXMLSetup()

TString GetSetupAsString()

Bool_t IsValidXmlSetup(const char* setupstr)

Bool_t ReadSetupFromStr(const char* setupstr)

void PrintSetup()

const char* XmlConvertClassName(const char* clname)

const char* XmlClassNameSpaceRef(const TClass* cl)

const char* XmlGetElementName(const TStreamerElement* el)

const char* GetElItemName(TStreamerElement* el)

TClass* XmlDefineClass(const char* xmlClassName)

Int_t AtoI(const char* sbuf, Int_t def, const char* errinfo)

### Inline Functions

            TXMLSetup::EXMLLayout GetXmlLayout() const
                           Bool_t IsStoreStreamerInfos() const
                           Bool_t IsUseDtd() const
                           Bool_t IsUseNamespaces() const
                             void SetXmlLayout(TXMLSetup::EXMLLayout layout)
                             void SetStoreStreamerInfos(Bool_t iConvert = kTRUE)
                             void SetUsedDtd(Bool_t use = kTRUE)
                             void SetUseNamespaces(Bool_t iUseNamespaces = kTRUE)
                            Int_t GetNextRefCounter()
                          TClass* Class()
                          TClass* IsA() const
                             void ShowMembers(TMemberInspector& insp, char* parent)
                             void Streamer(TBuffer& b)
                             void StreamerNVirtual(TBuffer& b)
                       TXMLSetup& operator=(const TXMLSetup&)

Author: Sergey Linev 10.05.2004
Last update: root/xml:$Name: $:$Id: TXMLSetup.cxx,v 1.6 2004/06/29 14:45:38 brun Exp $
Copyright (C) 1995-2004, Rene Brun and Fons Rademakers. *