1 16 17 package org.springframework.orm.ibatis.support; 18 19 import java.sql.PreparedStatement ; 20 import java.sql.ResultSet ; 21 import java.sql.SQLException ; 22 23 import org.springframework.jdbc.support.lob.LobCreator; 24 import org.springframework.jdbc.support.lob.LobHandler; 25 26 42 public class ClobStringTypeHandler extends AbstractLobTypeHandler { 43 44 49 public ClobStringTypeHandler() { 50 super(); 51 } 52 53 56 protected ClobStringTypeHandler(LobHandler lobHandler) { 57 super(lobHandler); 58 } 59 60 protected void setParameterInternal( 61 PreparedStatement ps, int index, Object value, String jdbcType, LobCreator lobCreator) 62 throws SQLException { 63 lobCreator.setClobAsString(ps, index, (String ) value); 64 } 65 66 protected Object getResultInternal(ResultSet rs, int index, LobHandler lobHandler) 67 throws SQLException { 68 return lobHandler.getClobAsString(rs, index); 69 } 70 71 public Object valueOf(String s) { 72 return s; 73 } 74 75 } 76 | Popular Tags |