public class DocumentAnalysisDAO
extends java.lang.Object
DocumentAnalysis by JPA queries.| Constructor and Description |
|---|
DocumentAnalysisDAO() |
| Modifier and Type | Method and Description |
|---|---|
static boolean |
contains(int year,
java.lang.String collection,
java.lang.String shelf,
javax.persistence.EntityManager em)
checks, whether a specific
DocumentAnalysis is in the database |
static double |
getAverageLoan(java.util.Hashtable<java.lang.String,java.lang.Integer> yearRange,
java.util.Hashtable<java.lang.String,java.lang.String> range,
java.lang.String collection,
javax.persistence.EntityManager em) |
static void |
persistDocumentAnalyses(java.util.List<DocumentAnalysis> analyses)
persists a list of
DocumentAnalysis objects to the database |
static void |
persistDocumentAnalysis(DocumentAnalysis analysis)
Persists a single
DocumentAnalysis to the database |
public static void persistDocumentAnalysis(DocumentAnalysis analysis)
DocumentAnalysis to the databaseanalysis - the document analysis to be persistedpublic static void persistDocumentAnalyses(java.util.List<DocumentAnalysis> analyses)
DocumentAnalysis objects to the databaseanalyses - the list of DocumentAnalysis objects to be persistedpublic static boolean contains(int year,
java.lang.String collection,
java.lang.String shelf,
javax.persistence.EntityManager em)
DocumentAnalysis is in the databaseyear - the year of the document analysiscollection - the collection of the document analyzedshelf - the shelf of the document analyzedem - the entity manager for the databasepublic static double getAverageLoan(java.util.Hashtable<java.lang.String,java.lang.Integer> yearRange,
java.util.Hashtable<java.lang.String,java.lang.String> range,
java.lang.String collection,
javax.persistence.EntityManager em)