Mantid
Loading...
Searching...
No Matches
Framework
Kernel
inc
MantidKernel
make_cow.h
Go to the documentation of this file.
1
// Mantid Repository : https://github.com/mantidproject/mantid
2
//
3
// Copyright © 2018 ISIS Rutherford Appleton Laboratory UKRI,
4
// NScD Oak Ridge National Laboratory, European Spallation Source,
5
// Institut Laue - Langevin & CSNS, Institute of High Energy Physics, CAS
6
// SPDX - License - Identifier: GPL - 3.0 +
7
#pragma once
8
9
#include "
MantidKernel/cow_ptr.h
"
10
#include <memory>
11
12
/*
13
Creates a cow_ptr in-place.
14
*/
15
16
namespace
Mantid
{
17
18
namespace
Kernel {
19
20
template
<
class
T,
class
... Args>
inline
cow_ptr<T>
make_cow
(Args &&...args) {
21
return
cow_ptr<T>
(std::make_shared<T>(std::forward<Args>(args)...));
22
}
23
24
}
// namespace Kernel
25
}
// namespace Mantid
Mantid::Kernel::cow_ptr
Implements a copy on write data template.
Definition:
cow_ptr.h:41
cow_ptr.h
Mantid::Kernel::make_cow
cow_ptr< T > make_cow(Args &&...args)
Definition:
make_cow.h:20
Mantid
Helper class which provides the Collimation Length for SANS instruments.
Definition:
AbsorptionCorrection.h:18
Generated on Tue Jan 3 2023 11:57:50 for Mantid by
1.9.5