org.apache.hadoop.hive.serde2.lazy
Class LazyArray
java.lang.Object
org.apache.hadoop.hive.serde2.lazy.LazyObjectBase
org.apache.hadoop.hive.serde2.lazy.LazyObject<OI>
org.apache.hadoop.hive.serde2.lazy.LazyNonPrimitive<LazyListObjectInspector>
org.apache.hadoop.hive.serde2.lazy.LazyArray
public class LazyArray
- extends LazyNonPrimitive<LazyListObjectInspector>
LazyArray stores an array of Lazy Objects.
LazyArray does not deal with the case of a NULL array. That is handled by the
parent LazyObject.
Fields inherited from class org.apache.hadoop.hive.serde2.lazy.LazyObject |
oi |
Method Summary |
List<Object> |
getList()
Returns the List of actual primitive objects. |
Object |
getListElementObject(int index)
Returns the actual primitive object at the index position inside the array
represented by this LazyObject. |
int |
getListLength()
Returns -1 for null array. |
void |
init(ByteArrayRef bytes,
int start,
int length)
Set the row data for this LazyArray. |
LazyArray
protected LazyArray(LazyListObjectInspector oi)
- Construct a LazyArray object with the ObjectInspector.
- Parameters:
oi
- the oi representing the type of this LazyArray as well as meta
information like separator etc.
init
public void init(ByteArrayRef bytes,
int start,
int length)
- Set the row data for this LazyArray.
- Overrides:
init
in class LazyNonPrimitive<LazyListObjectInspector>
- Parameters:
bytes
- The wrapper of the byte[].start
- The start position inside the bytes.length
- The length of the data, starting from "start"- See Also:
LazyObjectBase.init(ByteArrayRef, int, int)
getListElementObject
public Object getListElementObject(int index)
- Returns the actual primitive object at the index position inside the array
represented by this LazyObject.
getListLength
public int getListLength()
- Returns -1 for null array.
getList
public List<Object> getList()
- Returns the List of actual primitive objects. Returns null for null array.
Copyright © 2013 The Apache Software Foundation