Elffuss BraidHub

kikocis/java-driver public

Improve doc for ResultSet#wasApplied (JAVA-358).
Changeset73e7b6a4d0efe9ebf23445bcb9d07f68a15b7db131678b491af6769a239ae3ed
Authorolim7t <omichallat+github@gmail.com> · 2014-09-08 17:22 -07:00
Committerolim7t <omichallat+github@gmail.com> · 2014-09-08 17:22 -07:00
Parents0385b2721a89

Browse the files at this changeset

1 file changed

modified driver-core/src/main/java/com/datastax/driver/core/ResultSet.java +3 −4
@@ -195,17 +195,16 @@
195195 * <pre>
196196 * rs.one().getBool("[applied]");
197197 * </pre>
198- *
199198 * <p>
200199 * For consistency, this method always returns {@code true} for
201200 * non-conditional queries (although there is no reason to call the method
202- * in that case).
203- *
201+ * in that case). This is also the case for conditional DDL statements
202+ * ({@code CREATE KEYSPACE... IF NOT EXISTS}, {@code CREATE TABLE... IF NOT EXISTS}),
203+ * for which Cassandra doesn't return an {@code [applied]} column.
204204 * <p>
205205 * Note that, for versions of Cassandra strictly lower than 2.0.9 and 2.1.0-rc2,
206206 * a server-side bug (CASSANDRA-7337) causes this method to always return
207207 * {@code true} for batches containing conditional queries.
208- * </p>
209208 *
210209 * @return if the query was a conditional update, whether it was applied.
211210 * {@code true} for other types of queries.