class MessageBase implements Message<T, R> {

    protected Promise<R> verifyResult(Promise<R> result) {
        if (result == null) {
            AssertionError exception = new AssertionError("Actor methods are not allowed to return null");
            //noinspection UnnecessaryInitCause, have to support Java 1.6
            exception.initCause(mExceptionTemplate);
            throw exception;
        }
        return result;
    }

    protected  MessageBase(@NonNull ActorInvokeException exception);

}