Example usage for org.springframework.jdbc.support.rowset ResultSetWrappingSqlRowSet next

List of usage examples for org.springframework.jdbc.support.rowset ResultSetWrappingSqlRowSet next

Introduction

In this page you can find the example usage for org.springframework.jdbc.support.rowset ResultSetWrappingSqlRowSet next.

Prototype

@Override
public boolean next() throws InvalidResultSetAccessException 

Source Link

Usage

From source file:ar.com.zauber.commons.spring.secrets.SQLSecretMap.java

/** @see AbstractSecretsMap#hasSecret(java.lang.String) */
@Override/*w  ww .  j  ava2  s .  c  om*/
protected final boolean hasSecret(final String secret) {
    final String sql = "SELECT secret FROM " + table + " WHERE secret=?";

    final ResultSetWrappingSqlRowSet rset = (ResultSetWrappingSqlRowSet) template.query(sql,
            new Object[] { secret }, new int[] { Types.VARCHAR }, extractor);
    boolean ret = false;
    while (!ret && rset.next()) {
        ret = true;
    }

    return ret;
}