📄 record.java
字号:
// Decompiled by Jad v1.5.7g. Copyright 2000 Pavel Kouznetsov.
// Jad home page: http://www.geocities.com/SiliconValley/Bridge/8617/jad.html
// Decompiler options: packimports(3) fieldsfirst ansi
// Source File Name: Record.java
package jxl.read.biff;
import common.Logger;
import java.util.ArrayList;
import jxl.biff.IntegerHelper;
import jxl.biff.Type;
// Referenced classes of package jxl.read.biff:
// File
public final class Record
{
private static final Logger logger;
private int code;
private Type type;
private int length;
private int dataPos;
private File file;
private byte data[];
private ArrayList continueRecords;
static Class class$jxl$read$biff$Record; /* synthetic field */
Record(byte d[], int offset, File f)
{
code = IntegerHelper.getInt(d[offset], d[offset + 1]);
length = IntegerHelper.getInt(d[offset + 2], d[offset + 3]);
file = f;
file.skip(4);
dataPos = f.getPos();
file.skip(length);
type = Type.getType(code);
}
public Type getType()
{
return type;
}
public int getLength()
{
return length;
}
public byte[] getData()
{
if(data == null)
data = file.read(dataPos, length);
if(continueRecords != null)
{
int size = 0;
byte contData[][] = new byte[continueRecords.size()][];
for(int i = 0; i < continueRecords.size(); i++)
{
Record r = (Record)continueRecords.get(i);
contData[i] = r.getData();
byte d2[] = contData[i];
size += d2.length;
}
byte d3[] = new byte[data.length + size];
System.arraycopy(data, 0, d3, 0, data.length);
int pos = data.length;
for(int i = 0; i < contData.length; i++)
{
byte d2[] = contData[i];
System.arraycopy(d2, 0, d3, pos, d2.length);
pos += d2.length;
}
data = d3;
}
return data;
}
public int getCode()
{
return code;
}
void setType(Type t)
{
type = t;
}
public void addContinueRecord(Record d)
{
if(continueRecords == null)
continueRecords = new ArrayList();
continueRecords.add(d);
}
static Class class$(String x0)
{
return Class.forName(x0);
ClassNotFoundException x1;
x1;
throw new NoClassDefFoundError(x1.getMessage());
}
static
{
logger = Logger.getLogger(class$jxl$read$biff$Record != null ? class$jxl$read$biff$Record : (class$jxl$read$biff$Record = class$("jxl.read.biff.Record")));
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -