Siren4J v2.0.0 Release Notes

Release Date: 2017-02-26 // almost 8 years ago
  • A getter type method can now be directly tagged as a Siren4JProperty without the need of having an actual property exist. This is particularly useful for calculated property values.

    Example:

    @Siren4JProperty
    public void getUniqueName() {
       // Do something to calculate name  
       return uniqueName
    }
    

    Will end up with a property named "uniqueName" in the "properties" or the Siren response JSON output.

    You can also override the name of the outputted property by specifying it in the annotation
    @Siren4JProperty('differentPropertyName')


    The types for the following properties in the Field object have changed

    • max , min , and maxLength were changed from int to Integer and the default value is now null
    • step is now a String instead of int , to accommodate the "any" possible value. This is a possible breaking change as consumers will need to deal with the conversion from string to the appropriate integer value. The default value is null.

    ๐Ÿ›  Fixes:

    • ๐Ÿ‘ ReflectingConverter does not support getters that aren't backed by a field #11
    • Unset values no longer suppressed with Jackson 2.7.0 #27