test
Main Page
Namespaces
Classes
Package Documentation
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
CondFormats
SiPixelObjects
interface
LinearConversion.h
Go to the documentation of this file.
1
#ifndef SiPixelObjects_LinearConversion_H
2
#define SiPixelObjects_LinearConversion_H
3
4
namespace
sipixelobjects {
5
6
class
LinearConversion
{
7
8
public
:
9
LinearConversion
(
int
offset
=0,
int
slope
=1) :
theOffset
(
offset
),
theSlope
(
slope
) { }
10
int
convert
(
int
item)
const
{
return
theOffset
+
theSlope
*item; }
11
int
inverse
(
int
item)
const
{
return
(item -
theOffset
)/
theSlope
; }
12
int
offset
()
const
{
return
theOffset
; }
13
int
slope
()
const
{
return
theSlope
; }
14
15
private
:
16
int
theOffset
,
theSlope
;
17
};
18
19
}
20
#endif
sipixelobjects::LinearConversion::theSlope
int theSlope
Definition:
LinearConversion.h:16
sipixelobjects::LinearConversion::offset
int offset() const
Definition:
LinearConversion.h:12
sipixelobjects::LinearConversion::slope
int slope() const
Definition:
LinearConversion.h:13
sipixelobjects::LinearConversion
Definition:
LinearConversion.h:6
sipixelobjects::LinearConversion::convert
int convert(int item) const
Definition:
LinearConversion.h:10
sipixelobjects::LinearConversion::LinearConversion
LinearConversion(int offset=0, int slope=1)
Definition:
LinearConversion.h:9
sipixelobjects::LinearConversion::theOffset
int theOffset
Definition:
LinearConversion.h:16
sipixelobjects::LinearConversion::inverse
int inverse(int item) const
Definition:
LinearConversion.h:11
Generated for CMSSW Reference Manual by
1.8.5