CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_6_1_1/src/Alignment/HIPAlignmentAlgorithm/interface/HIPUserVariablesIORoot.h

Go to the documentation of this file.
00001 #ifndef HIPUserVariablesIORoot_H
00002 #define HIPUserVariablesIORoot_H
00003 
00004 #include "Alignment/CommonAlignmentAlgorithm/interface/AlignmentIORootBase.h"
00005 #include "Alignment/CommonAlignmentAlgorithm/interface/AlignmentUserVariablesIO.h"
00006 
00009 class HIPUserVariablesIORoot : public AlignmentIORootBase,
00010                                  public AlignmentUserVariablesIO
00011 {
00012 
00013   public:
00014 
00015   typedef std::vector<Alignable*> Alignables;
00016 
00018   HIPUserVariablesIORoot(); 
00019 
00021   void writeHIPUserVariables (const Alignables& alivec, 
00022     const char* filename, int iter, bool validCheck, int& ierr);
00023 
00025   std::vector<AlignmentUserVariables*> readHIPUserVariables 
00026     (const Alignables& alivec, const char* filename, int iter, int& ierr);
00027 
00028 
00029 
00030   private:
00031 
00033   int writeOne(Alignable* ali);
00034 
00036   AlignmentUserVariables* readOne(Alignable* ali, int& ierr);
00037 
00039   int open(const char* filename, int iteration, bool writemode)
00040     {newopen=true; return openRoot(filename,iteration,writemode);};
00041 
00043   int close(void) {return closeRoot();};
00044 
00045   // helper functions
00046 
00047   int findEntry(unsigned int detId,int comp);
00048   void createBranches(void);
00049   void setBranchAddresses(void);
00050 
00051   // data members
00052 
00053   static const int nparmax=6;
00054 
00056   int ObjId;
00057   unsigned int Id;
00058   int Nhit,Nparj,Npare;
00059   double Jtvj[nparmax*(nparmax+1)/2];
00060   double Jtve[nparmax];
00061   double AlignableChi2;
00062   unsigned int AlignableNdof;
00063 
00064   bool newopen;
00065   typedef  std::map< std::pair<int,int> , int > treemaptype;
00066   treemaptype treemap;
00067 
00068 };
00069 
00070 #endif