@Retention(SOURCE)
@Target({TYPE,PACKAGE,MODULE})
@Documented
public @interface JStacheFormatterTypes
Statically sets allowed formatting types.
If a type is not allowed or known and used as a variable a compile error will happen. This annotation allows you to change that behavior by adding types.
By default the only allowed (and always allowed) types to be formatted are:
Config lookup and precedence is as follows:
- type annotated with JStache and this annotation.
- enclosing class (of type annotated with JStache) with this annotation with inner to outer order.
- package annotated with this annotation.
- module annotated with this annotation.
- the chosen formatter with this annotation.
- Author:
- agentgt
- See Also:
- API Note
- n.b. the retention policy is SOURCE as this settings are only needed for the
compiler and why it is not in
JStacheConfig
.
-
Optional Element Summary
-
Element Details
-
types
Whitelist classes that will be allowed to be passed to the formatter.- Returns:
- Allowed classes that will be passed to the formatter.
- Default:
- {}
-
patterns
List of regex used to match whitelist class names that are allowed to be formatted.- Returns:
- regex used to match class names that are allowed to be formatted.
- Default:
- {}
-