Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/hibernate/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java 如何在hibernate中从集合中添加或删除哪些元素_Java_Hibernate_Spring Data Jpa_Hibernate Mapping - Fatal编程技术网

Java 如何在hibernate中从集合中添加或删除哪些元素

Java 如何在hibernate中从集合中添加或删除哪些元素,java,hibernate,spring-data-jpa,hibernate-mapping,Java,Hibernate,Spring Data Jpa,Hibernate Mapping,我已经在hibernate中实现了PostCollectionUpdateEventListener,我想知道有没有办法找出集合中更改的数据 PersistentCollection collection = event.getCollection(); collection.getValue(); 这给了我想要的结果

我已经在hibernate中实现了PostCollectionUpdateEventListener,我想知道有没有办法找出集合中更改的数据

PersistentCollection collection = event.getCollection();

collection.getValue();
这给了我想要的结果