Example usage for org.apache.zookeeper Op withChroot

List of usage examples for org.apache.zookeeper Op withChroot

Introduction

In this page you can find the example usage for org.apache.zookeeper Op withChroot.

Prototype

abstract Op withChroot(String addRootPrefix);

Source Link

Document

Reconstructs the transaction with the chroot prefix.

Usage

From source file:org.lab.mars.onem2m.ZooKeeper.java

License:Apache License

private Op withRootPrefix(Op op) {
    if (null != op.getPath()) {
        final String serverPath = prependChroot(op.getPath());
        if (!op.getPath().equals(serverPath)) {
            return op.withChroot(serverPath);
        }//ww w .j  av  a  2  s  .c o  m
    }
    return op;
}