MCPcopy Create free account
hub / github.com/OpenEndedGroup/Field2 / _getCallerClass

Method _getCallerClass

src/main/java/field/utility/Dict.java:293–303  ·  view source on GitHub ↗
(int i)

Source from the content-addressed store, hash-verified

291 }
292
293 private Class _getCallerClass(int i) {
294 return StackWalker.getInstance(StackWalker.Option.RETAIN_CLASS_REFERENCE).walk(x -> {
295
296 for (Iterator<StackWalker.StackFrame> it = x.iterator(); it.hasNext(); ) {
297 StackWalker.StackFrame f = it.next();
298 if (!f.getClassName().equals(this.getClass().getName()))
299 return f.getDeclaringClass();
300 }
301 return null;
302 });
303 }
304
305 public <T> Prop<T> autoConstructs(Supplier<T> t) {
306 Prop on = this;

Callers 1

typeMethod · 0.95

Calls 6

getInstanceMethod · 0.80
hasNextMethod · 0.65
nextMethod · 0.65
iteratorMethod · 0.45
equalsMethod · 0.45
getNameMethod · 0.45

Tested by

no test coverage detected