You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@gora.apache.org by le...@apache.org on 2017/09/05 16:10:21 UTC
[1/2] gora git commit: GORA-525: Add Java Doc
Repository: gora
Updated Branches:
refs/heads/master e7b4c3d16 -> 7a0174fa3
GORA-525: Add Java Doc
Project: http://git-wip-us.apache.org/repos/asf/gora/repo
Commit: http://git-wip-us.apache.org/repos/asf/gora/commit/742df58c
Tree: http://git-wip-us.apache.org/repos/asf/gora/tree/742df58c
Diff: http://git-wip-us.apache.org/repos/asf/gora/diff/742df58c
Branch: refs/heads/master
Commit: 742df58cbacbac40aa29045c332089a98e21a286
Parents: e7b4c3d
Author: madhawa-gunasekara <ma...@wso2.com>
Authored: Mon Sep 4 21:46:46 2017 -0500
Committer: madhawa-gunasekara <ma...@wso2.com>
Committed: Mon Sep 4 22:41:55 2017 -0500
----------------------------------------------------------------------
.../AvroSerialization/CassandraKey.java | 38 +++-
.../AvroSerialization/CassandraRecord.java | 204 +++++++++++++++----
.../cassandra/query/CassandraResultSet.java | 11 -
.../serializers/CassandraSerializer.java | 2 +-
.../store/CassandraMappingBuilder.java | 2 +-
.../gora/cassandra/store/CassandraStore.java | 46 -----
6 files changed, 198 insertions(+), 105 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/gora/blob/742df58c/gora-cassandra/src/examples/java/org/apache/gora/cassandra/example/generated/AvroSerialization/CassandraKey.java
----------------------------------------------------------------------
diff --git a/gora-cassandra/src/examples/java/org/apache/gora/cassandra/example/generated/AvroSerialization/CassandraKey.java b/gora-cassandra/src/examples/java/org/apache/gora/cassandra/example/generated/AvroSerialization/CassandraKey.java
index 6b89c33..568ae7b 100644
--- a/gora-cassandra/src/examples/java/org/apache/gora/cassandra/example/generated/AvroSerialization/CassandraKey.java
+++ b/gora-cassandra/src/examples/java/org/apache/gora/cassandra/example/generated/AvroSerialization/CassandraKey.java
@@ -39,6 +39,8 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Creates a new CassandraKey RecordBuilder
+ *
+ * @return builder
*/
public static org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraKey.Builder newBuilder() {
return new org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraKey.Builder();
@@ -46,6 +48,9 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Creates a new CassandraKey RecordBuilder by copying an existing Builder
+ *
+ * @param other existing builder
+ * @return builder
*/
public static org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraKey.Builder newBuilder(org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraKey.Builder other) {
return new org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraKey.Builder(other);
@@ -53,6 +58,9 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Creates a new CassandraKey RecordBuilder by copying an existing CassandraKey instance
+ *
+ * @param other existing Cassandra Key instance
+ * @return builder
*/
public static org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraKey.Builder newBuilder(org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraKey other) {
return new org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraKey.Builder(other);
@@ -123,6 +131,8 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Gets the value of the 'url' field.
+ *
+ * @return url
*/
public java.lang.CharSequence getUrl() {
return url;
@@ -141,7 +151,7 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Checks the dirty status of the 'url' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isUrlDirty
*/
public boolean isUrlDirty() {
return isDirty(0);
@@ -149,6 +159,8 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Gets the value of the 'timestamp' field.
+ *
+ * @return timestamp
*/
public java.lang.Long getTimestamp() {
return timestamp;
@@ -167,7 +179,7 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Checks the dirty status of the 'timestamp' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isTimestampDirty
*/
public boolean isTimestampDirty() {
return isDirty(1);
@@ -308,6 +320,8 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Gets the value of the 'url' field
+ *
+ * @return url
*/
public java.lang.CharSequence getUrl() {
return url;
@@ -315,6 +329,9 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Sets the value of the 'url' field
+ *
+ * @param value url
+ * @return builder
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraKey.Builder setUrl(java.lang.CharSequence value) {
validate(fields()[0], value);
@@ -325,6 +342,8 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Checks whether the 'url' field has been set
+ *
+ * @return hasUrl
*/
public boolean hasUrl() {
return fieldSetFlags()[0];
@@ -332,6 +351,8 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Clears the value of the 'url' field
+ *
+ * @return builder
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraKey.Builder clearUrl() {
url = null;
@@ -341,6 +362,8 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Gets the value of the 'timestamp' field
+ *
+ * @return timestamp
*/
public java.lang.Long getTimestamp() {
return timestamp;
@@ -348,6 +371,9 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Sets the value of the 'timestamp' field
+ *
+ * @param value timestamp
+ * @return builder
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraKey.Builder setTimestamp(long value) {
validate(fields()[1], value);
@@ -358,6 +384,8 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Checks whether the 'timestamp' field has been set
+ *
+ * @return hasTimestamp
*/
public boolean hasTimestamp() {
return fieldSetFlags()[1];
@@ -365,6 +393,8 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Clears the value of the 'timestamp' field
+ *
+ * @return builder
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraKey.Builder clearTimestamp() {
fieldSetFlags()[1] = false;
@@ -407,8 +437,6 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Checks the dirty status of the 'url' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isUrlDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -432,8 +460,6 @@ public class CassandraKey extends org.apache.gora.persistency.impl.PersistentBas
/**
* Checks the dirty status of the 'timestamp' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isTimestampDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
http://git-wip-us.apache.org/repos/asf/gora/blob/742df58c/gora-cassandra/src/examples/java/org/apache/gora/cassandra/example/generated/AvroSerialization/CassandraRecord.java
----------------------------------------------------------------------
diff --git a/gora-cassandra/src/examples/java/org/apache/gora/cassandra/example/generated/AvroSerialization/CassandraRecord.java b/gora-cassandra/src/examples/java/org/apache/gora/cassandra/example/generated/AvroSerialization/CassandraRecord.java
index da320ab..4ca0a1c 100644
--- a/gora-cassandra/src/examples/java/org/apache/gora/cassandra/example/generated/AvroSerialization/CassandraRecord.java
+++ b/gora-cassandra/src/examples/java/org/apache/gora/cassandra/example/generated/AvroSerialization/CassandraRecord.java
@@ -61,6 +61,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Creates a new CassandraRecord RecordBuilder
+ *
+ * @return builder
*/
public static org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder newBuilder() {
return new org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder();
@@ -68,6 +70,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Creates a new CassandraRecord RecordBuilder by copying an existing Builder
+ *
+ * @param other existing builder
+ * @return builder
*/
public static org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder newBuilder(org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder other) {
return new org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder(other);
@@ -75,6 +80,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Creates a new CassandraRecord RecordBuilder by copying an existing CassandraRecord instance
+ *
+ * @param other existing CassandraRecord instance
+ * @return builder
*/
public static org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder newBuilder(org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord other) {
return new org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder(other);
@@ -200,6 +208,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'dataString' field.
+ *
+ * @return dataString
*/
public java.lang.CharSequence getDataString() {
return dataString;
@@ -218,7 +228,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'dataString' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isDataStringDirty
*/
public boolean isDataStringDirty() {
return isDirty(0);
@@ -226,6 +236,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'dataInt' field.
+ *
+ * @return dataInt
*/
public java.lang.Integer getDataInt() {
return dataInt;
@@ -244,7 +256,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'dataInt' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isDataIntDirty
*/
public boolean isDataIntDirty() {
return isDirty(1);
@@ -252,6 +264,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'dataLong' field.
+ *
+ * @return dataLong
*/
public java.lang.Long getDataLong() {
return dataLong;
@@ -270,7 +284,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'dataLong' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isDataLongDirty.
*/
public boolean isDataLongDirty() {
return isDirty(2);
@@ -278,6 +292,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'dataDouble' field.
+ *
+ * @return dataDouble.
*/
public java.lang.Double getDataDouble() {
return dataDouble;
@@ -296,7 +312,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'dataDouble' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isDataDoubleDirty.
*/
public boolean isDataDoubleDirty() {
return isDirty(3);
@@ -304,6 +320,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'dataBytes' field.
+ *
+ * @return dataBytes.
*/
public java.nio.ByteBuffer getDataBytes() {
return dataBytes;
@@ -322,7 +340,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'dataBytes' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isDataBytesDirty.
*/
public boolean isDataBytesDirty() {
return isDirty(4);
@@ -330,6 +348,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'arrayInt' field.
+ *
+ * @return arrayInt.
*/
public java.util.List<java.lang.Integer> getArrayInt() {
return arrayInt;
@@ -348,7 +368,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'arrayInt' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isArrayIntDirty.
*/
public boolean isArrayIntDirty() {
return isDirty(5);
@@ -356,6 +376,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'arrayString' field.
+ *
+ * @return arrayString.
*/
public java.util.List<java.lang.CharSequence> getArrayString() {
return arrayString;
@@ -374,7 +396,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'arrayString' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isArrayStringDirty.
*/
public boolean isArrayStringDirty() {
return isDirty(6);
@@ -382,6 +404,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'arrayLong' field.
+ *
+ * @return arrayLong.
*/
public java.util.List<java.lang.Long> getArrayLong() {
return arrayLong;
@@ -400,7 +424,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'arrayLong' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isArrayLongDirty.
*/
public boolean isArrayLongDirty() {
return isDirty(7);
@@ -408,6 +432,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'arrayDouble' field.
+ *
+ * @return arrayDouble.
*/
public java.util.List<java.lang.Double> getArrayDouble() {
return arrayDouble;
@@ -426,7 +452,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'arrayDouble' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isArrayDoubleDirty.
*/
public boolean isArrayDoubleDirty() {
return isDirty(8);
@@ -434,6 +460,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'mapInt' field.
+ *
+ * @return mapInt.
*/
public java.util.Map<java.lang.CharSequence, java.lang.Integer> getMapInt() {
return mapInt;
@@ -452,7 +480,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'mapInt' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isMapIntDirty.
*/
public boolean isMapIntDirty() {
return isDirty(9);
@@ -460,6 +488,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'mapString' field.
+ *
+ * @return mapString.
*/
public java.util.Map<java.lang.CharSequence, java.lang.CharSequence> getMapString() {
return mapString;
@@ -478,7 +508,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'mapString' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isMapStringDirty.
*/
public boolean isMapStringDirty() {
return isDirty(10);
@@ -486,6 +516,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'mapLong' field.
+ *
+ * @return mapLong.
*/
public java.util.Map<java.lang.CharSequence, java.lang.Long> getMapLong() {
return mapLong;
@@ -504,7 +536,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'mapLong' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isMapLongDirty.
*/
public boolean isMapLongDirty() {
return isDirty(11);
@@ -512,6 +544,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'mapDouble' field.
+ *
+ * @return mapDouble.
*/
public java.util.Map<java.lang.CharSequence, java.lang.Double> getMapDouble() {
return mapDouble;
@@ -530,7 +564,7 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'mapDouble' field. A field is dirty if it represents a change that has not yet been written to the database.
*
- * @param value the value to set.
+ * @return isMapDoubleDirty.
*/
public boolean isMapDoubleDirty() {
return isDirty(12);
@@ -737,6 +771,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'dataString' field
+ *
+ * @return dataString.
*/
public java.lang.CharSequence getDataString() {
return dataString;
@@ -744,6 +780,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'dataString' field
+ *
+ * @param value string value to set
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setDataString(java.lang.CharSequence value) {
validate(fields()[0], value);
@@ -754,6 +793,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'dataString' field has been set
+ *
+ * @return hasDataString.
*/
public boolean hasDataString() {
return fieldSetFlags()[0];
@@ -761,6 +802,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'dataString' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearDataString() {
dataString = null;
@@ -770,6 +813,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'dataInt' field
+ *
+ * @return dataInt.
*/
public java.lang.Integer getDataInt() {
return dataInt;
@@ -777,6 +822,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'dataInt' field
+ *
+ * @param value int value to set
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setDataInt(int value) {
validate(fields()[1], value);
@@ -787,6 +835,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'dataInt' field has been set
+ *
+ * @return hasDataInt.
*/
public boolean hasDataInt() {
return fieldSetFlags()[1];
@@ -794,6 +844,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'dataInt' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearDataInt() {
fieldSetFlags()[1] = false;
@@ -802,6 +854,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'dataLong' field
+ *
+ * @return dataLong.
*/
public java.lang.Long getDataLong() {
return dataLong;
@@ -809,6 +863,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'dataLong' field
+ *
+ * @param value long value to set
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setDataLong(java.lang.Long value) {
validate(fields()[2], value);
@@ -819,6 +876,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'dataLong' field has been set
+ *
+ * @return hasDataLong.
*/
public boolean hasDataLong() {
return fieldSetFlags()[2];
@@ -826,6 +885,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'dataLong' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearDataLong() {
dataLong = null;
@@ -835,6 +896,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'dataDouble' field
+ *
+ * @return dataDouble.
*/
public java.lang.Double getDataDouble() {
return dataDouble;
@@ -842,6 +905,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'dataDouble' field
+ *
+ * @param value double value to set
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setDataDouble(java.lang.Double value) {
validate(fields()[3], value);
@@ -852,6 +918,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'dataDouble' field has been set
+ *
+ * @return hasDataDouble.
*/
public boolean hasDataDouble() {
return fieldSetFlags()[3];
@@ -859,6 +927,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'dataDouble' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearDataDouble() {
dataDouble = null;
@@ -868,6 +938,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'dataBytes' field
+ *
+ * @return dataBytes.
*/
public java.nio.ByteBuffer getDataBytes() {
return dataBytes;
@@ -875,6 +947,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'dataBytes' field
+ *
+ * @param value ByteBuffer to set
+ * @return builder
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setDataBytes(java.nio.ByteBuffer value) {
validate(fields()[4], value);
@@ -885,6 +960,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'dataBytes' field has been set
+ *
+ * @return hasDataBytes.
*/
public boolean hasDataBytes() {
return fieldSetFlags()[4];
@@ -892,6 +969,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'dataBytes' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearDataBytes() {
dataBytes = null;
@@ -901,6 +980,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'arrayInt' field
+ *
+ * @return arrayInt.
*/
public java.util.List<java.lang.Integer> getArrayInt() {
return arrayInt;
@@ -908,6 +989,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'arrayInt' field
+ *
+ * @param value Integer List to set
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setArrayInt(java.util.List<java.lang.Integer> value) {
validate(fields()[5], value);
@@ -918,6 +1002,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'arrayInt' field has been set
+ *
+ * @return hasArrayInt.
*/
public boolean hasArrayInt() {
return fieldSetFlags()[5];
@@ -925,6 +1011,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'arrayInt' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearArrayInt() {
arrayInt = null;
@@ -934,6 +1022,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'arrayString' field
+ *
+ * @return arrayString.
*/
public java.util.List<java.lang.CharSequence> getArrayString() {
return arrayString;
@@ -941,6 +1031,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'arrayString' field
+ *
+ * @param value CharSequence List to set
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setArrayString(java.util.List<java.lang.CharSequence> value) {
validate(fields()[6], value);
@@ -951,6 +1044,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'arrayString' field has been set
+ *
+ * @return hasArrayString.
*/
public boolean hasArrayString() {
return fieldSetFlags()[6];
@@ -958,6 +1053,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'arrayString' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearArrayString() {
arrayString = null;
@@ -967,6 +1064,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'arrayLong' field
+ *
+ * @return arrayLong.
*/
public java.util.List<java.lang.Long> getArrayLong() {
return arrayLong;
@@ -974,6 +1073,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'arrayLong' field
+ *
+ * @param value Long List to set
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setArrayLong(java.util.List<java.lang.Long> value) {
validate(fields()[7], value);
@@ -984,6 +1086,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'arrayLong' field has been set
+ *
+ * @return hasArrayLong.
*/
public boolean hasArrayLong() {
return fieldSetFlags()[7];
@@ -991,6 +1095,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'arrayLong' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearArrayLong() {
arrayLong = null;
@@ -1000,6 +1106,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'arrayDouble' field
+ *
+ * @return arrayDouble.
*/
public java.util.List<java.lang.Double> getArrayDouble() {
return arrayDouble;
@@ -1007,6 +1115,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'arrayDouble' field
+ *
+ * @param value Double List to set
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setArrayDouble(java.util.List<java.lang.Double> value) {
validate(fields()[8], value);
@@ -1017,6 +1128,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'arrayDouble' field has been set
+ *
+ * @return hasArrayDouble.
*/
public boolean hasArrayDouble() {
return fieldSetFlags()[8];
@@ -1024,6 +1137,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'arrayDouble' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearArrayDouble() {
arrayDouble = null;
@@ -1033,6 +1148,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'mapInt' field
+ *
+ * @return mapInt.
*/
public java.util.Map<java.lang.CharSequence, java.lang.Integer> getMapInt() {
return mapInt;
@@ -1040,6 +1157,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'mapInt' field
+ *
+ * @param value Map to set
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setMapInt(java.util.Map<java.lang.CharSequence, java.lang.Integer> value) {
validate(fields()[9], value);
@@ -1050,6 +1170,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'mapInt' field has been set
+ *
+ * @return hasMapInt.
*/
public boolean hasMapInt() {
return fieldSetFlags()[9];
@@ -1057,6 +1179,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'mapInt' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearMapInt() {
mapInt = null;
@@ -1066,6 +1190,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'mapString' field
+ *
+ * @return mapString.
*/
public java.util.Map<java.lang.CharSequence, java.lang.CharSequence> getMapString() {
return mapString;
@@ -1073,6 +1199,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'mapString' field
+ *
+ * @param value Map to Set
+ * @return builder
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setMapString(java.util.Map<java.lang.CharSequence, java.lang.CharSequence> value) {
validate(fields()[10], value);
@@ -1083,6 +1212,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'mapString' field has been set
+ *
+ * @return hasMapString.
*/
public boolean hasMapString() {
return fieldSetFlags()[10];
@@ -1090,6 +1221,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'mapString' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearMapString() {
mapString = null;
@@ -1099,6 +1232,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'mapLong' field
+ *
+ * @return mapLong.
*/
public java.util.Map<java.lang.CharSequence, java.lang.Long> getMapLong() {
return mapLong;
@@ -1106,6 +1241,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'mapLong' field
+ *
+ * @param value Map to set
+ * @return builder
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setMapLong(java.util.Map<java.lang.CharSequence, java.lang.Long> value) {
validate(fields()[11], value);
@@ -1116,6 +1254,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'mapLong' field has been set
+ *
+ * @return hasMapLong.
*/
public boolean hasMapLong() {
return fieldSetFlags()[11];
@@ -1123,6 +1263,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'mapLong' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearMapLong() {
mapLong = null;
@@ -1132,6 +1274,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Gets the value of the 'mapDouble' field
+ *
+ * @return mapDouble.
*/
public java.util.Map<java.lang.CharSequence, java.lang.Double> getMapDouble() {
return mapDouble;
@@ -1139,6 +1283,9 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Sets the value of the 'mapDouble' field
+ *
+ * @param value Map to Set
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder setMapDouble(java.util.Map<java.lang.CharSequence, java.lang.Double> value) {
validate(fields()[12], value);
@@ -1149,6 +1296,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks whether the 'mapDouble' field has been set
+ *
+ * @return hasMapDouble.
*/
public boolean hasMapDouble() {
return fieldSetFlags()[12];
@@ -1156,6 +1305,8 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Clears the value of the 'mapDouble' field
+ *
+ * @return builder.
*/
public org.apache.gora.cassandra.example.generated.AvroSerialization.CassandraRecord.Builder clearMapDouble() {
mapDouble = null;
@@ -1210,8 +1361,6 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'dataString' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isDataStringDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -1235,8 +1384,6 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'dataInt' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isDataIntDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -1260,8 +1407,6 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'dataLong' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isDataLongDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -1285,8 +1430,6 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'dataDouble' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isDataDoubleDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -1310,8 +1453,6 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'dataBytes' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isDataBytesDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -1335,8 +1476,6 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'arrayInt' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isArrayIntDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -1360,8 +1499,6 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'arrayString' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isArrayStringDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -1385,8 +1522,6 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'arrayLong' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isArrayLongDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -1410,8 +1545,6 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'arrayDouble' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isArrayDoubleDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -1435,8 +1568,6 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'mapInt' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isMapIntDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -1460,8 +1591,6 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'mapString' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isMapStringDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -1485,8 +1614,6 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'mapLong' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isMapLongDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
@@ -1510,14 +1637,11 @@ public class CassandraRecord extends org.apache.gora.persistency.impl.Persistent
/**
* Checks the dirty status of the 'mapDouble' field. A field is dirty if it represents a change that has not yet been written to the database.
- *
- * @param value the value to set.
*/
public boolean isMapDoubleDirty() {
throw new java.lang.UnsupportedOperationException("IsDirty is not supported on tombstones");
}
-
}
}
http://git-wip-us.apache.org/repos/asf/gora/blob/742df58c/gora-cassandra/src/main/java/org/apache/gora/cassandra/query/CassandraResultSet.java
----------------------------------------------------------------------
diff --git a/gora-cassandra/src/main/java/org/apache/gora/cassandra/query/CassandraResultSet.java b/gora-cassandra/src/main/java/org/apache/gora/cassandra/query/CassandraResultSet.java
index 4e44d0d..f34cc66 100644
--- a/gora-cassandra/src/main/java/org/apache/gora/cassandra/query/CassandraResultSet.java
+++ b/gora-cassandra/src/main/java/org/apache/gora/cassandra/query/CassandraResultSet.java
@@ -51,9 +51,6 @@ public class CassandraResultSet<K, T extends Persistent> extends ResultBase<K, T
/**
* {@inheritDoc}
- *
- * @return
- * @throws IOException
*/
@Override
protected boolean nextInner() throws IOException {
@@ -68,10 +65,6 @@ public class CassandraResultSet<K, T extends Persistent> extends ResultBase<K, T
/**
* {@inheritDoc}
- *
- * @return
- * @throws IOException
- * @throws InterruptedException
*/
@Override
public float getProgress() throws IOException, InterruptedException {
@@ -80,8 +73,6 @@ public class CassandraResultSet<K, T extends Persistent> extends ResultBase<K, T
/**
* {@inheritDoc}
- *
- * @return
*/
@Override
public T get() {
@@ -90,8 +81,6 @@ public class CassandraResultSet<K, T extends Persistent> extends ResultBase<K, T
/**
* {@inheritDoc}
- *
- * @return
*/
@Override
public K getKey() {
http://git-wip-us.apache.org/repos/asf/gora/blob/742df58c/gora-cassandra/src/main/java/org/apache/gora/cassandra/serializers/CassandraSerializer.java
----------------------------------------------------------------------
diff --git a/gora-cassandra/src/main/java/org/apache/gora/cassandra/serializers/CassandraSerializer.java b/gora-cassandra/src/main/java/org/apache/gora/cassandra/serializers/CassandraSerializer.java
index 208428e..d93ff9c 100644
--- a/gora-cassandra/src/main/java/org/apache/gora/cassandra/serializers/CassandraSerializer.java
+++ b/gora-cassandra/src/main/java/org/apache/gora/cassandra/serializers/CassandraSerializer.java
@@ -95,7 +95,7 @@ public abstract class CassandraSerializer<K, T extends Persistent> {
/**
* In this method persistent class been analyzed to find inner records with UDT type, this method should call in every Cassandra serialization Constructor.
*
- * @throws Exception
+ * @throws Exception exception
*/
protected abstract void analyzePersistent() throws Exception;
http://git-wip-us.apache.org/repos/asf/gora/blob/742df58c/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraMappingBuilder.java
----------------------------------------------------------------------
diff --git a/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraMappingBuilder.java b/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraMappingBuilder.java
index a5ada56..23e1fc9 100644
--- a/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraMappingBuilder.java
+++ b/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraMappingBuilder.java
@@ -72,7 +72,7 @@ public class CassandraMappingBuilder<K, T extends Persistent> {
/**
* @param fileName mapping fileName
* @return All the Cassandra Mappings in the mapping file
- * @throws Exception
+ * @throws Exception exception
*/
@SuppressWarnings("all")
public List<CassandraMapping> readMappingFile(File fileName) throws Exception {
http://git-wip-us.apache.org/repos/asf/gora/blob/742df58c/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
----------------------------------------------------------------------
diff --git a/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java b/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
index 129c49f..7d7d0d8 100644
--- a/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
+++ b/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
@@ -93,8 +93,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @return
*/
@SuppressWarnings("all")
@Override
@@ -117,8 +115,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @return
*/
@Override
public String getSchemaName() {
@@ -143,8 +139,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @return
*/
@SuppressWarnings("all")
@Override
@@ -154,8 +148,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @param keyClass the class of keys
*/
@Override
public void setKeyClass(Class<K> keyClass) {
@@ -164,8 +156,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @return
*/
@Override
public K newKey() {
@@ -182,8 +172,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @return
*/
@SuppressWarnings("all")
@Override
@@ -201,8 +189,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @return
*/
@Override
public BeanFactory<K, T> getBeanFactory() {
@@ -211,8 +197,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @param beanFactory the BeanFactory to use
*/
@Override
public void setBeanFactory(BeanFactory<K, T> beanFactory) {
@@ -229,9 +213,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @param key the key of the object
- * @return
*/
@Override
public T get(K key) {
@@ -240,10 +221,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @param key the key of the object
- * @param fields the fields required in the object. Pass null, to retrieve all fields
- * @return
*/
@Override
public T get(K key, String[] fields) {
@@ -252,9 +229,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @param key key value
- * @param obj object value
*/
@Override
public void put(K key, T obj) {
@@ -263,9 +237,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @param key the key of the object
- * @return
*/
@Override
public boolean delete(K key) {
@@ -274,9 +245,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @param query matching records to this query will be deleted
- * @return
*/
@Override
public long deleteByQuery(Query<K, T> query) {
@@ -285,9 +253,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @param query the query to execute.
- * @return
*/
@Override
public Result<K, T> execute(Query<K, T> query) {
@@ -306,8 +271,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @return
*/
@Override
public Query<K, T> newQuery() {
@@ -317,10 +280,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @param query cassandra Query
- * @return
- * @throws IOException
*/
@Override
public List<PartitionQuery<K, T>> getPartitions(Query<K, T> query) throws IOException {
@@ -341,9 +300,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @param obj
- * @return
*/
@Override
public boolean equals(Object obj) {
@@ -360,8 +316,6 @@ public class CassandraStore<K, T extends Persistent> implements DataStore<K, T>
/**
* {@inheritDoc}
- *
- * @return
*/
@Override
public boolean schemaExists() {
[2/2] gora git commit: GORA-525: Add Java Doc
Posted by le...@apache.org.
GORA-525: Add Java Doc
Project: http://git-wip-us.apache.org/repos/asf/gora/repo
Commit: http://git-wip-us.apache.org/repos/asf/gora/commit/7a0174fa
Tree: http://git-wip-us.apache.org/repos/asf/gora/tree/7a0174fa
Diff: http://git-wip-us.apache.org/repos/asf/gora/diff/7a0174fa
Branch: refs/heads/master
Commit: 7a0174fa338294b3ff20859ad3b776b7f0e2970b
Parents: 742df58
Author: Lewis John McGibbney <le...@gmail.com>
Authored: Tue Sep 5 09:10:26 2017 -0700
Committer: Lewis John McGibbney <le...@gmail.com>
Committed: Tue Sep 5 09:10:26 2017 -0700
----------------------------------------------------------------------
.../org/apache/gora/avro/store/AvroStore.java | 33 +++++-----
.../java/org/apache/gora/filter/Filter.java | 7 +--
.../java/org/apache/gora/filter/FilterList.java | 3 -
.../apache/gora/filter/MapFieldValueFilter.java | 3 -
.../gora/filter/SingleFieldValueFilter.java | 3 -
.../apache/gora/mapreduce/GoraInputFormat.java | 12 ++--
.../org/apache/gora/mapreduce/GoraMapper.java | 50 ++++++++--------
.../apache/gora/mapreduce/GoraOutputFormat.java | 8 +--
.../org/apache/gora/mapreduce/GoraReducer.java | 24 ++++----
.../gora/mapreduce/PersistentSerializer.java | 4 +-
.../apache/gora/persistency/BeanFactory.java | 8 +--
.../gora/persistency/impl/BeanFactoryImpl.java | 10 ++--
.../persistency/ws/impl/BeanFactoryWSImpl.java | 9 ++-
.../persistency/ws/impl/PersistentWSBase.java | 33 +++++-----
.../org/apache/gora/spark/GoraSparkEngine.java | 14 ++---
.../java/org/apache/gora/store/DataStore.java | 8 +--
.../apache/gora/store/impl/DataStoreBase.java | 24 ++++----
.../store/impl/FileBackedDataStoreBase.java | 63 ++++++++++----------
18 files changed, 148 insertions(+), 168 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/avro/store/AvroStore.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/avro/store/AvroStore.java b/gora-core/src/main/java/org/apache/gora/avro/store/AvroStore.java
index 1eb1efe..f1f79c9 100644
--- a/gora-core/src/main/java/org/apache/gora/avro/store/AvroStore.java
+++ b/gora-core/src/main/java/org/apache/gora/avro/store/AvroStore.java
@@ -49,15 +49,14 @@ import org.slf4j.LoggerFactory;
/**
* An adapter DataStore for binary-compatible Avro serializations.
* AvroDataStore supports Binary and JSON serializations.
- * @param <T>
*/
public class AvroStore<K, T extends PersistentBase>
- extends FileBackedDataStoreBase<K, T> implements Configurable {
+extends FileBackedDataStoreBase<K, T> implements Configurable {
/** The property key specifying avro encoder/decoder type to use. Can take values
* "BINARY" or "JSON". */
public static final String CODEC_TYPE_KEY = "codec.type";
-
+
public static final Logger LOG = LoggerFactory.getLogger(AvroStore.class);
/**
@@ -79,16 +78,14 @@ public class AvroStore<K, T extends PersistentBase>
@Override
public void initialize(Class<K> keyClass, Class<T> persistentClass,
- Properties properties) {
- super.initialize(keyClass, persistentClass, properties);
-
- if(properties != null) {
- if(this.codecType == null) {
- String codecType = DataStoreFactory.findProperty(
+ Properties properties) {
+ super.initialize(keyClass, persistentClass, properties);
+
+ if(properties != null && this.codecType == null) {
+ String codecType = DataStoreFactory.findProperty(
properties, this, CODEC_TYPE_KEY, "BINARY");
- this.codecType = CodecType.valueOf(codecType);
- }
- }
+ this.codecType = CodecType.valueOf(codecType);
+ }
}
public void setCodecType(CodecType codecType) {
@@ -142,7 +139,7 @@ public class AvroStore<K, T extends PersistentBase>
@Override
protected Result<K,T> executeQuery(Query<K,T> query) throws IOException {
return new AvroResult<>(this, (AvroQuery<K,T>)query,
- getDatumReader(), getDecoder());
+ getDatumReader(), getDecoder());
}
/**
@@ -150,7 +147,7 @@ public class AvroStore<K, T extends PersistentBase>
*/
@Override
protected Result<K,T> executePartial(FileSplitPartitionQuery<K,T> query)
- throws IOException {
+ throws IOException {
throw new OperationNotSupportedException("Not yet implemented");
}
@@ -215,9 +212,9 @@ public class AvroStore<K, T extends PersistentBase>
protected Encoder createEncoder() throws IOException {
switch(codecType) {
case BINARY:
- return EncoderFactory.get().binaryEncoder(getOrCreateOutputStream(), null);
+ return EncoderFactory.get().binaryEncoder(getOrCreateOutputStream(), null);
case JSON:
- return EncoderFactory.get().jsonEncoder(schema, getOrCreateOutputStream());
+ return EncoderFactory.get().jsonEncoder(schema, getOrCreateOutputStream());
}
return null;
}
@@ -225,9 +222,9 @@ public class AvroStore<K, T extends PersistentBase>
protected Decoder createDecoder() throws IOException {
switch(codecType) {
case BINARY:
- return DecoderFactory.get().binaryDecoder(getOrCreateInputStream(), null);
+ return DecoderFactory.get().binaryDecoder(getOrCreateInputStream(), null);
case JSON:
- return DecoderFactory.get().jsonDecoder(schema, getOrCreateInputStream());
+ return DecoderFactory.get().jsonDecoder(schema, getOrCreateInputStream());
}
return null;
}
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/filter/Filter.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/filter/Filter.java b/gora-core/src/main/java/org/apache/gora/filter/Filter.java
index badaa61..53dd674 100644
--- a/gora-core/src/main/java/org/apache/gora/filter/Filter.java
+++ b/gora-core/src/main/java/org/apache/gora/filter/Filter.java
@@ -24,17 +24,14 @@ import org.apache.hadoop.io.Writable;
* Defines filtering (possibly including modification) of rows. By default
* all filtering is done client side. (In generic Gora classes). Datastore
* implementations can decide if they install remote filters, when possible.
- *
- * @param <K>
- * @param <T>
*/
public interface Filter<K, T extends Persistent> extends Writable{
/**
* Filter the key and persistent. Modification is possible.
*
- * @param key
- * @param persistent
+ * @param key the key to use in the filter
+ * @param persistent the {@link Persistent} object to filter on
* @return <code>true</code> if the row is filtered out (excluded),
* <code>false</code> otherwise.
*/
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/filter/FilterList.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/filter/FilterList.java b/gora-core/src/main/java/org/apache/gora/filter/FilterList.java
index 63ef656..1416a22 100644
--- a/gora-core/src/main/java/org/apache/gora/filter/FilterList.java
+++ b/gora-core/src/main/java/org/apache/gora/filter/FilterList.java
@@ -32,9 +32,6 @@ import java.util.List;
* {@link FilterList} enables us to utilize conditional operands
* for advanced filtering within the construction and
* execution of Gora queries.
- *
- * @param <K>
- * @param <T>
*/
public class FilterList<K, T extends PersistentBase> implements Filter<K, T> {
/** set operator */
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/filter/MapFieldValueFilter.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/filter/MapFieldValueFilter.java b/gora-core/src/main/java/org/apache/gora/filter/MapFieldValueFilter.java
index 610d9d7..1775e7e 100644
--- a/gora-core/src/main/java/org/apache/gora/filter/MapFieldValueFilter.java
+++ b/gora-core/src/main/java/org/apache/gora/filter/MapFieldValueFilter.java
@@ -33,9 +33,6 @@ import java.util.Map;
/**
* A filter that checks for a single field in the persistent.
- *
- * @param <K>
- * @param <T>
*/
public class MapFieldValueFilter<K, T extends PersistentBase> implements Filter<K, T> {
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/filter/SingleFieldValueFilter.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/filter/SingleFieldValueFilter.java b/gora-core/src/main/java/org/apache/gora/filter/SingleFieldValueFilter.java
index 9846c59..a96d667 100644
--- a/gora-core/src/main/java/org/apache/gora/filter/SingleFieldValueFilter.java
+++ b/gora-core/src/main/java/org/apache/gora/filter/SingleFieldValueFilter.java
@@ -32,9 +32,6 @@ import java.util.List;
/**
* A filter that checks for a single field in the persistent.
- *
- * @param <K>
- * @param <T>
*/
public class SingleFieldValueFilter<K, T extends PersistentBase> implements Filter<K, T>{
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/mapreduce/GoraInputFormat.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/mapreduce/GoraInputFormat.java b/gora-core/src/main/java/org/apache/gora/mapreduce/GoraInputFormat.java
index a082da9..637200e 100644
--- a/gora-core/src/main/java/org/apache/gora/mapreduce/GoraInputFormat.java
+++ b/gora-core/src/main/java/org/apache/gora/mapreduce/GoraInputFormat.java
@@ -131,9 +131,9 @@ public class GoraInputFormat<K, T extends PersistentBase>
* @param job the job to set the properties for
* @param query the query to get the inputs from
* @param reuseObjects whether to reuse objects in serialization
- * @param <K1>
- * @param <V1>
- * @throws IOException
+ * @param <K1> key class for {@link org.apache.gora.query.Query}
+ * @param <V1> object value key class for {@link org.apache.gora.query.Query}
+ * @throws IOException if there is an error configuring the input parameters for the job
*/
public static <K1, V1 extends Persistent> void setInput(Job job
, Query<K1,V1> query, boolean reuseObjects)
@@ -155,9 +155,9 @@ public class GoraInputFormat<K, T extends PersistentBase>
* @param inKeyClass Map input key class
* @param inValueClass Map input value class
* @param reuseObjects whether to reuse objects in serialization
- * @param <K1>
- * @param <V1>
- * @throws IOException
+ * @param <K1> key class for {@link org.apache.gora.query.Query}
+ * @param <V1> object value key class for {@link org.apache.gora.query.Query}
+ * @throws IOException if there is an error configuring the input parameters for the job
*/
public static <K1, V1 extends Persistent> void setInput(
Job job,
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/mapreduce/GoraMapper.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/mapreduce/GoraMapper.java b/gora-core/src/main/java/org/apache/gora/mapreduce/GoraMapper.java
index 1a49c69..7583fe4 100644
--- a/gora-core/src/main/java/org/apache/gora/mapreduce/GoraMapper.java
+++ b/gora-core/src/main/java/org/apache/gora/mapreduce/GoraMapper.java
@@ -46,11 +46,11 @@ public class GoraMapper<K1, V1 extends Persistent, K2, V2> extends Mapper<K1, V1
* @param mapperClass the mapper class extending GoraMapper
* @param partitionerClass optional partitioner class
* @param reuseObjects whether to reuse objects in serialization
- * @param <K1>
- * @param <V1>
- * @param <K2>
- * @param <V2>
- * @throws IOException
+ * @param <K1> Map input key class
+ * @param <V1> Map input value class
+ * @param <K2> Map output key class
+ * @param <V2> Map output value class
+ * @throws IOException if there is an error initializing the Map job
*/
@SuppressWarnings("rawtypes")
public static <K1, V1 extends Persistent, K2, V2> void initMapperJob(
@@ -90,11 +90,11 @@ public class GoraMapper<K1, V1 extends Persistent, K2, V2> extends Mapper<K1, V1
* @param outValueClass Map output value class
* @param mapperClass the mapper class extending GoraMapper
* @param reuseObjects whether to reuse objects in serialization
- * @param <K1>
- * @param <V1>
- * @param <K2>
- * @param <V2>
- * @throws IOException
+ * @param <K1> Map input key class
+ * @param <V1> Map input value class
+ * @param <K2> Map output key class
+ * @param <V2> Map output value class
+ * @throws IOException if there is an error initializing the Map job
*/
@SuppressWarnings("rawtypes")
public static <K1, V1 extends Persistent, K2, V2> void initMapperJob(
@@ -120,11 +120,11 @@ public class GoraMapper<K1, V1 extends Persistent, K2, V2> extends Mapper<K1, V1
* @param mapperClass the mapper class extending GoraMapper
* @param partitionerClass optional partitioner class
* @param reuseObjects whether to reuse objects in serialization
- * @param <K1>
- * @param <V1>
- * @param <K2>
- * @param <V2>
- * @throws IOException
+ * @param <K1> Map input key class
+ * @param <V1> Map input value class
+ * @param <K2> Map output key class
+ * @param <V2> Map output value class
+ * @throws IOException if there is an error initializing the Map job
*/
@SuppressWarnings("rawtypes")
public static <K1, V1 extends Persistent, K2, V2> void initMapperJob(
@@ -156,11 +156,11 @@ public class GoraMapper<K1, V1 extends Persistent, K2, V2> extends Mapper<K1, V1
* @param outValueClass Map output value class
* @param mapperClass the mapper class extending GoraMapper
* @param reuseObjects whether to reuse objects in serialization
- * @param <K1>
- * @param <V1>
- * @param <K2>
- * @param <V2>
- * @throws IOException
+ * @param <K1> Map input key class
+ * @param <V1> Map input value class
+ * @param <K2> Map output key class
+ * @param <V2> Map output value class
+ * @throws IOException if there is an error initializing the Map job
*/
@SuppressWarnings({ "rawtypes" })
public static <K1, V1 extends Persistent, K2, V2> void initMapperJob(
@@ -183,11 +183,11 @@ public class GoraMapper<K1, V1 extends Persistent, K2, V2> extends Mapper<K1, V1
* @param outValueClass Map output value class
* @param mapperClass the mapper class extending GoraMapper
* @param reuseObjects whether to reuse objects in serialization
- * @param <K1>
- * @param <V1>
- * @param <K2>
- * @param <V2>
- * @throws IOException
+ * @param <K1> Map input key class
+ * @param <V1> Map input value class
+ * @param <K2> Map output key class
+ * @param <V2> Map output value class
+ * @throws IOException if there is an error initializing the Map job
*/
@SuppressWarnings({ "rawtypes" })
public static <K1, V1 extends Persistent, K2, V2> void initMapperJob(
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/mapreduce/GoraOutputFormat.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/mapreduce/GoraOutputFormat.java b/gora-core/src/main/java/org/apache/gora/mapreduce/GoraOutputFormat.java
index e4792e3..9b67de8 100644
--- a/gora-core/src/main/java/org/apache/gora/mapreduce/GoraOutputFormat.java
+++ b/gora-core/src/main/java/org/apache/gora/mapreduce/GoraOutputFormat.java
@@ -99,8 +99,8 @@ public class GoraOutputFormat<K, T extends Persistent>
* @param job the job to set the properties for
* @param dataStore the datastore as the output
* @param reuseObjects whether to reuse objects in serialization
- * @param <K>
- * @param <V>
+ * @param <K> key class for the {@link org.apache.gora.store.DataStore}
+ * @param <V> value class for the {@link org.apache.gora.store.DataStore}
*/
public static <K, V extends Persistent> void setOutput(Job job,
DataStore<K,V> dataStore, boolean reuseObjects) {
@@ -116,8 +116,8 @@ public class GoraOutputFormat<K, T extends Persistent>
* @param keyClass output key class
* @param persistentClass output value class
* @param reuseObjects whether to reuse objects in serialization
- * @param <K>
- * @param <V>
+ * @param <K> key class for the {@link org.apache.gora.store.DataStore}
+ * @param <V> value class for the {@link org.apache.gora.store.DataStore}
*/
@SuppressWarnings("rawtypes")
public static <K, V extends Persistent> void setOutput(Job job,
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/mapreduce/GoraReducer.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/mapreduce/GoraReducer.java b/gora-core/src/main/java/org/apache/gora/mapreduce/GoraReducer.java
index 627f799..2d71fd7 100644
--- a/gora-core/src/main/java/org/apache/gora/mapreduce/GoraReducer.java
+++ b/gora-core/src/main/java/org/apache/gora/mapreduce/GoraReducer.java
@@ -37,10 +37,10 @@ public class GoraReducer<K1, V1, K2, V2 extends Persistent>
* @param persistentClass output value class
* @param reducerClass the reducer class extending GoraReducer
* @param reuseObjects whether to reuse objects in serialization
- * @param <K1>
- * @param <V1>
- * @param <K2>
- * @param <V2>
+ * @param <K1> Reduce input key class
+ * @param <V1> Reduce input value class
+ * @param <K2> Reduce output key class
+ * @param <V2> Reduce output value class
*/
public static <K1, V1, K2, V2 extends Persistent>
void initReducerJob(
@@ -62,10 +62,10 @@ public class GoraReducer<K1, V1, K2, V2 extends Persistent>
* @param job the job to set the properties for
* @param dataStore the datastore as the output
* @param reducerClass the reducer class extending GoraReducer* @param reducerClass
- * @param <K1>
- * @param <V1>
- * @param <K2>
- * @param <V2>
+ * @param <K1> Reduce input key class
+ * @param <V1> Reduce input value class
+ * @param <K2> Reduce output key class
+ * @param <V2> Reduce output value class
*/
public static <K1, V1, K2, V2 extends Persistent>
void initReducerJob(
@@ -83,10 +83,10 @@ public class GoraReducer<K1, V1, K2, V2 extends Persistent>
* @param dataStore the datastore as the output
* @param reducerClass the reducer class extending GoraReducer
* @param reuseObjects whether to reuse objects in serialization
- * @param <K1>
- * @param <V1>
- * @param <K2>
- * @param <V2>
+ * @param <K1> Reduce input key class
+ * @param <V1> Reduce input value class
+ * @param <K2> Reduce output key class
+ * @param <V2> Reduce output value class
*/
public static <K1, V1, K2, V2 extends Persistent>
void initReducerJob(
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/mapreduce/PersistentSerializer.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/mapreduce/PersistentSerializer.java b/gora-core/src/main/java/org/apache/gora/mapreduce/PersistentSerializer.java
index 1851ff5..c266b8b 100644
--- a/gora-core/src/main/java/org/apache/gora/mapreduce/PersistentSerializer.java
+++ b/gora-core/src/main/java/org/apache/gora/mapreduce/PersistentSerializer.java
@@ -57,8 +57,8 @@ public class PersistentSerializer implements Serializer<PersistentBase> {
/**
* Do the serialization of the {@link PersistentBase} object
*
- * @param persistent
- * @throws IOException
+ * @param persistent {@link PersistentBase} object to serialize
+ * @throws IOException if there is an error during serialization
*/
@Override
public void serialize(PersistentBase persistent) throws IOException {
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/persistency/BeanFactory.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/persistency/BeanFactory.java b/gora-core/src/main/java/org/apache/gora/persistency/BeanFactory.java
index a2dff8c..eb0ba28 100644
--- a/gora-core/src/main/java/org/apache/gora/persistency/BeanFactory.java
+++ b/gora-core/src/main/java/org/apache/gora/persistency/BeanFactory.java
@@ -21,16 +21,16 @@ package org.apache.gora.persistency;
/**
* BeanFactory's enable contruction of keys and Persistent objects.
*
- * @param <K>
- * @param <T>
+ * @param <K> a key
+ * @param <T> a {@link Persistent} object
*/
-public interface BeanFactory<K, T>{
+public interface BeanFactory<K, T> {
/**
* Constructs a new instance of the key class
*
* @return a new instance of the key class
- * @throws Exception
+ * @throws Exception if unabe to create the key class
*/
K newKey() throws Exception;
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/persistency/impl/BeanFactoryImpl.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/persistency/impl/BeanFactoryImpl.java b/gora-core/src/main/java/org/apache/gora/persistency/impl/BeanFactoryImpl.java
index 445f58e..763cba1 100644
--- a/gora-core/src/main/java/org/apache/gora/persistency/impl/BeanFactoryImpl.java
+++ b/gora-core/src/main/java/org/apache/gora/persistency/impl/BeanFactoryImpl.java
@@ -26,10 +26,10 @@ import org.apache.gora.util.ReflectionUtils;
/**
* A default implementation of the {@link BeanFactory} interface. Constructs
- * the keys using by reflection, {@link Persistent} objects by calling
+ * the keys by using reflection, {@link Persistent} objects by calling
*
- * @param <K>
- * @param <T>
+ * @param <K> a key
+ * @param <T> a {@link Persistent} object
*/
public class BeanFactoryImpl<K, T extends Persistent> implements BeanFactory<K, T> {
@@ -54,8 +54,8 @@ public class BeanFactoryImpl<K, T extends Persistent> implements BeanFactory<K,
/**
* Default constructor for this class.
*
- * @param keyClass
- * @param persistentClass
+ * @param keyClass class of the keys
+ * @param persistentClass class of the [{@link Persistent} objects to be stored
*/
public BeanFactoryImpl(Class<K> keyClass, Class<T> persistentClass) {
this.keyClass = keyClass;
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/persistency/ws/impl/BeanFactoryWSImpl.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/persistency/ws/impl/BeanFactoryWSImpl.java b/gora-core/src/main/java/org/apache/gora/persistency/ws/impl/BeanFactoryWSImpl.java
index c106829..bd8b676 100644
--- a/gora-core/src/main/java/org/apache/gora/persistency/ws/impl/BeanFactoryWSImpl.java
+++ b/gora-core/src/main/java/org/apache/gora/persistency/ws/impl/BeanFactoryWSImpl.java
@@ -31,8 +31,8 @@ import org.slf4j.LoggerFactory;
* A default implementation of the {@link BeanFactory} interface. Constructs
* the keys using by reflection, {@link Persistent} objects by calling
*
- * @param <K>
- * @param <T>
+ * @param <K> a key
+ * @param <T> a {@link Persistent} object
*/
public class BeanFactoryWSImpl<K, T extends Persistent> implements BeanFactory<K, T> {
@@ -71,8 +71,8 @@ public class BeanFactoryWSImpl<K, T extends Persistent> implements BeanFactory<K
/**
* Constructor
*
- * @param keyClass
- * @param persistentClass
+ * @param keyClass class of the key to be used
+ * @param persistentClass class of the {@link Persistent} objects to be stored
*/
public BeanFactoryWSImpl(Class<K> keyClass, Class<T> persistentClass) {
this.keyClass = keyClass;
@@ -92,7 +92,6 @@ public class BeanFactoryWSImpl<K, T extends Persistent> implements BeanFactory<K
}
@Override
- @SuppressWarnings("unchecked")
/**
* Creates a new key
*/
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/persistency/ws/impl/PersistentWSBase.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/persistency/ws/impl/PersistentWSBase.java b/gora-core/src/main/java/org/apache/gora/persistency/ws/impl/PersistentWSBase.java
index 3c15e23..68c4b8b 100644
--- a/gora-core/src/main/java/org/apache/gora/persistency/ws/impl/PersistentWSBase.java
+++ b/gora-core/src/main/java/org/apache/gora/persistency/ws/impl/PersistentWSBase.java
@@ -34,14 +34,14 @@ public abstract class PersistentWSBase implements Persistent {
* Maps keys to their own classes
*/
protected static Map<Class<?>, Map<String, Integer>> FIELD_MAP =
- new HashMap<>();
+ new HashMap<>();
/**
* Maps fields to their own classes
*/
protected static Map<Class<?>, String[]> FIELDS =
- new HashMap<>();
-
+ new HashMap<>();
+
/** Subclasses should call this function for all the persistable fields
* in the class to register them.
@@ -61,6 +61,7 @@ public abstract class PersistentWSBase implements Persistent {
/**
* Gets fields using a specific class
+ * @return a {@link java.util.Map} of fields to their own classes
*/
public String[] getFields() {
return FIELDS.get(getClass());
@@ -68,6 +69,7 @@ public abstract class PersistentWSBase implements Persistent {
/**
* Gets a specific field from the fields map
+ * @return a specific {@link java.lang.String} field
*/
public String getField(int index) {
return FIELDS.get(getClass())[index];
@@ -75,6 +77,7 @@ public abstract class PersistentWSBase implements Persistent {
/**
* Gets a field index based on the field name
+ * @return a specific {@link java.lang.String} field
*/
public int getFieldIndex(String field) {
return FIELD_MAP.get(getClass()).get(field);
@@ -91,11 +94,10 @@ public abstract class PersistentWSBase implements Persistent {
}
private void clearReadable() {
- // TODO Auto-generated method stub
-
+
}
- @Override
+ @Override
/**
* Determines if an object has been modified or not
*/
@@ -132,7 +134,6 @@ public abstract class PersistentWSBase implements Persistent {
}
@Override
- // TODO
public int hashCode() {
int result = 1;
return result;
@@ -144,18 +145,18 @@ public abstract class PersistentWSBase implements Persistent {
int h = 1;
int p = buf.arrayOffset();
for (int j = buf.limit() - 1; j >= p; j--)
- h = 31 * h + buf.get(j);
+ h = 31 * h + buf.get(j);
return h;
}
-
+
@Override
/**
* Clones a persistent object
*/
public Persistent clone() {
- return null;
+ return null;
}
-
+
@Override
/**
* Converts an object to string
@@ -171,12 +172,12 @@ public abstract class PersistentWSBase implements Persistent {
/**
* Checks if a field is equal between two objects
- * @param index
- * @param value
- * @return
+ * @param index index position of the field to compare
+ * @param value object to compare against
+ * @return true if this field if equal otherwise false
*/
protected boolean isFieldEqual(int index, Object value) {
- // TODO
- return true;
+ //TODO not implemented
+ return true;
}
}
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/spark/GoraSparkEngine.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/spark/GoraSparkEngine.java b/gora-core/src/main/java/org/apache/gora/spark/GoraSparkEngine.java
index 48490b0..b1916b6 100644
--- a/gora-core/src/main/java/org/apache/gora/spark/GoraSparkEngine.java
+++ b/gora-core/src/main/java/org/apache/gora/spark/GoraSparkEngine.java
@@ -100,10 +100,8 @@ public class GoraSparkEngine<K, V extends Persistent> {
* Creates a job and sets the output parameters for the conf that Spark will use
*
* @param dataStore the datastore as the output
- * @param <K>
- * @param <V>
- * @return
- * @throws IOException
+ * @return a populated output {@link org.apache.hadoop.conf.Configuration}
+ * @throws IOException if there is an error creating the configuration
*/
public <K, V extends Persistent> Configuration generateOutputConf(DataStore<K, V> dataStore)
throws IOException {
@@ -121,9 +119,7 @@ public class GoraSparkEngine<K, V extends Persistent> {
*
* @param job the job to set the properties for
* @param dataStore the datastore as the output
- * @param <K>
- * @param <V>
- * @return
+ * @return a populated output {@link org.apache.hadoop.conf.Configuration}
*/
public <K, V extends Persistent> Configuration generateOutputConf(Job job,
DataStore<K, V> dataStore) {
@@ -138,9 +134,7 @@ public class GoraSparkEngine<K, V extends Persistent> {
* @param dataStoreClass the datastore class
* @param keyClass output key class
* @param persistentClass output value class
- * @param <K>
- * @param <V>
- * @return
+ * @return a populated output {@link org.apache.hadoop.conf.Configuration}
*/
@SuppressWarnings("rawtypes")
public <K, V extends Persistent> Configuration generateOutputConf(Job job,
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/store/DataStore.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/store/DataStore.java b/gora-core/src/main/java/org/apache/gora/store/DataStore.java
index ace39b8..55c71b9 100644
--- a/gora-core/src/main/java/org/apache/gora/store/DataStore.java
+++ b/gora-core/src/main/java/org/apache/gora/store/DataStore.java
@@ -147,8 +147,8 @@ public interface DataStore<K, T extends Persistent> {
* be replaced. See also the note on
* <a href="#visibility">visibility</a>.
*
- * @param key
- * @param obj
+ * @param key the key of the object
+ * @param obj the {@link Persistent} object
*/
void put(K key, T obj);
@@ -187,9 +187,9 @@ public interface DataStore<K, T extends Persistent> {
* is null, then the data store returns the partitions for the default query
* (returning every object)
*
- * @param query
+ * @param query the {@link Query} to partition
* @return a List of PartitionQuery's
- * @throws IOException
+ * @throws IOException if there is an error generating partitions
*/
List<PartitionQuery<K, T>> getPartitions(Query<K, T> query) throws IOException;
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/store/impl/DataStoreBase.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/store/impl/DataStoreBase.java b/gora-core/src/main/java/org/apache/gora/store/impl/DataStoreBase.java
index 4fe339d..6b21a67 100644
--- a/gora-core/src/main/java/org/apache/gora/store/impl/DataStoreBase.java
+++ b/gora-core/src/main/java/org/apache/gora/store/impl/DataStoreBase.java
@@ -53,9 +53,9 @@ import org.slf4j.LoggerFactory;
/**
* A Base class for Avro persistent {@link DataStore}s.
*/
-public abstract class DataStoreBase<K, T extends PersistentBase>
+public abstract class DataStoreBase<K, T extends PersistentBase>
implements DataStore<K, T>, Configurable, Writable, Closeable {
-
+
protected BeanFactory<K, T> beanFactory;
protected Class<K> keyClass;
@@ -76,7 +76,7 @@ public abstract class DataStoreBase<K, T extends PersistentBase>
protected SpecificDatumReader<T> datumReader;
protected SpecificDatumWriter<T> datumWriter;
-
+
public static final Logger LOG = LoggerFactory.getLogger(AvroStore.class);
public DataStoreBase() {
@@ -84,7 +84,7 @@ public abstract class DataStoreBase<K, T extends PersistentBase>
@Override
public void initialize(Class<K> keyClass, Class<T> persistentClass,
- Properties properties) {
+ Properties properties) {
setKeyClass(keyClass);
setPersistentClass(persistentClass);
if (this.beanFactory == null) {
@@ -157,11 +157,11 @@ public abstract class DataStoreBase<K, T extends PersistentBase>
}
/**
- * Checks whether the fields argument is null, and if so
- * returns all the fields of the Persistent object, else returns the
+ * Check whether the fields argument is null, if it is not,
+ * return all the fields of the Persistent object, else return the
* argument.
*
- * @param fields
+ * @param fields a string array of fields to query against
* @return String array
*/
protected String[] getFieldsToQuery(String[] fields) {
@@ -170,10 +170,10 @@ public abstract class DataStoreBase<K, T extends PersistentBase>
}
return getFields();
}
-
+
protected String[] getFields() {
List<Field> schemaFields = beanFactory.getCachedPersistent().getSchema().getFields();
-
+
List<Field> list = new ArrayList<>();
for (Field field : schemaFields) {
if (!Persistent.DIRTY_BYTES_FIELD_NAME.equalsIgnoreCase(field.name())) {
@@ -181,12 +181,12 @@ public abstract class DataStoreBase<K, T extends PersistentBase>
}
}
schemaFields = list;
-
+
String[] fieldNames = new String[schemaFields.size()];
for(int i = 0; i<fieldNames.length; i++ ){
fieldNames[i] = schemaFields.get(i).name();
}
-
+
return fieldNames;
}
@@ -266,7 +266,7 @@ public abstract class DataStoreBase<K, T extends PersistentBase>
if (confSchemaName != null) {
return confSchemaName;
}
-
+
String schemaName = DataStoreFactory.getDefaultSchemaName(properties, this);
if(schemaName != null) {
return schemaName;
http://git-wip-us.apache.org/repos/asf/gora/blob/7a0174fa/gora-core/src/main/java/org/apache/gora/store/impl/FileBackedDataStoreBase.java
----------------------------------------------------------------------
diff --git a/gora-core/src/main/java/org/apache/gora/store/impl/FileBackedDataStoreBase.java b/gora-core/src/main/java/org/apache/gora/store/impl/FileBackedDataStoreBase.java
index 23ce9fa..817a28f 100644
--- a/gora-core/src/main/java/org/apache/gora/store/impl/FileBackedDataStoreBase.java
+++ b/gora-core/src/main/java/org/apache/gora/store/impl/FileBackedDataStoreBase.java
@@ -50,7 +50,7 @@ import org.slf4j.LoggerFactory;
* Base implementations for {@link FileBackedDataStore} methods.
*/
public abstract class FileBackedDataStoreBase<K, T extends PersistentBase>
- extends DataStoreBase<K, T> implements FileBackedDataStore<K, T> {
+extends DataStoreBase<K, T> implements FileBackedDataStore<K, T> {
protected long inputSize; //input size in bytes
@@ -59,12 +59,12 @@ public abstract class FileBackedDataStoreBase<K, T extends PersistentBase>
protected InputStream inputStream;
protected OutputStream outputStream;
-
+
public static final Logger LOG = LoggerFactory.getLogger(AvroStore.class);
@Override
public void initialize(Class<K> keyClass, Class<T> persistentClass,
- Properties properties) {
+ Properties properties) {
super.initialize(keyClass, persistentClass, properties);
if(properties != null) {
if(this.inputPath == null) {
@@ -77,37 +77,37 @@ public abstract class FileBackedDataStoreBase<K, T extends PersistentBase>
}
@Override
-public void setInputPath(String inputPath) {
+ public void setInputPath(String inputPath) {
this.inputPath = inputPath;
}
@Override
-public void setOutputPath(String outputPath) {
+ public void setOutputPath(String outputPath) {
this.outputPath = outputPath;
}
@Override
-public String getInputPath() {
+ public String getInputPath() {
return inputPath;
}
@Override
-public String getOutputPath() {
+ public String getOutputPath() {
return outputPath;
}
@Override
-public void setInputStream(InputStream inputStream) {
+ public void setInputStream(InputStream inputStream) {
this.inputStream = inputStream;
}
@Override
-public void setOutputStream(OutputStream outputStream) {
+ public void setOutputStream(OutputStream outputStream) {
this.outputStream = outputStream;
}
@Override
-public InputStream getInputStream() {
+ public InputStream getInputStream() {
return inputStream;
}
@@ -116,10 +116,11 @@ public InputStream getInputStream() {
return outputStream;
}
- /** Opens an InputStream for the input Hadoop path
- *
- * @return
- * @throws IOException
+ /**
+ * Opens an InputStream for the input Hadoop path
+ * @return an open {@link java.io.InputStream}
+ * @throws IOException if there is an error obtaining the FileSystem or/from
+ * the path
*/
protected InputStream createInputStream() throws IOException {
//TODO: if input path is a directory, use smt like MultiInputStream to
@@ -130,9 +131,9 @@ public InputStream getInputStream() {
return fs.open(path);
}
- /** Opens an OutputStream for the output Hadoop path
- *
- * @return
+ /**
+ * Opens an OutputStream for the output Hadoop path
+ * @return an open {@link java.io.OutputStream}
*/
protected OutputStream createOutputStream() {
OutputStream conf = null;
@@ -171,7 +172,7 @@ public InputStream getInputStream() {
try{
splits = GoraMapReduceUtils.getSplits(getConf(), inputPath);
queries = new ArrayList<>(splits.size());
-
+
for(InputSplit split : splits) {
queries.add(new FileSplitPartitionQuery<>(query, (FileSplit) split));
}
@@ -200,22 +201,22 @@ public InputStream getInputStream() {
* Executes a normal Query reading the whole data. #execute() calls this function
* for non-PartitionQuery's.
*
- * @param query
- * @return
- * @throws IOException
+ * @param query the {@link org.apache.gora.query.Query} to execute
+ * @return a {@link org.apache.gora.query.Result}
+ * @throws IOException if there is an error during query exeuction
*/
protected abstract Result<K,T> executeQuery(Query<K,T> query)
- throws IOException;
+ throws IOException;
/**
* Executes a PartitialQuery, reading the data between start and end.
*
- * @param query
- * @return
- * @throws IOException
+ * @param query the {@link org.apache.gora.query.impl.FileSplitPartitionQuery} to execute
+ * @return a {@link org.apache.gora.query.Result}
+ * @throws IOException if there is an error during query exeuction
*/
protected abstract Result<K,T> executePartial(FileSplitPartitionQuery<K,T> query)
- throws IOException;
+ throws IOException;
@Override
public void flush() {
@@ -234,7 +235,7 @@ public InputStream getInputStream() {
@Override
public void deleteSchema() {
throw new OperationNotSupportedException("delete schema is not supported for " +
- "file backed data stores");
+ "file backed data stores");
}
@Override
@@ -272,9 +273,9 @@ public InputStream getInputStream() {
@Override
public void close() {
- IOUtils.closeStream(inputStream);
- IOUtils.closeStream(outputStream);
- inputStream = null;
- outputStream = null;
+ IOUtils.closeStream(inputStream);
+ IOUtils.closeStream(outputStream);
+ inputStream = null;
+ outputStream = null;
}
}