Package org.immutables.generator
Annotation Type Generator.Typedef
-
@Target(FIELD) public static @interface Generator.TypedefUsed to introduce complex types as simple type names available to template language. Annotate fields with this annotations to introduce such typedef. Fields should be named starting with uppercase, so template will recognize it as type identifier.@Generator.Typedef java.util.Map.Entry<String, String> Pair;
In the example above, new type Pair will be introduced in template and will serve as alias to declared generic Map.Entry type of the fields. Field's value doesn't matter and can be left uninitialized).