Code example for Joiner

Methods: join

public class TestZookeeperLockManager { 
  private static final Joiner SLASH = Joiner.on("/");
  private static final String PARENT = "hive";
  private static final String TABLE = "t1";
  private static final String PARENT_LOCK_PATH = SLASH.join("", PARENT, TABLE);
  private static final String TABLE_LOCK_PATH =  SLASH.join("", PARENT, TABLE, "00001");
  private HiveConf conf;
  private ZooKeeper zooKeeper;
  private HiveLockObject hiveLock;
  private ZooKeeperHiveLock zLock;
  public void setup() { 
    conf = new HiveConf();
    zooKeeper = mock(ZooKeeper.class);
    hiveLock = mock(HiveLockObject.class);
    zLock = new ZooKeeperHiveLock(TABLE_LOCK_PATH, hiveLock, HiveLockMode.SHARED);
Connect your IDE to all the code out there  Get Codota for Java