📄 integer4.java
字号:
package com.tssx.ebiz.sgip;
import java.io.*;
public class Integer4 {
int m_i;
public Integer4() {
super();
m_i = 0;
}
public Integer4(int i) {
super();
m_i = i;
}
public int length() {
return 4;
}
public int maxLength() {
return 4;
}
public void setMaxLength(int len) throws SgipException{
if (len != 4) {
throw new SgipException("Invalid max length specified for Integer4.");
}
}
public int read(DataInputStream is) throws IOException, SgipException {
return read(is, 0x7FFFFFFF);
}
public int read(DataInputStream is, int iLeft) throws IOException, SgipException {
if (iLeft < 4) {
throw new SgipException("Not enought bytes in stream to read.");
}
m_i = is.readInt();
return 4;
}
public int write(DataOutputStream os) throws IOException {
os.writeInt(m_i);
return 4;
}
public int intValue() {
return m_i;
}
public void setValue(int i) {
m_i = i;
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -