|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.lang.Throwable java.lang.Exception org.apache.zookeeper.KeeperException
public abstract class KeeperException
Constructor Summary | |
---|---|
KeeperException(KeeperException.Code code)
|
Method Summary | |
---|---|
KeeperException.Code |
code()
Read the error Code for this exception |
static KeeperException |
create(int code)
Deprecated. deprecated in 3.1.0, use create(Code)
instead |
static KeeperException |
create(int code,
String path)
Deprecated. deprecated in 3.1.0, use create(Code, String)
instead |
static KeeperException |
create(KeeperException.Code code)
All non-specific keeper exceptions should be constructed via this factory method in order to guarantee consistency in error codes and such. |
static KeeperException |
create(KeeperException.Code code,
String path)
All non-specific keeper exceptions should be constructed via this factory method in order to guarantee consistency in error codes and such. |
int |
getCode()
Deprecated. deprecated in 3.1.0, use code() instead |
String |
getMessage()
|
String |
getPath()
Read the path for this exception |
List<org.apache.zookeeper.OpResult> |
getResults()
If this exception was thrown by a multi-request then the (partial) results and error codes can be retrieved using this getter. |
void |
setCode(int code)
Deprecated. deprecated in 3.1.0, exceptions should be immutable, this method should not be used |
Methods inherited from class java.lang.Throwable |
---|
fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public KeeperException(KeeperException.Code code)
Method Detail |
---|
public static KeeperException create(KeeperException.Code code, String path)
code
- The error code.path
- The ZooKeeper path being operated on.
@Deprecated public static KeeperException create(int code, String path)
create(Code, String)
instead
@Deprecated public static KeeperException create(int code)
create(Code)
instead
public static KeeperException create(KeeperException.Code code)
code
- The error code of your new exception. This will
also determine the specific type of the exception that is
returned.
@Deprecated public void setCode(int code)
code
- error code@Deprecated public int getCode()
code()
instead
public KeeperException.Code code()
public String getPath()
public String getMessage()
getMessage
in class Throwable
public List<org.apache.zookeeper.OpResult> getResults()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |