HI!

I noticed due to JDK 11 there is a subtile change in handling of final fields and initialization.

On rare cases we used final fields including @Property(write = false), which is no longer working. Example:

    @Property(write="false") private final String[] _keys = new String[] {
        "A", "B", "C"
    };

This allowed us to initialize the field once, but still access it from the page (tml). Using JDK 11 and T5.8.x this now throws an exception. But modifying it to

    private static final String[] _keys = new String[] {
        "A", "B", "C"
    };

    public String[] getKeys() {
        return _keys;
    };

requires an additional instance method, because @Property can't handle static fields. Are there any plans to solve it by Tapestry itself (eg to add this "get" method automatically while class transformation is applyed in case a field is marked as static and and property)?

Currently I do not see another workaround apart rewriting parts like this, right?

Thanks

Jens



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to