Geant4  10.01.p01
G4UOrb.cc
Go to the documentation of this file.
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 // $Id:$
27 //
28 //
29 // Implementation for G4UOrb wrapper class
30 // --------------------------------------------------------------------
31 
32 #include "G4Orb.hh"
33 #include "G4UOrb.hh"
34 #include "G4VPVParameterisation.hh"
35 
37 //
38 // constructor - check positive radius
39 //
40 
41 G4UOrb::G4UOrb( const G4String& pName, G4double pRmax )
42  : G4USolid(pName, new UOrb(pName, pRmax))
43 {
44 }
45 
47 //
48 // Fake default constructor - sets only member data and allocates memory
49 // for usage restricted to object persistency.
50 //
51 G4UOrb::G4UOrb( __void__& a )
52  : G4USolid(a)
53 {
54 }
55 
57 //
58 // Destructor
59 
61 {
62 }
63 
65 //
66 // Copy constructor
67 
69  : G4USolid(rhs)
70 {
71 }
72 
74 //
75 // Assignment operator
76 
78 {
79  // Check assignment to self
80  //
81  if (this == &rhs) { return *this; }
82 
83  // Copy base class data
84  //
86 
87  return *this;
88 }
89 
91 //
92 // Dispatch to parameterisation for replication mechanism dimension
93 // computation & modification.
94 
96  const G4int n,
97  const G4VPhysicalVolume* pRep )
98 {
99  p->ComputeDimensions(*(G4Orb*)this,n,pRep);
100 }
101 
103 //
104 // Make a clone of the object
105 
107 {
108  return new G4UOrb(*this);
109 }
G4UOrb(const G4String &pName, G4double pRmax)
Definition: G4UOrb.cc:41
G4double a
Definition: TRTMaterials.hh:39
G4VSolid * Clone() const
Definition: G4UOrb.cc:106
int G4int
Definition: G4Types.hh:78
G4UOrb & operator=(const G4UOrb &rhs)
Definition: G4UOrb.cc:77
Definition: UOrb.hh:28
void ComputeDimensions(G4VPVParameterisation *p, const G4int n, const G4VPhysicalVolume *pRep)
Definition: G4UOrb.cc:95
const G4int n
Definition: G4Orb.hh:61
virtual void ComputeDimensions(G4Box &, const G4int, const G4VPhysicalVolume *) const
G4USolid & operator=(const G4USolid &rhs)
Definition: G4USolid.cc:372
Definition: G4UOrb.hh:49
~G4UOrb()
Definition: G4UOrb.cc:60
double G4double
Definition: G4Types.hh:76