Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
hcana
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
jlab
hallc
analyzer_software
hcana
Commits
2b03efaf
Commit
2b03efaf
authored
13 years ago
by
Stephen A. Wood
Browse files
Options
Downloads
Patches
Plain Diff
THcHodoscopHit compiles
parent
e514e996
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/THcHodoscopeHit.cxx
+9
-5
9 additions, 5 deletions
src/THcHodoscopeHit.cxx
src/THcHodoscopeHit.h
+11
-5
11 additions, 5 deletions
src/THcHodoscopeHit.h
with
20 additions
and
10 deletions
src/THcHodoscopeHit.cxx
+
9
−
5
View file @
2b03efaf
...
...
@@ -10,21 +10,22 @@
#include
"THcHodoscopeHit.h"
ClassImp
(
ThcHodoscopeHit
)
using
namespace
std
;
void
SetData
(
Int_t
signal
,
Int_t
data
)
{
void
THcHodoscopeHit
::
SetData
(
Int_t
signal
,
Int_t
data
)
{
if
(
signal
==
1
)
{
fADC_pos
=
data
;
}
else
if
(
signal
==
2
)
{
fADC_ne
t
=
data
;
fADC_ne
g
=
data
;
}
else
if
(
signal
==
3
)
{
fADC_pos
=
data
;
}
else
if
(
signal
==
4
)
{
fADC_ne
t
=
data
;
fADC_ne
g
=
data
;
}
}
Int_t
GetData
(
Int_t
signal
)
{
Int_t
THcHodoscopeHit
::
GetData
(
Int_t
signal
)
{
if
(
signal
==
1
)
{
return
(
fADC_pos
);
}
else
if
(
signal
==
2
)
{
...
...
@@ -34,6 +35,9 @@ Int_t GetData(Int_t signal) {
}
else
if
(
signal
==
4
)
{
return
(
fADC_neg
);
}
return
(
-
1
);
// Actually should throw exception
}
//////////////////////////////////////////////////////////////////////////
ClassImp
(
THcHodoscopeHit
)
This diff is collapsed.
Click to expand it.
src/THcHodoscopeHit.h
+
11
−
5
View file @
2b03efaf
#ifndef ROOT_THcHodoscopeHit
#define ROOT_THcHodoscopeHit
// Should we have a generic hit object that we inherit from? (A template,
// whatever that is?)
#include
"TObject.h"
class
THcHodoscopeHit
:
public
TObject
{
public:
THcHodoscopeHit
(
Int_t
plane
,
Int_t
counter
)
:
fPlane
(
plane
),
fCounter
(
counter
),
fADC_pos
(
-
1
),
fADC_net
(
-
1
),
fTDC_pos
(
-
1
),
fTDC_net
(
-
1
)
{}
virtual
~
THcHodosscopeHit
()
{}
THcHodoscopeHit
(
Int_t
plane
,
Int_t
counter
)
:
fPlane
(
plane
),
fCounter
(
counter
),
fADC_pos
(
-
1
),
fADC_neg
(
-
1
),
fTDC_pos
(
-
1
),
fTDC_neg
(
-
1
)
{}
virtual
~
THcHodoscopeHit
()
{}
void
SetData
(
Int_t
signal
,
Int_t
data
);
Int_t
GetData
(
Int_t
signal
);
Int_t
fPlane
;
Int_t
fCounter
;
...
...
@@ -24,7 +30,7 @@ class THcHodoscopeHit : public TObject {
private
:
ClassDef
(
TH
a
HodoscopeHit
,
0
);
ClassDef
(
TH
c
HodoscopeHit
,
0
);
// Hodoscope hit class
};
#endif
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment