Feedback on the implementation of StringJoiner
Henry Jen
henry.jen at oracle.com
Fri Dec 14 09:06:23 PST 2012
On Dec 14, 2012, at 2:24 AM, Stephen Colebourne <scolebourne at joda.org> wrote:
> On 13 December 2012 19:14, Henry Jen <henry.jen at oracle.com> wrote:
>
> So, why is this class not final?
>
> I'm struggling to think of a case where extending it would be useful,
> and making it final generally makes it safer.
>
There are something we decided not needed but probably not for others, for example, while we believe most use cases coming from stream, and use alternative representation for empty or null elements should be done outside the joiner, one may choose to extend the joiner to support that in general.
Sure that can also be implemented via delegation, just to illustrate a possibility.
Cheers,
Henry
More information about the lambda-dev
mailing list