Search in sources :

Example 1 with DB2ServerApplication

use of org.jkiss.dbeaver.ext.db2.model.app.DB2ServerApplication in project dbeaver by serge-rider.

the class DB2Utils method readApplications.

// ---------------------
// DBA Data and Actions
// ---------------------
public static List<DB2ServerApplication> readApplications(DBRProgressMonitor monitor, JDBCSession session) throws SQLException {
    LOG.debug("readApplications");
    List<DB2ServerApplication> listApplications = new ArrayList<>();
    try (JDBCPreparedStatement dbStat = session.prepareStatement(SEL_APP)) {
        try (JDBCResultSet dbResult = dbStat.executeQuery()) {
            while (dbResult.next()) {
                listApplications.add(new DB2ServerApplication(dbResult));
            }
        }
    }
    return listApplications;
}
Also used : JDBCPreparedStatement(org.jkiss.dbeaver.model.exec.jdbc.JDBCPreparedStatement) JDBCResultSet(org.jkiss.dbeaver.model.exec.jdbc.JDBCResultSet) ArrayList(java.util.ArrayList) DB2ServerApplication(org.jkiss.dbeaver.ext.db2.model.app.DB2ServerApplication)

Aggregations

ArrayList (java.util.ArrayList)1 DB2ServerApplication (org.jkiss.dbeaver.ext.db2.model.app.DB2ServerApplication)1 JDBCPreparedStatement (org.jkiss.dbeaver.model.exec.jdbc.JDBCPreparedStatement)1 JDBCResultSet (org.jkiss.dbeaver.model.exec.jdbc.JDBCResultSet)1