protected LazyMapObjectInspector() { super(); lazyParams = new LazyObjectInspectorParametersImpl(); } /**
/** * Call ObjectInspectorFactory.getStandardListObjectInspector instead. */ protected LazyMapObjectInspector(ObjectInspector mapKeyObjectInspector, ObjectInspector mapValueObjectInspector, byte itemSeparator, byte keyValueSeparator, Text nullSequence, boolean escaped, byte escapeChar) { this.mapKeyObjectInspector = mapKeyObjectInspector; this.mapValueObjectInspector = mapValueObjectInspector; this.itemSeparator = itemSeparator; this.keyValueSeparator = keyValueSeparator; this.lazyParams = new LazyObjectInspectorParametersImpl( escaped, escapeChar, false, null, null, nullSequence); }
@Deprecated public static LazySimpleStructObjectInspector getLazySimpleStructObjectInspector( List<String> structFieldNames, List<ObjectInspector> structFieldObjectInspectors, List<String> structFieldComments, byte separator, Text nullSequence, boolean lastColumnTakesRest, boolean escaped,byte escapeChar, ObjectInspectorOptions option) { return getLazySimpleStructObjectInspector(structFieldNames, structFieldObjectInspectors, structFieldComments, separator, new LazyObjectInspectorParametersImpl( escaped, escapeChar, false, null, null, nullSequence, lastColumnTakesRest), option); }
@Deprecated public static LazyUnionObjectInspector getLazyUnionObjectInspector( List<ObjectInspector> ois, byte separator, Text nullSequence, boolean escaped, byte escapeChar) { return getLazyUnionObjectInspector(ois, separator, new LazyObjectInspectorParametersImpl(escaped, escapeChar, false, null, null, nullSequence)); }
@Deprecated public static LazyListObjectInspector getLazySimpleListObjectInspector( ObjectInspector listElementObjectInspector, byte separator, Text nullSequence, boolean escaped, byte escapeChar) { return getLazySimpleListObjectInspector(listElementObjectInspector, separator, new LazyObjectInspectorParametersImpl(escaped, escapeChar, false, null, null, nullSequence)); }
@Deprecated public static LazyMapObjectInspector getLazySimpleMapObjectInspector( ObjectInspector mapKeyObjectInspector, ObjectInspector mapValueObjectInspector, byte itemSeparator, byte keyValueSeparator, Text nullSequence, boolean escaped, byte escapeChar) { return getLazySimpleMapObjectInspector(mapKeyObjectInspector, mapValueObjectInspector, itemSeparator, keyValueSeparator, new LazyObjectInspectorParametersImpl(escaped, escapeChar, false, null, null, nullSequence)); }
public static AbstractPrimitiveLazyObjectInspector<?> getLazyObjectInspector( PrimitiveTypeInfo typeInfo, boolean escaped, byte escapeChar, boolean extBoolean) { LazyObjectInspectorParameters lazyParams = new LazyObjectInspectorParametersImpl( escaped, escapeChar, extBoolean, null, null, null); return getLazyObjectInspector(typeInfo, lazyParams); }
protected void init(List<String> structFieldNames, List<ObjectInspector> structFieldObjectInspectors, List<String> structFieldComments, byte separator, Text nullSequence, boolean lastColumnTakesRest, boolean escaped, byte escapeChar) { LazyObjectInspectorParameters lazyParams = new LazyObjectInspectorParametersImpl(escaped, escapeChar, false, null, null, nullSequence, lastColumnTakesRest); init(structFieldNames, structFieldObjectInspectors, structFieldComments, separator, lazyParams); }
/** * Create a hierarchical ObjectInspector for ColumnarStruct with the given * columnNames and columnTypeInfos. * @throws SerDeException * * @see LazyFactory#createLazyObjectInspector(TypeInfo, byte[], int, Text, * boolean, byte) */ @Deprecated public static ObjectInspector createColumnarStructInspector( List<String> columnNames, List<TypeInfo> columnTypes, byte[] separators, Text nullSequence, boolean escaped, byte escapeChar) throws SerDeException { LazyObjectInspectorParametersImpl lazyParams = new LazyObjectInspectorParametersImpl( escaped, escapeChar, false, null, separators, nullSequence); return createColumnarStructInspector(columnNames, columnTypes, lazyParams); }
/** * Create a hierarchical ObjectInspector for LazyStruct with the given * columnNames and columnTypeInfos. * * @param lastColumnTakesRest * whether the last column of the struct should take the rest of the * row if there are extra fields. * @param extendedBooleanLiteral whether extended boolean literal set is legal * @throws SerDeException * @see LazyFactory#createLazyObjectInspector(TypeInfo, byte[], int, Text, * boolean, byte) */ @Deprecated public static ObjectInspector createLazyStructInspector( List<String> columnNames, List<TypeInfo> typeInfos, byte[] separators, Text nullSequence, boolean lastColumnTakesRest, boolean escaped, byte escapeChar, boolean extendedBooleanLiteral) throws SerDeException { LazyObjectInspectorParametersImpl lazyParams = new LazyObjectInspectorParametersImpl( escaped, escapeChar, extendedBooleanLiteral, null, separators, nullSequence, lastColumnTakesRest); return createLazyStructInspector(columnNames, typeInfos, lazyParams); }
/** * Create a hierarchical ObjectInspector for LazyObject with the given typeInfo. * * @param typeInfo The type information for the LazyObject * @param separators The array of separators for delimiting each level * @param separatorIndex The current level (for separators). List(array), struct uses 1 level of * separator, and map uses 2 levels: the first one for delimiting entries, the second one * for delimiting key and values. * @param nullSequence The sequence of bytes representing NULL. * @param extendedBooleanLiteral whether extended boolean literal set is legal * @param option the {@link ObjectInspectorOptions} * @return The ObjectInspector * @throws SerDeException */ @Deprecated public static ObjectInspector createLazyObjectInspector(TypeInfo typeInfo, byte[] separators, int separatorIndex, Text nullSequence, boolean escaped, byte escapeChar, boolean extendedBooleanLiteral, ObjectInspectorOptions option) throws SerDeException { LazyObjectInspectorParametersImpl lazyParams = new LazyObjectInspectorParametersImpl( escaped, escapeChar, extendedBooleanLiteral, null, separators, nullSequence); return createLazyObjectInspector(typeInfo, separatorIndex, lazyParams, option); }
/** * Initialize the SerDe given the parameters. serialization.format: separator * char or byte code (only supports byte-value up to 127) columns: * ","-separated column names columns.types: ",", ":", or ";"-separated column * types * * @see org.apache.hadoop.hive.serde2.AbstractSerDe#initialize(Configuration, Properties) */ @Override public void initialize(Configuration job, Properties tbl) throws SerDeException { super.initialize(job, tbl); serdeParams = new LazySerDeParameters(job, tbl, getClass().getName()); // Create the ObjectInspectors for the fields cachedObjectInspector = LazyFactory.createLazyStructInspector(serdeParams .getColumnNames(), serdeParams.getColumnTypes(), new LazyObjectInspectorParametersImpl(serdeParams)); cachedLazyStruct = (LazyStruct) LazyFactory .createLazyObject(cachedObjectInspector); serializedSize = 0; stats = new SerDeStats(); lastOperationSerialize = false; lastOperationDeserialize = false; }
@Deprecated public static LazySimpleStructObjectInspector getLazySimpleStructObjectInspector( List<String> structFieldNames, List<ObjectInspector> structFieldObjectInspectors, List<String> structFieldComments, byte separator, Text nullSequence, boolean lastColumnTakesRest, boolean escaped,byte escapeChar, ObjectInspectorOptions option) { return getLazySimpleStructObjectInspector(structFieldNames, structFieldObjectInspectors, structFieldComments, separator, new LazyObjectInspectorParametersImpl( escaped, escapeChar, false, null, null, nullSequence, lastColumnTakesRest), option); }
@Deprecated public static LazyMapObjectInspector getLazySimpleMapObjectInspector( ObjectInspector mapKeyObjectInspector, ObjectInspector mapValueObjectInspector, byte itemSeparator, byte keyValueSeparator, Text nullSequence, boolean escaped, byte escapeChar) { return getLazySimpleMapObjectInspector(mapKeyObjectInspector, mapValueObjectInspector, itemSeparator, keyValueSeparator, new LazyObjectInspectorParametersImpl(escaped, escapeChar, false, null, null, nullSequence)); }
protected void init(List<String> structFieldNames, List<ObjectInspector> structFieldObjectInspectors, List<String> structFieldComments, byte separator, Text nullSequence, boolean lastColumnTakesRest, boolean escaped, byte escapeChar) { LazyObjectInspectorParameters lazyParams = new LazyObjectInspectorParametersImpl(escaped, escapeChar, false, null, null, nullSequence, lastColumnTakesRest); init(structFieldNames, structFieldObjectInspectors, structFieldComments, separator, lazyParams); }
@Deprecated public static LazyUnionObjectInspector getLazyUnionObjectInspector( List<ObjectInspector> ois, byte separator, Text nullSequence, boolean escaped, byte escapeChar) { return getLazyUnionObjectInspector(ois, separator, new LazyObjectInspectorParametersImpl(escaped, escapeChar, false, null, null, nullSequence)); }
protected void init(List<String> structFieldNames, List<ObjectInspector> structFieldObjectInspectors, List<String> structFieldComments, byte separator, Text nullSequence, boolean lastColumnTakesRest, boolean escaped, byte escapeChar) { LazyObjectInspectorParameters lazyParams = new LazyObjectInspectorParametersImpl(escaped, escapeChar, false, null, null, nullSequence, lastColumnTakesRest); init(structFieldNames, structFieldObjectInspectors, structFieldComments, separator, lazyParams); }
@Deprecated public static LazyListObjectInspector getLazySimpleListObjectInspector( ObjectInspector listElementObjectInspector, byte separator, Text nullSequence, boolean escaped, byte escapeChar) { return getLazySimpleListObjectInspector(listElementObjectInspector, separator, new LazyObjectInspectorParametersImpl(escaped, escapeChar, false, null, null, nullSequence)); }
public static AbstractPrimitiveLazyObjectInspector<?> getLazyObjectInspector( PrimitiveTypeInfo typeInfo, boolean escaped, byte escapeChar, boolean extBoolean) { LazyObjectInspectorParameters lazyParams = new LazyObjectInspectorParametersImpl( escaped, escapeChar, extBoolean, null, null, null); return getLazyObjectInspector(typeInfo, lazyParams); }
@Deprecated public static LazyMapObjectInspector getLazySimpleMapObjectInspector( ObjectInspector mapKeyObjectInspector, ObjectInspector mapValueObjectInspector, byte itemSeparator, byte keyValueSeparator, Text nullSequence, boolean escaped, byte escapeChar) { return getLazySimpleMapObjectInspector(mapKeyObjectInspector, mapValueObjectInspector, itemSeparator, keyValueSeparator, new LazyObjectInspectorParametersImpl(escaped, escapeChar, false, null, null, nullSequence)); }