You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Martin Grigorov (JIRA)" <ji...@apache.org> on 2017/06/13 11:09:00 UTC

[jira] [Resolved] (WICKET-6396) Model should provide other Optional's methods

     [ https://issues.apache.org/jira/browse/WICKET-6396?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Martin Grigorov resolved WICKET-6396.
-------------------------------------
    Resolution: Won't Fix

It has never been a target to make IModel API as `java.util.Optional`.
Those methods could be implemented but they do not make any sense for Wicket.

If you have a good use case for any of them then we can reconsider and reopen!

> Model should provide other Optional's methods
> ---------------------------------------------
>
>                 Key: WICKET-6396
>                 URL: https://issues.apache.org/jira/browse/WICKET-6396
>             Project: Wicket
>          Issue Type: Improvement
>    Affects Versions: 8.0.0-M6
>            Reporter: Kamil
>            Priority: Minor
>
> Model should provide
> {code}
> public <X extends Throwable> T orElseThrow(Supplier<? extends X> exceptionSupplier) throws X;
> {code}
> {code}
> public boolean isPresent();
> {code}
> {code}
> public void ifPresent(Consumer<? super T> consumer);
> {code}
> methods for the sake of consistency with Optional API



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)