Package org.immutables.value
Annotation Type Value.Modifiable
-
@Documented @Target(TYPE) public static @interface Value.ModifiableGenerate modifiable implementation of abstract value class. Modifiable implementation class might be useful when you either need over-flexible builder or, alternatively, partially built representation of value type. This annotation could be used as companion toValue.Immutableto provide modifiable variant that is convertible back and forth to immutable form. When it is used in a standalone manner, i.e. without usingGenerated class will have name with "Modifiable" prefix by default which can be customizable using
"typeModifiable" style. Usecreate()factory method to create instances or using "new" operator which is also depends on"create" style. Generated modifiable class will have setter methods that returnthisfor chained invocation. Getters will be of the same shape as defined by abstract value types.Note: unlike @
Value.Immutable, this annotation has very little of additional "magic" and customisations implemented. Annotation likeValue.Include,Value.Enclosing,Value.Lazydo not work with modifiable implementationThis is beta functionality that is likely to change