LCOV - code coverage report
Current view: top level - TRIGGER - AliTrigDigitalCircuit.cxx (source / functions) Hit Total Coverage
Test: coverage.info Lines: 1 11 9.1 %
Date: 2016-06-14 17:26:59 Functions: 1 6 16.7 %

          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             : // Author: Andrei Gheata, 28/07/2009
      18             : 
      19             : //==============================================================================
      20             : //   AliTrigDigitalCircuit - Device that has N Boolean inputs and one Boolean
      21             : // output. This is a base class and derived digital circuits must implement the
      22             : // response function Trigger()
      23             : //==============================================================================
      24             : 
      25             : #include "AliTrigDigitalCircuit.h"
      26             : #include "AliTrigConnector.h"
      27             : 
      28          12 : ClassImp(AliTrigDigitalCircuit)
      29             : 
      30             : //______________________________________________________________________________
      31             : AliTrigDigitalCircuit::~AliTrigDigitalCircuit()
      32           0 : {
      33             : // Destructor
      34           0 :   if (fConnector) delete fConnector;
      35           0 : }  
      36             : 
      37             : //______________________________________________________________________________
      38             : Bool_t AliTrigDigitalCircuit::Connect(Int_t output, AliTrigDevice *other, Int_t at_input)
      39             : {
      40             : // Connect to an input of another device.
      41           0 :   if (!fConnector) fConnector = new AliTrigConnector(Form("wire_%s_%d", GetName(), output), (AliTrigDevice*)this, 0);
      42           0 :   fConnector->Connect(other, at_input);
      43           0 :   return kTRUE;
      44           0 : }
      45             : 
      46             : //______________________________________________________________________________
      47             : Bool_t AliTrigDigitalCircuit::Response(Int_t /*output*/)
      48             : {
      49             : // Response function of the digital circuit. Calling user-defined one.
      50           0 :   fLastOutput = Trigger();
      51           0 :   if (fConnector) fConnector->Transmit(fLastOutput);
      52           0 :   return fLastOutput;
      53             : }   

Generated by: LCOV version 1.11