📄 clobimpl.java
字号:
package com.easyjf.dbo;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.Reader;
import java.io.Writer;
import java.io.StringReader;
import java.sql.Clob;
import java.sql.SQLException;
/**
* @author wangliang138840
*
*/
public class ClobImpl implements Clob{
private Reader reader = null;
private int length;
public ClobImpl(String str){
reader = new StringReader(str);
length = str.length();
}
public ClobImpl(Reader reader, int length){
this.reader = reader;
this.length = length;
}
public long length()
throws SQLException{
return length;
}
public void truncate(long l)
throws SQLException{
}
public InputStream getAsciiStream()
throws SQLException{
return null;
}
public OutputStream setAsciiStream(long l)
throws SQLException{
return null;
}
public Reader getCharacterStream()
throws SQLException{
return reader;
}
public Writer setCharacterStream(long l)
throws SQLException{
return null;
}
public String getSubString(long l, int i)
throws SQLException{
return null;
}
public int setString(long l, String s)
throws SQLException{
return -1;
}
public int setString(long l, String s, int i, int j)
throws SQLException{
return -1;
}
public long position(String s, long l)
throws SQLException{
return -1;
}
public long position(Clob clob, long l)
throws SQLException{
return -1;
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -