/
githubmr
/
facebook-react-native
Обзор
Документация
Войти
/
githubmr
/
facebook-react-native
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
main
packages/react-native/ReactCommon/react/performance/timeline/PerformanceEntryKeyedBuffer.h
38 строк
963 B
Alex Hunt
Refactor PerformanceEntry as std::variant (#50995)
02 май 2025, 08:40
02 май 2025, 08:40
1135f10
Код
Авторство
О чём код?
/* * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ #pragma once #include <optional> #include <unordered_map> #include <vector> #include "PerformanceEntryBuffer.h" namespace facebook::react { class PerformanceEntryKeyedBuffer : public PerformanceEntryBuffer { public: PerformanceEntryKeyedBuffer() = default; void add(const PerformanceEntry& entry) override; void getEntries(std::vector<PerformanceEntry>& target) const override; void getEntries( std::vector<PerformanceEntry>& target, const std::string& name) const override; void clear() override; void clear(const std::string& name) override; std::optional<PerformanceEntry> find(const std::string& name) const; private: std::unordered_map<std::string, std::vector<PerformanceEntry>> entryMap_{}; }; } // namespace facebook::react