MCPcopy Create free account
hub / github.com/OpenTSDB/asynchbase / getOpt

Method getOpt

test/Common.java:46–63  ·  view source on GitHub ↗
(final Class<?> klass, final String[] args)

Source from the content-addressed store, hash-verified

44 }
45
46 static HBaseClient getOpt(final Class<?> klass, final String[] args) {
47 if (args.length < 2) {
48 System.err.println("Usage: " + klass.getSimpleName()
49 + " <table> <family> [zkquorum] [znode]");
50 System.exit(1);
51 }
52 final String zkquorum;
53 if (args.length > 2) {
54 zkquorum = args[2];
55 } else {
56 zkquorum = "localhost";
57 }
58 if (args.length > 3) {
59 return new HBaseClient(zkquorum, args[3]);
60 } else {
61 return new HBaseClient(zkquorum); // Default znode
62 }
63 }
64
65}

Callers 4

mainMethod · 0.95
mainMethod · 0.95
setUpMethod · 0.95
preFlightTestMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected