class CompositeException extends RuntimeException {

    public List<Throwable> getCauses() {
        List<Throwable> causes = new ArrayList<>();
        causes.add(getCause());
        causes.addAll(Arrays.asList(getSuppressed()));
        return causes;
    }

    public  CompositeException(List<Throwable> causes);
    public  CompositeException(Throwable... causes);
    public  CompositeException(CompositeException other, Throwable toBeAppended);

}