Public Member Functions | Public Attributes | List of all members
caf::Proxy< caf::SRVector3D > Class Template Reference

Proxy for caf::SRVector3D. More...

#include "/cvmfs/nova-development.opensciencegrid.org/novasoft/releases/N20-11-30/StandardRecord/Proxy/SRProxy.h"

Public Member Functions

 Proxy (TDirectory *d, TTree *tr, const std::string &name, const long &base, int offset)
 
 Proxy (const Proxy &)=delete
 
 Proxy (const Proxy &&)=delete
 
Proxyoperator= (const caf::SRVector3D &x)
 
void CheckEquals (const caf::SRVector3D &sr) const
 
float X () const
 
float Y () const
 
float Z () const
 
 operator TVector3 () const
 
float Mag2 () const
 
float Mag () const
 
float Dot (const Proxy &v) const
 
float Dot (const TVector3 &v) const
 
TVector3 Unit () const
 

Public Attributes

caf::Proxy< float > x
 
caf::Proxy< float > y
 
caf::Proxy< float > z
 

Detailed Description

template<>
class caf::Proxy< caf::SRVector3D >

Proxy for caf::SRVector3D.

Definition at line 78 of file SRProxy.h.

Constructor & Destructor Documentation

caf::Proxy< caf::SRVector3D >::Proxy ( TDirectory *  d,
TTree *  tr,
const std::string name,
const long &  base,
int  offset 
)

Definition at line 125 of file SRProxy.cxx.

125  :
126  x(d, tr, Join(name, "x"), base, offset),
127  y(d, tr, Join(name, "y"), base, offset),
128  z(d, tr, Join(name, "z"), base, offset)
129 {
130 }
const XML_Char * name
Definition: expat.h:151
const XML_Char int const XML_Char int const XML_Char * base
Definition: expat.h:331
std::string Join(const std::string &a, const std::string &b)
Definition: HDF5Record.h:17
caf::Proxy< float > z
Definition: SRProxy.h:108
caf::Proxy< float > x
Definition: SRProxy.h:106
Float_t d
Definition: plot.C:236
caf::Proxy< float > y
Definition: SRProxy.h:107
caf::Proxy< caf::SRVector3D >::Proxy ( const Proxy< caf::SRVector3D > &  )
delete
caf::Proxy< caf::SRVector3D >::Proxy ( const Proxy< caf::SRVector3D > &&  )
delete

Member Function Documentation

void caf::Proxy< caf::SRVector3D >::CheckEquals ( const caf::SRVector3D sr) const

Definition at line 140 of file SRProxy.cxx.

References caf::SRVector3D::x, submit_syst::x, caf::SRVector3D::y, submit_syst::y, test::z, and caf::SRVector3D::z.

141 {
142  x.CheckEquals(sr.x);
143  y.CheckEquals(sr.y);
144  z.CheckEquals(sr.z);
145 }
caf::Proxy< float > z
Definition: SRProxy.h:108
caf::Proxy< float > x
Definition: SRProxy.h:106
caf::Proxy< float > y
Definition: SRProxy.h:107
void CheckEquals(const T &x) const
float caf::Proxy< caf::SRVector3D >::Dot ( const Proxy< caf::SRVector3D > &  v) const
inline

Definition at line 98 of file SRProxy.h.

References submit_syst::y, and test::z.

98 {return x*v.x + y*v.y + z*v.z;}
caf::Proxy< float > z
Definition: SRProxy.h:108
caf::Proxy< float > x
Definition: SRProxy.h:106
caf::Proxy< float > y
Definition: SRProxy.h:107
float caf::Proxy< caf::SRVector3D >::Dot ( const TVector3 &  v) const
inline

Definition at line 99 of file SRProxy.h.

References caf::SRVector3D::X(), submit_syst::y, and test::z.

99 {return x*v.X() + y*v.Y() + z*v.Z();}
caf::Proxy< float > z
Definition: SRProxy.h:108
caf::Proxy< float > x
Definition: SRProxy.h:106
caf::Proxy< float > y
Definition: SRProxy.h:107
float caf::Proxy< caf::SRVector3D >::Mag ( ) const
inline

Definition at line 97 of file SRProxy.h.

References Mag2(), and std::sqrt().

97 {return sqrt(Mag2());}
T sqrt(T number)
Definition: d0nt_math.hpp:156
float caf::Proxy< caf::SRVector3D >::Mag2 ( ) const
inline

Definition at line 96 of file SRProxy.h.

References submit_syst::y, and test::z.

96 {return x*x+y*y+z*z;}
caf::Proxy< float > z
Definition: SRProxy.h:108
caf::Proxy< float > x
Definition: SRProxy.h:106
caf::Proxy< float > y
Definition: SRProxy.h:107
caf::Proxy< caf::SRVector3D >::operator TVector3 ( ) const
inline

Definition at line 94 of file SRProxy.h.

References submit_syst::y, and test::z.

94 {return TVector3(x, y, z);}
caf::Proxy< float > z
Definition: SRProxy.h:108
caf::Proxy< float > x
Definition: SRProxy.h:106
caf::Proxy< float > y
Definition: SRProxy.h:107

Definition at line 132 of file SRProxy.cxx.

References caf::SRVector3D::x, submit_syst::x, caf::SRVector3D::y, submit_syst::y, test::z, and caf::SRVector3D::z.

133 {
134  x = sr.x;
135  y = sr.y;
136  z = sr.z;
137  return *this;
138 }
caf::Proxy< float > z
Definition: SRProxy.h:108
caf::StandardRecord * sr
caf::Proxy< float > y
Definition: SRProxy.h:107
TVector3 caf::Proxy< caf::SRVector3D >::Unit ( ) const
inline

Definition at line 100 of file SRProxy.h.

References m, Mag(), submit_syst::y, and test::z.

101  {
102  const float m = Mag();
103  return TVector3(x/m, y/m, z/m);
104  }
caf::Proxy< float > z
Definition: SRProxy.h:108
caf::Proxy< float > x
Definition: SRProxy.h:106
caf::Proxy< float > y
Definition: SRProxy.h:107
float caf::Proxy< caf::SRVector3D >::X ( ) const
inline
float caf::Proxy< caf::SRVector3D >::Y ( ) const
inline
float caf::Proxy< caf::SRVector3D >::Z ( ) const
inline

Member Data Documentation


The documentation for this class was generated from the following files: