HBASE-7897 Add support for tags to Cell Interface

git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1480430 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Michael Stack 2013-05-08 20:01:57 +00:00
parent 56d965829c
commit 6ad28427b1
4 changed files with 64 additions and 2 deletions

View File

@ -157,6 +157,24 @@ public class TestPayloadCarryingRpcController {
public int getValueLength() {
return Bytes.SIZEOF_INT;
}
@Override
public int getTagsOffset() {
// TODO Auto-generated method stub
return 0;
}
@Override
public int getTagsLength() {
// TODO Auto-generated method stub
return 0;
}
@Override
public byte[] getTagsArray() {
// TODO Auto-generated method stub
return null;
}
};
}

View File

@ -90,7 +90,7 @@ public interface Cell {
byte[] getFamilyArray();
/**
* @return Array index of first row byte
* @return Array index of first family byte
*/
int getFamilyOffset();
@ -168,4 +168,19 @@ public interface Cell {
*/
int getValueLength();
/**
* @return the tags byte array
*/
byte[] getTagsArray();
/**
* @return the first offset where the tags start in the Cell
*/
int getTagsOffset();
/**
* @return the total length of the tags in the Cell.
*/
int getTagsLength();
}

View File

@ -2806,4 +2806,19 @@ public class KeyValue implements Cell, HeapSize, Cloneable {
sum += Bytes.SIZEOF_LONG;// memstoreTS
return ClassSize.align(sum);
}
@Override
public int getTagsOffset() {
throw new UnsupportedOperationException("Not implememnted");
}
@Override
public int getTagsLength() {
throw new UnsupportedOperationException("Not implememnted");
}
@Override
public byte[] getTagsArray() {
throw new UnsupportedOperationException("Not implememnted");
}
}

View File

@ -194,4 +194,18 @@ public class PrefixTreeCell implements Cell, Comparable<Cell> {
return kv.toString();
}
@Override
public int getTagsOffset() {
throw new UnsupportedOperationException("Not implemented");
}
@Override
public int getTagsLength() {
throw new UnsupportedOperationException("Not implemented");
}
@Override
public byte[] getTagsArray() {
throw new UnsupportedOperationException("Not implemented");
}
}