mirror of
https://github.com/PolyhedralDev/Terra.git
synced 2025-07-02 16:05:29 +00:00
add autocloseable option
This commit is contained in:
parent
eb4bf74cc6
commit
da366a75e8
@ -12,4 +12,9 @@ public interface Profiler {
|
||||
void stop();
|
||||
|
||||
Map<String, Timings> getTimings();
|
||||
|
||||
default AutoCloseable profile(String frame) {
|
||||
push(frame);
|
||||
return () -> pop(frame);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user