super();
this.hasTimestamp = false;
this.theTable="content_x_media";
+ try { this.theEntityClass = Class.forName("mir.entity.GenericEntity"); }
+ catch (Exception e) { throw new StorageObjectException(e.toString()); }
}
/**
throw new StorageObjectException("-- hasMedia failed: content is NULL");
}
}
-
+
super();
this.hasTimestamp = false;
this.theTable="content_x_topic";
+ try { this.theEntityClass = Class.forName("mir.entity.GenericEntity"); }
+ catch (Exception e) { throw new StorageObjectException(e.toString()); }
+
}
/**
}
return returnList;
}
-
+
/**
* Returns a ArrayList of Integer-Objects from a content-id.
* @returns ArrayList
Collection hasTopics = getTopicsOfContent(contentId);
Collection toSet = new ArrayList();
Collection toDelete = new ArrayList();
-
+
if(hasTopics!=null && hasTopics.size()>0){
//now we check if there are new topics and copy them to an array.
for(int i = 0; i< topicId.length;i++){
toSet.add(topicId[i]);
}
}
-
+
//first delete all row with content_id=contentId
String sql = "delete from "+ theTable +" where content_id=" + contentId
+ " and topic_id in (";