All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.avaje.validation.MixIn Maven / Gradle / Ivy

Go to download

validator for annotated pojos using constraint annotations and source code generation

There is a newer version: 2.4
Show newest version
package io.avaje.validation;

import static java.lang.annotation.ElementType.TYPE;
import static java.lang.annotation.RetentionPolicy.SOURCE;

import java.lang.annotation.Retention;
import java.lang.annotation.Target;

/**
 * Marks this Class as a MixIn Type that can add/modify constraint annotations on the specified type.
 * 

* These types are typically in an external project / dependency or otherwise * types that we can't explicitly annotate or modify. *

* In the example below, the VehicleMixin class augments the the generated Vehicle * adapter to add a @NotBlank annotation to the type property. * *

{@code
 *
 *   @MixIn(Vehicle.class)
 *   public abstract class VehicleMixIn {
 *
 *   @NotBlank
 *   private String type;
 *    ...
 *
 * }
*/ @Target(TYPE) @Retention(SOURCE) public @interface MixIn { /** The concrete type to mix. */ Class value(); }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy