FairRoot/PandaRoot
Public Member Functions | Private Attributes | List of all members
PndFieldAdaptor Class Reference

#include <PndFieldAdaptor.h>

Inheritance diagram for PndFieldAdaptor:
GFAbsBField

Public Member Functions

 PndFieldAdaptor ()
 
 PndFieldAdaptor (FairField *field)
 
TVector3 get (const TVector3 &) const
 override this is you concrete implementation More...
 
 ClassDef (PndFieldAdaptor, 1)
 

Private Attributes

FairField * fField
 

Detailed Description

Definition at line 32 of file PndFieldAdaptor.h.

Constructor & Destructor Documentation

PndFieldAdaptor::PndFieldAdaptor ( )
inline

Definition at line 36 of file PndFieldAdaptor.h.

References fField.

36 {fField=NULL;}
FairField * fField
PndFieldAdaptor::PndFieldAdaptor ( FairField *  field)

Definition at line 33 of file PndFieldAdaptor.cxx.

34  : fField(field)
35 {}
FairField * fField

Member Function Documentation

PndFieldAdaptor::ClassDef ( PndFieldAdaptor  ,
 
)
TVector3 PndFieldAdaptor::get ( const TVector3 &  ) const
virtual

override this is you concrete implementation

Implements GFAbsBField.

Definition at line 38 of file PndFieldAdaptor.cxx.

References Double_t, f, fField, and x.

38  {
39  assert(fField!=NULL);
40  Double_t x[3];
41  x[0] = pos.X();
42  x[1] = pos.Y();
43  x[2] = pos.Z();
44 
45  Double_t f[3];
46  fField->GetFieldValue(x,f);
47  //std::cout << "PndFieldAdapter::get() field at "
48  // <<x[0]<<","<<x[1]<<","<<x[2]<<" has value "
49  // <<f[0]<<","<<f[1]<<","<<f[2]<<std::endl;
50  return TVector3(f[0],f[1],f[2]);
51 }
TVector3 pos
FairField * fField
Double_t
TFile * f
Definition: bump_analys.C:12
Double_t x

Member Data Documentation

FairField* PndFieldAdaptor::fField
private

Definition at line 46 of file PndFieldAdaptor.h.

Referenced by get(), and PndFieldAdaptor().


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