<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;">Hi,<div><br></div><div>I was just wondering if any thought has been put into providing a standard approach to validating input? Something like ValidatorFX for example [1]? There have been attempts at solving this in ControlsFX but that one was too heavily bound to the actual controls while ValidatorFX works on anything that is observable. I have been using it now for several years in our CRM desktop application and I feel like it is striking a perfect balance between being flexible and easy to use.</div><div><br></div><div>Small / incomplete example:</div><div><br></div><div><div style="caret-color: rgb(0, 0, 0); color: rgb(0, 0, 0);"><span class="Apple-tab-span" style="white-space: pre;"> </span>TextField userTextField = new TextField();</div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>Validator validator = new Validator();</div><div> validator.createCheck()</div><div> .dependsOn("username", userTextField.textProperty())</div><div> .withMethod(c -> {</div><div><span class="Apple-tab-span" style="white-space:pre"> </span> String userName = c.get("username");</div><div> <span class="Apple-tab-span" style="white-space:pre"> </span> if (!userName.toLowerCase().equals(userName)) {</div><div> <span class="Apple-tab-span" style="white-space:pre"> </span> c.error("Please use only lowercase letters.");</div><div> <span class="Apple-tab-span" style="white-space:pre"> </span>}</div><div> <span class="Apple-tab-span" style="white-space:pre"> </span>})</div><div> .decorates(userTextField)</div><div> .immediate();</div><div><br></div><div>I know that one can easily say “just use the library” but I think that not everybody will find it and it also is nice to have a standard way of doing things.</div><div><br></div><div>Dirk</div><div><br></div><div>[1] <a href="https://github.com/effad/ValidatorFX">https://github.com/effad/ValidatorFX</a></div><div><br></div></div></body></html>