public abstract class HiveFileProcessor extends Object implements IHiveFileProcessor
| Constructor and Description |
|---|
HiveFileProcessor() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract BufferedReader |
loadFile(String fileName)
load commands into buffered reader from the file
|
protected abstract int |
processCmd(String cmd)
define the processor for each Hive command supported by Hive
|
int |
processFile(String fileName)
Parse the file and execute the Hive commands in it.
|
protected int |
processLine(String line)
process the Hive command by lines
|
protected int |
processReader(BufferedReader reader)
execute the buffered reader which stores the commands
|
public int processFile(String fileName) throws IOException
IHiveFileProcessorprocessFile in interface IHiveFileProcessorfileName - the name of the fileIOException - if an I/O error occurs.protected abstract BufferedReader loadFile(String fileName) throws IOException
fileName - IOExceptionprotected int processReader(BufferedReader reader) throws IOException
reader - the buffered readerIOExceptionprotected int processLine(String line)
line - contains a legal Hive commandprotected abstract int processCmd(String cmd)
cmd - Copyright © 2019 The Apache Software Foundation. All Rights Reserved.