ATLAS Offline Software
Functions
CopyFloatWithErrorcode.h File Reference

Copies a single float from a persistent LAr calibration object, protected against roundoff errors. More...

#include "LArElecCalib/LArCalibErrorCode.h"
#include <math.h>
Include dependency graph for CopyFloatWithErrorcode.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

float copyFloatPT (const float &pers)
 

Detailed Description

Copies a single float from a persistent LAr calibration object, protected against roundoff errors.

Author
Walter Lampl walte.nosp@m.r.la.nosp@m.mpl@c.nosp@m.ern..nosp@m.ch
Id
CopyFloatWithErrorcode.h,v 1.1 2009-04-27 15:22:44 gunal Exp

Definition in file CopyFloatWithErrorcode.h.

Function Documentation

◆ copyFloatPT()

float copyFloatPT ( const float &  pers)
inline

Definition at line 21 of file CopyFloatWithErrorcode.h.

21  {
22  //Protect against rounding effects and nans.
23  if (std::isnan(pers) || pers<=1.0+LArElecCalib::ERRORCODE)
24  return (float)LArElecCalib::ERRORCODE;
25  else
26  return pers;
27 }
LArElecCalib::ERRORCODE
@ ERRORCODE
Definition: LArCalibErrorCode.h:17