43 public final class FunctionInitializer implements Serializable { 44 45 private final String className; 46 private final MethodType methodType; 47 private final int flags; 48 private transient Map<Integer, Type> invalidatedProgramPoints; 49 private transient Class<?> code; 50 51 private static final long serialVersionUID = -5420835725902966692L; 52 53 /** 54 * Constructor. 55 * 56 * @param functionNode the function node 57 */ 58 public FunctionInitializer(final FunctionNode functionNode) { 59 this(functionNode, null); 60 } 61 62 /** 63 * Constructor. 64 * 65 * @param functionNode the function node 66 * @param invalidatedProgramPoints invalidated program points 67 */ 68 public FunctionInitializer(final FunctionNode functionNode, final Map<Integer, Type> invalidatedProgramPoints) { 69 this.className = functionNode.getCompileUnit().getUnitClassName(); 70 this.methodType = new FunctionSignature(functionNode).getMethodType(); 71 this.flags = functionNode.getFlags(); 72 this.invalidatedProgramPoints = invalidatedProgramPoints; 73 74 final CompileUnit cu = functionNode.getCompileUnit(); 75 if (cu != null) { 76 this.code = cu.getCode(); 77 } 78 79 assert className != null; 80 } 81 82 /** | 43 public final class FunctionInitializer implements Serializable { 44 45 private final String className; 46 private final MethodType methodType; 47 private final int flags; 48 private transient Map<Integer, Type> invalidatedProgramPoints; 49 private transient Class<?> code; 50 51 private static final long serialVersionUID = -5420835725902966692L; 52 53 /** 54 * Constructor. 55 * 56 * @param functionNode the function node 57 */ 58 public FunctionInitializer(final FunctionNode functionNode) { 59 this(functionNode, null); 60 } 61 62 /** 63 * Copy constructor. 64 * 65 * @param init original initializer 66 */ 67 FunctionInitializer(final FunctionInitializer init) { 68 this.className = init.getClassName(); 69 this.methodType = init.getMethodType(); 70 this.flags = init.getFlags(); 71 } 72 73 /** 74 * Constructor. 75 * 76 * @param functionNode the function node 77 * @param invalidatedProgramPoints invalidated program points 78 */ 79 public FunctionInitializer(final FunctionNode functionNode, final Map<Integer, Type> invalidatedProgramPoints) { 80 this.className = functionNode.getCompileUnit().getUnitClassName(); 81 this.methodType = new FunctionSignature(functionNode).getMethodType(); 82 this.flags = functionNode.getFlags(); 83 this.invalidatedProgramPoints = invalidatedProgramPoints; 84 85 final CompileUnit cu = functionNode.getCompileUnit(); 86 if (cu != null) { 87 this.code = cu.getCode(); 88 } 89 90 assert className != null; 91 } 92 93 /** |