All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.zeromq.ZMQException Maven / Gradle / Ivy

There is a newer version: 0.6.0
Show newest version
package org.zeromq;

import zmq.ZError;

public class ZMQException extends RuntimeException
{
    private static final long serialVersionUID = -978820750094924644L;

    private final int code;

    public ZMQException(int errno)
    {
        super("Errno " + errno);
        code = errno;
    }

    public ZMQException(String message, int errno)
    {
        super(message);
        code = errno;
    }

    public int getErrorCode()
    {
        return code;
    }

    @Override
    public String toString()
    {
        return super.toString() + " : " + ZError.toString(code);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy