public static LazyObject<? extends ObjectInspector> createLazyObject(ObjectInspector oi) {
    ObjectInspector.Category c = oi.getCategory();
    switch (c) {
    case PRIMITIVE:
      return createLazyPrimitiveClass((PrimitiveObjectInspector) oi);
    case MAP:
      return new LazyMap((LazyMapObjectInspector) oi);
    case LIST:
      return new LazyArray((LazyListObjectInspector) oi);
    case STRUCT:
      return new LazyStruct((LazySimpleStructObjectInspector) oi);
    case UNION:
      return new LazyUnion((LazyUnionObjectInspector) oi);
    }

    throw new RuntimeException("Hive LazySerDe Internal error.");
  }
Create a hierarchical LazyObject based on the given typeInfo.
serde/src/java/org/apache/hadoop/hive/serde2/lazy/LazyFactory.java