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

Gary D. Gregory commented on LANG-1704:
---------------------------------------

The API should stay as extensible, the use cases are:
- Allow typed subclasses, for example, MyCustomPair extends ImmutablePair<Foo, 
Bar>
- Allow inline subclasses, for example, new ImmutablePair(foo, bar) \{ some 
overrides \} (handy when writing tests).

I have use cases for both of these (at work).


> ImmutablePair and ImmutableTriple not actually final as documented
> ------------------------------------------------------------------
>
>                 Key: LANG-1704
>                 URL: https://issues.apache.org/jira/browse/LANG-1704
>             Project: Commons Lang
>          Issue Type: Bug
>          Components: lang.tuple.*
>    Affects Versions: 3.13.0
>            Reporter: Dan Ziemba
>            Priority: Minor
>
> As of commons-lang3 3.13.0, the ImmutablePair and ImmutableTriple classes are 
> no longer final, even though their javadocs claim that they are. This is a 
> problem because you can now subclass those and, for example, make an 
> effectively mutable object that could be passed to a method with a parameter 
> of type ImmutablePair.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to