jSparrow v3.10.0/v2.7.0

A nova regra Optional.ifPresentOrElse melhora a legibilidade e permite o uso de funções de ordem superior.
Novembro 6, 2019
Nova versão

Recursos

New Rule - Use Optional::ifPresentOrElse (for Java 9 and above).

  • In Java 9, the Optional API has been extended with the Optional#ifPresentOrElse method. jSparrow replaces if-then-else statements, checking for Optional#isPresent , with a single invocation of Optional#ifPresentOrElse.
    This improves the readability of the code and enables the usage of higher order functions with Optional.
Optional::ifPresentOrElse rule in jSparrow.

jSparrow

Refatoração automática de Java.

Tem alguma pergunta?

Chat ao vivo com nossos especialistas de licenciamento de jSparrow.