You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tapestry.apache.org by "Ben Weidig (Jira)" <ji...@apache.org> on 2022/11/24 15:29:00 UTC
[jira] [Created] (TAP5-2743) PerThreadValue should provide more convenience methods
Ben Weidig created TAP5-2743:
--------------------------------
Summary: PerThreadValue<T> should provide more convenience methods
Key: TAP5-2743
URL: https://issues.apache.org/jira/browse/TAP5-2743
Project: Tapestry 5
Issue Type: Improvement
Components: tapestry-ioc
Reporter: Ben Weidig
The type org.apache.tapestry5.ioc.services.PerThreadValue<T> should provide more convenience methods like Map does, e. g.:
* {{T computeIfAbsent(Supplier<? super T> fn)}}
* {{TÂ }}{{computeIfPresent(Function<? super T, ? extends T> fn)}}
* {{{}T compute{}}}{{{}(Function<? super T, ? extends T> fn){}}}{{{}{}}}
I believe these methods would simplify using PerThreadValue and they should be implementable with default methods directly on the interface.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)