BloombergLP::bslmt::OnceGuard::OnceGuard

Create a guard optionally associated with the specified once object.

Synopsis

Declared in <bslmt_once.h>

explicit
OnceGuard(Once* once = 0);

Description

Initialize this object to guard the (optionally) specified once object. If once is not specified, then it must be set later using the setOnce method before other methods may be called.

Parameters

NameDescription
onceoptional Once object to guard; may be null