check if the feed has changed by using publishDate of the feed or the first entry

This commit is contained in:
Athou
2013-04-19 11:51:40 +02:00
parent f8a7241bc1
commit 7502707930
5 changed files with 73 additions and 6 deletions

View File

@@ -1,6 +1,7 @@
package com.commafeed.backend.dao;
import java.util.Arrays;
import java.util.Collection;
import java.util.List;
import javax.annotation.PostConstruct;
@@ -38,13 +39,13 @@ public abstract class GenericDAO<T extends AbstractModel> {
em.persist(object);
}
public void save(List<T> objects) {
public void save(Collection<T> objects) {
for (Object object : objects) {
em.persist(object);
}
}
public void update(List<T> objects) {
public void update(Collection<T> objects) {
for (Object object : objects) {
em.merge(object);
}