test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
UniformMagneticField Class Reference

#include <UniformMagneticField.h>

Inheritance diagram for UniformMagneticField:
MagneticField

Public Member Functions

GlobalVector inTesla (const GlobalPoint &gp) const
 Field value ad specified global point, in Tesla. More...
 
GlobalVector inTeslaUnchecked (const GlobalPoint &gp) const
 
bool isDefined (const GlobalPoint &gp) const
 True if the point is within the region where the concrete field. More...
 
 UniformMagneticField (double value)
 Construct passing the Z field component in Tesla. More...
 
virtual ~UniformMagneticField ()
 
- Public Member Functions inherited from MagneticField
virtual MagneticFieldclone () const
 
GlobalVector inInverseGeV (const GlobalPoint &gp) const
 Field value ad specified global point, in 1/Gev. More...
 
GlobalVector inKGauss (const GlobalPoint &gp) const
 Field value ad specified global point, in KGauss. More...
 
 MagneticField ()
 
 MagneticField (const MagneticField &orig)
 
int nominalValue () const
 The nominal field value for this map in kGauss. More...
 
virtual ~MagneticField ()
 

Private Attributes

GlobalVector theField
 

Detailed Description

A MagneticField engine that returns a constant programmable field value.

Author
N. Amapane - CERN

Definition at line 14 of file UniformMagneticField.h.

Constructor & Destructor Documentation

UniformMagneticField::UniformMagneticField ( double  value)

Construct passing the Z field component in Tesla.

Definition at line 11 of file UniformMagneticField.cc.

virtual UniformMagneticField::~UniformMagneticField ( )
inlinevirtual

Definition at line 20 of file UniformMagneticField.h.

20 {}

Member Function Documentation

GlobalVector UniformMagneticField::inTesla ( const GlobalPoint gp) const
virtual

Field value ad specified global point, in Tesla.

Implements MagneticField.

Definition at line 15 of file UniformMagneticField.cc.

References theField.

15  {
16  return theField;
17 }
GlobalVector UniformMagneticField::inTeslaUnchecked ( const GlobalPoint gp) const
virtual

Optional implementation that derived classes can implement to provide faster query by skipping the check to isDefined.

Reimplemented from MagneticField.

Definition at line 19 of file UniformMagneticField.cc.

References theField.

19  {
20  return theField;
21 }
bool UniformMagneticField::isDefined ( const GlobalPoint ) const
inlinevirtual

True if the point is within the region where the concrete field.

Reimplemented from MagneticField.

Definition at line 26 of file UniformMagneticField.h.

26 {return true;}

Member Data Documentation

GlobalVector UniformMagneticField::theField
private

Definition at line 29 of file UniformMagneticField.h.

Referenced by inTesla(), and inTeslaUnchecked().