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

📄 dbcellrecord.java

📁 实现JAVA界面的代码GWT
💻 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:   DBCellRecord.java

package jxl.write.biff;

import java.util.ArrayList;
import java.util.Iterator;
import jxl.biff.*;

class DBCellRecord extends WritableRecordData
{

    private int rowPos;
    private int cellOffset;
    private ArrayList cellRowPositions;
    private int position;

    public DBCellRecord(int rp)
    {
        super(Type.DBCELL);
        rowPos = rp;
        cellRowPositions = new ArrayList(10);
    }

    void setCellOffset(int pos)
    {
        cellOffset = pos;
    }

    void addCellRowPosition(int pos)
    {
        cellRowPositions.add(new Integer(pos));
    }

    void setPosition(int pos)
    {
        position = pos;
    }

    protected byte[] getData()
    {
        byte data[] = new byte[4 + 2 * cellRowPositions.size()];
        IntegerHelper.getFourBytes(position - rowPos, data, 0);
        int pos = 4;
        int lastCellPos = cellOffset;
        for(Iterator i = cellRowPositions.iterator(); i.hasNext();)
        {
            int cellPos = ((Integer)i.next()).intValue();
            IntegerHelper.getTwoBytes(cellPos - lastCellPos, data, pos);
            lastCellPos = cellPos;
            pos += 2;
        }

        return data;
    }
}

⌨️ 快捷键说明

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