private NodePropBundle readBundle ( NodeId id , ResultSet rs , int column ) throws SQLException { try { InputStream in ; if ( rs . getMetaData ( ) . getColumnType ( column ) == Types . BLOB ) { in = rs . getBlob ( column ) . getBinaryStream ( ) ; } else { in = rs . getBinaryStream ( column ) ; } try { return binding . readBundle ( in , id ) ; } finally { in . close ( ) ; } } catch ( IOException e ) { SQLException exception = new SQLException ( "Failed to parse bundle " + id ) ; exception . initCause ( e ) ; throw exception ; } }
Reads and parses a bundle from the BLOB in the given column of the current row of the given result set . This is a helper method to circumvent issues JCR - 1039 and JCR - 1474 .