@Override public String getQueryString(CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); return cache; }
@Override public boolean hasValues(CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); return values != null; }
@Override public ByteBuffer[] getValues(ProtocolVersion protocolVersion, CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); return values == null ? null : Utils.convert(values.toArray(), protocolVersion, codecRegistry); }
/** * Returns the {@code i}th value as the Java type matching its CQL type. * * @param i the index to retrieve. * @param codecRegistry the codec registry that will be used if the statement must be rebuilt in * order to determine if it has values, and Java objects must be inlined in the process (see * {@link BuiltStatement} for more explanations on why this is so). * @return the value of the {@code i}th value of this statement. * @throws IllegalStateException if this statement does not have values. * @throws IndexOutOfBoundsException if {@code i} is not a valid index for this object. * @see #getObject(int) */ public Object getObject(int i, CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); if (values == null || values.isEmpty()) throw new IllegalStateException("This statement does not have values"); if (i < 0 || i >= values.size()) throw new ArrayIndexOutOfBoundsException(i); return values.get(i); }
@Override public boolean hasValues(CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); return values != null; }
@Override public boolean hasValues(CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); return values != null; }
@Override public ByteBuffer[] getValues() { maybeRebuildCache(); return values; }
@Override public boolean hasValues(CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); return values != null; }
@Override public String getQueryString() { maybeRebuildCache(); return cache; }
@Override public String getQueryString(CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); return cache; }
@Override public String getQueryString(CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); return cache; }
@Override public String getQueryString(CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); return cache; }
@Override public ByteBuffer[] getValues(ProtocolVersion protocolVersion, CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); return values == null ? null : Utils.convert(values.toArray(), protocolVersion, codecRegistry); }
@Override public ByteBuffer[] getValues(ProtocolVersion protocolVersion, CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); return values == null ? null : Utils.convert(values.toArray(), protocolVersion, codecRegistry); }
@Override public ByteBuffer[] getValues(ProtocolVersion protocolVersion, CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); return values == null ? null : Utils.convert(values.toArray(), protocolVersion, codecRegistry); }
/** * Returns the {@code i}th value as the Java type matching its CQL type. * * @param i the index to retrieve. * @param codecRegistry the codec registry that will be used if the statement must be * rebuilt in order to determine if it has values, and Java objects * must be inlined in the process (see {@link BuiltStatement} for * more explanations on why this is so). * @return the value of the {@code i}th value of this statement. * @throws IllegalStateException if this statement does not have values. * @throws IndexOutOfBoundsException if {@code i} is not a valid index for this object. * @see #getObject(int) */ public Object getObject(int i, CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); if (values == null || values.isEmpty()) throw new IllegalStateException("This statement does not have values"); if (i < 0 || i >= values.size()) throw new ArrayIndexOutOfBoundsException(i); return values.get(i); }
/** * Returns the {@code i}th value as the Java type matching its CQL type. * * @param i the index to retrieve. * @param codecRegistry the codec registry that will be used if the statement must be * rebuilt in order to determine if it has values, and Java objects * must be inlined in the process (see {@link BuiltStatement} for * more explanations on why this is so). * @return the value of the {@code i}th value of this statement. * @throws IllegalStateException if this statement does not have values. * @throws IndexOutOfBoundsException if {@code i} is not a valid index for this object. * @see #getObject(int) */ public Object getObject(int i, CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); if (values == null || values.isEmpty()) throw new IllegalStateException("This statement does not have values"); if (i < 0 || i >= values.size()) throw new ArrayIndexOutOfBoundsException(i); return values.get(i); }
/** * Returns the {@code i}th value as the Java type matching its CQL type. * * @param i the index to retrieve. * @param codecRegistry the codec registry that will be used if the statement must be * rebuilt in order to determine if it has values, and Java objects * must be inlined in the process (see {@link BuiltStatement} for * more explanations on why this is so). * @return the value of the {@code i}th value of this statement. * @throws IllegalStateException if this statement does not have values. * @throws IndexOutOfBoundsException if {@code i} is not a valid index for this object. * @see #getObject(int) */ public Object getObject(int i, CodecRegistry codecRegistry) { maybeRebuildCache(codecRegistry); if (values == null || values.isEmpty()) throw new IllegalStateException("This statement does not have values"); if (i < 0 || i >= values.size()) throw new ArrayIndexOutOfBoundsException(i); return values.get(i); }