org.apache.lens.lib.query
Class AbstractOutputFormatter
java.lang.Object
org.apache.lens.lib.query.AbstractOutputFormatter
- All Implemented Interfaces:
- QueryOutputFormatter
- Direct Known Subclasses:
- AbstractFileFormatter, WrappedFileFormatter
public abstract class AbstractOutputFormatter
- extends Object
- implements QueryOutputFormatter
Provides abstract implementation of the query output formatter.
In this it initializes column names, types column object inspectors Also provides methods to construct header from
serde
HEADER_TYPE
public static final String HEADER_TYPE
- The Constant HEADER_TYPE.
- See Also:
- Constant Field Values
AbstractOutputFormatter
public AbstractOutputFormatter()
init
public void init(QueryContext ctx,
LensResultSetMetadata metadata)
throws IOException
- Description copied from interface:
QueryOutputFormatter
- Initialize the formatter.
- Specified by:
init
in interface QueryOutputFormatter
- Parameters:
ctx
- The QueryContext
objectmetadata
- LensResultSetMetadata
object
- Throws:
IOException
- Signals that an I/O exception has occurred.
getMetadata
public LensResultSetMetadata getMetadata()
- Description copied from interface:
QueryOutputFormatter
- Get resultset metadata
- Specified by:
getMetadata
in interface QueryOutputFormatter
- Returns:
LensResultSetMetadata
Copyright © 2014–2015 Apache Software Foundation. All rights reserved.