Meta annotations for JPA?

I did not find meta annotations for JPA. Any way to define a custom annotation that works like a stereotype (something like):

@MyCustomAnnotation in the field equal to:

@ElementCollection
@CollectionTable(name="foo",joinColumns=@JoinColumn(name="foobar", referencedColumnName = "bar", nullable = true, insertable = false, updatable = false) )
@MapKeyColumn(name = "bla")
@Column(name = "bla")
+4
source share

Source: https://habr.com/ru/post/1653807/


All Articles