class ServiceResult extends BaseFailingOrSucceedingResult<T, ServiceFailure> implements Serializable {

    public static <T> ServiceResult<List<T>> aggregate(final List<ServiceResult<T>> input) {
        return BaseFailingOrSucceedingResult.aggregate(
                input,
                (f1, f2) -> new ServiceFailure(combineLists(f1.getErrors(), f2.getErrors())),
                serviceSuccess(emptyList()));
    }

    private  ServiceResult(Either<ServiceFailure, T> result);

}