private ContainerNode<?> visitList(final ObjectInspector oi, final Object o)
      throws SerDeException {
    final ListObjectInspector loi = (ListObjectInspector) oi;

    final List<?> list = loi.getList(o);
    final ArrayNode arrayNode = this.nodeFactory.arrayNode(list.size());

    for (final Object item : list) {
      final JsonNode valueNode = walkObjectGraph(
          loi.getListElementObjectInspector(), item, Collections.emptyList());
      arrayNode.add(valueNode);
    }

    return arrayNode;
  }
Visit a vertex in the graph that is a Java List.

@param oi The list's ObjectInspector
@param o The List object
@return A JsonNode representation of the List
@throws SerDeException The List cannot be parsed
serde/src/java/org/apache/hadoop/hive/serde2/json/HiveJsonWriter.java