Hibernate Annotations - Which is better, field or property access?

后端 未结 25 1601
说谎
说谎 2020-11-22 15:02

This question is somewhat related to Hibernate Annotation Placement Question.

But I want to know which is better? Access via properties or access vi

25条回答
  •  孤独总比滥情好
    2020-11-22 15:29

    i thinking about this and i choose method accesor

    why?

    because field and methos accesor is the same but if later i need some logic in load field, i save move all annotation placed in fields

    regards

    Grubhart

提交回复
热议问题