Is it possible to unpack Optional parameters?
So instead of doing this:
Optional provider = ...
if (provider.isPresent()) {
LOG.info("Detected container provider [{}] needs to be reloaded.",
provider.get());
return true;
}
I can just use the parameter directly
Optional provider = ...
if (pr
Hi Łukasz,
On Sat, 11 Mar 2023 at 10:36, Lukasz Lenart wrote:
> Is it possible to unpack Optional parameters?
Yes and no: the default message factories [1] and [2] do treat
`Optional` parameter as any other `Object` parameter.
In your case:
LOG.info("Detected container provider [{}] needs to b
sob., 11 mar 2023 o 13:51 Piotr P. Karwasz napisał(a):
> However I don't believe that this is the right way to go: IIRC
> `Optional.isPresent()` and `Optional.get()` should be replaced with a
> single call to `Optional.ifPresent()` whenever possible:
>
> provider.ifPresent(p -> {
> LOG.info("D
About dropping `ratchetFrom`, it is totally legitimate in my perspective.
`ratchetFrom` is often a good way to wire Spotless, delaying the big-bang
until the project is happy with spotless configuration.
> I am not against using other Github applications, especially if their code
is ASL.
> What do