A few more private fields prefixed with __

parent 44c2607d
Pipeline #3525 passed with stages
in 3 minutes and 9 seconds
......@@ -22,9 +22,9 @@ abstract class AbstractParser {
//
protected LocalVars allLocalVars = new LocalVars();
LocalVars allLocalVars = new LocalVars();
public LocalVars getAllLocalVars() {
LocalVars getAllLocalVars() {
return allLocalVars;
}
......@@ -34,7 +34,7 @@ abstract class AbstractParser {
// ****************************************
// returns local vars defined in this class
protected void processLocalVars (
void processLocalVars (
final ClassNode dislClass
) throws ParserException {
// parse local variables
......
......@@ -19,10 +19,10 @@ class ArgProcessorParser extends AbstractParser {
//
private final Map <Type, ArgProcessor> __processors = new HashMap <> ();
private final ClassLoader classLoader;
private final ClassLoader __classLoader;
ArgProcessorParser(final ClassLoader classLoader){
this.classLoader = classLoader;
this.__classLoader = classLoader;
}
......@@ -128,7 +128,7 @@ class ArgProcessorParser extends AbstractParser {
// and create a code template for the argument processor method.
//
final UnprocessedCode codeTemplate = new UnprocessedCode (
className, method, classLoader
className, method, __classLoader
);
return new ArgProcessorMethod (
......@@ -225,7 +225,7 @@ class ArgProcessorParser extends AbstractParser {
private Class <?> __resolveClass (final Type type) {
try {
return ReflectionHelper.resolveClass (type, classLoader);
return ReflectionHelper.resolveClass (type, __classLoader);
} catch (final ReflectionException e) {
throw new ParserRuntimeException (e);
......
......@@ -24,12 +24,12 @@ class IsolatedSnippetParser extends SnippetParser {
* Map of all available classes in instrumentation.
* The key here is binary name of the class as defined by The Java(TM) Language Specification.
*/
private final Map<String, ClassNode> allClasses = new HashMap<> ();
private final Map<String, ClassNode> __allClasses = new HashMap<> ();
/**
* DiSL session {@link ClassLoader} instance.
*/
private final ClassLoader classLoader;
private final ClassLoader __classLoader;
/**
......@@ -41,9 +41,9 @@ class IsolatedSnippetParser extends SnippetParser {
final ClassLoader classLoader
){
for(ClassNode classNode : allClasses){
this.allClasses.put ( classNode.name.replace ('/', '.'), classNode );
this.__allClasses.put ( classNode.name.replace ('/', '.'), classNode );
}
this.classLoader = classLoader;
this.__classLoader = classLoader;
}
......@@ -103,7 +103,7 @@ class IsolatedSnippetParser extends SnippetParser {
final boolean dynamicBypass
) {
return new SnippetUnprocessedCode (
className, methodNode, dynamicBypass, classLoader
className, methodNode, dynamicBypass, __classLoader
);
}
......@@ -122,10 +122,10 @@ class IsolatedSnippetParser extends SnippetParser {
final String guardName = guardType.getClassName ();
if ( !allClasses.containsKey (guardName) )
if ( !__allClasses.containsKey (guardName) )
throw new Reflection.MissingClassException ("Requested class not found %", guardName);
return classLoader.getClass (allClasses.get(guardName));
return __classLoader.getClass (__allClasses.get(guardName));
}
......@@ -167,7 +167,7 @@ class IsolatedSnippetParser extends SnippetParser {
ContextKind contextType = ContextKind.forType (type);
String className = type.getClassName ();
ClassNode classNode = allClasses.getOrDefault ( className, null );
ClassNode classNode = __allClasses.getOrDefault ( className, null );
List<ClassNode> classNodes= new ArrayList<> (); // The class nodes to load when
// StaticContext found at the end of the chain
......@@ -190,12 +190,12 @@ class IsolatedSnippetParser extends SnippetParser {
t = Type.getObjectType (superclass);
contextType = ContextKind.forType (t);
className = t.getClassName ();
classNode = allClasses.getOrDefault (className, null);
classNode = __allClasses.getOrDefault (className, null);
}
}
for( ClassNode cn : classNodes){
classLoader.getClass (cn);
__classLoader.getClass (cn);
}
......
......@@ -26,7 +26,7 @@ public class UnprocessedCode {
/** Method node containing the snippet code. */
private final MethodNode __method;
private final ClassLoader classLoader;
private final ClassLoader __classLoader;
//
UnprocessedCode (
......@@ -36,7 +36,7 @@ public class UnprocessedCode {
) {
__className = className;
__method = method;
this.classLoader = classLoader;
this.__classLoader = classLoader;
}
//
......@@ -75,7 +75,7 @@ public class UnprocessedCode {
// variables, and finally determine if there is any exception handler in
// the code that handles the exception and does not propagate it.
//
final ContextUsage ctxs = ContextUsage.forMethod (__method, classLoader);
final ContextUsage ctxs = ContextUsage.forMethod (__method, __classLoader);
final Set <StaticContextMethod> scms = __collectStaticContextMethods (
__method.instructions, ctxs.staticContextTypes ()
);
......@@ -222,7 +222,7 @@ public class UnprocessedCode {
private Class <?> __resolveClass (final MethodInsnNode insn) {
try {
return ReflectionHelper.resolveClass (Type.getObjectType (insn.owner), classLoader);
return ReflectionHelper.resolveClass (Type.getObjectType (insn.owner), __classLoader);
} catch (final ReflectionException e) {
throw new InvalidStaticContextInvocationException (e.getMessage (), insn);
......
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