class Result implements ImmutableBean, Serializable {

  public void ifSuccess(Consumer<? super T> consumer) {
    if (value != null) {
      consumer.accept(value);
    }
  }

  private  Result(T value);
  private  Result(Failure failure);
  private  Result(
      T value,
      Failure failure);

}