Hi Please help me.I have requirement like
In my project having arround 100 pojos .I have used @EntityListener and @prePersist annotaions to invoke my action class ..
But problem is how can i get oldvalue and new value of current form of pojo in side my @entity Listener Action class.
code snipt
=====
Action class
=======
public class AuditLogAction extends ActionSupport implements ModelDriven<IptAuditLog> { //public class AuditLogAction extends ActionSupport implements AuditorWare<IptAuditLog> @PrePersist public void prePersist(Object obj) { System.out.println("=========@PrePersist Annotation is called on iptAuditLog id: Before Saving Record into the Entity MAnager.=========="); } }
Pojo
====
@Entity @EntityListeners({AuditLogAction.class}) @Table(name = "IPT_AUDIT_LOG") public class IptAuditLog implements PKPersistence<Long> { }
in action runtime any pojo will come then what kind of pojo values can i capture inside prePersist() method