/** * Returns the name of the data type that is inspected by this * ObjectInspector. This is used to display the type information to the user. * <p> * For primitive types, the type name is standardized. For other types, the * type name can be something like "list<int>", "map<int,string>", java class * names, or user-defined type names similar to typedef. */ @Override public String getTypeName() { return baseOI.getTypeName(); }
@Override public String getTypeName() { return wrapped.getTypeName(); }
@Override public String getTypeName() { return wrapped.getTypeName(); }
private void initOperatorContext(List<Operator<? extends OperatorDesc>> children) throws HiveException { for (Map<Operator<?>, MapOpCtx> contexts : opCtxMap.values()) { for (MapOpCtx context : contexts.values()) { if (!children.contains(context.op)) { continue; } StructObjectInspector prev = childrenOpToOI.put(context.op, context.rowObjectInspector); if (prev != null && !prev.equals(context.rowObjectInspector)) { throw new HiveException("Conflict on row inspector for " + context.alias); } if (LOG.isDebugEnabled()) { LOG.debug("dump " + context.op + " " + context.rowObjectInspector.getTypeName()); } } } }
private void initOperatorContext(List<Operator<? extends OperatorDesc>> children) throws HiveException { for (Map<Operator<?>, MapOpCtx> contexts : opCtxMap.values()) { for (MapOpCtx context : contexts.values()) { if (!children.contains(context.op)) { continue; } StructObjectInspector prev = childrenOpToOI.put(context.op, context.rowObjectInspector); if (prev != null && !prev.equals(context.rowObjectInspector)) { throw new HiveException("Conflict on row inspector for " + context.alias); } if (isLogDebugEnabled) { LOG.debug("dump " + context.op + " " + context.rowObjectInspector.getTypeName()); } } } }
readerInspector.getCategory()); assertEquals("struct<bytes1:binary,string1:string>", readerInspector.getTypeName()); List<? extends StructField> fields = readerInspector.getAllStructFieldRefs();
+ "string1:string>>>,list:array<struct<int1:int,string1:string>>," + "map:map<string,struct<int1:int,string1:string>>,ts:timestamp," + "decimal1:decimal(38,18)>", readerInspector.getTypeName()); List<? extends StructField> fields = readerInspector .getAllStructFieldRefs();
readerInspector.getCategory()); assertEquals("struct<bytes1:binary,string1:string>", readerInspector.getTypeName()); List<? extends StructField> fields = readerInspector.getAllStructFieldRefs();
+ "string1:string>>>,list:array<struct<int1:int,string1:string>>," + "map:map<string,struct<int1:int,string1:string>>>", readerInspector.getTypeName()); List<? extends StructField> fields = readerInspector.getAllStructFieldRefs();
"bigint,c6:float,c7:double,c8:binary,c9:string,c10:struct<" + "c1:int>,c11:map<int,int>,c12:uniontype<int>,c13:array<timestamp>>", inspector.getTypeName()); assertEquals(null, inspector.getAllStructFieldRefs().get(0).getFieldComment());
assertEquals(OrcSerde.OrcSerdeRow.class, serde.getSerializedClass()); inspector = (StructObjectInspector) serde.getObjectInspector(); assertEquals("struct<x:int,y:int>", inspector.getTypeName()); InputFormat<?,?> in = new OrcInputFormat(); FileInputFormat.setInputPaths(conf, testFilePath.toString());
SerDeUtils.initializeSerDe(serde, conf, properties, null); inspector = (StructObjectInspector) serde.getObjectInspector(); assertEquals("struct<str:string,str2:string>", inspector.getTypeName()); InputFormat<?,?> in = new OrcInputFormat(); FileInputFormat.setInputPaths(conf, testFilePath.toString());
assertEquals(OrcSerde.OrcSerdeRow.class, serde.getSerializedClass()); inspector = (StructObjectInspector) serde.getObjectInspector(); assertEquals("struct<x:int,y:int>", inspector.getTypeName()); InputFormat<?,?> in = new OrcInputFormat(); FileInputFormat.setInputPaths(conf, testFilePath.toString());
/** * Returns the name of the data type that is inspected by this * ObjectInspector. This is used to display the type information to the user. * * For primitive types, the type name is standardized. For other types, the * type name can be something like "list<int>", "map<int,string>", java class * names, or user-defined type names similar to typedef. */ @Override public String getTypeName() { return baseOI.getTypeName(); }
@Override public String getTypeName() { return wrapped.getTypeName(); }
private void initOperatorContext(List<Operator<? extends OperatorDesc>> children) throws HiveException { for (Map<Operator<?>, MapOpCtx> contexts : opCtxMap.values()) { for (MapOpCtx context : contexts.values()) { if (!children.contains(context.op)) { continue; } StructObjectInspector prev = childrenOpToOI.put(context.op, context.rowObjectInspector); if (prev != null && !prev.equals(context.rowObjectInspector)) { throw new HiveException("Conflict on row inspector for " + context.alias); } if (isLogDebugEnabled) { LOG.debug("dump " + context.op + " " + context.rowObjectInspector.getTypeName()); } } } }
@Override protected void initializeOp(Configuration hconf) throws HiveException { // Just forward the row as is if (conf.isSelStarNoCompute()) { initializeChildren(hconf); return; } ArrayList<ExprNodeDesc> colList = conf.getColList(); eval = new ExprNodeEvaluator[colList.size()]; for (int i = 0; i < colList.size(); i++) { assert (colList.get(i) != null); eval[i] = ExprNodeEvaluatorFactory.get(colList.get(i)); } output = new Object[eval.length]; LOG.info("SELECT " + ((StructObjectInspector) inputObjInspectors[0]).getTypeName()); outputObjInspector = initEvaluatorsAndReturnStruct(eval, conf .getOutputColumnNames(), inputObjInspectors[0]); initializeChildren(hconf); }
childrenPaths.add(onefile); LOG.info("dump " + op.getName() + " " + opCtxMap.get(inp).getRowObjectInspector().getTypeName()); if (!done) { setInspectorInput(inp);
joinValuesStandardObjectInspectors, conf); LOG.info("JOIN " + ((StructObjectInspector) outputObjInspector).getTypeName() + " totalsz = " + totalSz);