[jira] [Commented] (LANG-1477) Implement castToXXX in Functions class

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[jira] [Commented] (LANG-1477) Implement castToXXX in Functions class

ASF GitHub Bot (Jira)

    [ https://issues.apache.org/jira/browse/LANG-1477?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16913661#comment-16913661 ]

Jochen Wiedmann commented on LANG-1477:
---------------------------------------

Is this, what you had in mind?

 

[https://gitbox.apache.org/repos/asf?p=commons-lang.git;a=commit;h=bc16e0109a30b819c50895e157830fe9b3f8e93f]

 

> Implement castToXXX in Functions class
> --------------------------------------
>
>                 Key: LANG-1477
>                 URL: https://issues.apache.org/jira/browse/LANG-1477
>             Project: Commons Lang
>          Issue Type: Bug
>          Components: lang.*
>    Affects Versions: 3.9
>            Reporter: Peter Verhas
>            Priority: Minor
>              Labels: newbie
>   Original Estimate: 168h
>  Remaining Estimate: 168h
>
> Proposal to implement functional interface conversion functions in the class {{org.apache.commons.lang3.Functions}} that convert {{FailableXXX}} to {{XXX}}.
> For example, the FailableRunnable can be converted with the method:
>  
> {code:java}
> static <K extends Throwable> Runnable castToRunnable(FailableRunnable<K> s) {
>    return () -> run(s);
> }{code}
>  
>  



--
This message was sent by Atlassian Jira
(v8.3.2#803003)