⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 linenumbertable.java

📁 无线通信的主要编程软件,是无线通信工作人员的必备工具,关天相关教程我会在后续传上.
💻 JAVA
字号:
// Copyright 2001 Finn Bockpackage org.python.compiler;import java.io.*;import java.util.*;public class LineNumberTable extends Attribute {    int attName;    ConstantPool pool;    Vector lines;    public LineNumberTable(ConstantPool pool) throws IOException {        this.pool = pool;        attName = pool.UTF8("LineNumberTable");        lines = new Vector();    }    public void write(DataOutputStream stream) throws IOException {        stream.writeShort(attName);        int n = lines.size();        stream.writeInt(n * 2 + 2);        stream.writeShort(n / 2);        for (int i = 0; i < n; i += 2) {            Short startpc = (Short) lines.elementAt(i);            Short lineno =  (Short) lines.elementAt(i+1);            stream.writeShort(startpc.shortValue());            stream.writeShort(lineno.shortValue());        }    }    public void addLine(int startpc, int lineno) {        lines.addElement(new Short((short) startpc));        lines.addElement(new Short((short) lineno));    }    public int length() {        return lines.size() * 2 + 8;    }}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -