CGEM BOSS 6.6.5.g
BESIII Offline Software System
Loading...
Searching...
No Matches
TrkView Class Reference

#include <TrkView.h>

Public Member Functions

 TrkView (TrkEnums::TrkViewInfo view=TrkEnums::noView)
 
 TrkView (unsigned short &data)
 
 TrkView (const TrkView &)
 
TrkViewoperator= (const TrkView &)
 
virtual ~TrkView ()
 
void addView (TrkEnums::TrkViewInfo view)
 
TrkEnums::TrkViewInfo view () const
 
bool contains (const TrkView &other) const
 
bool contains (TrkEnums::TrkViewInfo view) const
 
bool operator== (const TrkView &other) const
 
bool operator!= (const TrkView &other) const
 
unsigned short viewData () const
 

Static Public Attributes

static const unsigned short _xyview
 
static const unsigned short _zview
 
static const unsigned short _bothview
 

Detailed Description

Definition at line 24 of file TrkView.h.

Constructor & Destructor Documentation

◆ TrkView() [1/3]

TrkView::TrkView ( TrkEnums::TrkViewInfo  view = TrkEnums::noView)

Definition at line 27 of file TrkView.cxx.

27 :
28 _view(0)
29{
31}
void addView(TrkEnums::TrkViewInfo view)
Definition: TrkView.cxx:53
TrkEnums::TrkViewInfo view() const
Definition: TrkView.cxx:70

◆ TrkView() [2/3]

TrkView::TrkView ( unsigned short &  data)

Definition at line 33 of file TrkView.cxx.

33 :
34 _view( (pat & _bothview))
35{
36}
static const unsigned short _bothview
Definition: TrkView.h:51

◆ TrkView() [3/3]

TrkView::TrkView ( const TrkView other)

Definition at line 38 of file TrkView.cxx.

38 : _view(other._view)
39{}
Index other(Index i, Index j)
Definition: EvtCyclic3.cc:118

◆ ~TrkView()

TrkView::~TrkView ( )
virtual

Definition at line 49 of file TrkView.cxx.

50{}

Member Function Documentation

◆ addView()

void TrkView::addView ( TrkEnums::TrkViewInfo  view)

Definition at line 53 of file TrkView.cxx.

53 {
54 switch (view) {
55 case TrkEnums::noView: default:
56 break;
58 _view |= _xyview;
59 break;
60 case TrkEnums::zView:
61 _view |= _zview;
62 break;
64 _view |= _bothview;
65 break;
66 }
67}
static const unsigned short _xyview
Definition: TrkView.h:49
static const unsigned short _zview
Definition: TrkView.h:50
@ xyView
Definition: TrkEnums.h:22
@ zView
Definition: TrkEnums.h:22
@ noView
Definition: TrkEnums.h:22
@ bothView
Definition: TrkEnums.h:22

Referenced by TrkHotListFull::svtView(), and TrkView().

◆ contains() [1/2]

bool TrkView::contains ( const TrkView other) const

Definition at line 84 of file TrkView.cxx.

84 {
85 return (other.viewData() & _view) == other.viewData();
86}

Referenced by contains(), and TrkHotList::hasSvtView().

◆ contains() [2/2]

bool TrkView::contains ( TrkEnums::TrkViewInfo  view) const

Definition at line 99 of file TrkView.cxx.

99 {
101 return contains(other);
102}
bool contains(const TrkView &other) const
Definition: TrkView.cxx:84

◆ operator!=()

bool TrkView::operator!= ( const TrkView other) const

Definition at line 94 of file TrkView.cxx.

94 {
95 return other.viewData() != _view;
96}

◆ operator=()

TrkView & TrkView::operator= ( const TrkView other)

Definition at line 42 of file TrkView.cxx.

42 {
43 if(this != &other){
44 _view = other._view;
45 }
46 return *this;
47}

◆ operator==()

bool TrkView::operator== ( const TrkView other) const

Definition at line 89 of file TrkView.cxx.

89 {
90 return other.viewData() == _view;
91}

◆ view()

TrkEnums::TrkViewInfo TrkView::view ( ) const

Definition at line 70 of file TrkView.cxx.

70 {
71 switch (_view) {
72 case 0: default:
73 return TrkEnums::noView;
74 case _xyview:
75 return TrkEnums::xyView;
76 case _zview:
77 return TrkEnums::zView;
78 case _bothview:
79 return TrkEnums::bothView;
80 }
81}

Referenced by addView(), contains(), and TrkView().

◆ viewData()

unsigned short TrkView::viewData ( ) const
inline

Definition at line 44 of file TrkView.h.

44{ return _view; }

Member Data Documentation

◆ _bothview

const unsigned short TrkView::_bothview
static

Definition at line 51 of file TrkView.h.

Referenced by addView(), and view().

◆ _xyview

const unsigned short TrkView::_xyview
static

Definition at line 49 of file TrkView.h.

Referenced by addView(), and view().

◆ _zview

const unsigned short TrkView::_zview
static

Definition at line 50 of file TrkView.h.

Referenced by addView(), and view().


The documentation for this class was generated from the following files: