ESPResSo
Extensible Simulation Package for Research on Soft Matter Systems
Loading...
Searching...
No Matches
ScriptInterface Namespace Reference

Namespaces

namespace  Accumulators
namespace  Analysis
namespace  BondBreakage
namespace  CellSystem
namespace  Particles
namespace  ClusterAnalysis
namespace  CodeInfo
namespace  CollisionDetection
namespace  Constraints
namespace  EK
namespace  Coulomb
namespace  Galilei
namespace  Writer
namespace  Integrators
namespace  Interactions
namespace  LB
namespace  LeesEdwards
namespace  Dipoles
namespace  Math
namespace  MPIIO
namespace  Observables
namespace  PairCriteria
namespace  Profiler
namespace  ReactionMethods
namespace  Scafacos
namespace  Shapes
namespace  System
namespace  Thermostat
namespace  impl
namespace  walberla

Classes

struct  AutoParameter
 Description and getter/setter for a parameter. More...
class  AutoParameters
 Bind parameters in the script interface. More...
class  Context
 Context of an object handle. More...
class  ContextManager
 Manage object contexts. More...
struct  Exception
class  GlobalContext
 Global synchronizing context. More...
class  LocalContext
 Trivial context. More...
class  None
 Type to indicate no value in Variant. More...
class  ObjectHandle
 Base class for interface handles. More...
struct  ObjectId
 Strongly typed integer type to hold a unique identifier for a ObjectHandle object, using its memory address. More...
class  ObjectList
 Owning list of object handles. More...
class  ObjectMap
 Owning map of object handles. More...
struct  ObjectState
 State of an object ready for serialization. More...
struct  PackVisitor
 Visitor that converts a Variant to a PackedVariant. More...
struct  UnpackVisitor
 Visitor that converts a PackedVariant to a Variant. More...
class  ParallelExceptionHandler
 Handle exceptions thrown in MPI parallel code. More...
class  LatticeIndices
 Interface to carry out simple operations on lattice indices. More...

Typedefs

template<template< typename... > class Container, typename ManagedType, class BaseType>
using ObjectContainer
 Base class for containers whose BaseType might be a full specialization of AutoParameters.
using PackedVariant = make_recursive_variant<ObjectId>
 Packed version of Variant.
using PackedMap = std::vector<std::pair<std::string, PackedVariant>>
template<typename ObjectType>
using make_recursive_variant
 Helper typedef to generate consistent variant types.
using ObjectRef = std::shared_ptr<ObjectHandle>
using Variant = make_recursive_variant<ObjectRef>
 Possible types for parameters.
using VariantMap = std::unordered_map<std::string, Variant>

Functions

template<typename T>
T mpi_reduce_sum (boost::mpi::communicator const &comm, T const &result)
 Reduce object by sum on the head node.
template<typename T>
T get_value (Variant const &v)
 Extract value of specific type T from a Variant.
template<typename T>
T get_value (VariantMap const &vals, std::string const &name)
 Get a value from a VariantMap by name, or throw if it does not exist or is not convertible to the target type.
template<typename T>
T get_value_or (VariantMap const &vals, std::string const &name, T const &default_)
 Get a value from a VariantMap by name, or return a default value if it does not exist.
template<typename T, typename... Types, typename... ArgNames>
std::shared_ptr< T > make_shared_from_args (VariantMap const &vals, ArgNames &&...args)
 Make a new std::shared_ptr<T> with arguments extracted from a VariantMap.
template<typename T>
void set_from_args (T &dst, VariantMap const &vals, const char *name)
void initialize (Utils::Factory< ObjectHandle > *f)
PackedVariant pack (const Variant &v)
 Transform a Variant to a PackedVariant.
Variant unpack (const PackedVariant &v, std::unordered_map< ObjectId, ObjectRef > const &objects)
 Unpack a PackedVariant.
PackedMap pack (const VariantMap &v)
 Pack a VariantMap.
VariantMap unpack (const PackedMap &v, std::unordered_map< ObjectId, ObjectRef > const &objects)
 Unpack a PackedMap.
template<typename T>
Variant make_variant (const T &x)
 Make a Variant from argument.
template<typename K, typename V>
auto make_unordered_map_of_variants (std::unordered_map< K, V > const &v)
template<typename T>
auto make_vector_of_variants (std::vector< T > const &v)
template<class T>
constexpr bool is_type (Variant const &v)
 Check is a Variant holds a specific type.
constexpr bool is_none (Variant const &v)

Variables

constexpr const None none {}
 None-"literal".

Typedef Documentation

◆ make_recursive_variant

template<typename ObjectType>
using ScriptInterface::make_recursive_variant
Initial value:
None, bool, int, std::size_t, double, std::string, std::filesystem::path,
Utils::Vector3d, Utils::Vector4d, std::vector<int>, std::vector<double>>
Type to indicate no value in Variant.
Definition None.hpp:31
VectorXd< 2 > Vector2d
Definition Vector.hpp:206
VectorXd< 4 > Vector4d
Definition Vector.hpp:208
VectorXd< 3 > Vector3d
Definition Vector.hpp:207
Utils::Vector< bool, 3 > Vector3b
Definition Variant.hpp:44
VectorXi< 3 > Vector3i
Definition Vector.hpp:216
Recursive variant implementation.
Definition Variant.hpp:84

Helper typedef to generate consistent variant types.

This is a custom recursive variant type designed specifically for the script interface. It features all basic types required to interface with the core. Recursive types are added by impl::recursive_variant_add_containers. The template parameter ObjectType is used to ensure instantiations like Variant and PackedVariant hold the same types in the same order.

Template Parameters
ObjectTypeType of the script interface object handle or reference.

Definition at line 115 of file Variant.hpp.

◆ ObjectContainer

template<template< typename... > class Container, typename ManagedType, class BaseType>
using ScriptInterface::ObjectContainer
Initial value:
std::conditional_t<
std::is_same_v<BaseType, ObjectHandle>,
Bind parameters in the script interface.

Base class for containers whose BaseType might be a full specialization of AutoParameters.

Definition at line 35 of file ObjectContainer.hpp.

◆ ObjectRef

using ScriptInterface::ObjectRef = std::shared_ptr<ObjectHandle>

Definition at line 121 of file Variant.hpp.

◆ PackedMap

using ScriptInterface::PackedMap = std::vector<std::pair<std::string, PackedVariant>>

Definition at line 53 of file packed_variant.hpp.

◆ PackedVariant

Packed version of Variant.

When packing variants by PackVisitor, objects of type ObjectRef are packed as ObjectId. Other than that, all other types allowed in Variant also appear here.

Definition at line 51 of file packed_variant.hpp.

◆ Variant

Possible types for parameters.

Definition at line 131 of file Variant.hpp.

◆ VariantMap

using ScriptInterface::VariantMap = std::unordered_map<std::string, Variant>

Definition at line 133 of file Variant.hpp.

Function Documentation

◆ get_value() [1/2]

template<typename T>
T ScriptInterface::get_value ( Variant const & v)

Extract value of specific type T from a Variant.

This is a wrapper around std::get that allows us to customize the behavior for different types. This is needed e.g. to deal with containers whose elements have mixed types that are implicitly convertible to a requested type.

Definition at line 398 of file get_value.hpp.

Referenced by ScriptInterface::Accumulators::AccumulatorBase::AccumulatorBase(), ScriptInterface::walberla::EKContainer::add_in_core(), ScriptInterface::walberla::VTKHandleBase< Field >::attach_to_lattice(), ScriptInterface::AutoParameter::AutoParameter(), ScriptInterface::AutoParameter::AutoParameter(), ScriptInterface::AutoParameter::AutoParameter(), ScriptInterface::AutoParameter::AutoParameter(), ScriptInterface::PairCriteria::BondCriterion::BondCriterion(), ScriptInterface::walberla::EKReaction::calculate_bulk_conversion_factor(), ScriptInterface::CellSystem::CellSystem::CellSystem(), ScriptInterface::ClusterAnalysis::ClusterStructure::ClusterStructure(), ScriptInterface::CollisionDetection::CollisionDetection::CollisionDetection(), ScriptInterface::Galilei::ComFixed::ComFixed(), ScriptInterface::Interactions::AngleCosineBond::construct_bond(), ScriptInterface::Interactions::AngleCossquareBond::construct_bond(), ScriptInterface::Interactions::AngleHarmonicBond::construct_bond(), ScriptInterface::Interactions::BondedCoulomb::construct_bond(), ScriptInterface::Interactions::BondedCoulombSR::construct_bond(), ScriptInterface::Interactions::DihedralBond::construct_bond(), ScriptInterface::Interactions::FeneBond::construct_bond(), ScriptInterface::Interactions::HarmonicBond::construct_bond(), ScriptInterface::Interactions::IBMTribend::construct_bond(), ScriptInterface::Interactions::IBMTriel::construct_bond(), ScriptInterface::Interactions::IBMVolCons::construct_bond(), ScriptInterface::Interactions::OifGlobalForcesBond::construct_bond(), ScriptInterface::Interactions::OifLocalForcesBond::construct_bond(), ScriptInterface::Interactions::QuarticBond::construct_bond(), ScriptInterface::Interactions::RigidBond::construct_bond(), ScriptInterface::Interactions::TabulatedAngleBond::construct_bond(), ScriptInterface::Interactions::TabulatedDihedralBond::construct_bond(), ScriptInterface::Interactions::TabulatedDistanceBond::construct_bond(), ScriptInterface::Interactions::ThermalizedBond::construct_bond(), ScriptInterface::Coulomb::Container::Container(), ScriptInterface::Dipoles::Container::Container(), ScriptInterface::LB::Container::Container(), ScriptInterface::System::CudaInitHandle::CudaInitHandle(), ScriptInterface::walberla::EKFieldSerializer::deserialize(), ScriptInterface::walberla::LBFieldSerializer::deserialize(), ScriptInterface::PairCriteria::DistanceCriterion::DistanceCriterion(), ScriptInterface::Accumulators::AccumulatorBase::do_call_method(), ScriptInterface::Analysis::Analysis::do_call_method(), ScriptInterface::CellSystem::CellSystem::do_call_method(), ScriptInterface::ClusterAnalysis::Cluster::do_call_method(), ScriptInterface::ClusterAnalysis::ClusterStructure::do_call_method(), ScriptInterface::Constraints::ExternalField< Scaled, Interpolated< double, 3 > >::do_call_method(), ScriptInterface::Constraints::ExternalPotential< Scaled, Interpolated< double, 1 > >::do_call_method(), ScriptInterface::Coulomb::CoulombScafacos::do_call_method(), ScriptInterface::Interactions::BondedInteraction::do_call_method(), ScriptInterface::Interactions::NonBondedInteractions::do_call_method(), ScriptInterface::LeesEdwards::LeesEdwards::do_call_method(), ScriptInterface::MPIIO::MPIIOScript::do_call_method(), ScriptInterface::ObjectList< AccumulatorBase, AutoParameters< ObjectList< AccumulatorBase, System::Leaf >, System::Leaf > >::do_call_method(), ScriptInterface::ObjectMap< BreakageSpec, AutoParameters< ObjectMap< BreakageSpec, System::Leaf >, System::Leaf > >::do_call_method(), ScriptInterface::PairCriteria::PairCriterion::do_call_method(), ScriptInterface::Particles::ParticleHandle::do_call_method(), ScriptInterface::Particles::ParticleList::do_call_method(), ScriptInterface::Particles::ParticleSlice::do_call_method(), ScriptInterface::Particles::Polymer::do_call_method(), ScriptInterface::Profiler::Caliper::do_call_method(), ScriptInterface::ReactionMethods::ExclusionRadius::do_call_method(), ScriptInterface::ReactionMethods::ReactionAlgorithm::do_call_method(), ScriptInterface::Shapes::Shape::do_call_method(), ScriptInterface::System::System::do_call_method(), ScriptInterface::walberla::EKIndexedReaction::do_call_method(), ScriptInterface::walberla::EKIndexedReactionSlice::do_call_method(), ScriptInterface::walberla::EKNone::do_call_method(), ScriptInterface::walberla::EKPoissonSolverNode::do_call_method(), ScriptInterface::walberla::EKPoissonSolverSlice::do_call_method(), ScriptInterface::walberla::EKSpecies::do_call_method(), ScriptInterface::walberla::EKSpeciesNode::do_call_method(), ScriptInterface::walberla::EKSpeciesSlice::do_call_method(), ScriptInterface::walberla::LatticeModel<::EKinWalberlaBase, EKVTKHandle >::do_call_method(), ScriptInterface::walberla::LBFluid::do_call_method(), ScriptInterface::walberla::LBFluidNode::do_call_method(), ScriptInterface::walberla::LBFluidSlice::do_call_method(), ScriptInterface::Accumulators::ContactTimes::do_construct(), ScriptInterface::Accumulators::Correlator::do_construct(), ScriptInterface::ClusterAnalysis::ClusterStructure::do_construct(), ScriptInterface::Coulomb::CoulombMMM1D::do_construct(), ScriptInterface::Coulomb::CoulombP3M::do_construct(), ScriptInterface::Coulomb::CoulombScafacos::do_construct(), ScriptInterface::Coulomb::DebyeHueckel::do_construct(), ScriptInterface::Coulomb::ElectrostaticLayerCorrection::do_construct(), ScriptInterface::Coulomb::ICCStar::do_construct(), ScriptInterface::Coulomb::ReactionField::do_construct(), ScriptInterface::Dipoles::DipolarDirectSum::do_construct(), ScriptInterface::Dipoles::DipolarLayerCorrection::do_construct(), ScriptInterface::Dipoles::DipolarP3M< Architecture >::do_construct(), ScriptInterface::Dipoles::DipolarScafacos::do_construct(), ScriptInterface::Integrators::SteepestDescent::do_construct(), ScriptInterface::Integrators::StokesianDynamics::do_construct(), ScriptInterface::Integrators::VelocityVerletIsoNPT::do_construct(), ScriptInterface::Interactions::InteractionPotentialInterface< CoreIA >::do_construct(), ScriptInterface::Interactions::NonBondedInteractionHandle::do_construct(), ScriptInterface::Math::CylindricalTransformationParameters::do_construct(), ScriptInterface::MPIIO::MPIIOScript::do_construct(), ScriptInterface::Observables::CylindricalLBProfileObservable< CoreCylLBObs >::do_construct(), ScriptInterface::Observables::CylindricalPidProfileObservable< CoreObs >::do_construct(), ScriptInterface::Observables::LBProfileObservable< CoreLBObs >::do_construct(), ScriptInterface::PairCriteria::EnergyCriterion::do_construct(), ScriptInterface::Particles::ParticleHandle::do_construct(), ScriptInterface::Particles::ParticleModifier::do_construct(), ScriptInterface::Particles::ParticleSlice::do_construct(), ScriptInterface::ReactionMethods::ReactionAlgorithm::do_construct(), ScriptInterface::Shapes::HollowConicalFrustum::do_construct(), ScriptInterface::walberla::EKContainer::do_construct(), ScriptInterface::walberla::EKFFT::do_construct(), ScriptInterface::walberla::EKIndexedReactionSlice::do_construct(), ScriptInterface::walberla::EKNone::do_construct(), ScriptInterface::walberla::EKPoissonSolverNode::do_construct(), ScriptInterface::walberla::EKPoissonSolverSlice::do_construct(), ScriptInterface::walberla::EKReactant::do_construct(), ScriptInterface::walberla::EKSpecies::do_construct(), ScriptInterface::walberla::EKSpeciesNode::do_construct(), ScriptInterface::walberla::EKSpeciesSlice::do_construct(), ScriptInterface::walberla::LatticeWalberla::do_construct(), ScriptInterface::walberla::LBFluid::do_construct(), ScriptInterface::walberla::LBFluidNode::do_construct(), ScriptInterface::walberla::LBFluidSlice::do_construct(), ScriptInterface::walberla::VTKHandleBase< Field >::do_construct(), ScriptInterface::Writer::H5md::do_construct(), ScriptInterface::CollisionDetection::BindAtPointOfCollision::do_initialize(), ScriptInterface::CollisionDetection::BindCenters::do_initialize(), ScriptInterface::CollisionDetection::GlueToSurface::do_initialize(), ScriptInterface::walberla::EKBulkReaction::EKBulkReaction(), ScriptInterface::walberla::EKFFT::EKFFT(), ScriptInterface::walberla::EKIndexedReaction::EKIndexedReaction(), ScriptInterface::walberla::EKSpecies::EKSpecies(), ScriptInterface::Shapes::Ellipsoid::Ellipsoid(), ScriptInterface::PairCriteria::EnergyCriterion::EnergyCriterion(), ScriptInterface::ReactionMethods::ExclusionRadius::ExclusionRadius(), ScriptInterface::Thermostat::Interface< CoreClass >::extract_kT(), ScriptInterface::Thermostat::LBThermostat::extract_kT(), ScriptInterface::CollisionDetection::Protocol::find_bond_id(), ScriptInterface::walberla::EKReaction::get_agrid(), ScriptInterface::Accumulators::AccumulatorBase::get_core_system_pointer(), ScriptInterface::Particles::get_gamma_safe(), ScriptInterface::walberla::EKReaction::get_is_gpu(), ScriptInterface::ObjectMap< BreakageSpec, AutoParameters< ObjectMap< BreakageSpec, System::Leaf >, System::Leaf > >::get_key(), ScriptInterface::Thermostat::Interface< CoreClass >::get_member_handle(), ScriptInterface::Particles::get_quaternion_safe(), ScriptInterface::Analysis::get_summary(), get_value_or(), ScriptInterface::Shapes::HollowConicalFrustum::HollowConicalFrustum(), ScriptInterface::Constraints::HomogeneousMagneticField::HomogeneousMagneticField(), ScriptInterface::Integrators::Integrator::integrate(), ScriptInterface::Integrators::SteepestDescent::integrate(), ScriptInterface::Integrators::IntegratorHandle::IntegratorHandle(), ScriptInterface::Thermostat::LBThermostat::invalid_rng_state(), ScriptInterface::walberla::LBFluid::LBFluid(), ScriptInterface::Thermostat::LBThermostat::LBThermostat(), ScriptInterface::LeesEdwards::LeesEdwards::LeesEdwards(), ScriptInterface::Thermostat::Interface< CoreClass >::make_autogamma(), ScriptInterface::Thermostat::Interface< CoreClass >::make_autoparameter(), ScriptInterface::Thermostat::Thermostat::make_autoparameter(), ScriptInterface::walberla::EKFFT::make_instance(), ScriptInterface::walberla::EKReaction::make_instance(), ScriptInterface::walberla::EKSpecies::make_instance(), ScriptInterface::walberla::LBFluid::make_instance(), make_shared_from_args(), ScriptInterface::Interactions::NonBondedInteractionHandle::NonBondedInteractionHandle(), ScriptInterface::CellSystem::CellSystem::on_bind_system(), ScriptInterface::Integrators::IntegratorHandle::on_bind_system(), ScriptInterface::Particles::ParticleHandle::ParticleHandle(), ScriptInterface::Observables::ProfileObservable< CoreObs >::ProfileObservable(), ScriptInterface::System::set_bonds(), set_from_args(), ScriptInterface::System::System::set_internal_state(), ScriptInterface::Thermostat::Interface< CoreClass >::set_rng_counter(), ScriptInterface::Thermostat::Interface< CoreClass >::set_rng_seed(), ScriptInterface::Constraints::ShapeBasedConstraint::ShapeBasedConstraint(), ScriptInterface::System::System::System(), and ScriptInterface::Shapes::Wall::Wall().

◆ get_value() [2/2]

template<typename T>
T ScriptInterface::get_value ( VariantMap const & vals,
std::string const & name )

Get a value from a VariantMap by name, or throw if it does not exist or is not convertible to the target type.

Definition at line 408 of file get_value.hpp.

◆ get_value_or()

template<typename T>
T ScriptInterface::get_value_or ( VariantMap const & vals,
std::string const & name,
T const & default_ )

Get a value from a VariantMap by name, or return a default value if it does not exist.

Definition at line 420 of file get_value.hpp.

References get_value().

Referenced by ScriptInterface::Interactions::IBMTribend::construct_bond(), ScriptInterface::Interactions::IBMTriel::construct_bond(), ScriptInterface::Analysis::Analysis::do_call_method(), ScriptInterface::CellSystem::CellSystem::do_call_method(), ScriptInterface::Constraints::ExternalField< Scaled, Interpolated< double, 3 > >::do_call_method(), ScriptInterface::Constraints::ExternalPotential< Scaled, Interpolated< double, 1 > >::do_call_method(), ScriptInterface::Galilei::Galilei::do_call_method(), ScriptInterface::Interactions::InteractionPotentialInterface< CoreIA >::do_call_method(), ScriptInterface::Interactions::NonBondedInteractionHandle::do_call_method(), ScriptInterface::Particles::Polymer::do_call_method(), ScriptInterface::Accumulators::ContactTimes::do_construct(), ScriptInterface::Accumulators::Correlator::do_construct(), ScriptInterface::Accumulators::MeanVarianceCalculator::do_construct(), ScriptInterface::Accumulators::TimeSeries::do_construct(), ScriptInterface::CellSystem::CheckpointerContext::do_construct(), ScriptInterface::Coulomb::CoulombP3M::do_construct(), ScriptInterface::Dipoles::DipolarDirectSum::do_construct(), ScriptInterface::Dipoles::DipolarP3M< Architecture >::do_construct(), ScriptInterface::Integrators::StokesianDynamics::do_construct(), ScriptInterface::Integrators::VelocityVerletIsoNPT::do_construct(), ScriptInterface::ObjectList< AccumulatorBase, AutoParameters< ObjectList< AccumulatorBase, System::Leaf >, System::Leaf > >::do_construct(), ScriptInterface::Observables::CylindricalLBProfileObservable< CoreCylLBObs >::do_construct(), ScriptInterface::Observables::CylindricalPidProfileObservable< CoreObs >::do_construct(), ScriptInterface::Observables::LBProfileObservable< CoreLBObs >::do_construct(), ScriptInterface::Particles::ParticleSlice::do_construct(), ScriptInterface::Shapes::HollowConicalFrustum::do_construct(), ScriptInterface::walberla::EKFFT::do_construct(), ScriptInterface::walberla::EKNone::do_construct(), ScriptInterface::walberla::EKSpecies::do_construct(), ScriptInterface::walberla::LBFluid::do_construct(), ScriptInterface::walberla::VTKHandleBase< Field >::do_construct(), ScriptInterface::walberla::EKSpecies::make_instance(), ScriptInterface::walberla::LBFluid::make_instance(), and ScriptInterface::ObjectMap< BreakageSpec, AutoParameters< ObjectMap< BreakageSpec, System::Leaf >, System::Leaf > >::restore_from_checkpoint().

◆ initialize()

◆ is_none()

◆ is_type()

◆ make_shared_from_args()

template<typename T, typename... Types, typename... ArgNames>
std::shared_ptr< T > ScriptInterface::make_shared_from_args ( VariantMap const & vals,
ArgNames &&... args )

Make a new std::shared_ptr<T> with arguments extracted from a VariantMap.

Definition at line 433 of file get_value.hpp.

References get_value().

Referenced by ScriptInterface::Observables::PairwiseDistances< CoreObs >::do_construct(), ScriptInterface::Observables::PidObservable< CorePidObs >::do_construct(), ScriptInterface::Observables::PidProfileObservable< CoreObs >::do_construct(), ScriptInterface::Observables::RDF::do_construct(), ScriptInterface::Writer::H5md::do_construct(), ScriptInterface::Interactions::InteractionBMHTF::make_new_instance(), ScriptInterface::Interactions::InteractionBuckingham::make_new_instance(), ScriptInterface::Interactions::InteractionDPD::make_new_instance(), ScriptInterface::Interactions::InteractionGaussian::make_new_instance(), ScriptInterface::Interactions::InteractionGayBerne::make_new_instance(), ScriptInterface::Interactions::InteractionHat::make_new_instance(), ScriptInterface::Interactions::InteractionHertzian::make_new_instance(), ScriptInterface::Interactions::InteractionLJ::make_new_instance(), ScriptInterface::Interactions::InteractionLJcos2::make_new_instance(), ScriptInterface::Interactions::InteractionLJcos::make_new_instance(), ScriptInterface::Interactions::InteractionLJGen::make_new_instance(), ScriptInterface::Interactions::InteractionMorse::make_new_instance(), ScriptInterface::Interactions::InteractionSmoothStep::make_new_instance(), ScriptInterface::Interactions::InteractionSoftSphere::make_new_instance(), ScriptInterface::Interactions::InteractionTabulated::make_new_instance(), ScriptInterface::Interactions::InteractionThole::make_new_instance(), and ScriptInterface::Interactions::InteractionWCA::make_new_instance().

◆ make_unordered_map_of_variants()

◆ make_variant()

template<typename T>
Variant ScriptInterface::make_variant ( const T & x)

Make a Variant from argument.

This is a convenience function, so that rather involved constructors from Variant are not needed in the script interface.

Definition at line 141 of file Variant.hpp.

Referenced by ScriptInterface::CollisionDetection::CollisionDetection::CollisionDetection(), and ScriptInterface::LeesEdwards::LeesEdwards::LeesEdwards().

◆ make_vector_of_variants()

◆ mpi_reduce_sum()

template<typename T>
T ScriptInterface::mpi_reduce_sum ( boost::mpi::communicator const & comm,
T const & result )

Reduce object by sum on the head node.

Worker nodes get a default-constructed object.

Definition at line 35 of file script_interface/communication.hpp.

Referenced by ScriptInterface::Analysis::Analysis::do_call_method().

◆ pack() [1/2]

◆ pack() [2/2]

PackedMap ScriptInterface::pack ( const VariantMap & v)
inline

Pack a VariantMap.

Applies pack to every value in the input map.

Definition at line 183 of file packed_variant.hpp.

◆ set_from_args()

◆ unpack() [1/2]

VariantMap ScriptInterface::unpack ( const PackedMap & v,
std::unordered_map< ObjectId, ObjectRef > const & objects )
inline

Unpack a PackedMap.

Applies unpack to every value in the input map.

Definition at line 200 of file packed_variant.hpp.

References unpack().

◆ unpack() [2/2]

Variant ScriptInterface::unpack ( const PackedVariant & v,
std::unordered_map< ObjectId, ObjectRef > const & objects )
inline

Unpack a PackedVariant.

Applies UnpackVisitor to a Variant.

Parameters
vPacked Variant.
objectsMap of ids to reference.
Returns
Transformed variant.

Definition at line 172 of file packed_variant.hpp.

Referenced by ScriptInterface::System::System::set_internal_state(), and unpack().

Variable Documentation

◆ none