Changed getUTFLen() to getUTFLength() in UTF8StringPointable

git-svn-id: https://asterixdb.googlecode.com/svn/branches/asterix_stabilization@404 eaa15691-b419-025a-1212-ee371bd00084
diff --git a/asterix-common/src/main/java/edu/uci/ics/asterix/common/utils/UTF8CharSequence.java b/asterix-common/src/main/java/edu/uci/ics/asterix/common/utils/UTF8CharSequence.java
index 3e03c0a..a6d1c54 100644
--- a/asterix-common/src/main/java/edu/uci/ics/asterix/common/utils/UTF8CharSequence.java
+++ b/asterix-common/src/main/java/edu/uci/ics/asterix/common/utils/UTF8CharSequence.java
@@ -2,7 +2,6 @@
 
 import edu.uci.ics.hyracks.data.std.api.IValueReference;
 import edu.uci.ics.hyracks.data.std.primitive.UTF8StringPointable;
-import edu.uci.ics.hyracks.dataflow.common.data.util.StringUtils;
 
 public class UTF8CharSequence implements CharSequence {
 
@@ -57,7 +56,7 @@
     }
 
     private void resetLength(IValueReference valueRef) {
-        this.len = UTF8StringPointable.getUTFLen(valueRef.getByteArray(), start);
+        this.len = UTF8StringPointable.getUTFLength(valueRef.getByteArray(), start);
     }
 
 }
diff --git a/asterix-om/src/main/java/edu/uci/ics/asterix/dataflow/data/nontagged/serde/ARecordSerializerDeserializer.java b/asterix-om/src/main/java/edu/uci/ics/asterix/dataflow/data/nontagged/serde/ARecordSerializerDeserializer.java
index caa8821..694d189 100644
--- a/asterix-om/src/main/java/edu/uci/ics/asterix/dataflow/data/nontagged/serde/ARecordSerializerDeserializer.java
+++ b/asterix-om/src/main/java/edu/uci/ics/asterix/dataflow/data/nontagged/serde/ARecordSerializerDeserializer.java
@@ -268,11 +268,13 @@
             return -1; // this record does not have an open part
 
         int numberOfOpenField = AInt32SerializerDeserializer.getInt(serRecord, openPartOffset);
-        int utflength = UTF8StringPointable.getUTFLen(fieldName, 1);
-        
-        IBinaryHashFunction utf8HashFunction = AqlBinaryHashFunctionFactoryProvider.UTF8STRING_POINTABLE_INSTANCE.createBinaryHashFunction();
+        int utflength = UTF8StringPointable.getUTFLength(fieldName, 1);
 
-        IBinaryComparator utf8BinaryComparator = AqlBinaryComparatorFactoryProvider.UTF8STRING_POINTABLE_INSTANCE.createBinaryComparator();
+        IBinaryHashFunction utf8HashFunction = AqlBinaryHashFunctionFactoryProvider.UTF8STRING_POINTABLE_INSTANCE
+                .createBinaryHashFunction();
+
+        IBinaryComparator utf8BinaryComparator = AqlBinaryComparatorFactoryProvider.UTF8STRING_POINTABLE_INSTANCE
+                .createBinaryComparator();
 
         int fieldNameHashCode = utf8HashFunction.hash(fieldName, 1, utflength);
 
diff --git a/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/ContainsDescriptor.java b/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/ContainsDescriptor.java
index 8dcf5c2..ab4fb3a 100644
--- a/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/ContainsDescriptor.java
+++ b/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/ContainsDescriptor.java
@@ -39,8 +39,8 @@
 
                     @Override
                     protected boolean findMatch(byte[] strBytes, byte[] patternBytes) {
-                        int utflen1 = UTF8StringPointable.getUTFLen(strBytes, 1);
-                        int utflen2 = UTF8StringPointable.getUTFLen(patternBytes, 1);
+                        int utflen1 = UTF8StringPointable.getUTFLength(strBytes, 1);
+                        int utflen2 = UTF8StringPointable.getUTFLength(patternBytes, 1);
 
                         int s1Start = 3;
                         int s2Start = 3;
diff --git a/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/EndsWithDescriptor.java b/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/EndsWithDescriptor.java
index d8a5367..19a3be7 100644
--- a/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/EndsWithDescriptor.java
+++ b/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/EndsWithDescriptor.java
@@ -39,8 +39,8 @@
 
                     @Override
                     protected boolean findMatch(byte[] strBytes, byte[] patternBytes) {
-                        int utflen1 = UTF8StringPointable.getUTFLen(strBytes, 1);
-                        int utflen2 = UTF8StringPointable.getUTFLen(patternBytes, 1);
+                        int utflen1 = UTF8StringPointable.getUTFLength(strBytes, 1);
+                        int utflen2 = UTF8StringPointable.getUTFLength(patternBytes, 1);
 
                         int s1Start = 3;
                         int s2Start = 3;
diff --git a/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/StartsWithDescriptor.java b/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/StartsWithDescriptor.java
index af2fc8d..2405ad9 100644
--- a/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/StartsWithDescriptor.java
+++ b/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/StartsWithDescriptor.java
@@ -39,8 +39,8 @@
 
                     @Override
                     protected boolean findMatch(byte[] strBytes, byte[] patternBytes) {
-                        int utflen1 = UTF8StringPointable.getUTFLen(strBytes, 1);
-                        int utflen2 = UTF8StringPointable.getUTFLen(patternBytes, 1);
+                        int utflen1 = UTF8StringPointable.getUTFLength(strBytes, 1);
+                        int utflen2 = UTF8StringPointable.getUTFLength(patternBytes, 1);
 
                         int s1Start = 3;
                         int s2Start = 3;
diff --git a/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/SubstringDescriptor.java b/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/SubstringDescriptor.java
index 6eb0c76..c6d0627 100644
--- a/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/SubstringDescriptor.java
+++ b/asterix-runtime/src/main/java/edu/uci/ics/asterix/runtime/evaluators/functions/SubstringDescriptor.java
@@ -57,7 +57,7 @@
                         evalString.evaluate(tuple);
 
                         byte[] bytes = argOut.getByteArray();
-                        int utflen = UTF8StringPointable.getUTFLen(bytes, 1);
+                        int utflen = UTF8StringPointable.getUTFLength(bytes, 1);
                         int sStart = 3;
                         int c = 0;
                         int idxPos1 = 0;