1 package alt.jiapi.instrumentor; 2 3 import alt.jiapi.reflect.Instruction; 4 import alt.jiapi.reflect.InstructionList; 5 6 15 public class HotSpot { 16 private int start; 17 private int end; 18 private Instruction startIns; 19 private Instruction endIns; 20 private InstructionList il; 21 22 public HotSpot(int start, int end) { 23 this.start = start; 24 this.end = end; 25 } 26 27 public HotSpot(InstructionList il, Instruction start, Instruction end) { 28 this.il = il; 29 this.startIns = start; 30 this.endIns = end; 31 } 32 33 37 public int getStart() { 38 return this.start; 39 } 40 41 42 46 public int getEnd() { 47 return this.end; 48 } 49 50 51 public Instruction getStartInstruction() { 52 return startIns; 53 } 54 55 public Instruction getEndInstruction() { 56 return endIns; 57 } 58 59 public InstructionList getView() { 60 return il.createView(il.indexOf(startIns), 61 il.indexOf(endIns) + 1); 62 } 63 } 64 | Popular Tags |