private void initFrames(CtClass clazz, MethodInfo minfo) throws BadBytecode { if (frames == null) { frames = ((new Analyzer())).analyze(clazz, minfo); offset = 0; // start tracking changes } }
/** * Returns the types of the local variables and stack frame entries * available at the given position. If the byte at the position is * not the first byte of an instruction, then this method returns * null. * * @param pos the position. */ public Frame frameAt(int pos) throws BadBytecode { if (frames == null) frames = new Analyzer().analyze(clazz, methodInfo); return frames[pos]; }
private void initFrames(CtClass clazz, MethodInfo minfo) throws BadBytecode { if (frames == null) { frames = ((new Analyzer())).analyze(clazz, minfo); offset = 0; // start tracking changes } }
/** * Returns the types of the local variables and stack frame entries * available at the given position. If the byte at the position is * not the first byte of an instruction, then this method returns * null. * * @param pos the position. */ public Frame frameAt(int pos) throws BadBytecode { if (frames == null) frames = new Analyzer().analyze(clazz, methodInfo); return frames[pos]; }
/** * Performs data-flow analysis on a method and returns an array, indexed by * instruction position, containing the starting frame state of all reachable * instructions. Non-reachable code, and illegal code offsets are represented * as a null in the frame state array. This can be used to detect dead code. * * If the method does not contain code (it is either native or abstract), null * is returned. * * @param method the method to analyze * @return an array, indexed by instruction position, of the starting frame state, * or null if this method doesn't have code * @throws BadBytecode if the bytecode does not comply with the JVM specification */ public Frame[] analyze(CtMethod method) throws BadBytecode { return analyze(method.getDeclaringClass(), method.getMethodInfo2()); }
/** * Performs data-flow analysis on a method and returns an array, indexed by * instruction position, containing the starting frame state of all reachable * instructions. Non-reachable code, and illegal code offsets are represented * as a null in the frame state array. This can be used to detect dead code. * * If the method does not contain code (it is either native or abstract), null * is returned. * * @param method the method to analyze * @return an array, indexed by instruction position, of the starting frame state, * or null if this method doesn't have code * @throws BadBytecode if the bytecode does not comply with the JVM specification */ public Frame[] analyze(CtMethod method) throws BadBytecode { return analyze(method.getDeclaringClass(), method.getMethodInfo2()); }
frames = (new Analyzer()).analyze(method.getDeclaringClass(), info); } catch (BadBytecode e) { throw new RuntimeException(e);
frames = (new Analyzer()).analyze(method.getDeclaringClass(), info); } catch (BadBytecode e) { throw new RuntimeException(e);
private void initFrames(CtClass clazz, MethodInfo minfo) throws BadBytecode { if (frames == null) { frames = ((new Analyzer())).analyze(clazz, minfo); offset = 0; // start tracking changes } }
private void initFrames(CtClass clazz, MethodInfo minfo) throws BadBytecode { if (frames == null) { frames = ((new Analyzer())).analyze(clazz, minfo); offset = 0; // start tracking changes } }
private void initFrames(CtClass clazz, MethodInfo minfo) throws BadBytecode { if (frames == null) { frames = ((new Analyzer())).analyze(clazz, minfo); offset = 0; // start tracking changes } }
private void initFrames(CtClass clazz, MethodInfo minfo) throws BadBytecode { if (frames == null) { frames = ((new Analyzer())).analyze(clazz, minfo); offset = 0; // start tracking changes } }
/** * Returns the types of the local variables and stack frame entries * available at the given position. If the byte at the position is * not the first byte of an instruction, then this method returns * null. * * @param pos the position. */ public Frame frameAt(int pos) throws BadBytecode { if (frames == null) frames = new Analyzer().analyze(clazz, methodInfo); return frames[pos]; }
/** * Returns the types of the local variables and stack frame entries * available at the given position. If the byte at the position is * not the first byte of an instruction, then this method returns * null. * * @param pos the position. */ public Frame frameAt(int pos) throws BadBytecode { if (frames == null) frames = new Analyzer().analyze(clazz, methodInfo); return frames[pos]; }
/** * Returns the types of the local variables and stack frame entries * available at the given position. If the byte at the position is * not the first byte of an instruction, then this method returns * null. * * @param pos the position. */ public Frame frameAt(int pos) throws BadBytecode { if (frames == null) frames = new Analyzer().analyze(clazz, methodInfo); return frames[pos]; }
/** * Performs data-flow analysis on a method and returns an array, indexed by * instruction position, containing the starting frame state of all reachable * instructions. Non-reachable code, and illegal code offsets are represented * as a null in the frame state array. This can be used to detect dead code. * * If the method does not contain code (it is either native or abstract), null * is returned. * * @param method the method to analyze * @return an array, indexed by instruction position, of the starting frame state, * or null if this method doesn't have code * @throws BadBytecode if the bytecode does not comply with the JVM specification */ public Frame[] analyze(CtMethod method) throws BadBytecode { return analyze(method.getDeclaringClass(), method.getMethodInfo2()); }
/** * Performs data-flow analysis on a method and returns an array, indexed by * instruction position, containing the starting frame state of all reachable * instructions. Non-reachable code, and illegal code offsets are represented * as a null in the frame state array. This can be used to detect dead code. * * If the method does not contain code (it is either native or abstract), null * is returned. * * @param method the method to analyze * @return an array, indexed by instruction position, of the starting frame state, * or null if this method doesn't have code * @throws BadBytecode if the bytecode does not comply with the JVM specification */ public Frame[] analyze(CtMethod method) throws BadBytecode { return analyze(method.getDeclaringClass(), method.getMethodInfo2()); }
/** * Performs data-flow analysis on a method and returns an array, indexed by * instruction position, containing the starting frame state of all reachable * instructions. Non-reachable code, and illegal code offsets are represented * as a null in the frame state array. This can be used to detect dead code. * * If the method does not contain code (it is either native or abstract), null * is returned. * * @param method the method to analyze * @return an array, indexed by instruction position, of the starting frame state, * or null if this method doesn't have code * @throws BadBytecode if the bytecode does not comply with the JVM specification */ public Frame[] analyze(CtMethod method) throws BadBytecode { return analyze(method.getDeclaringClass(), method.getMethodInfo2()); }
/** * Performs data-flow analysis on a method and returns an array, indexed by * instruction position, containing the starting frame state of all reachable * instructions. Non-reachable code, and illegal code offsets are represented * as a null in the frame state array. This can be used to detect dead code. * * If the method does not contain code (it is either native or abstract), null * is returned. * * @param method the method to analyze * @return an array, indexed by instruction position, of the starting frame state, * or null if this method doesn't have code * @throws BadBytecode if the bytecode does not comply with the JVM specification */ public Frame[] analyze(CtMethod method) throws BadBytecode { return analyze(method.getDeclaringClass(), method.getMethodInfo2()); }
frames = (new Analyzer()).analyze(method.getDeclaringClass(), info); } catch (BadBytecode e) { throw new RuntimeException(e);