/** * Return the parameter that this instruction operates on, or -1 if none. */ public int getParam() { return getCode().getParamsIndex(getLocal()); }
/** * Return the parameter that this instruction operates on, or -1 if none. */ public int getParam() { return getCode().getParamsIndex(getLocal()); }
/** * Set the method parameter that this instruction operates on. This * will set both the local index and the type of the instruction based * on the current method parameters. */ public LocalVariableInstruction setParam(int param) { int local = getCode().getLocalsIndex(param); if (local != -1) { BCMethod method = getCode().getMethod(); setType(method.getParamNames()[param]); } return setLocal(local); }
/** * Set the method parameter that this instruction operates on. This * will set both the local index and the type of the instruction based * on the current method parameters. */ public LocalVariableInstruction setParam(int param) { int local = getCode().getLocalsIndex(param); if (local != -1) { BCMethod method = getCode().getMethod(); setType(method.getParamNames()[param]); } return setLocal(local); }
/** * Return the local variable object this instruction * operates on, or null if none. * * @see LocalVariableTable#getLocalVariable(int) */ public LocalVariable getLocalVariable() { LocalVariableTable table = getCode().getLocalVariableTable(false); if (table == null) return null; return table.getLocalVariable(getLocal()); }
/** * Return the local variable object this instruction * operates on, or null if none. * * @see LocalVariableTable#getLocalVariable(int) */ public LocalVariable getLocalVariable() { LocalVariableTable table = getCode().getLocalVariableTable(false); if (table == null) return null; return table.getLocalVariable(getLocal()); }