use of mom.trd.opentheso.bdd.helper.ToolsHelper in project opentheso by miledrousset.
the class ImportSkosHelper method getNewId.
private String getNewId() {
ConceptHelper conceptHelper = new ConceptHelper();
ToolsHelper toolsHelper = new ToolsHelper();
String id = toolsHelper.getNewId(10);
while (conceptHelper.isIdExiste(ds, id, thesaurus.getId_thesaurus())) {
id = toolsHelper.getNewId(10);
}
return id;
}
use of mom.trd.opentheso.bdd.helper.ToolsHelper in project opentheso by miledrousset.
the class ImportRdf4jHelper method getNewGroupId.
private String getNewGroupId() {
GroupHelper groupHelper = new GroupHelper();
ToolsHelper toolsHelper = new ToolsHelper();
String id = toolsHelper.getNewId(10);
while (groupHelper.isIdOfGroup(ds, id, thesaurus.getId_thesaurus())) {
id = toolsHelper.getNewId(10);
}
return id;
}
use of mom.trd.opentheso.bdd.helper.ToolsHelper in project opentheso by miledrousset.
the class SelectedThesaurus method regenerateOrphan.
/**
* Cette fonction permet de regénérer les Orphelins
*
* @return
*/
public boolean regenerateOrphan() {
if (thesaurus.getLanguage() == null || thesaurus.getId_thesaurus() == null) {
return false;
}
if (!new ToolsHelper().orphanDetect(connect.getPoolConnexion(), thesaurus.getId_thesaurus())) {
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(FacesMessage.SEVERITY_ERROR, langueBean.getMsg("error"), "error"));
vue.setRegenerateOrphan(0);
return false;
}
return true;
}
use of mom.trd.opentheso.bdd.helper.ToolsHelper in project opentheso by miledrousset.
the class SelectedThesaurus method removeLoopRelations.
private void removeLoopRelations() {
if (thesaurus.getLanguage() == null || thesaurus.getId_thesaurus() == null) {
return;
}
new ToolsHelper().removeLoopRelations(connect.getPoolConnexion(), "BT", thesaurus.getId_thesaurus());
new ToolsHelper().removeLoopRelations(connect.getPoolConnexion(), "NT", thesaurus.getId_thesaurus());
new ToolsHelper().removeLoopRelations(connect.getPoolConnexion(), "RT", thesaurus.getId_thesaurus());
}
Aggregations