DLG4::VolumeBuilders
A fluent interface for Geant4 geometry definition.
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Protected Member Functions | Static Protected Member Functions | Protected Attributes | List of all members
Length Class Reference

#include <DLG4Units.hh>

Collaboration diagram for Length:
[legend]

Public Member Functions

 Length (double raw, Length u)
 
 Length ()
 
PropertySetter InUnits (const Unit< Length > &u)
 
G4double InUnits (const Unit< Length > &u) const
 
PropertySetter InDefaultUnits ()
 
G4double InDefaultUnits () const
 

Static Public Member Functions

static Length FromNative (G4double)
 

Public Attributes

PropertySetter Native
 

Static Public Attributes

static const Length fermi {CLHEP::fermi}
 
static const Length angstrom {CLHEP::angstrom}
 
static const Length nm {CLHEP::nanometer}
 
static const Length pm {1e-9 * CLHEP::mm}
 
static const Length um {CLHEP::micrometer}
 
static const Length micron {CLHEP::micrometer}
 
static const Length mm {CLHEP::mm}
 
static const Length cm {CLHEP::cm}
 
static const Length dm
 
static const Length m {CLHEP::m}
 
static const Length km {CLHEP::kilometer}
 
static const Length mil {0.0254}
 
static const Length inch {25.4}
 
static const Length foot {304.8}
 
static const Length feet {304.8}
 
static Length native
 

Protected Member Functions

G4double NativeValue () const
 
 operator G4double () const
 

Static Protected Member Functions

static Derived GetGlobalDefault ()
 

Protected Attributes

std::optional< G4double > NativeValue_
 

Detailed Description

Definition at line 262 of file DLG4Units.hh.

Constructor & Destructor Documentation

◆ Length() [1/2]

Length ( double  raw,
Length  u 
)
inlineexplicit

Definition at line 270 of file DLG4Units.hh.

271 : Unit<Length>(raw, u) {
272 }

◆ Length() [2/2]

Length ( )
inline

Definition at line 274 of file DLG4Units.hh.

std::optional< G4double > NativeValue_
Definition DLG4Units.hh:247
static Derived GetGlobalDefault()
Definition DLG4Units.hh:299
PropertySetter Native
Definition DLG4Units.hh:182

Member Function Documentation

◆ FromNative()

Length FromNative ( G4double  native_value)
inlinestaticinherited

Definition at line 197 of file DLG4Units.hh.

253 {
254 // This calls the protected explicit Unit(double) constructor
255 return T(native_value);
256 }

◆ GetGlobalDefault()

Length GetGlobalDefault ( )
inlinestaticprotectedinherited

Definition at line 245 of file DLG4Units.hh.

299{ return T(global_default_unit<T>); }

◆ InDefaultUnits() [1/2]

PropertySetter InDefaultUnits ( )
inlineinherited

Definition at line 184 of file DLG4Units.hh.

184{ return {*this, GetGlobalDefault().NativeValue()}; }
G4double NativeValue() const
Definition DLG4Units.hh:192

◆ InDefaultUnits() [2/2]

G4double InDefaultUnits ( ) const
inlineinherited

Definition at line 188 of file DLG4Units.hh.

188{ return InUnits(GetGlobalDefault()); }
PropertySetter InUnits(const Unit< Length > &u)
Definition DLG4Units.hh:183

◆ InUnits() [1/2]

PropertySetter InUnits ( const Unit< Length > &  u)
inlineinherited

Definition at line 183 of file DLG4Units.hh.

183{ return {*this, u.NativeValue()}; }

◆ InUnits() [2/2]

G4double InUnits ( const Unit< Length > &  u) const
inlineinherited

Definition at line 187 of file DLG4Units.hh.

187{ return GetScaled(1.0 / u.NativeValue()); }

◆ NativeValue()

G4double NativeValue ( ) const
inlineprotectedinherited

Definition at line 192 of file DLG4Units.hh.

192{ return GetScaled(1.0); }

◆ operator G4double()

operator G4double ( ) const
inlineexplicitprotectedinherited

Definition at line 193 of file DLG4Units.hh.

193{ return GetScaled(1.0); }

Member Data Documentation

◆ angstrom

const Length angstrom {CLHEP::angstrom}
inlinestatic

Definition at line 278 of file DLG4Units.hh.

◆ cm

const Length cm {CLHEP::cm}
inlinestatic

Definition at line 284 of file DLG4Units.hh.

◆ dm

const Length dm
static

Definition at line 285 of file DLG4Units.hh.

◆ feet

const Length feet {304.8}
inlinestatic

Definition at line 293 of file DLG4Units.hh.

◆ fermi

const Length fermi {CLHEP::fermi}
inlinestatic

Definition at line 277 of file DLG4Units.hh.

◆ foot

const Length foot {304.8}
inlinestatic

Definition at line 292 of file DLG4Units.hh.

◆ inch

const Length inch {25.4}
inlinestatic

Definition at line 291 of file DLG4Units.hh.

◆ km

const Length km {CLHEP::kilometer}
inlinestatic

Definition at line 287 of file DLG4Units.hh.

◆ m

const Length m {CLHEP::m}
inlinestatic

Definition at line 286 of file DLG4Units.hh.

◆ micron

const Length micron {CLHEP::micrometer}
inlinestatic

Definition at line 282 of file DLG4Units.hh.

◆ mil

const Length mil {0.0254}
inlinestatic

Definition at line 290 of file DLG4Units.hh.

◆ mm

const Length mm {CLHEP::mm}
inlinestatic

Definition at line 283 of file DLG4Units.hh.

◆ Native

PropertySetter Native
inherited

Definition at line 182 of file DLG4Units.hh.

◆ native

Length native
inlinestaticinherited

Definition at line 196 of file DLG4Units.hh.

196{1.0};

◆ NativeValue_

std::optional<G4double> NativeValue_
protectedinherited

Definition at line 247 of file DLG4Units.hh.

◆ nm

const Length nm {CLHEP::nanometer}
inlinestatic

Definition at line 279 of file DLG4Units.hh.

◆ pm

const Length pm {1e-9 * CLHEP::mm}
inlinestatic

Definition at line 280 of file DLG4Units.hh.

◆ um

const Length um {CLHEP::micrometer}
inlinestatic

Definition at line 281 of file DLG4Units.hh.


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