remove getAllPerformanceCounters() function
Reviewed By: fkgozali Differential Revision: D4626085 fbshipit-source-id: f07f5a72791176f075d3ce450af4c7ae4cd6fa5c
This commit is contained in:
parent
bd4b5dedc2
commit
6b738d1b2e
|
@ -12,8 +12,6 @@ package com.facebook.react.bridge;
|
|||
import javax.annotation.Nullable;
|
||||
|
||||
import java.lang.ref.WeakReference;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.concurrent.CopyOnWriteArraySet;
|
||||
|
||||
import android.app.Activity;
|
||||
|
@ -28,10 +26,6 @@ import com.facebook.react.bridge.queue.MessageQueueThread;
|
|||
import com.facebook.react.bridge.queue.ReactQueueConfiguration;
|
||||
import com.facebook.react.common.LifecycleState;
|
||||
|
||||
import static com.facebook.react.common.LifecycleState.BEFORE_CREATE;
|
||||
import static com.facebook.react.common.LifecycleState.BEFORE_RESUME;
|
||||
import static com.facebook.react.common.LifecycleState.RESUMED;
|
||||
|
||||
/**
|
||||
* Abstract ContextWrapper for Android application or activity {@link Context} and
|
||||
* {@link CatalystInstance}
|
||||
|
@ -180,20 +174,6 @@ public class ReactContext extends ContextWrapper {
|
|||
mLifecycleEventListeners.remove(listener);
|
||||
}
|
||||
|
||||
public Map<String, Map<String,Double>> getAllPerformanceCounters() {
|
||||
Map<String, Map<String,Double>> totalPerfMap =
|
||||
new HashMap<>();
|
||||
if (mCatalystInstance != null) {
|
||||
for (NativeModule nativeModule : mCatalystInstance.getNativeModules()) {
|
||||
if (nativeModule instanceof PerformanceCounter) {
|
||||
PerformanceCounter perfCounterModule = (PerformanceCounter) nativeModule;
|
||||
totalPerfMap.put(nativeModule.getName(), perfCounterModule.getPerformanceCounters());
|
||||
}
|
||||
}
|
||||
}
|
||||
return totalPerfMap;
|
||||
}
|
||||
|
||||
public void addActivityEventListener(ActivityEventListener listener) {
|
||||
mActivityEventListeners.add(listener);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue