modules/ballerina-native/src/main/java/org/ballerinalang/nativeimpl/connectors/data/sql/client/SQLConnectorUtils.java
public static void cleanupConnection(ResultSet rs, Statement stmt, Connection conn) {
        if (rs != null) {
            try {
                rs.close();
            } catch (SQLException ignore) { /* ignore */ }
        }
        if (stmt != null) {
            try {
                stmt.close();
            } catch (SQLException ignore) { /* ignore */ }
        }
        if (conn != null) {
            try {
                conn.close();
            } catch (SQLException ignore) { /* ignore */ }
        }
    }
/**
     * This will close Database connection, statement and the resultset.
     *
     * @param rs   SQL resultset
     * @param stmt SQL statement
     * @param conn SQL connection
     */
This will close Database connection, statement and the resultset.
@param rs   SQL resultset
@param stmt SQL statement
@param conn SQL connection
This will close Database connection statement and the resultset . @param rs SQL resultset @param stmt SQL statement @param conn SQL connection
public static void cleanupConnection(ResultSet rs, Statement stmt, Connection conn) {
        if (rs != null) {
            try {
                rs.close();
            } catch (SQLException ignore) { /* ignore */ }
        }
        if (stmt != null) {
            try {
                stmt.close();
            } catch (SQLException ignore) { /* ignore */ }
        }
        if (conn != null) {
            try {
                conn.close();
            } catch (SQLException ignore) { /* ignore */ }
        }
    }
public static void cleanupConnection ( ResultSet rs , Statement stmt , Connection conn ) { if ( rs != null ) { try { rs . close ( ) ; } catch ( SQLException ignore ) { /* ignore */ } } if ( stmt != null ) { try { stmt . close ( ) ; } catch ( SQLException ignore ) { /* ignore */ } } if ( conn != null ) { try { conn . close ( ) ; } catch ( SQLException ignore ) { /* ignore */ } } }
This will close Database connection, statement and the resultset.
This will close Database connection statement and the resultset .