OracleDataSource ods = new OracleDataSource(); ods.setDescription("A new OracleDataSource"); DataSource ds = ods; System.out.println(Integer.toString(ds.getLoginTimeout()));