CLHEP
2.4.6.4
C++ Class Library for High Energy Physics
Loading...
Searching...
No Matches
Abs.hh
Go to the documentation of this file.
1
// $Id:
2
// -*- C++ -*-
3
//
4
//----------------------Abs---------- --------------------------------------//
5
// //
6
// Class Abs //
7
// Joe Boudreau, Petar Maksimovic, Nov. 1999 //
8
// //
9
// Abs is a function that returns the absolute value of its argument //
10
//--------------------------------------------------------------------------//
11
#ifndef Abs_h
12
#define Abs_h 1
13
#include "CLHEP/GenericFunctions/AbsFunction.hh"
14
namespace
Genfun
{
15
class
Abs
:
public
AbsFunction
{
16
17
FUNCTION_OBJECT_DEF
(
Abs
)
18
19
public
:
20
21
// Constructor
22
Abs
();
23
24
// Copy constructor
25
Abs
(
const
Abs
&right);
26
27
// Destructor
28
virtual
~Abs
();
29
30
// Retrieve function value
31
virtual
double
operator ()
(
double
argument)
const override
;
32
virtual
double
operator ()
(
const
Argument
& a)
const override
{
return
operator()
(a[0]);}
33
34
private
:
35
36
// It is illegal to assign a fixed constant
37
const
Abs
& operator=(
const
Abs
&right);
38
39
};
40
}
41
42
#endif
FUNCTION_OBJECT_DEF
#define FUNCTION_OBJECT_DEF(classname)
Definition:
AbsFunction.hh:143
Genfun::AbsFunction
Definition:
AbsFunction.hh:48
Genfun::Abs
Definition:
Abs.hh:15
Genfun::Abs::Abs
Abs()
Definition:
Abs.cc:11
Genfun::Abs::~Abs
virtual ~Abs()
Definition:
Abs.cc:18
Genfun::Abs::operator()
virtual double operator()(double argument) const override
Definition:
Abs.cc:21
Genfun::Argument
Definition:
Argument.hh:17
Genfun
Definition:
Abs.hh:14
CLHEP-CLHEP_2_4_6_4
GenericFunctions
GenericFunctions
Abs.hh
Generated by
1.9.6