SHiP Geometry
SHiP experiment geometry implementation using GeoModel.
Loading...
Searching...
No Matches
SHiP::geometry::Materials Class Reference

Central material manager for the SHiP detector. More...

#include <Materials.h>

Public Member Functions

 Materials ()
 ~Materials ()=default
 Materials (const Materials &)=delete
Materials & operator= (const Materials &)=delete
GeoMaterial * getMaterial (std::string_view name) const
 Get a material by name.
GeoMaterial * requireMaterial (std::string_view name) const
 Get a material by name, throwing if not found.

Detailed Description

Central material manager for the SHiP detector.

This class provides access to all materials and elements used in the SHiP detector geometry. Materials are created once and shared across all subsystem factories.

Constructor & Destructor Documentation

◆ Materials() [1/2]

SHiP::geometry::Materials::Materials ( )

◆ ~Materials()

SHiP::geometry::Materials::~Materials ( )
default

◆ Materials() [2/2]

SHiP::geometry::Materials::Materials ( const Materials & )
delete

Member Function Documentation

◆ getMaterial()

GeoMaterial * SHiP::geometry::Materials::getMaterial ( std::string_view name) const
nodiscard

Get a material by name.

Parameters
nameMaterial name (e.g., "Air", "Concrete", "Tungsten")
Returns
Pointer to GeoMaterial or nullptr if not found

◆ operator=()

Materials & SHiP::geometry::Materials::operator= ( const Materials & )
delete

◆ requireMaterial()

GeoMaterial * SHiP::geometry::Materials::requireMaterial ( std::string_view name) const
nodiscard

Get a material by name, throwing if not found.

Parameters
nameMaterial name (e.g., "Air", "Concrete", "Tungsten")
Returns
Pointer to GeoMaterial (never nullptr)
Exceptions
std::runtime_errorif material not found

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