Skip to content
Browse files

Merge pull request #40 from frankhsueh/master

putColumn impl for float
  • Loading branch information...
2 parents d712c58 + 0de766a commit b26b4d92a3e7b438337baf81b7c5a274ec2fc9fb @elandau elandau committed Apr 17, 2012
View
2 src/main/java/com/netflix/astyanax/ColumnListMutation.java
@@ -64,6 +64,8 @@
ColumnListMutation<C> putColumn(C columnName, Date value, Integer ttl);
+ ColumnListMutation<C> putColumn(C columnName, float value, Integer ttl);
+
ColumnListMutation<C> putColumn(C columnName, double value, Integer ttl);
ColumnListMutation<C> putColumn(C columnName, UUID value, Integer ttl);
View
7 src/main/java/com/netflix/astyanax/thrift/ThriftColumnFamilyMutationImpl.java
@@ -35,6 +35,7 @@
import com.netflix.astyanax.serializers.BytesArraySerializer;
import com.netflix.astyanax.serializers.DateSerializer;
import com.netflix.astyanax.serializers.DoubleSerializer;
+import com.netflix.astyanax.serializers.FloatSerializer;
import com.netflix.astyanax.serializers.IntegerSerializer;
import com.netflix.astyanax.serializers.LongSerializer;
import com.netflix.astyanax.serializers.StringSerializer;
@@ -130,6 +131,12 @@ else if (defaultTtl != null)
}
@Override
+ public ColumnListMutation<C> putColumn(C columnName, float value,
+ Integer ttl) {
+ return putColumn(columnName, value, FloatSerializer.get(), ttl);
+ }
+
+ @Override
public ColumnListMutation<C> putColumn(C columnName, double value,
Integer ttl) {
return putColumn(columnName, value, DoubleSerializer.get(), ttl);
View
7 src/main/java/com/netflix/astyanax/thrift/ThriftSuperColumnMutationImpl.java
@@ -36,6 +36,7 @@
import com.netflix.astyanax.serializers.BytesArraySerializer;
import com.netflix.astyanax.serializers.DateSerializer;
import com.netflix.astyanax.serializers.DoubleSerializer;
+import com.netflix.astyanax.serializers.FloatSerializer;
import com.netflix.astyanax.serializers.IntegerSerializer;
import com.netflix.astyanax.serializers.LongSerializer;
import com.netflix.astyanax.serializers.StringSerializer;
@@ -132,6 +133,12 @@ private void addMutation(Column column) {
}
@Override
+ public ColumnListMutation<C> putColumn(C columnName, float value,
+ Integer ttl) {
+ return putColumn(columnName, value, FloatSerializer.get(), ttl);
+ }
+
+ @Override
public ColumnListMutation<C> putColumn(C columnName, double value,
Integer ttl) {
return putColumn(columnName, value, DoubleSerializer.get(), ttl);
View
7 src/main/java/com/netflix/astyanax/thrift/model/ThriftCounterSuperColumnMutationImpl.java
@@ -35,6 +35,7 @@
import com.netflix.astyanax.serializers.BytesArraySerializer;
import com.netflix.astyanax.serializers.DateSerializer;
import com.netflix.astyanax.serializers.DoubleSerializer;
+import com.netflix.astyanax.serializers.FloatSerializer;
import com.netflix.astyanax.serializers.IntegerSerializer;
import com.netflix.astyanax.serializers.LongSerializer;
import com.netflix.astyanax.serializers.StringSerializer;
@@ -101,6 +102,12 @@ public ThriftCounterSuperColumnMutationImpl(long timestamp,
}
@Override
+ public ColumnListMutation<C> putColumn(C columnName, float value,
+ Integer ttl) {
+ return putColumn(columnName, value, FloatSerializer.get(), ttl);
+ }
+
+ @Override
public ColumnListMutation<C> putColumn(C columnName, double value,
Integer ttl) {
return putColumn(columnName, value, DoubleSerializer.get(), ttl);

0 comments on commit b26b4d9

Please sign in to comment.
Something went wrong with that request. Please try again.