Back to home page

EIC code displayed by LXR

 
 

    


Warning, file /include/Geant4/G4VPVParameterisation.hh was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 //
0002 // ********************************************************************
0003 // * License and Disclaimer                                           *
0004 // *                                                                  *
0005 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
0006 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
0007 // * conditions of the Geant4 Software License,  included in the file *
0008 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
0009 // * include a list of copyright holders.                             *
0010 // *                                                                  *
0011 // * Neither the authors of this software system, nor their employing *
0012 // * institutes,nor the agencies providing financial support for this *
0013 // * work  make  any representation or  warranty, express or implied, *
0014 // * regarding  this  software system or assume any liability for its *
0015 // * use.  Please see the license in the file  LICENSE  and URL above *
0016 // * for the full disclaimer and the limitation of liability.         *
0017 // *                                                                  *
0018 // * This  code  implementation is the result of  the  scientific and *
0019 // * technical work of the GEANT4 collaboration.                      *
0020 // * By using,  copying,  modifying or  distributing the software (or *
0021 // * any work based  on the software)  you  agree  to acknowledge its *
0022 // * use  in  resulting  scientific  publications,  and indicate your *
0023 // * acceptance of all terms of the Geant4 Software license.          *
0024 // ********************************************************************
0025 //
0026 // G4VPVParamterisation
0027 //
0028 // Class description:
0029 //
0030 // Parameterisation class, able to compute the transformation and
0031 // (indirectly) the dimensions of parameterised volumes, given a
0032 // replication number.
0033 
0034 // 25.07.96, P.Kent        - Initial stub version
0035 // 20.09.96, V.Grichine    - Modifications for G4Trap/Cons/Sphere
0036 // 31.10.96, V.Grichine    - Modifications for G4Torus/Para
0037 // 17.02.98, J.Apostolakis - Allowing the parameterisation of solid type
0038 // --------------------------------------------------------------------
0039 #ifndef G4VPVPARAMETERISATION_HH
0040 #define G4VPVPARAMETERISATION_HH 1
0041 
0042 #include "G4Types.hh"
0043 #include "G4VVolumeMaterialScanner.hh"
0044 #include "G4VTouchable.hh"
0045 
0046 class G4VPhysicalVolume;
0047 class G4VSolid;
0048 class G4Material;
0049 
0050 // Entities which may be parameterised/replicated
0051 //
0052 class G4Box;
0053 class G4Tubs;
0054 class G4Trd;
0055 class G4Trap;
0056 class G4Cons;
0057 class G4Sphere;
0058 class G4Orb;
0059 class G4Ellipsoid;
0060 class G4Torus;
0061 class G4Para;
0062 class G4Polycone;
0063 class G4Polyhedra;
0064 class G4Hype;
0065 
0066 class G4VVolumeMaterialScanner; 
0067 
0068 class G4VPVParameterisation
0069 {
0070   public:
0071 
0072     G4VPVParameterisation() = default;
0073     virtual ~G4VPVParameterisation() = default;
0074 
0075     virtual void ComputeTransformation(const G4int,
0076                                        G4VPhysicalVolume * ) const = 0;
0077 
0078     virtual G4VSolid*   ComputeSolid(const G4int, G4VPhysicalVolume *);
0079                        
0080     virtual G4Material* ComputeMaterial(const G4int repNo, 
0081                                     G4VPhysicalVolume* currentVol,
0082                                     const G4VTouchable* parentTouch = nullptr);
0083        //  Refined method, enabling nested parameterisations
0084 
0085     virtual G4bool IsNested() const;
0086     virtual G4VVolumeMaterialScanner* GetMaterialScanner(); 
0087        //   These enable material scan for nested parameterisations
0088 
0089     virtual void ComputeDimensions(G4Box &,
0090                                    const G4int,
0091                                    const G4VPhysicalVolume *) const {}
0092 
0093     virtual void ComputeDimensions(G4Tubs &,
0094                                    const G4int,
0095                                    const G4VPhysicalVolume *) const {}
0096 
0097     virtual void ComputeDimensions(G4Trd &,
0098                                    const G4int,
0099                                    const G4VPhysicalVolume *) const {}
0100     
0101     virtual void ComputeDimensions(G4Trap &,
0102                                    const G4int,
0103                                    const G4VPhysicalVolume *) const {}
0104     
0105     virtual void ComputeDimensions(G4Cons &,
0106                                    const G4int,
0107                                    const G4VPhysicalVolume *) const {}
0108 
0109     virtual void ComputeDimensions(G4Sphere &,
0110                                    const G4int,
0111                                    const G4VPhysicalVolume *) const {}
0112 
0113     virtual void ComputeDimensions(G4Orb &,
0114                                    const G4int,
0115                                    const G4VPhysicalVolume *) const {}
0116 
0117     virtual void ComputeDimensions(G4Ellipsoid &,
0118                                    const G4int,
0119                                    const G4VPhysicalVolume *) const {}
0120 
0121     virtual void ComputeDimensions(G4Torus &,
0122                                    const G4int,
0123                                    const G4VPhysicalVolume *) const {}
0124 
0125     virtual void ComputeDimensions(G4Para &,
0126                                    const G4int,
0127                                    const G4VPhysicalVolume *) const {}
0128 
0129     virtual void ComputeDimensions(G4Polycone &,
0130                                    const G4int,
0131                                    const G4VPhysicalVolume *) const {}
0132 
0133     virtual void ComputeDimensions(G4Polyhedra &,
0134                                    const G4int,
0135                                    const G4VPhysicalVolume *) const {}
0136 
0137     virtual void ComputeDimensions(G4Hype &,
0138                                    const G4int,
0139                                    const G4VPhysicalVolume *) const {}
0140 };
0141 
0142 #endif