@Override
	public synchronized List<RecordContext> getDataForContext (int contextId) throws DatabaseException {
    	try {
			List<RecordContext> result = new ArrayList<>();
			psGetAllDataForContext.setInt(1, contextId);
			try (ResultSet rs = psGetAllDataForContext.executeQuery()) {
				while (rs.next()) {
					result.add(new RecordContext(rs.getLong(DATAID), rs.getInt(CONTEXTID), rs.getInt(TYPE), rs.getString(DATA)));
				}
			}
			
			return result;
		} catch (SQLException e) {
			throw new DatabaseException(e);
		}
    }
@ Override public synchronized List < RecordContext > getDataForContext ( int contextId ) throws DatabaseException { try { List < RecordContext > result = new ArrayList < > ( ) ; psGetAllDataForContext . setInt ( 1 , contextId ) ; try ( ResultSet rs = psGetAllDataForContext . executeQuery ( ) ) { while ( rs . next ( ) ) { result . add ( new RecordContext ( rs . getLong ( DATAID ) , rs . getInt ( CONTEXTID ) , rs . getInt ( TYPE ) , rs . getString ( DATA ) ) ) ; } } return result ; } catch ( SQLException e ) { throw new DatabaseException ( e ) ; } }
/* (non-Javadoc)
@see org.parosproxy.paros.db.paros.TableContext#getDataForContext(int)