KaliVeda  1.12/06
Heavy-Ion Analysis Toolkit
KVIDCutLine.cpp
Go to the documentation of this file.
1 /*
2 $Id: KVIDCutLine.cpp,v 1.2 2009/03/03 13:36:00 franklan Exp $
3 $Revision: 1.2 $
4 $Date: 2009/03/03 13:36:00 $
5 */
6 
7 //Created by KVClassFactory on Fri Feb 15 15:00:17 2008
8 //Author: franklan
9 
10 #include "KVIDCutLine.h"
11 #include "Riostream.h"
12 #include "KVIDGraph.h"
13 
14 using namespace std;
15 
17 
18 
19 
22 KVIDCutLine::KVIDCutLine() : fAcceptedDirection("above")
23 {
24  // Default constructor
25 }
26 
27 
28 
31 
33 {
34  // Destructor
35 }
36 
37 
38 
39 
42 
44 {
45  // Write accepted direction for cut
46 
47  if (fAcceptedDirection == "") file << "[undefined accepted direction]" << endl;
48  else file << fAcceptedDirection.Data() << endl;
49 }
50 
51 
52 
53 
56 
58 {
59  // Read accepted direction for cut
60 
61  fAcceptedDirection.ReadLine(file);
62  if (fAcceptedDirection == "[undefined accepted direction]") fAcceptedDirection = "";
63 }
64 
65 
66 
73 
75 {
76  // Set the direction of the acceptable region relative to the cut line
77  // E.g. if points to identify must be above this cut, use
78  // cut->SetAcceptedDirection("above")
79  // Possible values are: "above", "below", "left" or "right"
80  // (see KVIDLine::WhereAmI).
81  fAcceptedDirection = dir;
82  if (GetParent()) GetParent()->Modified();
83 }
84 
85 
86 
ClassImp(KVPartitionList) void KVPartitionList
Initialisation.
char Char_t
Line in ID grid used to delimit regions where no identification is possible.
Definition: KVIDCutLine.h:22
virtual void ReadAsciiFile_extras(std::ifstream &)
Read accepted direction for cut.
Definition: KVIDCutLine.cpp:57
virtual ~KVIDCutLine()
Destructor.
Definition: KVIDCutLine.cpp:32
virtual void SetAcceptedDirection(const Char_t *dir)
Definition: KVIDCutLine.cpp:74
virtual void WriteAsciiFile_extras(std::ofstream &, const Char_t *name_prefix="")
Write accepted direction for cut.
Definition: KVIDCutLine.cpp:43