Win a copy of The Business Blockchain this week in the Cloud forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Anotation location

 
manu chaox
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

where is better to locate an annotation like @Id, @OneToMany etc., before field or getter ?
Could you give reason for it ?

Thanks
 
Cameron Wallace McKenzie
author and cow tipper
Saloon Keeper
Posts: 4968
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm seeing more and more implementations that put the annotation on the field.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic