41 const std::shared_ptr<fcl::CollisionGeometryd>& value)
43 assert(!key->getUUID().is_nil());
44 std::scoped_lock lock(
mutex_);
45 cache_[key->getUUID()] = value;
48 std::shared_ptr<fcl::CollisionGeometryd>
51 assert(!key->getUUID().is_nil());
52 std::scoped_lock lock(
mutex_);
53 auto it =
cache_.find(key->getUUID());
56 std::shared_ptr<fcl::CollisionGeometryd> collision_shape = it->second.lock();
57 if (collision_shape !=
nullptr)
58 return collision_shape;
60 cache_.erase(key->getUUID());
67 std::scoped_lock lock(
mutex_);
70 if (it->second.expired())