1 30 31 package oracle.toplink.libraries.asm.util.attrs; 32 33 import java.util.Map ; 34 35 import oracle.toplink.libraries.asm.Attribute; 36 import oracle.toplink.libraries.asm.ClassReader; 37 import oracle.toplink.libraries.asm.Label; 38 import oracle.toplink.libraries.asm.attrs.SourceDebugExtensionAttribute; 39 40 45 46 public class ASMSourceDebugExtensionAttribute 47 extends SourceDebugExtensionAttribute 48 implements ASMifiable 49 { 50 51 protected Attribute read (ClassReader cr, int off, 52 int len, char[] buf, int codeOff, Label[] labels) 53 { 54 SourceDebugExtensionAttribute attr = 55 (SourceDebugExtensionAttribute)super.read(cr, off, len, buf, codeOff, labels); 56 57 ASMSourceDebugExtensionAttribute result = new ASMSourceDebugExtensionAttribute(); 58 result.debugExtension = attr.debugExtension; 59 return result; 60 } 61 62 public void asmify (StringBuffer buf, String varName, Map labelNames) { 63 buf.append("SourceDebugExtensionAttribute ").append(varName) 64 .append(" = new SourceDebugExtensionAttribute(\"") 65 .append(debugExtension).append("\");\n"); 66 } 67 } 68 | Popular Tags |