@Override public ResultSet getResultSet(long index, int count) throws SQLException { return getResultSet0(getArray(index, count)); }
@Override public ResultSet getResultSet(Map<String, Class<?>> map) { return getResultSet(); }
@SuppressWarnings({ "rawtypes", "unchecked" }) @Override final void set0(BindingSetSQLOutputContext<U> ctx, Object[] value) throws SQLException { ctx.output().writeArray(new MockArray(ctx.family(), value, type())); }
@Override public ResultSet getResultSet() { return getResultSet0(array); }
@Override public T[] getArray(long index, int count, Map<String, Class<?>> map) throws SQLException { return getArray(index, count); }
return (U) new MockArray(null, fromArray, fromClass);
@SuppressWarnings({ "rawtypes", "unchecked" }) @Override final void set0(BindingSetStatementContext<U> ctx, Object[] value) throws SQLException { switch (ctx.family()) { case POSTGRES: { ctx.statement().setString(ctx.index(), toPGArrayString(value)); break; } case HSQLDB: { Object[] a = value; Class<?> t = type; // [#2325] [#5823] Cannot bind UUID[] type in HSQLDB. // See also: https://sourceforge.net/p/hsqldb/bugs/1466 if (t == UUID[].class) { a = Convert.convertArray(a, byte[][].class); t = byte[][].class; } ctx.statement().setArray(ctx.index(), new MockArray(ctx.family(), a, t)); break; } case H2: { ctx.statement().setObject(ctx.index(), value); break; } default: throw new SQLDialectNotSupportedException("Cannot bind ARRAY types in dialect " + ctx.family()); } }
@Override public ResultSet getResultSet(long index, int count, Map<String, Class<?>> map) throws SQLException { return getResultSet(index, count); }