1 16 17 package org.springframework.jdbc.support.lob; 18 19 import java.io.InputStream ; 20 import java.io.Reader ; 21 import java.sql.ResultSet ; 22 import java.sql.SQLException ; 23 24 34 public abstract class AbstractLobHandler implements LobHandler { 35 36 public byte[] getBlobAsBytes(ResultSet rs, String columnName) throws SQLException { 37 return getBlobAsBytes(rs, rs.findColumn(columnName)); 38 } 39 40 public InputStream getBlobAsBinaryStream(ResultSet rs, String columnName) throws SQLException { 41 return getBlobAsBinaryStream(rs, rs.findColumn(columnName)); 42 } 43 44 public String getClobAsString(ResultSet rs, String columnName) throws SQLException { 45 return getClobAsString(rs, rs.findColumn(columnName)); 46 } 47 48 public InputStream getClobAsAsciiStream(ResultSet rs, String columnName) throws SQLException { 49 return getClobAsAsciiStream(rs, rs.findColumn(columnName)); 50 } 51 52 public Reader getClobAsCharacterStream(ResultSet rs, String columnName) throws SQLException { 53 return getClobAsCharacterStream(rs, rs.findColumn(columnName)); 54 } 55 56 } 57 | Popular Tags |