ACTS
Experiment-independent tracking
Loading...
Searching...
No Matches
Acts::SurfaceJsonConverter Namespace Reference

Classes

struct  Options

Functions

std::shared_ptr< SurfacefromJson (const nlohmann::json &jSurface)
 The Surface converter from json.
nlohmann::json toJson (const GeometryContext &gctx, const Surface &surface, const Options &options=Options{})
 Contextual conversion of a surface.
nlohmann::json toJsonDetray (const GeometryContext &gctx, const Surface &surface, const Options &options=Options{})
 Contextual conversion of a surface - Detray export.

Function Documentation

◆ fromJson()

std::shared_ptr< Surface > Acts::SurfaceJsonConverter::fromJson ( const nlohmann::json & jSurface)

The Surface converter from json.

Parameters
jSurfacethe surface json object
Returns
a shared object created from json input

◆ toJson()

nlohmann::json Acts::SurfaceJsonConverter::toJson ( const GeometryContext & gctx,
const Surface & surface,
const Options & options = Options{} )

Contextual conversion of a surface.

Parameters
gctxthe geometry context for this
surfacethe surface to be converted
optionsthe writing options for the surfaces
Returns
a json object representing the surface

◆ toJsonDetray()

nlohmann::json Acts::SurfaceJsonConverter::toJsonDetray ( const GeometryContext & gctx,
const Surface & surface,
const Options & options = Options{} )

Contextual conversion of a surface - Detray export.

Parameters
gctxthe geometry context for this
surfacethe surface to be converted
optionsthe writing options for the surfaces
Note
reading back detray json is not supported and will fail
Returns
a json object representing the surface