File tree Expand file tree Collapse file tree 1 file changed +19
-1
lines changed
jsonb/src/main/java/io/avaje/jsonb Expand file tree Collapse file tree 1 file changed +19
-1
lines changed Original file line number Diff line number Diff line change 225225
226226 }
227227
228- /** Marks a Class as a MixIn class. */
228+ /**
229+ * Mark this Class as a MixIn Type that can add Jsonb Annotations on the specified type.
230+ * <p>
231+ * These types are typically in an external project / dependency or otherwise
232+ * types that we can't or don't want to explicitly annotate with {@code @Json}.
233+ * <p>
234+ * In the example below, the VehicleMixin class augments the the generated Vehicle JsonB adapter to use "ford-type" as the json property.
235+ *
236+ * <pre>{@code
237+ *
238+ * @Json.MixIn(Vehicle.class)
239+ * public abstract class VehicleMixIn {
240+ *
241+ * @Json.Property("ford-type")
242+ * private String type;
243+ * ...
244+ *
245+ * }</pre>
246+ */
229247 @ Retention (CLASS )
230248 @ Target ({ElementType .TYPE })
231249 @interface MixIn {
You can’t perform that action at this time.
0 commit comments