File SurfaceJsonConverter.hpp¶
-
namespace Acts
Note
This file is foreseen for the
Geometry
module to replaceExtent
Functions
-
std::shared_ptr<Surface> surfaceFromJson(const nlohmann::json &j)¶
Converstion to Surface from jsonn.
- Parameters
j – the read-in json object
- Returns
a shared_ptr to a surface object for type polymorphism
Converstion to Surface from json in correct type.
The type is given as a template argument in order to be able to construct the correct fitting types for surfaces.
- Parameters
j – the read-in json object
- Returns
a shared_ptr to a typed surface object for type polymorphism
-
void to_json(nlohmann::json &j, const SurfaceAndMaterialWithContext &surface)¶
Conversion of a pair of surface and material used for the material mapping.
-
void to_json(nlohmann::json &j, const Surface &surface)¶
Non-contextual conversion of a surface.
Note
it will take the default context
Non-contextual conversion of a surface.
Note
it will take the default context
-
void toJson(nlohmann::json &j, const Surface &surface, const Acts::GeometryContext &gctx)¶
Contextual conversion of a surface.
- Parameters
j – the json to be filled
surface – the surface to be converted
gctx – the geometry context for this
Contextual conversion of a surface.
- Parameters
j – the json to be filled
surface – the surface to be converted
gctx – the geometry context for this
Variables
-
static std::vector<std::string> surfaceTypes = {"ConeSurface", "CylinderSurface", "DiscSurface", "PerigeeSurface", "PlaneSurface", "StrawSurface", "CurvilinearSurface"}¶
-
std::shared_ptr<Surface> surfaceFromJson(const nlohmann::json &j)¶