Package org.apache.zookeeper
Class ZooKeeperMain
java.lang.Object
org.apache.zookeeper.ZooKeeperMain
The command line client to ZooKeeper.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddToHistory(int i, String cmd) Makes a list of possible completions, either for commands or for zk nodes if the token to complete begins with /protected voidconnectToZK(String newHost) voidexecuteLine(String line) booleanprotected Stringstatic voidstatic voidprintMessage(String msg) protected booleanprocessCmd(org.apache.zookeeper.ZooKeeperMain.MyCommandOptions co) protected booleanprocessZKCmd(org.apache.zookeeper.ZooKeeperMain.MyCommandOptions co)
-
Field Details
-
cl
protected org.apache.zookeeper.ZooKeeperMain.MyCommandOptions cl -
history
-
commandCount
protected int commandCount -
printWatches
protected boolean printWatches -
exitCode
protected int exitCode -
zk
-
host
-
-
Constructor Details
-
ZooKeeperMain
- Throws:
IOExceptionInterruptedException
-
ZooKeeperMain
-
-
Method Details
-
getPrintWatches
public boolean getPrintWatches() -
addToHistory
Makes a list of possible completions, either for commands or for zk nodes if the token to complete begins with / -
getCommands
-
getPrompt
-
printMessage
-
connectToZK
- Throws:
InterruptedExceptionIOException
-
main
- Throws:
IOExceptionInterruptedException
-
executeLine
- Throws:
InterruptedExceptionIOException
-
processCmd
protected boolean processCmd(org.apache.zookeeper.ZooKeeperMain.MyCommandOptions co) throws IOException, InterruptedException - Throws:
IOExceptionInterruptedException
-
processZKCmd
protected boolean processZKCmd(org.apache.zookeeper.ZooKeeperMain.MyCommandOptions co) throws CliException, IOException, InterruptedException
-