-
Notifications
You must be signed in to change notification settings - Fork 31
/
GeantGeoTraits.hh
57 lines (49 loc) · 1.72 KB
/
GeantGeoTraits.hh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
//----------------------------------*-C++-*----------------------------------//
// Copyright 2024 UT-Battelle, LLC, and other Celeritas developers.
// See the top-level COPYRIGHT file for details.
// SPDX-License-Identifier: (Apache-2.0 OR MIT)
//---------------------------------------------------------------------------//
//! \file geocel/g4/GeantGeoTraits.hh
//---------------------------------------------------------------------------//
#pragma once
#include "celeritas_config.h"
#include "geocel/GeoTraits.hh"
namespace celeritas
{
//---------------------------------------------------------------------------//
class GeantGeoParams;
class GeantGeoTrackView;
template<Ownership W, MemSpace M>
struct GeantGeoParamsData;
template<Ownership W, MemSpace M>
struct GeantGeoStateData;
#if CELERITAS_USE_GEANT4
//---------------------------------------------------------------------------//
/*!
* Traits specialization for Geant4 geometry.
*/
template<>
struct GeoTraits<GeantGeoParams>
{
//! Params data used during runtime
template<Ownership W, MemSpace M>
using ParamsData = GeantGeoParamsData<W, M>;
//! State data used during runtime
template<Ownership W, MemSpace M>
using StateData = GeantGeoStateData<W, M>;
//! Geometry track view
using TrackView = GeantGeoTrackView;
//! Descriptive name for the geometry
static constexpr inline char const* name = "Geant4";
//! TO BE REMOVED: "native" file extension for this geometry
static constexpr inline char const* ext = ".gdml";
};
#else
//! Geant4 is unavailable
template<>
struct GeoTraits<GeantGeoParams> : NotConfiguredGeoTraits
{
};
#endif
//---------------------------------------------------------------------------//
} // namespace celeritas