forked from npshub/mantid
-
Notifications
You must be signed in to change notification settings - Fork 0
/
MatrixProperty.cpp
54 lines (48 loc) · 1.79 KB
/
MatrixProperty.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
// Mantid Repository : https://github.com/mantidproject/mantid
//
// Copyright © 2018 ISIS Rutherford Appleton Laboratory UKRI,
// NScD Oak Ridge National Laboratory, European Spallation Source,
// Institut Laue - Langevin & CSNS, Institute of High Energy Physics, CAS
// SPDX - License - Identifier: GPL - 3.0 +
#include "MantidKernel/MatrixProperty.h"
#include "MantidKernel/IPropertyManager.h"
// PropertyWithValue implementation
#include "MantidKernel/Exception.h"
#include "MantidKernel/PropertyWithValue.tcc"
namespace Mantid {
namespace Kernel {
/**
* Constructor
* @param propName :: Name of the property
* @param validator :: A pointer to a validator whose ownership is
* transferred to this object
* @param direction :: The direction
*/
template <typename TYPE>
MatrixProperty<TYPE>::MatrixProperty(const std::string &propName, const IValidator_sptr &validator,
unsigned int direction)
: PropertyWithValue<HeldType>(propName, HeldType(), validator, direction) {}
/**
* Copy constructor
* @param rhs :: Contruct this object from rhs
*/
template <typename TYPE>
MatrixProperty<TYPE>::MatrixProperty(const MatrixProperty &rhs) : PropertyWithValue<HeldType>(rhs) {}
/// Destructor
template <typename TYPE> MatrixProperty<TYPE>::~MatrixProperty() {}
///@cond
// Symbol definitions
template class MANTID_KERNEL_DLL MatrixProperty<double>;
template class MANTID_KERNEL_DLL MatrixProperty<int>;
template class MANTID_KERNEL_DLL MatrixProperty<float>;
///@endcond
} // namespace Kernel
} // namespace Mantid
///@cond
/**
* IPropertyManager::getValue definitions
*/
DEFINE_IPROPERTYMANAGER_GETVALUE(Mantid::Kernel::DblMatrix)
DEFINE_IPROPERTYMANAGER_GETVALUE(Mantid::Kernel::IntMatrix)
DEFINE_IPROPERTYMANAGER_GETVALUE(Mantid::Kernel::Matrix<float>)
///@endcond