use of mom.trd.opentheso.bdd.helper.StatisticHelper in project opentheso by miledrousset.
the class StatBean method findCptByGroup.
/**
* méthode pour charger des concepts en filtrant par un groupe
* #JM
* @param idTheso
* @param langue
*/
public void findCptByGroup(String idTheso, String langue) {
if (this.selectedGroup == null) {
this.selectedGroup = this.statGroup.get(0);
}
String group = this.selectedGroup.split("\\(")[1];
group = group.replace(")", "");
statConcept = new StatisticHelper().getStatConceptByGroupAndDate(connect.getPoolConnexion(), "" + new java.sql.Date(0), "" + new Date(), "created", idTheso, lang, group, this.limit);
}
use of mom.trd.opentheso.bdd.helper.StatisticHelper in project opentheso by miledrousset.
the class StatBean method loadStatTheso.
public void loadStatTheso(String idTheso, String langue) {
statTheso = new ArrayList<>();
nbCpt = new StatisticHelper().getNbCpt(connect.getPoolConnexion(), idTheso);
ArrayList<NodeGroup> lng = new GroupHelper().getListConceptGroup(connect.getPoolConnexion(), idTheso, langue);
Collections.sort(lng);
StatisticHelper sh = new StatisticHelper();
for (NodeGroup ng : lng) {
NodeStatTheso nst = new NodeStatTheso();
nst.setGroup(ng.getLexicalValue() + "(" + ng.getConceptGroup().getIdgroup() + ")");
nst.setNbDescripteur(sh.getNbDescOfGroup(connect.getPoolConnexion(), idTheso, ng.getConceptGroup().getIdgroup()));
nst.setNbNonDescripteur(sh.getNbNonDescOfGroup(connect.getPoolConnexion(), idTheso, ng.getConceptGroup().getIdgroup(), langue));
int termNonTraduit = nst.getNbDescripteur() - sh.getNbTradOfGroup(connect.getPoolConnexion(), idTheso, ng.getConceptGroup().getIdgroup(), langue);
nst.setNbNoTrad(termNonTraduit);
int nombreNote = sh.getNbDefinitionNoteOfGroup(connect.getPoolConnexion(), idTheso, langue, ng.getConceptGroup().getIdgroup());
nst.setNbNotes(nombreNote);
statTheso.add(nst);
}
vue.setStatTheso(true);
vue.setStatCpt(false);
vue.setStatPermuted(false);
}
use of mom.trd.opentheso.bdd.helper.StatisticHelper in project opentheso by miledrousset.
the class showPermuted method loadStatPermuted.
public void loadStatPermuted(String idTheso, String idLange) throws SQLException {
Thesaurus datatheso = new Thesaurus();
Connexion conn = new Connexion();
String id_theso = datatheso.getId_thesaurus();
String langue = datatheso.getLanguage();
statTheso = new ArrayList<>();
ArrayList<NodeGroup> lng = new GroupHelper().getListConceptGroup2(connect.getPoolConnexion(), idTheso, idLange);
StatisticHelper sh = new StatisticHelper();
for (NodeGroup ng : lng) {
prendrePermuted nst = new prendrePermuted();
nst.setOrd(ng.getOrde());
nst.setId_concept(ng.getId_concept());
nst.setId_group(ng.getId_group());
nst.setId_theso(idTheso);
nst.setId_lang(idLange);
nst.setLexical_value(ng.getLexicalValue());
nst.setIspreferredterm(ng.isIspreferredterm());
nst.setOriginal_value(ng.getOriginal_value());
statTheso.add(nst);
}
vue.setStatPermuted(true);
vue.setStatTheso(false);
vue.setStatCpt(false);
}
use of mom.trd.opentheso.bdd.helper.StatisticHelper in project opentheso by miledrousset.
the class SelectedTerme method getTheNbConceptOfBranch.
/**
* Fonction pour trouver le nombre des concepts dans une branche
*
* @return
*/
public String getTheNbConceptOfBranch() {
if (totalConceptOfBranch.isEmpty()) {
StatisticHelper statisticHelper = new StatisticHelper();
int tot = statisticHelper.getConceptCountOfBranch(connect.getPoolConnexion(), idC, idTheso);
totalConceptOfBranch = "" + tot;
}
return totalConceptOfBranch;
}
Aggregations