2018-05-31 22:31:03 +00:00
|
|
|
// Copyright (c) 2004-present, Facebook, Inc.
|
|
|
|
|
|
|
|
// This source code is licensed under the MIT license found in the
|
|
|
|
// LICENSE file in the root directory of this source tree.
|
2018-05-10 05:01:53 +00:00
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#ifdef __APPLE__
|
|
|
|
#include <functional>
|
|
|
|
#endif
|
|
|
|
|
|
|
|
namespace facebook {
|
|
|
|
namespace react {
|
|
|
|
namespace ReactMarker {
|
|
|
|
|
|
|
|
enum ReactMarkerId {
|
|
|
|
NATIVE_REQUIRE_START,
|
|
|
|
NATIVE_REQUIRE_STOP,
|
|
|
|
RUN_JS_BUNDLE_START,
|
|
|
|
RUN_JS_BUNDLE_STOP,
|
|
|
|
CREATE_REACT_CONTEXT_STOP,
|
|
|
|
JS_BUNDLE_STRING_CONVERT_START,
|
|
|
|
JS_BUNDLE_STRING_CONVERT_STOP,
|
|
|
|
NATIVE_MODULE_SETUP_START,
|
|
|
|
NATIVE_MODULE_SETUP_STOP,
|
2018-08-10 16:26:18 +00:00
|
|
|
REGISTER_JS_SEGMENT_START,
|
|
|
|
REGISTER_JS_SEGMENT_STOP
|
2018-05-10 05:01:53 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#ifdef __APPLE__
|
|
|
|
using LogTaggedMarker = std::function<void(const ReactMarkerId, const char* tag)>;
|
|
|
|
#else
|
|
|
|
typedef void(*LogTaggedMarker)(const ReactMarkerId, const char* tag);
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef RN_EXPORT
|
|
|
|
#define RN_EXPORT __attribute__((visibility("default")))
|
|
|
|
#endif
|
|
|
|
|
|
|
|
extern RN_EXPORT LogTaggedMarker logTaggedMarker;
|
|
|
|
|
2018-06-01 21:55:56 +00:00
|
|
|
extern RN_EXPORT void logMarker(const ReactMarkerId markerId);
|
2018-05-10 05:01:53 +00:00
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|