Skip to content

Commit 05acdab

Browse files
committed
[hist] Document deleted copies of RHistEngine
1 parent 4196c39 commit 05acdab

File tree

1 file changed

+18
-1
lines changed

1 file changed

+18
-1
lines changed

hist/histv7/inc/ROOT/RHistEngine.hxx

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,11 +82,26 @@ public:
8282
{
8383
}
8484

85-
// Copy constructor and assignment operator are deleted to avoid surprises.
85+
/// The copy constructor is deleted.
86+
///
87+
/// Copying all bin contents can be an expensive operation, depending on the number of bins. If required, users can
88+
/// explicitly call Clone().
8689
RHistEngine(const RHistEngine<BinContentType> &) = delete;
90+
/// Efficiently move construct a histogram engine.
91+
///
92+
/// After this operation, the moved-from object is invalid.
8793
RHistEngine(RHistEngine<BinContentType> &&) = default;
94+
95+
/// The copy assignment operator is deleted.
96+
///
97+
/// Copying all bin contents can be an expensive operation, depending on the number of bins. If required, users can
98+
/// explicitly call Clone().
8899
RHistEngine<BinContentType> &operator=(const RHistEngine<BinContentType> &) = delete;
100+
/// Efficiently move a histogram engine.
101+
///
102+
/// After this operation, the moved-from object is invalid.
89103
RHistEngine<BinContentType> &operator=(RHistEngine<BinContentType> &&) = default;
104+
90105
~RHistEngine() = default;
91106

92107
const std::vector<RAxisVariant> &GetAxes() const { return fAxes.Get(); }
@@ -178,6 +193,8 @@ public:
178193

179194
/// Clone this histogram engine.
180195
///
196+
/// Copying all bin contents can be an expensive operation, depending on the number of bins.
197+
///
181198
/// \return the cloned object
182199
RHistEngine<BinContentType> Clone() const
183200
{

0 commit comments

Comments
 (0)