MCPcopy Create free account
hub / github.com/Icinga/icinga2 / LockIfRequired

Method LockIfRequired

lib/base/array.cpp:345–351  ·  view source on GitHub ↗

* Returns an already locked ObjectLock if the array is frozen. * Otherwise, returns an unlocked object lock. * * @returns An object lock. */

Source from the content-addressed store, hash-verified

343 * @returns An object lock.
344 */
345ObjectLock Array::LockIfRequired()
346{
347 if (Frozen()) {
348 return ObjectLock(this, std::defer_lock);
349 }
350 return ObjectLock(this);
351}
352
353Value Array::GetFieldByName(const String& field, bool sandboxed, const DebugInfo& debugInfo) const
354{

Callers 2

EncodeArrayMethod · 0.45
EncodeObjectMethod · 0.45

Calls 1

ObjectLockClass · 0.85

Tested by

no test coverage detected