18#include "MantidNexus/NexusFile.h"
19#include <boost/algorithm/string.hpp>
24#define strcasecmp _stricmp
35const std::string POS_PARAM_NAME =
"pos";
36const std::string POSX_PARAM_NAME =
"x";
37const std::string POSY_PARAM_NAME =
"y";
38const std::string POSZ_PARAM_NAME =
"z";
40const std::string ROT_PARAM_NAME =
"rot";
41const std::string ROTX_PARAM_NAME =
"rotx";
42const std::string ROTY_PARAM_NAME =
"roty";
43const std::string ROTZ_PARAM_NAME =
"rotz";
45const std::string DOUBLE_PARAM_NAME =
"double";
46const std::string INT_PARAM_NAME =
"int";
47const std::string BOOL_PARAM_NAME =
"bool";
48const std::string STRING_PARAM_NAME =
"string";
49const std::string V3D_PARAM_NAME =
"V3D";
50const std::string QUAT_PARAM_NAME =
"Quat";
52const std::string SCALE_PARAM_NAME =
"sca";
55Kernel::Logger
g_log(
"ParameterMap");
57void checkIsNotMaskingParameter(
const std::string &
name) {
58 if (
name == std::string(
"masked"))
59 throw std::runtime_error(
"Masking data (\"masked\") cannot be stored in "
60 "ParameterMap. Use DetectorInfo instead");
71 : m_parameterFileNames(other.m_parameterFileNames), m_map(other.m_map),
74 m_instrument(other.m_instrument) {
145 for (it =
m_map.begin(); it !=
m_map.end(); ++it) {
146 if (compName == it->first->getName()) {
147 std::shared_ptr<Parameter> param =
get(it->first,
name);
149 result = param->getDescription();
167 for (it =
m_map.begin(); it !=
m_map.end(); ++it) {
168 if (compName == it->first->getName()) {
169 std::shared_ptr<Parameter> param =
get(it->first,
name);
171 result = param->getShortDescription();
195 double num = std::fabs(x1 - x2);
197 double den = 0.5 * (std::fabs(x1) + std::fabs(x2));
199 return (num > errorVal);
201 return (num / den > errorVal);
219 const double doubleTolerance)
const {
221 return std::string(
"");
225 return std::string(
"Number of parameters does not match: ") +
std::to_string(this->
size()) +
" not equal to " +
233 std::unordered_multimap<std::string, Parameter_sptr> thisMap, rhsMap;
234 for (
auto &mappair : this->
m_map) {
235 thisMap.emplace(mappair.first->getFullName(), mappair.second);
237 for (
auto &mappair :
rhs.m_map) {
238 rhsMap.emplace(mappair.first->getFullName(), mappair.second);
241 std::stringstream strOutput;
242 for (
auto thisIt = thisMap.cbegin(); thisIt != thisMap.cend(); ++thisIt) {
243 const std::string fullName = thisIt->first;
244 const auto ¶m = thisIt->second;
246 for (
auto rhsIt = rhsMap.cbegin(); rhsIt != rhsMap.cend(); ++rhsIt) {
247 const std::string rhsFullName = rhsIt->first;
248 const auto &rhsParam = rhsIt->second;
249 if ((fullName == rhsFullName) && (param->name() == (rhsParam->name()))) {
250 if ((param->type() == rhsParam->type()) && (rhsParam->type() ==
"double")) {
252 if (!
relErr(param->value<
double>(), rhsParam->value<
double>(), doubleTolerance))
254 }
else if (std::abs(param->value<
double>() - rhsParam->value<
double>()) <= doubleTolerance)
256 }
else if (param->asString() == rhsParam->asString()) {
266 strOutput <<
"Parameter mismatch LHS=RHS for LHS parameter in component "
268 << fullName <<
". Parameter name is: " << (*param).name() <<
" and value: " << (*param).asString()
270 bool componentWithSameNameRHS =
false;
271 bool parameterWithSameNameRHS =
false;
272 for (
auto rhsIt = rhsMap.cbegin(); rhsIt != rhsMap.cend(); ++rhsIt) {
273 const std::string rhsFullName = rhsIt->first;
274 if (fullName == rhsFullName) {
275 componentWithSameNameRHS =
true;
276 if ((*param).name() == (*rhsIt->second).
name()) {
277 parameterWithSameNameRHS =
true;
278 strOutput <<
"RHS param with same name has value: " << (*rhsIt->second).
asString() <<
'\n';
282 if (!componentWithSameNameRHS) {
283 strOutput <<
"No matching RHS component name\n";
285 if (componentWithSameNameRHS && !parameterWithSameNameRHS) {
286 strOutput <<
"Found matching RHS component name but not parameter name\n";
289 return strOutput.str();
292 return strOutput.str();
300 checkIsNotMaskingParameter(
name);
302 for (
auto itr =
m_map.begin(); itr !=
m_map.end();) {
303 if (itr->second->name() ==
name) {
320 checkIsNotMaskingParameter(
name);
321 if (!
m_map.empty()) {
323 auto itrs =
m_map.equal_range(
id);
324 for (
auto it = itrs.first; it != itrs.second;) {
325 if (it->second->name() ==
name) {
349 const std::string &
value,
const std::string *
const pDescription,
const std::string &pVisible) {
351 param->fromString(
value);
352 this->
add(comp, param, pDescription);
363 const std::string *
const pDescription) {
366 checkIsNotMaskingParameter(par->name());
368 par->setDescription(*pDescription);
370 auto existing_par =
positionOf(comp, par->name().c_str(),
"");
376 if (existing_par !=
m_map.end()) {
377 std::atomic_store(&(existing_par->second), par);
381#if defined(__clang__) && !defined(__APPLE__)
382#define CLANG_ON_LINUX true
384#define CLANG_ON_LINUX false
386#if TBB_VERSION_MAJOR >= 4 && TBB_VERSION_MINOR >= 4 && !CLANG_ON_LINUX
409 const std::string &fittingFunction,
const std::string &
value,
410 const std::string *
const pDescription,
const std::string &pVisible) {
411 checkIsNotMaskingParameter(
name);
413 param->fromString(
value);
415 param->setDescription(*pDescription);
419 if (!
m_map.empty()) {
421 auto it_found =
m_map.find(
id);
422 if (it_found !=
m_map.end()) {
423 auto itrs =
m_map.equal_range(
id);
424 for (
auto itr = itrs.first; itr != itrs.second; ++itr) {
425 const auto &existing = itr->second;
426 if (existing->type() ==
"fitting" && strcasecmp(existing->nameAsCString(),
name.c_str()) == 0) {
429 g_log.
debug() <<
"addFittingParameter: [replace] matched existing (name='" <<
name <<
"', function='"
430 << fittingFunction <<
"') on component '" << comp->
getName() <<
"'; overwriting in place\n";
431 std::atomic_store(&(itr->second), param);
436 g_log.
debug() <<
"addFittingParameter: [skip-match] existing 'fitting' entry (name='" <<
name
437 <<
"') on component '" << comp->
getName()
438 <<
"' did not hold a FitParameter value; ignoring it and continuing search\n";
445 g_log.
debug() <<
"addFittingParameter: [insert] no existing match for (name='" <<
name <<
"', function='"
446 << fittingFunction <<
"') on component '" << comp->
getName() <<
"'; adding new entry\n";
460 const std::string *
const pDescription) {
480 g_log.
warning() <<
"addPositionCoordinate() called with unrecognized "
481 "coordinate symbol: "
485 param->setDescription(*pDescription);
506 const std::string *
const pDescription) {
510 double rotX, rotY, rotZ;
513 rotX = paramRotX->value<
double>();
518 rotY = paramRotY->value<
double>();
523 rotZ = paramRotZ->value<
double>();
539 g_log.
warning() <<
"addRotationParam() called with unrecognized coordinate symbol: " <<
name;
560 const std::string *
const pDescription,
const std::string &pVisible) {
574 const std::string *
const pDescription,
const std::string &pVisible) {
588 const std::string *
const pDescription,
const std::string &pVisible) {
602 const std::string *
const pDescription,
const std::string &pVisible) {
616 const std::string *
const pDescription,
const std::string &pVisible) {
629 const std::string *
const pDescription,
const std::string &pVisible) {
641 const std::string
name(
"masked");
643 auto typedParam = std::dynamic_pointer_cast<ParameterType<bool>>(param);
644 typedParam->setValue(
value);
648#if defined(__clang__) && !defined(__APPLE__)
649#define CLANG_ON_LINUX true
651#define CLANG_ON_LINUX false
653#if TBB_VERSION_MAJOR >= 4 && TBB_VERSION_MINOR >= 4 && !CLANG_ON_LINUX
670 const std::string *
const pDescription,
const std::string &pVisible) {
683 const std::string *
const pDescription) {
697 const std::string *
const pDescription) {
711 const std::string *
const pDescription) {
736 checkIsNotMaskingParameter(
name);
740 std::pair<pmap_cit, pmap_cit> components =
m_map.equal_range(
id);
741 bool anytype = (strlen(type) == 0);
742 for (
auto itr = components.first; itr != components.second; ++itr) {
743 const auto ¶m = itr->second;
744 if (strcasecmp(param->nameAsCString(),
name) == 0 && (anytype || param->type() == type)) {
757 checkIsNotMaskingParameter(parameter.
name());
758 if (
m_map.empty() || !comp)
762 auto it_found =
m_map.find(
id);
763 if (it_found !=
m_map.end()) {
764 auto itrs =
m_map.equal_range(
id);
765 for (
auto itr = itrs.first; itr != itrs.second; ++itr) {
767 if (*param == parameter)
782 return get(comp,
name.c_str(), type.c_str());
793 checkIsNotMaskingParameter(
name);
799 if (itr !=
m_map.end())
800 result = std::atomic_load(&itr->second);
812 auto result =
m_map.end();
815 const bool anytype = (strlen(type) == 0);
816 if (!
m_map.empty()) {
818 auto it_found =
m_map.find(
id);
819 if (it_found !=
m_map.end()) {
820 auto itrs =
m_map.equal_range(
id);
821 for (
auto itr = itrs.first; itr != itrs.second; ++itr) {
822 const auto ¶m = itr->second;
823 if (strcasecmp(param->nameAsCString(),
name) == 0 && (anytype || param->type() == type)) {
841 auto result =
m_map.end();
844 const bool anytype = (strlen(type) == 0);
845 if (!
m_map.empty()) {
847 auto it_found =
m_map.find(
id);
848 if (it_found !=
m_map.end()) {
849 auto itrs =
m_map.equal_range(
id);
850 for (
auto itr = itrs.first; itr != itrs.second; ++itr) {
851 const auto ¶m = itr->second;
852 if (strcasecmp(param->nameAsCString(),
name) == 0 && (anytype || param->type() == type)) {
869 if (!
m_map.empty()) {
871 auto it_found =
m_map.find(
id);
872 if (it_found !=
m_map.end() && it_found->first) {
873 auto itrs =
m_map.equal_range(
id);
874 for (
auto itr = itrs.first; itr != itrs.second; ++itr) {
875 const auto ¶m = itr->second;
876 if (strcasecmp(param->type().c_str(), type.c_str()) == 0) {
877 result = std::atomic_load(¶m);
893 std::shared_ptr<const IComponent> compInFocus(comp,
NoDeleting());
894 while (compInFocus !=
nullptr) {
899 compInFocus = compInFocus->getParent();
914 const std::string &type)
const {
927 checkIsNotMaskingParameter(
name);
934 result = this->
get(parent->getComponentID(),
name, type);
937 parent = parent->getParent();
956 const std::string &fittingFunction)
const {
957 checkIsNotMaskingParameter(
name);
958 if (!comp ||
m_map.empty())
961 std::shared_ptr<const IComponent> compInFocus(comp,
NoDeleting());
962 while (compInFocus !=
nullptr) {
964 auto it_found =
m_map.find(
id);
965 if (it_found !=
m_map.end()) {
966 auto itrs =
m_map.equal_range(
id);
967 for (
auto itr = itrs.first; itr != itrs.second; ++itr) {
968 const auto ¶m = itr->second;
969 if (param->type() ==
"fitting" && strcasecmp(param->nameAsCString(),
name.c_str()) == 0) {
972 return std::atomic_load(&itr->second);
980 compInFocus = compInFocus->getParent();
1002 return param->asString();
1011 std::set<std::string> paramNames;
1013 auto it_found =
m_map.find(
id);
1014 if (it_found ==
m_map.end()) {
1018 auto itrs =
m_map.equal_range(
id);
1019 for (
auto it = itrs.first; it != itrs.second; ++it) {
1020 paramNames.insert(it->second->name());
1033 std::stringstream out;
1034 for (
const auto &mappair :
m_map) {
1035 const std::shared_ptr<Parameter> &p = mappair.second;
1036 if (p && mappair.first) {
1037 const auto *comp =
dynamic_cast<const IComponent *
>(mappair.first);
1038 const auto *det =
dynamic_cast<const IDetector *
>(comp);
1040 out <<
"detID:" << det->
getID();
1042 out << comp->getFullName();
1045 const auto paramVisible =
"visible:" + std::string(p->visible() == 1 ?
"true" :
"false");
1046 out <<
';' << p->type() <<
';' << p->name() <<
';' << p->asString() <<
';' << paramVisible <<
'|';
1100 auto oldParameterNames = oldPMap->
names(oldComp);
1101 for (
const auto &oldParameterName : oldParameterNames) {
1104#if TBB_VERSION_MAJOR >= 4 && TBB_VERSION_MINOR >= 4 && !CLANG_ON_LINUX
1118 file->makeGroup(
group,
"NXnote",
true);
1119 file->putAttr(
"version", 1);
1120 file->writeData(
"author",
"");
1121 file->writeData(
"date", Types::Core::DateAndTime::getCurrentTime().toISO8601String());
1122 file->writeData(
"description",
"A string representation of the parameter "
1123 "map. The format is either: "
1124 "|detID:id-value;param-type;param-name;param-"
1125 "value| for a detector or "
1126 "|comp-name;param-type;param-name;param-value|"
1127 " for other components.");
1128 file->writeData(
"type",
"text/plain");
1130 file->writeData(
"data", s);
1146 const std::string &visible)
const {
1174 throw std::runtime_error(
"Cannot return reference to NULL DetectorInfo");
1181 throw std::runtime_error(
"Cannot return reference to NULL DetectorInfo");
1188 throw std::runtime_error(
"Cannot return reference to NULL ComponentInfo");
1196 throw std::runtime_error(
"Cannot return reference to NULL ComponentInfo");
1218 throw std::logic_error(
"ParameterMap::setInstrument: Cannot change "
1219 "instrument once it has been set.");
1221 throw std::logic_error(
"ParameterMap::setInstrument must be called with "
1222 "base instrument, not a parametrized instrument");
1224 if (
m_map.empty()) {
1237 const size_t n =
m_map.size();
1238 const size_t mapMem =
n * (
sizeof(pmap::value_type) + 2 *
sizeof(
void *));
1241 size_t parameterObjectsMem = 0;
1242 for (
const auto &entry :
m_map) {
1243 const auto ¶m = entry.second;
1245 parameterObjectsMem +=
sizeof(
Parameter);
1246 parameterObjectsMem += param->m_name.capacity();
1247 parameterObjectsMem += param->m_type.capacity();
1248 parameterObjectsMem += param->m_str_value.capacity();
1249 parameterObjectsMem += param->m_description.capacity();
1255 [](
size_t acc,
const auto &s) {
return acc + s.capacity(); });
1258 const size_t cacheLocMem =
m_cacheLocMap ?
sizeof(*m_cacheLocMap) : 0;
1259 const size_t cacheRotMem =
m_cacheRotMap ?
sizeof(*m_cacheRotMap) : 0;
1265 return sizeof(*this) + mapMem + parameterObjectsMem + fileNamesMem + cacheLocMem + cacheRotMem + detectorInfoMem +
const std::vector< double > & rhs
double value
The value of the point.
#define PARALLEL_CRITICAL(name)
Mantid::Kernel::Quat(ComponentInfo::* rotation)(const size_t) const
ComponentInfo : Provides a component centric view on to the instrument.
bool isParametrized() const override
Return true if the Component is, in fact, parametrized (that is - it has a valid parameter map)
Geometry::DetectorInfo is an intermediate step towards a DetectorInfo that is part of Instrument-2....
Store information about a fitting parameter such as its value if it is constrained or tied.
const std::string & getFunction() const
get function
base class for Geometric IComponent
virtual Kernel::V3D getPos() const =0
Get the position of the IComponent. Tree structure is traverse through the.
virtual std::shared_ptr< const IComponent > getParent() const =0
Return a pointer to the current parent.
virtual ComponentID getComponentID() const =0
Returns the ComponentID - a unique identifier of the component.
virtual std::string getName() const =0
Get the IComponent name.
Interface class for detector objects.
virtual detid_t getID() const =0
Get the detector ID.
std::pair< std::unique_ptr< ComponentInfo >, std::unique_ptr< DetectorInfo > > makeBeamlineNew(ParameterMap &pmap) const
Return ComponentInfo and DetectorInfo for instrument given by pmap.
std::pair< std::unique_ptr< ComponentInfo >, std::unique_ptr< DetectorInfo > > makeBeamline(ParameterMap &pmap, const ParameterMap *source=nullptr) const
Return ComponentInfo and DetectorInfo for instrument given by pmap.
size_t detectorIndex(const detid_t detID) const
Returns the index for a detector ID. Used for accessing DetectorInfo.
static std::shared_ptr< Parameter > create(const std::string &className, const std::string &name, const std::string &visible="true")
Creates an instance of a parameter.
component_map_it positionOf(const IComponent *comp, const char *name, const char *type)
internal function to get position of the parameter in the parameter map
bool getCachedRotation(const IComponent *comp, Kernel::Quat &rotation) const
Attempts to retrieve a rotation from the rotation cache.
const Geometry::DetectorInfo & detectorInfo() const
Only for use by ExperimentInfo. Returns a reference to the DetectorInfo.
const std::vector< std::string > & getParameterFilenames() const
Returns a list of all the parameter files loaded.
static const std::string & pQuat()
bool getCachedLocation(const IComponent *comp, Kernel::V3D &location) const
Attempts to retrieve a location from the location cache.
void clearPositionSensitiveCaches()
Clears the location, rotation & bounding box caches.
std::unique_ptr< Geometry::DetectorInfo > m_detectorInfo
Pointer to the DetectorInfo wrapper.
bool contains(const IComponent *comp, const std::string &name, const std::string &type="") const
Does the named parameter exist for the given component and type (std::string version)
void copyFromParameterMap(const IComponent *oldComp, const IComponent *newComp, const ParameterMap *oldPMap)
Copy pairs (oldComp->id,Parameter) to the m_map assigning the new newComp->id.
void addInt(const IComponent *comp, const std::string &name, const std::string &value, const std::string *const pDescription=nullptr, const std::string &pVisible="true")
Adds an int value to the parameter map.
void addPositionCoordinate(const IComponent *comp, const std::string &name, const double value, const std::string *const pDescription=nullptr)
Create or adjust "pos" parameter for a component.
std::shared_ptr< Parameter > getRecursive(const IComponent *comp, const std::string &name, const std::string &type="") const
Use get() recursively to see if can find param in all parents of comp and given type (std::string ver...
void addParameterFilename(const std::string &filename)
adds a parameter filename that has been loaded
static const std::string & scale()
std::shared_ptr< Parameter > getRecursiveByType(const IComponent *comp, const std::string &type) const
Looks recursively upwards in the component tree for the first instance of a parameter with a specifie...
static const std::string & rot()
void setCachedLocation(const IComponent *comp, const Kernel::V3D &location) const
Sets a cached location on the location cache.
const Instrument * m_instrument
Pointer to the owning instrument for translating detector IDs into detector indices when accessing th...
std::string getString(const IComponent *comp, const std::string &name, bool recursive=false) const
Return the value of a parameter as a string.
static const std::string & pBool()
void saveNexus(Nexus::File *file, const std::string &group) const
Persist a representation of the Parameter map to the open Nexus file.
void setCachedRotation(const IComponent *comp, const Kernel::Quat &rotation) const
Sets a cached rotation on the rotation cache.
void clearParametersByName(const std::string &name)
Clear any parameters with the given name.
const std::string getDescription(const std::string &compName, const std::string &name) const
Get the component description by name.
std::shared_ptr< Parameter > getByType(const IComponent *comp, const std::string &type) const
Finds the parameter in the map via the parameter type.
void setInstrument(const Instrument *instrument)
Only for use by Instrument. Sets the pointer to the owning instrument.
Geometry::ComponentInfo & mutableComponentInfo()
Only for use by ExperimentInfo. Returns a reference to the ComponentInfo.
bool operator==(const ParameterMap &rhs) const
Equality comparison operator.
std::shared_ptr< Parameter > create(const std::string &className, const std::string &name, const std::string &visible="true") const
Wrapper for ParameterFactory::create to avoid include in header.
void addString(const IComponent *comp, const std::string &name, const std::string &value, const std::string *const pDescription=nullptr, const std::string &pVisible="true")
Adds a std::string value to the parameter map.
std::set< std::string > names(const IComponent *comp) const
Returns a set with all parameter names for component.
int size() const
Return the size of the map.
std::vector< std::string > m_parameterFileNames
internal list of parameter files loaded
pmap m_map
internal parameter map instance
static const std::string & pV3D()
std::unique_ptr< Kernel::Cache< const ComponentID, Kernel::V3D > > m_cacheLocMap
internal cache map instance for cached position values
size_t getMemorySize() const
Get the footprint in memory in bytes.
void addDouble(const IComponent *comp, const std::string &name, const std::string &value, const std::string *const pDescription=nullptr, const std::string &pVisible="true")
Adds a double value to the parameter map.
static const std::string & posz()
std::unique_ptr< Kernel::Cache< const ComponentID, Kernel::Quat > > m_cacheRotMap
internal cache map instance for cached rotation values
bool relErr(double x1, double x2, double errorVal) const
calculate relative error for use in diff
const std::string diff(const ParameterMap &rhs, const bool &firstDiffOnly=false, const bool relative=false, const double doubleTolerance=Kernel::Tolerance) const
Output information that helps understanding the mismatch between two parameter maps.
static const std::string & pDouble()
static const std::string & pos()
Return string to be used in the map.
void addRotationParam(const IComponent *comp, const std::string &name, const double deg, const std::string *const pDescription=nullptr)
Create or adjust "rot" parameter for a component.
ParameterMap()
Default constructor.
std::string asString() const
Returns a string with all component names, parameter names and values.
void addFittingParameter(const IComponent *comp, const std::string &name, const std::string &fittingFunction, const std::string &value, const std::string *const pDescription=nullptr, const std::string &pVisible="true")
Add a fitting parameter.
void addQuat(const IComponent *comp, const std::string &name, const Kernel::Quat &value, const std::string *const pDescription=nullptr)
Adds a Kernel::Quat value to the parameter map.
size_t componentIndex(const Geometry::ComponentID componentId) const
void add(const std::string &type, const IComponent *comp, const std::string &name, const std::string &value, const std::string *const pDescription=nullptr, const std::string &visible="true")
Method for adding a parameter providing its value as a string.
std::shared_ptr< Parameter > getRecursiveFittingParameter(const IComponent *comp, const std::string &name, const std::string &fittingFunction) const
Look for a fitting parameter recursively, picking the one whose embedded FitParameter function name m...
static const std::string & rotz()
const std::string getShortDescription(const std::string &compName, const std::string &name) const
Get the component tooltip by name.
size_t detectorIndex(const detid_t detID) const
Only for use by Detector. Returns a detector index for a detector ID.
static const std::string & posy()
static const std::string & posx()
static const std::string & pString()
tbb::concurrent_unordered_multimap< ComponentID, std::shared_ptr< Parameter > >::const_iterator pmap_cit
Parameter map iterator typedef.
void addV3D(const IComponent *comp, const std::string &name, const std::string &value, const std::string *const pDescription=nullptr)
Adds a Kernel::V3D value to the parameter map.
static const std::string & pInt()
void addBool(const IComponent *comp, const std::string &name, const std::string &value, const std::string *const pDescription=nullptr, const std::string &pVisible="true")
Adds a bool value to the parameter map.
bool operator!=(const ParameterMap &rhs) const
Inquality comparison operator.
bool hasComponentInfo(const Instrument *instrument) const
Only for use by ExperimentInfo.
std::unique_ptr< Geometry::ComponentInfo > m_componentInfo
Pointer to the ComponentInfo wrapper.
static const std::string & rotx()
bool hasDetectorInfo(const Instrument *instrument) const
Only for use by ExperimentInfo.
std::shared_ptr< Parameter > get(const IComponent *comp, const std::string &name, const std::string &type="") const
Get a parameter with a given name and type (std::string version)
void forceUnsafeSetMasked(const IComponent *comp, bool value)
Force adding masking information.
static const std::string & roty()
const Geometry::ComponentInfo & componentInfo() const
Only for use by ExperimentInfo. Returns a reference to the ComponentInfo.
Geometry::DetectorInfo & mutableDetectorInfo()
Only for use by ExperimentInfo. Returns a reference to the DetectorInfo.
Base class for parameters of an instrument.
const std::string & name() const
Parameter name.
Cache is a generic caching storage class.
void debug(const std::string &msg)
Logs at debug level.
void warning(const std::string &msg)
Logs at warning level.
void setX(const double xx) noexcept
Set is x position.
This functor is used as the deleter object of a shared_ptr to effectively erase ownership Raw pointer...
tbb::concurrent_unordered_multimap< ComponentID, std::shared_ptr< Parameter > >::const_iterator component_map_cit
std::shared_ptr< Parameter > Parameter_sptr
Typedef for the shared pointer.
tbb::concurrent_unordered_multimap< ComponentID, std::shared_ptr< Parameter > >::iterator component_map_it
Parameter map iterator typedef.
Mantid::Kernel::Logger g_log("Goniometer")
int32_t detid_t
Typedef for a detector ID.
std::string to_string(const wide_integer< Bits, Signed > &n)