/** * Changes all texts recursively. * * @param modifier A function that take content and returns new content. * @param recurse If {@code true}, then this is applied recursively. */ public default void changeTexts(Function<String, String> modifier, boolean recurse) { changeTexts(modifier); if (recurse) { for (final Element child : getElements()) { child.changeTexts(modifier, true); } } }