DEV Community

iron_man
iron_man

Posted on

OracleConnectionFactory .java

package com.hardening;

import java.sql.Connection;
import java.sql.SQLException;
import org.springframework.stereotype.Service;

@Service
public class OracleConnectionFactory {

private final OracleRuntimeConnection runtimeConnection;

public OracleConnectionFactory(
        OracleRuntimeConnection runtimeConnection) {
    this.runtimeConnection = runtimeConnection;
}

public Connection open(String schema, String alias)
        throws SQLException {
    return runtimeConnection.open(alias, schema);
}
Enter fullscreen mode Exit fullscreen mode

}

Top comments (0)