Immutables v1.1 Release Notes
Release Date: 2014-12-27 // over 9 years ago-
๐ Features
- #53 Implemented
SortedSet
/NavigableSet
/SortedMap
/NavigableMap
attributes specifying@Value.NaturalOrder
or@Value.ReverseOrder
annotation. Idea contributed by Facebook Buck team. Thanks! - #63
@Value.Builder
: implemented standalone builder generations for static factory methods. This makes it possible to create builders for arbitrary factory methods, including google/AutoValue create methods! - ๐ฆ #38
@Value.Immutable.Include
: Ability to include other classes even from different packages and libraries as abstract value types. Think of generating immutable implementation of annotations from different library! - ๐
#33
@Value.Style
: insanely flexible style customization infrastructure now allows to tailor generated immutable types and builders to wide range of style and preferences!@BeanStyle.Accessors
is example of style annotations - allows accessors to be detected from with 'get' and 'is' prefixes, so prefix will be stripped on builder and in toString.
- ๐ #35
@Nullable
attributes. Support any annotation namedNullable
. Thanks to John Wood for this and other valuable feature and bug reports! - ๐ #44 Ability to run generated classes on JDK6 (including runtime support library
common
). JDK7 is still required to run annotation processor. Credits to Trask Stalnaker for the contribution! - ๐ Improved code generation: more clean code, more useful javadocs, dozens of fixes to edge cases, more correctness for customized value types.
- #64
org.immutables.json-runtime
minimal JSON runtime jar, extracted fromcommon
with only necessary transitive Jackson dependencies. - #54 Support for including Jackson marshaled POJOs as attributes of
@Json.Marshaled
immutable objects. Together with@Jackson.Mapped
this provides round-tripping from Immutables' marshalers to Jackson and back.
๐ Changes
- ๐ Dozens of fixes, including
- #61 Partially fixed
@Value.Default
methods on Java 8 implemented with interfacedefault
methods. Known issue is with more complex interface inheritance #67 - #48 JDBI marshaling fixes
- #50 Support for older versions of Guava, which did not have
MoreObjects
for example, detected from classpath. Checked with Guava v12, v16 - Fixed resolution of accesors inherited from couple of interfaces. (Still do not take into account most specific covariant override)
- #61 Partially fixed
- ๐ Deprecations
- Deprecated
@Value.Immutable(nonpublic)
in favor of@Value.Immutable(visibility)
, nonpublic not working now, but it should not break - Deprecated
@Value.Immutable(withers)
in favor of@Value.Immutable(copy)
- Deprecated
@Value.Getters
in favor of using@Value.Style
. May be undeprecated if found really useful - Removed underdeveloped annotations and processors to be reintroduced later (Transformer, Visitor, Parboiled)
- Deprecated
- Incompatibilites
- Upgrade to Jackson 2.4.4 for Jackson
ObjectMapper
cross-marshaling to work - Possible incompatibity:
@Json.Marshaled
now is required on each nested@Value.Immutable
, marshaled annotation on@Value.Nested
will not have effect - #59
@Value.Default
on collection attributes now issues warning, that makes collection attribute generated as plain regular attributes without any special collection support in builder
- Upgrade to Jackson 2.4.4 for Jackson
- #53 Implemented