Commit 039f6eeb authored by Skylot's avatar Skylot

core: rename depth traversal class

parent 8a464e82
package jadx.core;
import jadx.core.dex.nodes.ClassNode;
import jadx.core.dex.visitors.DepthTraverser;
import jadx.core.dex.visitors.DepthTraversal;
import jadx.core.dex.visitors.IDexTreeVisitor;
import jadx.core.utils.exceptions.DecodeException;
......@@ -20,7 +20,7 @@ public final class ProcessClass {
try {
cls.load();
for (IDexTreeVisitor visitor : passes) {
DepthTraverser.visit(visitor, cls);
DepthTraversal.visit(visitor, cls);
}
} catch (DecodeException e) {
LOG.error("Decode exception: " + cls, e);
......
......@@ -14,7 +14,7 @@ import jadx.core.dex.nodes.InsnNode;
import jadx.core.dex.nodes.MethodNode;
import jadx.core.dex.regions.Region;
import jadx.core.dex.trycatch.CatchAttr;
import jadx.core.dex.visitors.DepthTraverser;
import jadx.core.dex.visitors.DepthTraversal;
import jadx.core.dex.visitors.FallbackModeVisitor;
import jadx.core.utils.ErrorsCounter;
import jadx.core.utils.InsnUtils;
......@@ -274,7 +274,7 @@ public class MethodGen {
// load original instructions
try {
mth.load();
DepthTraverser.visit(new FallbackModeVisitor(), mth);
DepthTraversal.visit(new FallbackModeVisitor(), mth);
} catch (DecodeException e) {
LOG.error("Error reload instructions in fallback mode:", e);
code.startLine("// Can't loadFile method instructions: " + e.getMessage());
......
......@@ -4,7 +4,7 @@ import jadx.core.dex.nodes.ClassNode;
import jadx.core.dex.nodes.MethodNode;
import jadx.core.utils.ErrorsCounter;
public class DepthTraverser {
public class DepthTraversal {
public static void visit(IDexTreeVisitor visitor, ClassNode cls) {
try {
......
......@@ -3,7 +3,7 @@ package jadx.api;
import jadx.core.Jadx;
import jadx.core.dex.nodes.ClassNode;
import jadx.core.dex.nodes.MethodNode;
import jadx.core.dex.visitors.DepthTraverser;
import jadx.core.dex.visitors.DepthTraversal;
import jadx.core.dex.visitors.IDexTreeVisitor;
import java.io.BufferedInputStream;
......@@ -66,7 +66,7 @@ public abstract class InternalJadxTest extends TestUtils {
}
}, new File(outDir));
for (IDexTreeVisitor visitor : passes) {
DepthTraverser.visit(visitor, cls);
DepthTraversal.visit(visitor, cls);
}
assertThat(cls.getCode().toString(), not(containsString("inconsistent")));
return cls;
......
......@@ -2,7 +2,7 @@ package jadx.tests.internal;
import jadx.api.InternalJadxTest;
import jadx.core.dex.nodes.ClassNode;
import jadx.core.dex.visitors.DepthTraverser;
import jadx.core.dex.visitors.DepthTraversal;
import jadx.core.dex.visitors.IDexTreeVisitor;
import jadx.core.utils.exceptions.DecodeException;
......@@ -28,7 +28,7 @@ public class TestVariablesDefinitions extends InternalJadxTest {
cls.load();
Iterator<IDexTreeVisitor> iterator = passes.iterator();
while (iterator.hasNext()) {
DepthTraverser.visit(iterator.next(), cls);
DepthTraversal.visit(iterator.next(), cls);
}
} catch (DecodeException e) {
LOG.error("Decode exception: " + cls, e);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment