Jpp - the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Types | Public Member Functions | Static Private Attributes | List of all members
JTRIGGER::JTimesliceClone< JElement_t > Class Template Reference

Clone of JTimeslice. More...

#include <JTimesliceClone.hh>

Inheritance diagram for JTRIGGER::JTimesliceClone< JElement_t >:
std::vector< JSuperFrameClone1D< JElement_t > > JTRIGGER::JHitToolkit< JElement_t >

Public Types

typedef JLANG::JClass
< JElement_t >::argument_type 
argument_type
 
typedef JSuperFrameClone1D
< JElement_t > 
value_type
 
typedef std::vector
< value_type >::iterator 
iterator
 
typedef std::vector
< value_type >::const_iterator 
const_iterator
 
typedef std::vector
< value_type >
::reverse_iterator 
reverse_iterator
 
typedef std::vector
< value_type >
::const_reverse_iterator 
const_reverse_iterator
 

Public Member Functions

 JTimesliceClone ()
 Default constructor. More...
 
 JTimesliceClone (const JTimeslice< JElement_t > &input)
 Constructor. More...
 
 JTimesliceClone (const JTimeslice< JElement_t > &input, const JModuleRouter &router)
 Constructor. More...
 
JTimesliceClone< JElement_t > & transform (const JMatrix3D &R)
 Transform. More...
 
JTimesliceClone< JElement_t > & rotate (const JRotation3D &R)
 Rotate. More...
 
JTimesliceClone< JElement_t > & rotate_back (const JRotation3D &R)
 Rotate back. More...
 
void rewind () const
 Rewind internal iterators. More...
 
void lower_bound (argument_type hit) const
 Set the internal iterators to the lower bounds corresponding to the time of the given hit. More...
 
void fast_forward (argument_type hit) const
 Increment the internal iterators until the lower bounds corresponding to the time of the given hit. More...
 

Static Private Attributes

static JSuperFrame1D< JElement_t > buffer
 

Detailed Description

template<class JElement_t>
class JTRIGGER::JTimesliceClone< JElement_t >

Clone of JTimeslice.

Definition at line 33 of file JTimesliceClone.hh.

Member Typedef Documentation

template<class JElement_t >
typedef JLANG::JClass<JElement_t>::argument_type JTRIGGER::JTimesliceClone< JElement_t >::argument_type

Definition at line 39 of file JTimesliceClone.hh.

template<class JElement_t >
typedef JSuperFrameClone1D<JElement_t> JTRIGGER::JTimesliceClone< JElement_t >::value_type

Definition at line 40 of file JTimesliceClone.hh.

template<class JElement_t >
typedef std::vector<value_type>::iterator JTRIGGER::JTimesliceClone< JElement_t >::iterator

Definition at line 41 of file JTimesliceClone.hh.

template<class JElement_t >
typedef std::vector<value_type>::const_iterator JTRIGGER::JTimesliceClone< JElement_t >::const_iterator

Definition at line 42 of file JTimesliceClone.hh.

template<class JElement_t >
typedef std::vector<value_type>::reverse_iterator JTRIGGER::JTimesliceClone< JElement_t >::reverse_iterator

Definition at line 43 of file JTimesliceClone.hh.

Definition at line 44 of file JTimesliceClone.hh.

Constructor & Destructor Documentation

template<class JElement_t >
JTRIGGER::JTimesliceClone< JElement_t >::JTimesliceClone ( )
inline

Default constructor.

Definition at line 50 of file JTimesliceClone.hh.

51  {}
template<class JElement_t >
JTRIGGER::JTimesliceClone< JElement_t >::JTimesliceClone ( const JTimeslice< JElement_t > &  input)
inline

Constructor.

The cloned data are organised according the input time slice.

Parameters
inputsuper frame

Definition at line 61 of file JTimesliceClone.hh.

62  {
63  for (typename JTimeslice<JElement_t>::const_iterator i = input.begin(); i != input.end(); ++i) {
64  this->push_back(JSuperFrameClone1D<JElement_t>(*i));
65  }
66  }
std::vector< value_type >::const_iterator const_iterator
Definition: JTimeslice.hh:34
Clone of JSuperFrame1D.
template<class JElement_t >
JTRIGGER::JTimesliceClone< JElement_t >::JTimesliceClone ( const JTimeslice< JElement_t > &  input,
const JModuleRouter router 
)
inline

Constructor.

The cloned data are organised according the module router.

Parameters
inputsuper frame
routermodule router

Definition at line 77 of file JTimesliceClone.hh.

79  {
80  this->resize(router.getReference().size());
81 
82  for (typename JTimeslice<JElement_t>::const_iterator i = input.begin(); i != input.end(); ++i) {
83  (*this)[router.getAddress(i->getModuleID()).first] = JSuperFrameClone1D<JElement_t>(*i);
84  }
85 
86  // add end marker to empty frames
87 
88  if (buffer.empty()) {
89  buffer.push_back(this->getEndMarker());
90  }
91 
92  for (iterator i = this->begin(); i != this->end(); ++i) {
93  if (i->empty()) {
95  }
96  }
97  }
std::vector< value_type >::const_iterator const_iterator
Definition: JTimeslice.hh:34
then echo The file $DIR KM3NeT_00000001_00000000 root already please rename or remove it first
const JClass_t & getReference() const
Get reference to object.
Definition: JReference.hh:38
const JModuleAddress & getAddress(const JObjectID &id) const
Get address of module.
Clone of JSuperFrame1D.
static JSuperFrame1D< JElement_t > buffer

Member Function Documentation

template<class JElement_t >
JTimesliceClone<JElement_t>& JTRIGGER::JTimesliceClone< JElement_t >::transform ( const JMatrix3D &  R)
inline

Transform.

Parameters
Rmatrix

Definition at line 105 of file JTimesliceClone.hh.

106  {
107  for (iterator i = this->begin(); i != this->end(); ++i) {
108  i->transform(R);
109  }
110 
111  return *this;
112  }
template<class JElement_t >
JTimesliceClone<JElement_t>& JTRIGGER::JTimesliceClone< JElement_t >::rotate ( const JRotation3D R)
inline

Rotate.

Parameters
Rrotation matrix

Definition at line 120 of file JTimesliceClone.hh.

121  {
122  for (iterator i = this->begin(); i != this->end(); ++i) {
123  i->rotate(R);
124  }
125 
126  return *this;
127  }
template<class JElement_t >
JTimesliceClone<JElement_t>& JTRIGGER::JTimesliceClone< JElement_t >::rotate_back ( const JRotation3D R)
inline

Rotate back.

Parameters
Rrotation matrix

Definition at line 135 of file JTimesliceClone.hh.

136  {
137  for (iterator i = this->begin(); i != this->end(); ++i) {
138  i->rotate_back(R);
139  }
140 
141  return *this;
142  }
template<class JElement_t >
void JTRIGGER::JTimesliceClone< JElement_t >::rewind ( ) const
inline

Rewind internal iterators.

Definition at line 148 of file JTimesliceClone.hh.

149  {
150  for (const_iterator i = this->begin(); i != this->end(); ++i) {
151  i->rewind();
152  }
153  }
std::vector< value_type >::const_iterator const_iterator
template<class JElement_t >
void JTRIGGER::JTimesliceClone< JElement_t >::lower_bound ( argument_type  hit) const
inline

Set the internal iterators to the lower bounds corresponding to the time of the given hit.

Parameters
hithit

Definition at line 161 of file JTimesliceClone.hh.

162  {
163  for (const_iterator i = this->begin(); i != this->end(); ++i) {
164  i->lower_bound(hit);
165  }
166  }
std::vector< value_type >::const_iterator const_iterator
template<class JElement_t >
void JTRIGGER::JTimesliceClone< JElement_t >::fast_forward ( argument_type  hit) const
inline

Increment the internal iterators until the lower bounds corresponding to the time of the given hit.

Parameters
hithit

Definition at line 174 of file JTimesliceClone.hh.

175  {
176  for (const_iterator i = this->begin(); i != this->end(); ++i) {
177  i->fast_forward(hit);
178  }
179  }
std::vector< value_type >::const_iterator const_iterator

Member Data Documentation

template<class JElement_t >
JSuperFrame1D< JElement_t > JTRIGGER::JTimesliceClone< JElement_t >::buffer
staticprivate

Definition at line 182 of file JTimesliceClone.hh.


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