从本节,我将分五章贴出相应的源码:业务回调接口(LockListener)、协议支持父类(ProtocolSupport)、节点操作接口(ZookeeperOperation)、节点(ZNodeName)、锁(WriteLock)
LockListener:
public interface LockListener {
/**
* call back called when the lock
* is acquired
*/
public void lockAcquired();
/**
* call back called when the lock is
* released.
*/
public void lockReleased();
}