token.java~11~
来自「java写的词法分析器」· JAVA~11~ 代码 · 共 25 行
JAVA~11~
25 行
//package lexicalanalyzer2;/** * Title: Token * Description: Create the token,include token,type,line and position * Copyright: Copyright (c) 2004 15th,Oct * Company: B02251132 * @author: ZengBo Huang * @version 1.0 */public class token {//The class that create four attributes private String token; private Object type; private int line,position; public token(String tk,Object tp,int ln,int pos) {//Four attributes name,type,line and position token=tk; type=tp; line=ln; position=pos; } public String toString(){//Output the four attribute String out=token+"\t"+type+"\t"+line+"\t"+position; return out; }}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?