chsvlib
chsv helper source code

◆ swap()

void swap ( MyType rRight)

Exchanges the contents of the AutoResource object with those of rRight, transferring ownership of any managed object between them without destroying either.

Parameters
rRightis a reference to another AutoResource object of the same type (i.e. with the same class template parameters).
Remarks
The function swaps the respective stored handles, closers and checkers by invoking swap on them.