📄 zcol.java
字号:
/*
* put your module comment here
* formatted with JxBeauty (c) johann.langhofer@nextra.at
*/
package ezcell;
import java.io.*;
/**
* <p>Title: </p>
* <p>Description: </p>
* <p>Copyright: Copyright (c) 2001</p>
* <p>Company: </p>
* @author unascribed
* @version 1.0
*/
public
class ZCol extends ZBase
implements Serializable, Comparable, Cloneable {
/**
* put your documentation comment here
*/
private int width = 60;
/**
* put your documentation comment here
*/
public ZCol () {
}
/**
* put your documentation comment here
* @param ZDefaultSheet sheet
*/
public ZCol (ZDefaultSheet sheet) {
super(sheet);
}
/**
* put your documentation comment here
* @param ZDefaultSheet sheet
* @param int col
*/
public ZCol (ZDefaultSheet sheet, int col) {
this(sheet);
this.col = col;
}
/**
* put your documentation comment here
* @return
*/
public int getWidth () {
return width;
}
/**
* put your documentation comment here
* @param width
*/
public void setWidth (int width) {
this.width = width;
setProperty(PTY_Width);
}
/**
* put your documentation comment here
* @param row
* @param col
* @return
*/
public ZBase underLayer (int row, int col) {
return sheet.defaultBase;
}
/**
* put your documentation comment here
* @return
*/
public int type () {
return ZBase.COLUMN;
}
/**
* put your documentation comment here
* @param ois
* @exception ClassNotFoundException, IOException
*/
private void readObject (ObjectInputStream ois) throws ClassNotFoundException,
IOException {
width = 60;
_readObject(ois);
if (hasProperty(PTY_Width))
width = ois.readInt();
}
/**
* put your documentation comment here
* @param oos
* @exception ClassNotFoundException, IOException
*/
private void writeObject (ObjectOutputStream oos) throws ClassNotFoundException,
IOException {
_writeObject(oos);
if (hasProperty(PTY_Width))
oos.writeInt(width);
}
/**
* put your documentation comment here
* @param o
* @return
*/
public int compareTo (Object o) {
int result = 0;
ZCol oc = (ZCol)o;
if (col > oc.col)
result = 1;
else if (col < oc.col)
result = -1;
if (ZBase.compareReverse)
result *= -1;
return result;
}
/**
* put your documentation comment here
* @return
*/
public Object clone () {
Object obj = null;
try {
obj = super.clone();
} catch (Exception e) {}
return obj;
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -