LCOV - code coverage report
Current view: top level - MUON/MUONbase - AliMUONDigitStoreV2S.cxx (source / functions) Hit Total Coverage
Test: coverage.info Lines: 10 21 47.6 %
Date: 2016-06-14 17:26:59 Functions: 8 9 88.9 %

          Line data    Source code
       1             : /**************************************************************************
       2             : * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
       3             : *                                                                        *
       4             : * Author: The ALICE Off-line Project.                                    *
       5             : * Contributors are mentioned in the code where appropriate.              *
       6             : *                                                                        *
       7             : * Permission to use, copy, modify and distribute this software and its   *
       8             : * documentation strictly for non-commercial purposes is hereby granted   *
       9             : * without fee, provided that the above copyright notice appears in all   *
      10             : * copies and that both the copyright notice and this permission notice   *
      11             : * appear in the supporting documentation. The authors make no claims     *
      12             : * about the suitability of this software for any purpose. It is          *
      13             : * provided "as is" without express or implied warranty.                  *
      14             : **************************************************************************/
      15             : 
      16             : // $Id$
      17             : 
      18             : #include "AliMUONDigitStoreV2S.h"
      19             : 
      20             : //-----------------------------------------------------------------------------
      21             : /// \class AliMUONDigitStoreV2S
      22             : ///
      23             : /// Concrete implementation of AliMUONVDigitStore for simulated digits, using
      24             : /// the AliMUONDigitStoreVImpl base implementation
      25             : /// 
      26             : /// \author Laurent Aphecetche
      27             : //-----------------------------------------------------------------------------
      28             : 
      29             : 
      30             : #include "AliMUONDigit.h"
      31             : #include <TClonesArray.h>
      32             : 
      33             : /// \cond CLASSIMP
      34          18 : ClassImp(AliMUONDigitStoreV2S)
      35             : /// \endcond
      36             : 
      37             : //_____________________________________________________________________________
      38             : AliMUONDigitStoreV2S::AliMUONDigitStoreV2S()
      39           9 : : AliMUONDigitStoreVImpl("AliMUONDigit")
      40          45 : {
      41             :   /// ctor
      42          18 : }
      43             : 
      44             : //_____________________________________________________________________________
      45             : AliMUONDigitStoreV2S::~AliMUONDigitStoreV2S()
      46          36 : {
      47             :   /// dtor
      48          36 : }
      49             : 
      50             : //_____________________________________________________________________________
      51             : AliMUONVDigit*
      52             : AliMUONDigitStoreV2S::AddConcreteDigit(TClonesArray& a, 
      53             :                                        const AliMUONVDigit& digit,
      54             :                                        Int_t index)
      55             : {
      56             :   /// add a digit to this store  
      57             :   
      58        5516 :   if ( digit.IsA() != AliMUONDigit::Class() ) 
      59             :   {
      60           0 :     AliMUONDigit d(digit.DetElemId(),digit.ManuId(),digit.ManuChannel(),digit.Cathode());
      61           0 :     d.SetCharge(digit.Charge());
      62           0 :     d.SetADC(digit.ADC());
      63           0 :     d.SetPadXY(digit.PadX(),digit.PadY());
      64           0 :     d.ChargeInFC();
      65           0 :     d.Converted();
      66           0 :     return new(a[index]) AliMUONDigit(d);
      67           0 :   }
      68             : 
      69        5516 :   return new(a[index]) AliMUONDigit(static_cast<const AliMUONDigit&>(digit));
      70        2758 : }
      71             : 
      72             : //_____________________________________________________________________________
      73             : AliMUONVDigitStore* 
      74             : AliMUONDigitStoreV2S::Create() const
      75             : {
      76             :   /// create an empty store
      77           6 :   return new AliMUONDigitStoreV2S;
      78           0 : }
      79             : 
      80             : //_____________________________________________________________________________
      81             : AliMUONVDigit* 
      82             : AliMUONDigitStoreV2S::CreateDigit(Int_t detElemId, Int_t manuId,                                 
      83             :                                   Int_t manuChannel, Int_t cathode) const
      84             : {
      85             :   /// create a digit, compatible with this store
      86           0 :   return new AliMUONDigit(detElemId,manuId,manuChannel,cathode);
      87           0 : }
      88             : 
      89             : 

Generated by: LCOV version 1.11