import java.sql.*;
import javax.sql.*;
import oracle.jdbc.driver.*;
import oracle.jdbc.pool.*;
public class DataSource {
public static void main(String[] args) {
try {
OracleDataSource ods = new OracleDataSource();
ods.setUser("stud");
ods.setPassword("stud");
ods.setDriverType("thin");
ods.setDatabaseName("orbis");
ods.setServerName("localhost");
ods.setPortNumber(1521);
Connection conn = ods.getConnection();
System.out.println("Connection successful!!!");
} catch (SQLException se) {
se.printStackTrace();
}
System.out.println("Goodbye!");
}
}