@Override public MethodData getMethodData() { if (methodData == null){ methodData = new MethodData(name, "dummyfile", Arrays.asList(variableName)); } return methodData; }
public Set<String> discoverInstanceVariables() { HashSet<String> set = new HashSet(); RubyModule cls = this; while (cls != null) { for (DynamicMethod method : cls.getNonIncludedClass().getMethods().values()) { MethodData methodData = method.getMethodData(); set.addAll(methodData.getIvarNames()); } if (cls instanceof RubyClass) { cls = ((RubyClass)cls).getSuperClass(); } else { break; } } return set; }
public Set<String> discoverInstanceVariables() { HashSet<String> set = new HashSet(); RubyModule cls = this; while (cls != null) { for (DynamicMethod method : cls.getNonIncludedClass().getMethods().values()) { MethodData methodData = method.getMethodData(); set.addAll(methodData.getIvarNames()); } if (cls instanceof RubyClass) { cls = ((RubyClass)cls).getSuperClass(); } else { break; } } return set; }
@Override public MethodData getMethodData() { if (methodData == null){ methodData = new MethodData(name, "dummyfile", Arrays.asList(name)); } return methodData; }
public Set<String> discoverInstanceVariables() { HashSet<String> set = new HashSet(); RubyModule cls = this; while (cls != null) { for (DynamicMethod method : cls.getNonIncludedClass().getMethodLocation().getMethods().values()) { MethodData methodData = method.getMethodData(); set.addAll(methodData.getIvarNames()); } if (cls instanceof RubyClass) { cls = ((RubyClass)cls).getSuperClass(); } else { break; } } return set; }
@Override public MethodData getMethodData() { if (methodData == null){ methodData = new MethodData(name, "dummyfile", Arrays.asList(variableName)); } return methodData; } }
public Set<String> discoverInstanceVariables() { HashSet<String> set = new HashSet(); RubyModule cls = this; while (cls != null) { for (DynamicMethod method : cls.getNonIncludedClass().getMethodLocation().getMethods().values()) { MethodData methodData = method.getMethodData(); set.addAll(methodData.getIvarNames()); } if (cls instanceof RubyClass) { cls = ((RubyClass)cls).getSuperClass(); } else { break; } } return set; }
@Override public MethodData getMethodData() { if (methodData == null){ methodData = new MethodData(name, "dummyfile", Arrays.asList(name)); } return methodData; } }
@Override public MethodData getMethodData() { if (methodData == null){ methodData = new MethodData(name, "dummyfile", Arrays.asList(name)); } return methodData; } }
@Override public MethodData getMethodData() { if (methodData == null){ methodData = new MethodData(name, "dummyfile", Arrays.asList(variableName)); } return methodData; } }
@Override public MethodData getMethodData() { if (methodData == null){ methodData = new MethodData(name, "dummyfile", Arrays.asList(variableName)); } return methodData; }
@Override public MethodData getMethodData() { if (methodData == null){ methodData = new MethodData(name, "dummyfile", Arrays.asList(name)); } return methodData; }
@Override public MethodData getMethodData() { if (methodData == null){ methodData = new MethodData(name, getFile(), InstanceVariableFinder.findVariables(body)); } return methodData; }
@Override public MethodData getMethodData() { if (methodData == null){ methodData = new MethodData(name, getFile(), InstanceVariableFinder.findVariables(body)); } return methodData; }
/** * Additional metadata about this method. */ public MethodData getMethodData() { if (methodData == null) { List<String> ivarNames = new ArrayList<>(); InterpreterContext context = ensureInstrsReady(); for (Instr i : context.getInstructions()) { switch (i.getOperation()) { case GET_FIELD: ivarNames.add(((GetFieldInstr) i).getId()); break; case PUT_FIELD: ivarNames.add(((PutFieldInstr) i).getId()); break; } } methodData = new MethodData(method.getId(), method.getFile(), ivarNames); } return methodData; } }
/** * Additional metadata about this method. */ public MethodData getMethodData() { if (methodData == null) { List<String> ivarNames = new ArrayList<>(); InterpreterContext context = ensureInstrsReady(); for (Instr i : context.getInstructions()) { switch (i.getOperation()) { case GET_FIELD: ivarNames.add(((GetFieldInstr) i).getId()); break; case PUT_FIELD: ivarNames.add(((PutFieldInstr) i).getId()); break; } } methodData = new MethodData(method.getId(), method.getFile(), ivarNames); } return methodData; } }