@Override public InputStream getAsciiStream(int columnIndex) throws SQLException { return rs.getAsciiStream(columnIndex); }
@Override public InputStream getAsciiStream(String columnLabel) throws SQLException { return rs.getAsciiStream(columnLabel); }
@Override public InputStream getClobAsAsciiStream(ResultSet rs, int columnIndex) throws SQLException { logger.debug("Returning CLOB as ASCII stream"); if (this.wrapAsLob) { Clob clob = rs.getClob(columnIndex); return clob.getAsciiStream(); } else { return rs.getAsciiStream(columnIndex); } }
@Override public java.io.InputStream getAsciiStream(int columnIndex) throws SQLException { try { return rs.getAsciiStream(columnIndex); } catch (Throwable t) { throw checkException(t); } }
@Override public java.io.InputStream getAsciiStream(String columnLabel) throws SQLException { try { return rs.getAsciiStream(columnLabel); } catch (Throwable t) { throw checkException(t); } }
@SuppressWarnings("deprecation") @Override public InputStream getInputStream(final String columnLabel, final String type) throws SQLException { switch (type) { case "Ascii": return resultSet.getAsciiStream(columnLabel); case "Unicode": return resultSet.getUnicodeStream(columnLabel); case "Binary": return resultSet.getBinaryStream(columnLabel); default: throw new SQLException(String.format("Unsupported type: %s", type)); } }
@SuppressWarnings("deprecation") @Override public InputStream getInputStream(final int columnIndex, final String type) throws SQLException { switch (type) { case "Ascii": return resultSet.getAsciiStream(columnIndex); case "Unicode": return resultSet.getUnicodeStream(columnIndex); case "Binary": return resultSet.getBinaryStream(columnIndex); default: throw new SQLException(String.format("Unsupported type: %s", type)); } }
@Override public void run() throws Exception { rs.getAsciiStream(1); } });
@Override public void run() throws Exception { rs.getAsciiStream("id"); } });
@Override public java.io.InputStream resultSet_getAsciiStream(ResultSetProxy rs, String columnLabel) throws SQLException { if (this.pos < filterSize) { return nextFilter() .resultSet_getAsciiStream(this, rs, columnLabel); } return rs.getResultSetRaw() .getAsciiStream(columnLabel); }
@Override public java.io.InputStream resultSet_getAsciiStream(ResultSetProxy rs, int columnIndex) throws SQLException { if (this.pos < filterSize) { return nextFilter() .resultSet_getAsciiStream(this, rs, columnIndex); } return rs.getResultSetRaw() .getAsciiStream(columnIndex); }
@Override public InputStream getAsciiStream(String columnLabel) throws SQLException { SQLException e = null; try { InputStream value = delegate.getAsciiStream(columnLabel); eventListener.onAfterResultSetGet(resultSetInformation, columnLabel, value, null); return value; } catch (SQLException sqle) { e = sqle; eventListener.onAfterResultSetGet(resultSetInformation, columnLabel, null, e); throw e; } }
@Override public InputStream getAsciiStream(int columnIndex) throws SQLException { SQLException e = null; try { InputStream value = delegate.getAsciiStream(columnIndex); eventListener.onAfterResultSetGet(resultSetInformation, columnIndex, value, null); return value; } catch (SQLException sqle) { e = sqle; eventListener.onAfterResultSetGet(resultSetInformation, columnIndex, null, e); throw e; } }
@Test public void testGetClobAsAsciiStream() throws SQLException { lobHandler.getClobAsAsciiStream(rs, 1); verify(rs).getAsciiStream(1); }
@Override public java.io.InputStream getAsciiStream(String columnLabel) throws SQLException { try { return rs.getAsciiStream(columnLabel); } catch (Throwable t) { throw checkException(t); } }
@Override public java.io.InputStream getAsciiStream(int columnIndex) throws SQLException { try { return rs.getAsciiStream(columnIndex); } catch (Throwable t) { throw checkException(t); } }
@Override public InputStream getAsciiStream(String columnLabel) throws SQLException { SQLException e = null; try { InputStream value = delegate.getAsciiStream(columnLabel); eventListener.onAfterResultSetGet(resultSetInformation, columnLabel, value, null); return value; } catch (SQLException sqle) { e = sqle; eventListener.onAfterResultSetGet(resultSetInformation, columnLabel, null, e); throw e; } }
@Override public InputStream getAsciiStream(int columnIndex) throws SQLException { SQLException e = null; try { InputStream value = delegate.getAsciiStream(columnIndex); eventListener.onAfterResultSetGet(resultSetInformation, columnIndex, value, null); return value; } catch (SQLException sqle) { e = sqle; eventListener.onAfterResultSetGet(resultSetInformation, columnIndex, null, e); throw e; } }
@Override public java.io.InputStream resultSet_getAsciiStream(ResultSetProxy rs, int columnIndex) throws SQLException { if (this.pos < filterSize) { return nextFilter() .resultSet_getAsciiStream(this, rs, columnIndex); } return rs.getResultSetRaw() .getAsciiStream(columnIndex); }
@Override public java.io.InputStream resultSet_getAsciiStream(ResultSetProxy rs, String columnLabel) throws SQLException { if (this.pos < filterSize) { return nextFilter() .resultSet_getAsciiStream(this, rs, columnLabel); } return rs.getResultSetRaw() .getAsciiStream(columnLabel); }