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

com.github.phantomthief.concurrent.TryWaitUncheckedException Maven / Gradle / Ivy

There is a newer version: 0.1.55
Show newest version
package com.github.phantomthief.concurrent;

import java.util.Map;
import java.util.concurrent.CancellationException;
import java.util.concurrent.TimeoutException;

import javax.annotation.Nonnull;

/**
 * @author w.vela
 * Created on 2018-06-25.
 */
@SuppressWarnings("unchecked")
public class TryWaitUncheckedException extends RuntimeException {

    private final TryWaitResult result;

    TryWaitUncheckedException(TryWaitResult result) {
        this.result = result;
    }

    @Nonnull
    public  Map getSuccess() {
        return result.getSuccess();
    }

    @Nonnull
    public  Map getFailed() {
        return result.getFailed();
    }

    @Nonnull
    public  Map getTimeout() {
        return result.getTimeout();
    }

    @Nonnull
    public  Map getCancel() {
        return result.getCancel();
    }

    @Nonnull
    public  Map cancelAllTimeout(boolean mayInterruptIfRunning) {
        return result.cancelAllTimeout(mayInterruptIfRunning);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy