1 19 20 25 26 27 28 29 30 31 package soot.jimple.internal; 32 33 import soot.*; 34 import soot.tagkit.*; 35 import soot.jimple.*; 36 import soot.util.*; 37 import soot.baf.*; 38 import soot.jimple.*; 39 import java.util.*; 40 41 public class JNewExpr extends AbstractNewExpr implements ConvertToBaf 42 { 43 public JNewExpr(RefType type) { this.type = type; } 44 45 public void convertToBaf(JimpleToBafContext context, List out) 46 { 47 Unit u; 48 out.add(u = Baf.v().newNewInst(getBaseType())); 49 50 Unit currentUnit = context.getCurrentUnit(); 51 52 Iterator it = currentUnit.getTags().iterator(); 53 while(it.hasNext()) { 54 u.addTag((Tag) it.next()); 55 } 56 } 57 58 59 public Object clone() 60 { 61 return new JNewExpr(type); 62 } 63 } 64 | Popular Tags |