private static String _resetCriteria(List<Criteria> listeCriteria){
    StringBuilder sb = new StringBuilder();
    sb.append("/**\n");
    sb.append(" * Réinitialise les critères de recherche\n");
    sb.append(" * \n");
    sb.append(" * @param criteriaEntity l'entité contenant les critères de recherche\n");
    sb.append(" * @throws ModelException erreur technique survient lors d'un traitement dans le modèle interne\n");
    sb.append(" */\n");
    sb.append(" private void _resetCriteria(final BaseEntity<"+name+"CriteriaBean> criteriaEntity)\n");
    sb.append("                                                                                            throws ModelException {\n");
    sb.append("   \n");
    sb.append("   \n");
    sb.append(" // Alimentation initiale des entités mémoire\n");
    sb.append("  ((MemoryBasedStorageModule<"+name+"CriteriaBean>) criteriaEntity.getController()\n");
    sb.append("                                                                            .getOccurrenceGroupStorageModule()).createSingleOccurrenceGroup(null,\n");
    sb.append("                                                                                                                                            null,\n");
    sb.append("                                                                                                                                            OccurrenceStatus.INITED);\n");
    sb.append("                                                                                                                                            \n");
    sb.append("  final "+name+"CriteriaBean criteria = criteriaEntity.getOccurrence();\n");
    sb.append("  getModelObject(criteria).setMonitoringChanges(false);\n");
    sb.append("  \n");
    
    
    //@TODO traiter les PAESI TOESO TOTIE...
    for (Criteria critere : listeCriteria) {
      if (critere.getType().equalsIgnoreCase("Boolean") && critere.isCocheeParDefaut()){
        sb.append("  criteria.set"+critere.getNom()+"("+critere.isCocheeParDefaut()+");\n");
      }else if (critere.getComposantMetier()!=null && !critere.getComposantMetier().getType().isEmpty()){
        sb.append("  criteria.set"+critere.getComposantMetier().getType().toUpperCase()+"(new "+critere.getComposantMetier().getType().toUpperCase()+"Criterion());\n");
      }
      else if (critere.getType().equalsIgnoreCase("Date") && critere.isDateInitialisee()){
        sb.append("  criteria.set"+critere.getNom()+"(DateTools.getInstance().getToday());\n");
      }
      else{
        sb.append("  criteria.set"+critere.getNom()+"(null);\n");
      }
      
    }
    
    sb.append("  getModelObject(criteria).setMonitoringChanges(true);\n");
    sb.append("}\n");
    return sb.toString();
  }