You can subscribe to this list here.
| 2003 |
Jan
|
Feb
(89) |
Mar
(219) |
Apr
(82) |
May
(33) |
Jun
(11) |
Jul
(129) |
Aug
(357) |
Sep
(34) |
Oct
(37) |
Nov
(42) |
Dec
(182) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2004 |
Jan
(59) |
Feb
(74) |
Mar
(196) |
Apr
(205) |
May
(109) |
Jun
(268) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: <de...@us...> - 2003-12-11 12:41:55
|
Update of /cvsroot/fudaa/fudaa_devel/ebli/src/org/fudaa/ebli/commun
In directory sc8-pr-cvs1:/tmp/cvs-serv22991/commun
Modified Files:
EbliLib.java EbliListeSelectionMulti.java
Log Message:
Modification du paquetage graphe pour prendre en compte les modeles
Index: EbliLib.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/ebli/src/org/fudaa/ebli/commun/EbliLib.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** EbliLib.java 25 Nov 2003 10:06:39 -0000 1.6
--- EbliLib.java 11 Dec 2003 12:41:52 -0000 1.7
***************
*** 19,22 ****
--- 19,28 ----
public class EbliLib {
public final static boolean DEBUG= "TRUE".equals(System.getProperty("DEBUG"));
+ public static void debug(String _s) {
+ System.out.println("DEBUG: " + _s);
+ }
+ public static void error(String _s) {
+ System.out.println("ERROR: " + _s);
+ }
/**
* Cherche l'index de la chaine <code>_string</code>
Index: EbliListeSelectionMulti.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/ebli/src/org/fudaa/ebli/commun/EbliListeSelectionMulti.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** EbliListeSelectionMulti.java 25 Nov 2003 10:06:40 -0000 1.4
--- EbliListeSelectionMulti.java 11 Dec 2003 12:41:52 -0000 1.5
***************
*** 70,74 ****
it.advance();
int idx= it.key();
! EbliListeSelection e= (EbliListeSelection)idxListSelection_.get(idx);
if (e == null) {
e= new EbliListeSelection();
--- 70,74 ----
it.advance();
int idx= it.key();
! EbliListeSelection e= (EbliListeSelection)it.value();
if (e == null) {
e= new EbliListeSelection();
***************
*** 92,96 ****
it.advance();
int idx= it.key();
! EbliListeSelection e= (EbliListeSelection)idxListSelection_.get(idx);
if (e == null) {
e= new EbliListeSelection();
--- 92,96 ----
it.advance();
int idx= it.key();
! EbliListeSelection e= (EbliListeSelection)it.value();
if (e == null) {
e= new EbliListeSelection();
***************
*** 101,104 ****
--- 101,117 ----
return r;
}
+
+ /**
+ * Return the total number of selected index.
+ */
+ public int getNbSelectedItem() {
+ int r= 0;
+ TIntObjectIterator it= idxListSelection_.iterator();
+ for (int i= idxListSelection_.size(); i-- > 0;) {
+ it.advance();
+ r += ((EbliListeSelection)it.value()).getNbSelectedIndex();
+ }
+ return r;
+ }
public boolean remove(EbliListeSelectionMulti _m) {
if ((_m == null) || _m.isEmpty()) {
***************
*** 110,114 ****
it.advance();
int idx= it.key();
! EbliListeSelection e= (EbliListeSelection)idxListSelection_.get(idx);
if (e != null) {
r |= e.remove((EbliListeSelection)it.value());
--- 123,127 ----
it.advance();
int idx= it.key();
! EbliListeSelection e= (EbliListeSelection)it.value();
if (e != null) {
r |= e.remove((EbliListeSelection)it.value());
***************
*** 138,145 ****
return idxListSelection_.iterator();
}
! public void add(int _idxGlobal, int _idxSelected) {
EbliListeSelection l= new EbliListeSelection();
l.setSelectionInterval(_idxSelected, _idxSelected);
idxListSelection_.put(_idxGlobal, l);
}
}
--- 151,167 ----
return idxListSelection_.iterator();
}
! public void set(int _idxGlobal, int _idxSelected) {
! idxListSelection_.clear();
EbliListeSelection l= new EbliListeSelection();
l.setSelectionInterval(_idxSelected, _idxSelected);
idxListSelection_.put(_idxGlobal, l);
+ }
+ public void add(int _idxGlobal, int _idxSelected) {
+ EbliListeSelection l= (EbliListeSelection)idxListSelection_.get(_idxGlobal);
+ if (l == null) {
+ l= new EbliListeSelection();
+ idxListSelection_.put(_idxGlobal, l);
+ }
+ l.add(_idxSelected);
}
}
|
|
From: <de...@us...> - 2003-12-11 12:41:55
|
Update of /cvsroot/fudaa/fudaa_devel/ebli/src/org/fudaa/ebli/calque/action
In directory sc8-pr-cvs1:/tmp/cvs-serv22991/calque/action
Modified Files:
EbliChangeStateAction.java EbliPaletteAction.java
Log Message:
Modification du paquetage graphe pour prendre en compte les modeles
Index: EbliChangeStateAction.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/ebli/src/org/fudaa/ebli/calque/action/EbliChangeStateAction.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** EbliChangeStateAction.java 25 Nov 2003 10:06:39 -0000 1.2
--- EbliChangeStateAction.java 11 Dec 2003 12:41:51 -0000 1.3
***************
*** 24,28 ****
*/
public final void actionPerformed(ActionEvent _ae) {
! setSelected(((AbstractButton)_ae.getSource()).isSelected());
changeAction();
}
--- 24,28 ----
*/
public final void actionPerformed(ActionEvent _ae) {
! setSelected(!isSelected());
changeAction();
}
Index: EbliPaletteAction.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/ebli/src/org/fudaa/ebli/calque/action/EbliPaletteAction.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** EbliPaletteAction.java 25 Nov 2003 10:06:39 -0000 1.2
--- EbliPaletteAction.java 11 Dec 2003 12:41:52 -0000 1.3
***************
*** 44,48 ****
--- 44,52 ----
window_.setTitle(name);
window_.setContent(_c);
+ _c.setVisible(false);
}
+ /**
+ * Methode appele lorsque le bouton de cette palette change d'état (visible ou non).
+ */
public void setMainButtonVisible(boolean _b) {
if (_b && isSelected())
***************
*** 61,64 ****
--- 65,72 ----
}
}
+
+ public JComponent getPaletteContent(){
+ return window_.getContent();
+ }
private BuDesktop desktop_;
public BuDesktop getDesktop() {
***************
*** 92,95 ****
--- 100,107 ----
return window_.getPreferredSize();
}
+
+ public void updateBeforeShow(){
+
+ }
private void showWindow() {
if (loc_ == null) {
***************
*** 101,104 ****
--- 113,118 ----
}
}
+ updateBeforeShow();
+ window_.getContent().setVisible(true);
window_.pack();
Icon i= (Icon)getValue(Action.SMALL_ICON);
***************
*** 115,118 ****
--- 129,133 ----
loc_= window_.getLocation();
window_.setVisible(false);
+ window_.getContent().setVisible(false);
window_.revalidate();
if (desktop_ != null)
|
|
From: <de...@us...> - 2003-12-11 12:41:37
|
Update of /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/dico
In directory sc8-pr-cvs1:/tmp/cvs-serv23146/telemac/dico
Modified Files:
DicoArtemisv5p3.java DicoEstel2dv5p3.java DicoEstel3dv5p3.java
DicoPostel3dv5p3.java DicoSisyphev5p3.java DicoStbtelv5p3.java
DicoSubief2dv5p3.java DicoTelemac2dv5p3.java
DicoTomawacv5p3.java
Log Message:
Ajout de fonctionnalites au modele h2d
Index: DicoArtemisv5p3.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/dico/DicoArtemisv5p3.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** DicoArtemisv5p3.java 25 Nov 2003 10:11:56 -0000 1.2
--- DicoArtemisv5p3.java 11 Dec 2003 12:41:28 -0000 1.3
***************
*** 2,3079 ****
*File generated by fudaa
*/
! package org.fudaa.dodico.telemac.dico;
import org.fudaa.dodico.dico.*;
/**
* @author deniger
*/
! public class DicoArtemisv5p3 extends DicoModelAbstract {
! public DicoArtemisv5p3() {
! super();
[...5646 lines suppressed...]
! valueByLanguage[1]="DESCRIPTION DES LIBRARIES";
! entiteTableau=new DicoEntite.Tableau(valueByLanguage[languageIndex_],typeChaine);
entiteTableau.setTaille(4);
entiteTableau.setDynamique(true);
entiteTableau.setNiveau(1);
! valueByLanguage[0]="Description des librairies de ARTEMIS";
! valueByLanguage[1]="ARTEMIS LIBRARIES description";
entiteTableau.setAide(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="ENTREES-SORTIES, GENERALITES";
! valueByLanguage[1]="INPUT-OUTPUT, INFORMATION";
entiteTableau.setRubrique(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="artemis|arte_VVV|PPP|artemisMMMVVV.LLL;bief|bief_VVV|PPP|biefMMMVVV.LLL;damocles|damo_VVV|PPP|damoMMMVVV.LLL;paravoid|paravoid_VVV|PPP|paravoidMMMVVV.LLL";
! valueByLanguage[1]="artemis|arte_VVV|PPP|artemisMMMVVV.LLL;bief|bief_VVV|PPP|biefMMMVVV.LLL;damocles|damo_VVV|PPP|damoMMMVVV.LLL;paravoid|paravoid_VVV|PPP|paravoidMMMVVV.LLL";
entiteTableau.setDefautValue(valueByLanguage[languageIndex_]);
! entites[98]=entiteTableau.getImmutable();
!
return entites;
}
+
}
Index: DicoEstel2dv5p3.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/dico/DicoEstel2dv5p3.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** DicoEstel2dv5p3.java 25 Nov 2003 10:11:56 -0000 1.2
--- DicoEstel2dv5p3.java 11 Dec 2003 12:41:28 -0000 1.3
***************
*** 2,3072 ****
*File generated by fudaa
*/
! package org.fudaa.dodico.telemac.dico;
import org.fudaa.dodico.dico.*;
/**
* @author deniger
*/
! public class DicoEstel2dv5p3 extends DicoModelAbstract {
! public DicoEstel2dv5p3() {
! super();
[...5920 lines suppressed...]
!
! valueByLanguage[0]="IGNORE LES ERREURS POUR LE PARTICULAIRE";
! valueByLanguage[1]="IGNORE ERRORS IN PARTICLE TRACKING";
! entiteSimple=new DicoEntite.Simple(valueByLanguage[languageIndex_],typeBinaire);
entiteSimple.setNiveau(2);
! valueByLanguage[0]="";
! valueByLanguage[1]="";
entiteSimple.setAide(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="";
! valueByLanguage[1]="";
entiteSimple.setRubrique(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="true";
! valueByLanguage[1]="true";
entiteSimple.setDefautValue(valueByLanguage[languageIndex_]);
! entites[136]=entiteSimple.getImmutable();
!
return entites;
}
+
}
Index: DicoEstel3dv5p3.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/dico/DicoEstel3dv5p3.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** DicoEstel3dv5p3.java 25 Nov 2003 10:11:56 -0000 1.2
--- DicoEstel3dv5p3.java 11 Dec 2003 12:41:28 -0000 1.3
***************
*** 2,2266 ****
*File generated by fudaa
*/
! package org.fudaa.dodico.telemac.dico;
import org.fudaa.dodico.dico.*;
/**
* @author deniger
*/
! public class DicoEstel3dv5p3 extends DicoModelAbstract {
! public DicoEstel3dv5p3() {
! super();
[...4282 lines suppressed...]
! valueByLanguage[1]="INITIAL TIME SET ACCORDING TO KEYWORD INITIAL TIME";
! entiteSimple=new DicoEntite.Simple(valueByLanguage[languageIndex_],typeBinaire);
entiteSimple.setNiveau(2);
! valueByLanguage[0]="Remet le temps au mot cle temps initial en cas de suite"
! +"\nde calcul";
! valueByLanguage[1]="Initial time set to the intial time keyword in case"
! +"\nof restart";
entiteSimple.setAide(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="Parametres de la simulation";
! valueByLanguage[1]="Computation parameters";
entiteSimple.setRubrique(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="false";
! valueByLanguage[1]="false";
entiteSimple.setDefautValue(valueByLanguage[languageIndex_]);
! entites[88]=entiteSimple.getImmutable();
!
return entites;
}
+
}
Index: DicoPostel3dv5p3.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/dico/DicoPostel3dv5p3.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** DicoPostel3dv5p3.java 25 Nov 2003 10:11:56 -0000 1.2
--- DicoPostel3dv5p3.java 11 Dec 2003 12:41:28 -0000 1.3
***************
*** 2,987 ****
*File generated by fudaa
*/
! package org.fudaa.dodico.telemac.dico;
import org.fudaa.dodico.dico.*;
/**
* @author deniger
*/
! public class DicoPostel3dv5p3 extends DicoModelAbstract {
! public DicoPostel3dv5p3() {
! super();
[...1948 lines suppressed...]
! valueByLanguage[1]="DESCRIPTION OF LIBRARIES";
! entiteTableau=new DicoEntite.Tableau(valueByLanguage[languageIndex_],typeChaine);
entiteTableau.setTaille(4);
entiteTableau.setDynamique(true);
entiteTableau.setNiveau(1);
! valueByLanguage[0]="Description des librairies de POSTEL-3D";
! valueByLanguage[1]="POSTEL-3D LIBRARIES description";
entiteTableau.setAide(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="ENTREES-SORTIES, GENERALITES";
! valueByLanguage[1]="INPUT-OUTPUT, INFORMATION";
entiteTableau.setRubrique(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="postel3d|postel3d_VVV|PPP|postel3dMMMVVV.LLL;bief|bief_VVV|PPP|biefMMMVVV.LLL;damocles|damo_VVV|PPP|damoMMMVVV.LLL;paravoid|paravoid_VVV|PPP|paravoidMMMVVV.LLL";
! valueByLanguage[1]="postel3d|postel3d_VVV|PPP|postel3dMMMVVV.LLL;bief|bief_VVV|PPP|biefMMMVVV.LLL;damocles|damo_VVV|PPP|damoMMMVVV.LLL;paravoid|paravoid_VVV|PPP|paravoidMMMVVV.LLL";
entiteTableau.setDefautValue(valueByLanguage[languageIndex_]);
! entites[44]=entiteTableau.getImmutable();
!
return entites;
}
+
}
Index: DicoSisyphev5p3.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/dico/DicoSisyphev5p3.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** DicoSisyphev5p3.java 25 Nov 2003 10:11:56 -0000 1.2
--- DicoSisyphev5p3.java 11 Dec 2003 12:41:28 -0000 1.3
***************
*** 2,2496 ****
*File generated by fudaa
*/
! package org.fudaa.dodico.telemac.dico;
import org.fudaa.dodico.dico.*;
/**
* @author deniger
*/
! public class DicoSisyphev5p3 extends DicoModelAbstract {
! public DicoSisyphev5p3() {
! super();
[...4708 lines suppressed...]
! valueByLanguage[1]="NUMBER OF SEDIMENT LAYERS TO READ";
! entiteSimple=new DicoEntite.Simple(valueByLanguage[languageIndex_],typeEntier);
entiteSimple.setNiveau(1);
! valueByLanguage[0]="Fixe le nombre de couches de sédiments à lire dans le fichier"
! +"\nsuite sédimentologique en cas de suite de calcul - ne sert à rien sinon";
! valueByLanguage[1]="Sets value of number of layers that will be read from the previous"
! +"\ncomputation file";
entiteSimple.setAide(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="PARAMETER FOR NONUNIFORM BED MATERIAL";
! valueByLanguage[1]="PARAMETER FOR NONUNIFORM BED MATERIAL";
entiteSimple.setRubrique(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="1";
! valueByLanguage[1]="1";
entiteSimple.setDefautValue(valueByLanguage[languageIndex_]);
! entites[87]=entiteSimple.getImmutable();
!
return entites;
}
+
}
Index: DicoStbtelv5p3.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/dico/DicoStbtelv5p3.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** DicoStbtelv5p3.java 25 Nov 2003 10:11:57 -0000 1.2
--- DicoStbtelv5p3.java 11 Dec 2003 12:41:28 -0000 1.3
***************
*** 2,1147 ****
*File generated by fudaa
*/
! package org.fudaa.dodico.telemac.dico;
import org.fudaa.dodico.dico.*;
/**
* @author deniger
*/
! public class DicoStbtelv5p3 extends DicoModelAbstract {
! public DicoStbtelv5p3() {
! super();
[...2207 lines suppressed...]
! valueByLanguage[0]="EXECUTABLE PAR DEFAUT";
! valueByLanguage[1]="DEFAULT EXECUTABLE";
! entiteTableau=new DicoEntite.Tableau(valueByLanguage[languageIndex_],typeChaine);
entiteTableau.setTaille(1);
entiteTableau.setNiveau(1);
! valueByLanguage[0]="Executable par defaut de STBTEL";
! valueByLanguage[1]="Default executable for STBTEL";
entiteTableau.setAide(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="ENTREES-SORTIES, GENERALITES";
! valueByLanguage[1]="INPUT-OUTPUT, INFORMATION";
entiteTableau.setRubrique(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="stbtel|stbtel_VVV|PPP|stbtelMMMVVV.exe";
! valueByLanguage[1]="stbtel|stbtel_VVV|PPP|stbtelMMMVVV.exe";
entiteTableau.setDefautValue(valueByLanguage[languageIndex_]);
! entites[41]=entiteTableau.getImmutable();
!
return entites;
}
+
}
Index: DicoSubief2dv5p3.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/dico/DicoSubief2dv5p3.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** DicoSubief2dv5p3.java 25 Nov 2003 10:11:57 -0000 1.2
--- DicoSubief2dv5p3.java 11 Dec 2003 12:41:28 -0000 1.3
***************
*** 2,1678 ****
*File generated by fudaa
*/
! package org.fudaa.dodico.telemac.dico;
import org.fudaa.dodico.dico.*;
/**
* @author deniger
*/
! public class DicoSubief2dv5p3 extends DicoModelAbstract {
! public DicoSubief2dv5p3() {
! super();
[...3239 lines suppressed...]
! valueByLanguage[1]="DESCRIPTION OF THE LIBRARIES";
! entiteTableau=new DicoEntite.Tableau(valueByLanguage[languageIndex_],typeChaine);
entiteTableau.setTaille(5);
entiteTableau.setDynamique(true);
entiteTableau.setNiveau(1);
! valueByLanguage[0]="Description des librairies de SUBIEF2D";
! valueByLanguage[1]="LIBRARIES description for SUBIEF2D";
entiteTableau.setAide(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="ENTREES-SORTIES, GENERALITES";
! valueByLanguage[1]="INPUT-OUTPUT, INFORMATION";
entiteTableau.setRubrique(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="subief2d|subief2d_VVV|PPP|subief2dMMMVVV.LLL;telemac2d|tel2d_VVV|PPP|telemac2dMMMVVV.LLL;bief|bief_VVV|PPP|biefMMMVVV.LLL;damocles|damo_VVV|PPP|damoMMMVVV.LLL;paravoid|paravoid_VVV|PPP|paravoidMMMVVV.LLL";
! valueByLanguage[1]="subief2d|subief2d_VVV|PPP|subief2dMMMVVV.LLL;telemac2d|tel2d_VVV|PPP|telemac2dMMMVVV.LLL;bief|bief_VVV|PPP|biefMMMVVV.LLL;damocles|damo_VVV|PPP|damoMMMVVV.LLL;paravoid|paravoid_VVV|PPP|paravoidMMMVVV.LLL";
entiteTableau.setDefautValue(valueByLanguage[languageIndex_]);
! entites[84]=entiteTableau.getImmutable();
!
return entites;
}
+
}
Index: DicoTelemac2dv5p3.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/dico/DicoTelemac2dv5p3.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** DicoTelemac2dv5p3.java 25 Nov 2003 10:11:57 -0000 1.4
--- DicoTelemac2dv5p3.java 11 Dec 2003 12:41:28 -0000 1.5
***************
*** 2,5427 ****
*File generated by fudaa
*/
! package org.fudaa.dodico.telemac.dico;
import org.fudaa.dodico.dico.*;
/**
* @author deniger
*/
! public class DicoTelemac2dv5p3 extends DicoModelAbstract {
! public DicoTelemac2dv5p3() {
! super();
[...10197 lines suppressed...]
! valueByLanguage[1]="DESCRIPTION OF LIBRARIES";
! entiteTableau=new DicoEntite.Tableau(valueByLanguage[languageIndex_],typeChaine);
entiteTableau.setTaille(4);
entiteTableau.setDynamique(true);
entiteTableau.setNiveau(1);
! valueByLanguage[0]="Description des librairies de T2D";
! valueByLanguage[1]="LIBRARIES description";
entiteTableau.setAide(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="ENTREES-SORTIES, GENERALITES";
! valueByLanguage[1]="INPUT-OUTPUT, INFORMATION";
entiteTableau.setRubrique(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="telemac2d|tel2d_VVV|PPP|telemac2dMMMVVV.LLL;bief|bief_VVV|PPP|biefMMMVVV.LLL;damocles|damo_VVV|PPP|damoMMMVVV.LLL;paravoid|paravoid_VVV|PPP|paravoidMMMVVV.LLL";
! valueByLanguage[1]="telemac2d|tel2d_VVV|PPP|telemac2dMMMVVV.LLL;bief|bief_VVV|PPP|biefMMMVVV.LLL;damocles|damo_VVV|PPP|damoMMMVVV.LLL;paravoid|paravoid_VVV|PPP|paravoidMMMVVV.LLL";
entiteTableau.setDefautValue(valueByLanguage[languageIndex_]);
! entites[194]=entiteTableau.getImmutable();
!
return entites;
}
+
}
Index: DicoTomawacv5p3.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/dico/DicoTomawacv5p3.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** DicoTomawacv5p3.java 25 Nov 2003 10:11:57 -0000 1.2
--- DicoTomawacv5p3.java 11 Dec 2003 12:41:28 -0000 1.3
***************
*** 2,5661 ****
*File generated by fudaa
*/
! package org.fudaa.dodico.telemac.dico;
import org.fudaa.dodico.dico.*;
/**
* @author deniger
*/
! public class DicoTomawacv5p3 extends DicoModelAbstract {
! public DicoTomawacv5p3() {
! super();
[...11000 lines suppressed...]
! +"\nle spectre en frequences"
! +"\n**Mots-cles associes :**"
! +"\nNOMBRE DE FREQUENCES DE DISCRETISATION";
! valueByLanguage[1]="Indicates whether the user wants to discretize"
! +"\nthe spectrum in frequencies"
! +"\n**Related keyword :**"
! +"\nNUMBER OF FREQUENCIES";
entiteSimple.setAide(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="CONDITIONS AUX LIMITES";
! valueByLanguage[1]="BOUNDARY CONDITIONS";
entiteSimple.setRubrique(valueByLanguage[languageIndex_]);
! valueByLanguage[0]="false";
! valueByLanguage[1]="false";
entiteSimple.setDefautValue(valueByLanguage[languageIndex_]);
! entites[177]=entiteSimple.getImmutable();
!
return entites;
}
+
}
|
|
From: <de...@us...> - 2003-12-11 12:41:33
|
Update of /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/test/telemac
In directory sc8-pr-cvs1:/tmp/cvs-serv23146/test/telemac
Modified Files:
TestClMng.java TestLiquide.java TestSerafin.java
Log Message:
Ajout de fonctionnalites au modele h2d
Index: TestClMng.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/test/telemac/TestClMng.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** TestClMng.java 25 Nov 2003 10:12:02 -0000 1.6
--- TestClMng.java 11 Dec 2003 12:41:29 -0000 1.7
***************
*** 60,65 ****
//test intern frontier
assertEquals(16, frontiere.getNbPt(1));
! assertEquals(232, frontiere.getIdx(1, 0));
! assertEquals(23, frontiere.getIdx(1, 15));
}
public void testCl() {
--- 60,65 ----
//test intern frontier
assertEquals(16, frontiere.getNbPt(1));
! assertEquals(232, frontiere.getIdxGlobal(1, 0));
! assertEquals(23, frontiere.getIdxGlobal(1, 15));
}
public void testCl() {
Index: TestLiquide.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/test/telemac/TestLiquide.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** TestLiquide.java 25 Nov 2003 10:12:02 -0000 1.9
--- TestLiquide.java 11 Dec 2003 12:41:29 -0000 1.10
***************
*** 31,35 ****
H2dEvolutionFrontiereLiquide[] fs= _inter.getEvolutionsFrontieresLiquides();
H2dEvolutionFrontiereLiquide fsi= fs[0];
! assertEquals(2, fsi.getIndexFrontiere());
assertEquals("m3/s", fsi.getUnite());
assertEquals(H2dVariableType.DEBIT, fsi.getVariableType());
--- 31,35 ----
H2dEvolutionFrontiereLiquide[] fs= _inter.getEvolutionsFrontieresLiquides();
H2dEvolutionFrontiereLiquide fsi= fs[0];
! assertEquals(1, fsi.getIndexFrontiere());
assertEquals("m3/s", fsi.getUnite());
assertEquals(H2dVariableType.DEBIT, fsi.getVariableType());
***************
*** 46,50 ****
assertEquals(503, fsi.getValue(4), eps_);
fsi= fs[1];
! assertEquals(1, fsi.getIndexFrontiere());
assertEquals("m", fsi.getUnite());
assertEquals(H2dVariableType.COTE_EAU, fsi.getVariableType());
--- 46,50 ----
assertEquals(503, fsi.getValue(4), eps_);
fsi= fs[1];
! assertEquals(0, fsi.getIndexFrontiere());
assertEquals("m", fsi.getUnite());
assertEquals(H2dVariableType.COTE_EAU, fsi.getVariableType());
***************
*** 68,72 ****
.getInstance()
.getLastVersionImpl()
! .writeMaillage(
tmpFile,
inter,
--- 68,72 ----
.getInstance()
.getLastVersionImpl()
! .writeClLiquid(
tmpFile,
inter,
Index: TestSerafin.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/test/telemac/TestSerafin.java,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -d -r1.16 -r1.17
*** TestSerafin.java 25 Nov 2003 10:12:02 -0000 1.16
--- TestSerafin.java 11 Dec 2003 12:41:29 -0000 1.17
***************
*** 67,73 ****
assertEquals(maillage.getEltType(), H2dElementType.T3);
//IKLE1
! assertEquals(maillage.getElement(0).getPtIndex()[1], 1545);
assertEquals(
! maillage.getElement(maillage.getEltNb() - 1).getPtIndex()[0],
219);
//IPOBO1
--- 67,73 ----
assertEquals(maillage.getEltType(), H2dElementType.T3);
//IKLE1
! assertEquals(maillage.getElement(0).getPtIndex(1), 1545);
assertEquals(
! maillage.getElement(maillage.getEltNb() - 1).getPtIndex(0),
219);
//IPOBO1
|
|
From: <de...@us...> - 2003-12-11 12:41:33
|
Update of /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/test/reflux
In directory sc8-pr-cvs1:/tmp/cvs-serv23146/test/reflux
Modified Files:
TestCorEleBth.java TestDunes.java TestINP.java canal_s.inp
Log Message:
Ajout de fonctionnalites au modele h2d
Index: TestCorEleBth.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/test/reflux/TestCorEleBth.java,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** TestCorEleBth.java 25 Nov 2003 10:12:01 -0000 1.11
--- TestCorEleBth.java 11 Dec 2003 12:41:29 -0000 1.12
***************
*** 60,83 ****
assertEquals(d, dLu, eps_);
//test sur l'element 33
! int[] elems= maill.getElement(33).getPtIndex();
assertEquals(maill.getEltNb(), 792);
! assertEquals(elems.length, 6);
int i= 306;
! int iLu= elems[0];
assertEquals(i, iLu);
i= 307;
! iLu= elems[1];
assertEquals(i, iLu);
i= 308;
! iLu= elems[2];
assertEquals(i, iLu);
i= 298;
! iLu= elems[3];
assertEquals(i, iLu);
i= 288;
! iLu= elems[4];
assertEquals(i, iLu);
i= 297;
! iLu= elems[5];
assertEquals(i, iLu);
}
--- 60,83 ----
assertEquals(d, dLu, eps_);
//test sur l'element 33
! H2dElement ele=maill.getElement(33);
assertEquals(maill.getEltNb(), 792);
! assertEquals(maill.getElement(33).getPtNb(), 6);
int i= 306;
! int iLu= ele.getPtIndex(0);
assertEquals(i, iLu);
i= 307;
! iLu= ele.getPtIndex(1);
assertEquals(i, iLu);
i= 308;
! iLu= ele.getPtIndex(2);
assertEquals(i, iLu);
i= 298;
! iLu= ele.getPtIndex(3);
assertEquals(i, iLu);
i= 288;
! iLu= ele.getPtIndex(4);
assertEquals(i, iLu);
i= 297;
! iLu= ele.getPtIndex(5);
assertEquals(i, iLu);
}
Index: TestDunes.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/test/reflux/TestDunes.java,v
retrieving revision 1.12
retrieving revision 1.13
diff -C2 -d -r1.12 -r1.13
*** TestDunes.java 25 Nov 2003 10:12:02 -0000 1.12
--- TestDunes.java 11 Dec 2003 12:41:29 -0000 1.13
***************
*** 12,15 ****
--- 12,16 ----
import com.memoire.bu.BuTask;
import org.fudaa.dodico.commun.DodicoLib;
+ import org.fudaa.dodico.commun.DodicoUIDefault;
import org.fudaa.dodico.commun.ProgressionBuAdapter;
import org.fudaa.dodico.dunes.io.DunesFileFormat;
***************
*** 19,22 ****
--- 20,24 ----
import org.fudaa.dodico.h2d.H2dGrid;
import org.fudaa.dodico.h2d.H2dPoint;
+ import org.fudaa.dodico.olb.OLBExec;
import org.fudaa.dodico.test.TestIO;
/**
***************
*** 63,78 ****
temp= t.getMaillage().getEltNb();
assertEquals(temp, 9);
! int[] indices= t.getMaillage().getElement(1).getPtIndex();
! temp= indices.length;
assertEquals(temp, 3);
! assertEquals(indices[0], 4);
! assertEquals(indices[1], 0);
! assertEquals(indices[2], 5);
! indices= t.getMaillage().getElement(6).getPtIndex();
! temp= indices.length;
assertEquals(temp, 3);
! assertEquals(indices[0], 4);
! assertEquals(indices[1], 5);
! assertEquals(indices[2], 6);
}
/**
--- 65,80 ----
temp= t.getMaillage().getEltNb();
assertEquals(temp, 9);
! H2dElement el=t.getMaillage().getElement(1);
! temp= el.getPtNb();
assertEquals(temp, 3);
! assertEquals(el.getPtIndex(0), 4);
! assertEquals(el.getPtIndex(1), 0);
! assertEquals(el.getPtIndex(2), 5);
! el=t.getMaillage().getElement(6);
! temp= el.getPtNb();
assertEquals(temp, 3);
! assertEquals(el.getPtIndex(0), 4);
! assertEquals(el.getPtIndex(1), 5);
! assertEquals(el.getPtIndex(2), 6);
}
/**
***************
*** 104,107 ****
--- 106,116 ----
public void testLecture() {
_interfaceTest(getInter(fic_));
+ }
+
+ public void testOlb(){
+ H2dGrid f=getInter(fic_).getMaillage();
+ OLBExec exec=new OLBExec();
+ H2dGrid f2=exec.computeGrid(f, null,DodicoUIDefault.INSTANCE);
+ assertNotNull(f2);
}
public static void main(String[] args) {
Index: TestINP.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/test/reflux/TestINP.java,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -d -r1.13 -r1.14
*** TestINP.java 25 Nov 2003 10:12:02 -0000 1.13
--- TestINP.java 11 Dec 2003 12:41:29 -0000 1.14
***************
*** 16,19 ****
--- 16,20 ----
import org.fudaa.dodico.dico.DicoEntite;
import org.fudaa.dodico.fichiers.FileOperationSynthese;
+ import org.fudaa.dodico.h2d.H2dElement;
import org.fudaa.dodico.h2d.H2dTimeStepGroup;
import org.fudaa.dodico.h2d.H2dGrid;
***************
*** 96,142 ****
assertEquals(H2dBcType.PERMANENT, bord.getRugositeType());
assertEquals(3d, bord.getRugosite(), eps_);
- //H2dElement[] elems=t.getMaillage().getElts();
assertEquals(t.getMaillage().getEltNb(), 792);
! itemp= t.getMaillage().getElement(791).getPtIndex();
! assertEquals(itemp[0], 1788);
! assertEquals(itemp[1], 1789);
! assertEquals(itemp[2], 1790);
! assertEquals(itemp[3], 1780);
! assertEquals(itemp[4], 1770);
! assertEquals(itemp[5], 1779);
H2dNodalPropertyMixte[] propelem= t.getPropElementaires();
H2dNodalPropertyMixte prTemp= propelem[0];
- assertEquals(prTemp.getVariableType(), H2dVariableType.VISCOSITE);
assertEquals(prTemp.getValeurTransitoireNb(), 0);
! assertEquals(prTemp.getPermanentSpecifieNb(), 0);
! assertEquals(prTemp.getValeurLibreNb(), 0);
! assertEquals(prTemp.getDefaultValue(), 0.01, eps_);
prTemp= propelem[1];
! assertEquals(prTemp.getVariableType(), H2dVariableType.RUGOSITE);
! assertEquals(prTemp.getValeurTransitoireNb(), 0);
! assertEquals(prTemp.getPermanentSpecifieNb(), 0);
! assertEquals(prTemp.getValeurLibreNb(), 0);
! assertEquals(prTemp.getDefaultValue(), 0.025, eps_);
! assertEquals(prTemp.getPermanentValueForIndex(1), 0.025, eps_);
prTemp= propelem[2];
! assertEquals(
! prTemp.getVariableType(),
! H2dVariableType.ALPHA_LONGUEUR_MELANGE);
! assertEquals(prTemp.getValeurTransitoireNb(), 0);
! assertEquals(prTemp.getPermanentSpecifieNb(), 0);
! assertEquals(prTemp.getValeurLibreNb(), 0);
! assertEquals(prTemp.getDefaultValue(), 0.0, eps_);
prTemp= propelem[3];
- assertEquals(prTemp.getVariableType(), H2dVariableType.PERTE_CHARGE);
assertEquals(0, prTemp.getValeurTransitoireNb());
! assertEquals(792, prTemp.getPermanentSpecifieNb());
! assertEquals(0, prTemp.getValeurLibreNb());
! assertEquals(0.0, prTemp.getDefaultValue(), eps_);
! assertEquals(0.0, prTemp.getPermanentValueForIndex(0), eps_);
for (int i= 790; i >= 0; i--) {
if (i != 758)
! assertEquals(prTemp.getPermanentValueForIndex(i), 0.0, eps_);
else
! assertEquals(prTemp.getPermanentValueForIndex(i), 0.01, eps_);
}
String[] fics= t.getFichiers();
--- 97,128 ----
assertEquals(H2dBcType.PERMANENT, bord.getRugositeType());
assertEquals(3d, bord.getRugosite(), eps_);
assertEquals(t.getMaillage().getEltNb(), 792);
! H2dElement el=t.getMaillage().getElement(791);
! assertEquals(el.getPtIndex(0), 1788);
! assertEquals(el.getPtIndex(1), 1789);
! assertEquals(el.getPtIndex(2), 1790);
! assertEquals(el.getPtIndex(3), 1780);
! assertEquals(el.getPtIndex(4), 1770);
! assertEquals(el.getPtIndex(5), 1779);
H2dNodalPropertyMixte[] propelem= t.getPropElementaires();
H2dNodalPropertyMixte prTemp= propelem[0];
assertEquals(prTemp.getValeurTransitoireNb(), 0);
! assertEquals(792, prTemp.getNbPermanentPt());
prTemp= propelem[1];
! assertEquals(0, prTemp.getValeurTransitoireNb());
! assertEquals(792, prTemp.getNbPermanentPt());
! assertEquals(prTemp.getPermanentValueFor(1), 0.025, eps_);
prTemp= propelem[2];
! assertEquals(0, prTemp.getValeurTransitoireNb());
! assertEquals(792, prTemp.getNbPermanentPt());
prTemp= propelem[3];
assertEquals(0, prTemp.getValeurTransitoireNb());
! assertEquals(792, prTemp.getNbPermanentPt());
! assertEquals(0.0, prTemp.getPermanentValueFor(0), eps_);
for (int i= 790; i >= 0; i--) {
if (i != 758)
! assertEquals(prTemp.getPermanentValueFor(i), 0.0, eps_);
else
! assertEquals(prTemp.getPermanentValueFor(i), 0.01, eps_);
}
String[] fics= t.getFichiers();
***************
*** 155,159 ****
assertEquals(gt.getNbPasTemps(), 1);
assertEquals(gt.getSchema(), H2dResolutionSchemaType.STATIONNAIRE);
! assertEquals(gt.getMethode(), H2dResolutionMethodType.SELECT_LUMPING);
assertEquals(gt.getRelaxation(), 1, eps_);
assertEquals(gt.getPrecision(), 0.001, eps_);
--- 141,145 ----
assertEquals(gt.getNbPasTemps(), 1);
assertEquals(gt.getSchema(), H2dResolutionSchemaType.STATIONNAIRE);
! assertEquals(gt.getMethode(), H2dResolutionMethodType.SELECT_LUMPING_BCD);
assertEquals(gt.getRelaxation(), 1, eps_);
assertEquals(gt.getPrecision(), 0.001, eps_);
***************
*** 224,228 ****
assertEquals(mng.getGrid().getFrontiers().getNbFrontier(), 1);
H2dRefluxBcManager.RefluxMiddleFrontier frontiere0=
! mng.getRefluxBorderByFrontier(0);
H2dRefluxBoundaryCondition cl;
for (int i= 0; i < n; i += 2) {
--- 210,214 ----
assertEquals(mng.getGrid().getFrontiers().getNbFrontier(), 1);
H2dRefluxBcManager.RefluxMiddleFrontier frontiere0=
! mng.getRefluxMiddleFrontier(0);
H2dRefluxBoundaryCondition cl;
for (int i= 0; i < n; i += 2) {
***************
*** 234,238 ****
cl= (H2dRefluxBoundaryCondition)frontiere0.getCl(i);
assertTrue(cl.isMiddle());
! if ((i == 1421) || (i == 1403)) {
assertTrue(cl.isMiddleWithFriction());
H2dRefluxBoundaryConditionMiddleFriction clFr= cl.getMiddleFriction();
--- 220,224 ----
cl= (H2dRefluxBoundaryCondition)frontiere0.getCl(i);
assertTrue(cl.isMiddle());
! if ((cl.getIndexPt() == 1421) || (cl.getIndexPt() == 1403)) {
assertTrue(cl.isMiddleWithFriction());
H2dRefluxBoundaryConditionMiddleFriction clFr= cl.getMiddleFriction();
***************
*** 240,245 ****
assertEquals(3, clFr.getFriction(), eps_);
assertEquals(H2dBcType.PERMANENT, clFr.getFrictionType());
! } else
assertFalse(cl.isMiddleWithFriction());
}
}
--- 226,232 ----
assertEquals(3, clFr.getFriction(), eps_);
assertEquals(H2dBcType.PERMANENT, clFr.getFrictionType());
! } else {
assertFalse(cl.isMiddleWithFriction());
+ }
}
}
Index: canal_s.inp
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/test/reflux/canal_s.inp,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** canal_s.inp 1 Apr 2003 13:52:07 -0000 1.1
--- canal_s.inp 11 Dec 2003 12:41:29 -0000 1.2
***************
*** 3559,3563 ****
VIT_NU_CON
STATIONNAIRE
! SELUMP 1.0 0.0010 0.05 2
COEFFICIENTS 00.0 1.0000 2.000 3.00 4.0000 5.00
6.000 7.0000 8.00
--- 3559,3563 ----
VIT_NU_CON
STATIONNAIRE
! SELUMP_BCD 1.0 0.0010 0.05 2
COEFFICIENTS 00.0 1.0000 2.000 3.00 4.0000 5.00
6.000 7.0000 8.00
|
|
From: <de...@us...> - 2003-12-11 12:41:32
|
Update of /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/test/h2d
In directory sc8-pr-cvs1:/tmp/cvs-serv23146/test/h2d
Modified Files:
TestBord.java TestMaillage.java
Log Message:
Ajout de fonctionnalites au modele h2d
Index: TestBord.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/test/h2d/TestBord.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** TestBord.java 25 Nov 2003 10:12:00 -0000 1.6
--- TestBord.java 11 Dec 2003 12:41:29 -0000 1.7
***************
*** 96,100 ****
assertFalse(b.isBeginIdxSelected(13, 130));
int nbP= 20;
! b.setBordType(H2dBoundaryType.LIQUIDE_DEBIT_IMPOSE);
assertEquals(-1, b.isIntersectBy(0, 11, nbP));
assertEquals(0, b.isIntersectBy(0, 12, nbP));
--- 96,100 ----
assertFalse(b.isBeginIdxSelected(13, 130));
int nbP= 20;
! b.setBoundaryType(H2dBoundaryType.LIQUIDE_DEBIT_IMPOSE);
assertEquals(-1, b.isIntersectBy(0, 11, nbP));
assertEquals(0, b.isIntersectBy(0, 12, nbP));
***************
*** 105,109 ****
assertEquals(0, b.isIntersectBy(19, 15, nbP));
assertEquals(-1, b.isIntersectBy(19, 11, nbP));
! b.setBordType(H2dBoundaryType.SOLIDE);
assertEquals(-1, b.isIntersectBy(0, 12, nbP));
assertEquals(0, b.isIntersectBy(13, 14, nbP));
--- 105,109 ----
assertEquals(0, b.isIntersectBy(19, 15, nbP));
assertEquals(-1, b.isIntersectBy(19, 11, nbP));
! b.setBoundaryType(H2dBoundaryType.SOLIDE);
assertEquals(-1, b.isIntersectBy(0, 12, nbP));
assertEquals(0, b.isIntersectBy(13, 14, nbP));
***************
*** 113,117 ****
b.setIdxDeb(16);
b.setIdxFin(5);
! b.setBordType(H2dBoundaryType.LIQUIDE_DEBIT_IMPOSE);
assertEquals(-1, b.isIntersectBy(6, 15, nbP));
assertEquals(0, b.isIntersectBy(4, 12, nbP));
--- 113,117 ----
b.setIdxDeb(16);
b.setIdxFin(5);
! b.setBoundaryType(H2dBoundaryType.LIQUIDE_DEBIT_IMPOSE);
assertEquals(-1, b.isIntersectBy(6, 15, nbP));
assertEquals(0, b.isIntersectBy(4, 12, nbP));
***************
*** 119,123 ****
assertEquals(1, b.isIntersectBy(17, 4, nbP));
assertEquals(2, b.isIntersectBy(15, 6, nbP));
! b.setBordType(H2dBoundaryType.SOLIDE);
assertEquals(-1, b.isIntersectBy(5, 16, nbP));
assertEquals(0, b.isIntersectBy(4, 14, nbP));
--- 119,123 ----
assertEquals(1, b.isIntersectBy(17, 4, nbP));
assertEquals(2, b.isIntersectBy(15, 6, nbP));
! b.setBoundaryType(H2dBoundaryType.SOLIDE);
assertEquals(-1, b.isIntersectBy(5, 16, nbP));
assertEquals(0, b.isIntersectBy(4, 14, nbP));
Index: TestMaillage.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/test/h2d/TestMaillage.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** TestMaillage.java 25 Nov 2003 10:12:00 -0000 1.9
--- TestMaillage.java 11 Dec 2003 12:41:29 -0000 1.10
***************
*** 138,148 ****
initMaillage();
H2dElement el= mail_.getElement(0);
! assertEquals(el.getPtIndex()[0], 0);
! assertEquals(el.getPtIndex()[1], 2);
! assertEquals(el.getPtIndex()[2], 1);
el= mail_.getElement(1);
! assertEquals(el.getPtIndex()[0], 1);
! assertEquals(el.getPtIndex()[1], 2);
! assertEquals(el.getPtIndex()[2], 3);
assertEquals(mail_.isElementTrigoOriente(0), -1);
assertEquals(mail_.isElementTrigoOriente(1), -1);
--- 138,148 ----
initMaillage();
H2dElement el= mail_.getElement(0);
! assertEquals(el.getPtIndex(0), 0);
! assertEquals(el.getPtIndex(1), 2);
! assertEquals(el.getPtIndex(2), 1);
el= mail_.getElement(1);
! assertEquals(el.getPtIndex(0), 1);
! assertEquals(el.getPtIndex(1), 2);
! assertEquals(el.getPtIndex(2), 3);
assertEquals(mail_.isElementTrigoOriente(0), -1);
assertEquals(mail_.isElementTrigoOriente(1), -1);
***************
*** 156,162 ****
initMaillageT6();
H2dElement el= mail_.getElement(0);
! assertEquals(el.getPtIndex()[0], 0);
! assertEquals(el.getPtIndex()[1], 9);
! assertEquals(el.getPtIndex()[2], 2);
for (int i= 0; i < 9; i++) {
assertEquals(mail_.isElementTrigoOriente(i), -1);
--- 156,162 ----
initMaillageT6();
H2dElement el= mail_.getElement(0);
! assertEquals(el.getPtIndex(0), 0);
! assertEquals(el.getPtIndex(1), 9);
! assertEquals(el.getPtIndex(2), 2);
for (int i= 0; i < 9; i++) {
assertEquals(mail_.isElementTrigoOriente(i), -1);
***************
*** 200,214 ****
int n= bord.getNbPt(0);
assertEquals(n, 6);
! assertEquals(0, bord.getIdx(0, 0));
! assertEquals(1, bord.getIdx(0, 1));
! assertEquals(6, bord.getIdx(0, 2));
! assertEquals(8, bord.getIdx(0, 3));
! assertEquals(7, bord.getIdx(0, 4));
! assertEquals(4, bord.getIdx(0, 5));
n= bord.getNbPt(1);
assertEquals(n, 3);
! assertEquals(2, bord.getIdx(1, 0));
! assertEquals(5, bord.getIdx(1, 1));
! assertEquals(3, bord.getIdx(1, 2));
}
public void testBord() {
--- 200,214 ----
int n= bord.getNbPt(0);
assertEquals(n, 6);
! assertEquals(0, bord.getIdxGlobal(0, 0));
! assertEquals(1, bord.getIdxGlobal(0, 1));
! assertEquals(6, bord.getIdxGlobal(0, 2));
! assertEquals(8, bord.getIdxGlobal(0, 3));
! assertEquals(7, bord.getIdxGlobal(0, 4));
! assertEquals(4, bord.getIdxGlobal(0, 5));
n= bord.getNbPt(1);
assertEquals(n, 3);
! assertEquals(2, bord.getIdxGlobal(1, 0));
! assertEquals(5, bord.getIdxGlobal(1, 1));
! assertEquals(3, bord.getIdxGlobal(1, 2));
}
public void testBord() {
***************
*** 233,256 ****
int n= bord.getNbPt(0);
assertEquals(n, 12);
! assertEquals(0, bord.getIdx(0, 0));
! assertEquals(11, bord.getIdx(0, 1));
! assertEquals(1, bord.getIdx(0, 2));
! assertEquals(23, bord.getIdx(0, 3));
! assertEquals(6, bord.getIdx(0, 4));
! assertEquals(26, bord.getIdx(0, 5));
! assertEquals(8, bord.getIdx(0, 6));
! assertEquals(24, bord.getIdx(0, 7));
! assertEquals(7, bord.getIdx(0, 8));
! assertEquals(21, bord.getIdx(0, 9));
! assertEquals(4, bord.getIdx(0, 10));
! assertEquals(14, bord.getIdx(0, 11));
n= bord.getNbPt(1);
assertEquals(n, 6);
! assertEquals(2, bord.getIdx(1, 0));
! assertEquals(17, bord.getIdx(1, 1));
! assertEquals(5, bord.getIdx(1, 2));
! assertEquals(20, bord.getIdx(1, 3));
! assertEquals(3, bord.getIdx(1, 4));
! assertEquals(12, bord.getIdx(1, 5));
}
public void testT3T6() {
--- 233,256 ----
int n= bord.getNbPt(0);
assertEquals(n, 12);
! assertEquals(0, bord.getIdxGlobal(0, 0));
! assertEquals(11, bord.getIdxGlobal(0, 1));
! assertEquals(1, bord.getIdxGlobal(0, 2));
! assertEquals(23, bord.getIdxGlobal(0, 3));
! assertEquals(6, bord.getIdxGlobal(0, 4));
! assertEquals(26, bord.getIdxGlobal(0, 5));
! assertEquals(8, bord.getIdxGlobal(0, 6));
! assertEquals(24, bord.getIdxGlobal(0, 7));
! assertEquals(7, bord.getIdxGlobal(0, 8));
! assertEquals(21, bord.getIdxGlobal(0, 9));
! assertEquals(4, bord.getIdxGlobal(0, 10));
! assertEquals(14, bord.getIdxGlobal(0, 11));
n= bord.getNbPt(1);
assertEquals(n, 6);
! assertEquals(2, bord.getIdxGlobal(1, 0));
! assertEquals(17, bord.getIdxGlobal(1, 1));
! assertEquals(5, bord.getIdxGlobal(1, 2));
! assertEquals(20, bord.getIdxGlobal(1, 3));
! assertEquals(3, bord.getIdxGlobal(1, 4));
! assertEquals(12, bord.getIdxGlobal(1, 5));
}
public void testT3T6() {
|
|
From: <de...@us...> - 2003-12-11 12:41:32
|
Update of /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/io In directory sc8-pr-cvs1:/tmp/cvs-serv23146/telemac/io Modified Files: SerafinFileFormat.java TelemacCLFileFormat.java TelemacCLReader.java TelemacDicoFileFormatVersion.java TelemacLiquideFileFormat.java TelemacLiquideReader.java TelemacLiquideWriter.java Log Message: Ajout de fonctionnalites au modele h2d Index: SerafinFileFormat.java =================================================================== RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/io/SerafinFileFormat.java,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** SerafinFileFormat.java 25 Nov 2003 10:11:57 -0000 1.10 --- SerafinFileFormat.java 11 Dec 2003 12:41:28 -0000 1.11 *************** *** 9,12 **** --- 9,14 ---- package org.fudaa.dodico.telemac.io; import java.io.File; + import java.util.Arrays; + import org.fudaa.dodico.commun.ProgressionInterface; import org.fudaa.dodico.fichiers.FileFormat; *************** *** 34,37 **** --- 36,40 ---- super(NB_FILE); extensions_= new String[] { "ser", "res" }; + Arrays.sort(extensions_); ID_= "SERAFIN"; nom_= "Serafin"; *************** *** 43,46 **** --- 46,57 ---- type_= H2dFileFormatType.MAILLAGE.getId(); } + + public boolean containsGrid() { + return true; + } + + public FileFormatVersion getLastVersionInstance() { + return getLastVersionImpl(); + } public class SerafinVersion extends FileFormatVersion *************** *** 130,133 **** --- 141,167 ---- return write(_f, inter, _prog); } + /** + * + */ + public FileOperationSynthese readGrid( + File _f, + ProgressionInterface _prog) { + FileOperationSynthese f= read(_f, _prog); + if (f == null) + return f; + SerafinInterface in= (SerafinInterface)f.getSource(); + if (in == null) + return f; + f.setSource(in.getMaillage()); + return f; + } + + /** + * + */ + public boolean canWriteOnlyGrid() { + return true; + } + } /** Index: TelemacCLFileFormat.java =================================================================== RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/io/TelemacCLFileFormat.java,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** TelemacCLFileFormat.java 25 Nov 2003 10:11:58 -0000 1.10 --- TelemacCLFileFormat.java 11 Dec 2003 12:41:28 -0000 1.11 *************** *** 43,46 **** --- 43,50 ---- type_= H2dFileFormatType.CL.getId(); } + + public FileFormatVersion getLastVersionInstance(){ + return getLastVersionImpl(); + } public class TelemacCLVersion extends FileFormatVersion { private final int libre_= 4; Index: TelemacCLReader.java =================================================================== RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/io/TelemacCLReader.java,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** TelemacCLReader.java 25 Nov 2003 10:11:58 -0000 1.14 --- TelemacCLReader.java 11 Dec 2003 12:41:28 -0000 1.15 *************** *** 153,157 **** } catch (EOFException _oef) { if (DodicoLib.DEBUG) ! System.out.println("read end"); } catch (NumberFormatException _ex) { DodicoAnalyze.manageException(_ex, analyze_, in_); --- 153,157 ---- } catch (EOFException _oef) { if (DodicoLib.DEBUG) ! DodicoLib.debug("Telemac boundary file read end"); } catch (NumberFormatException _ex) { DodicoAnalyze.manageException(_ex, analyze_, in_); Index: TelemacDicoFileFormatVersion.java =================================================================== RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/io/TelemacDicoFileFormatVersion.java,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** TelemacDicoFileFormatVersion.java 25 Nov 2003 10:11:58 -0000 1.6 --- TelemacDicoFileFormatVersion.java 11 Dec 2003 12:41:29 -0000 1.7 *************** *** 19,22 **** --- 19,23 ---- import org.fudaa.dodico.h2d.type.H2dFileFormatType; import org.fudaa.dodico.telemac.TelemacDicoManager; + import sun.security.action.GetBooleanAction; /** * @author deniger *************** *** 59,62 **** --- 60,69 ---- return gridEntite_; } + public DicoEntite getCLLiquideEntiteFile() { + return getEntiteFor( + new String[] { + "FICHIER DES FRONTIERES LIQUIDES", + "LIQUID BOUNDARIES FILE" }); + } public DicoEntite getCLEntiteFile() { if (clEntite_ == null) *************** *** 113,117 **** if (ent == null) return null; - DicoEntite test; //entite du fichier cas if (ent.equals(getMaillageEntiteFile())) --- 120,123 ---- *************** *** 120,123 **** --- 126,132 ---- else if (ent.equals(getCLEntiteFile())) return TelemacCLFileFormat.getInstance(); + else if (ent.equals(getCLLiquideEntiteFile())) { + return TelemacLiquideFileFormat.getInstance(); + } return null; } *************** *** 168,173 **** * */ ! public boolean isVelocitiesFixedByVelocityProfils(String _v) { ! return DodicoLib.UN.equals(_v); } } --- 177,194 ---- * */ ! public boolean isFlowrateComputeFromVelocities(String _v) { ! return DodicoLib.DEUX.equals(_v); ! } ! /** ! * ! */ ! public boolean isFlowrateComputeFromElevation(String _v) { ! return DodicoLib.QUATRE.equals(_v); ! } ! /** ! * ! */ ! public boolean isFlowrateComputeFromVelocityU(String _v) { ! return DodicoLib.TROIS.equals(_v); } } Index: TelemacLiquideFileFormat.java =================================================================== RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/io/TelemacLiquideFileFormat.java,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** TelemacLiquideFileFormat.java 25 Nov 2003 10:11:59 -0000 1.7 --- TelemacLiquideFileFormat.java 11 Dec 2003 12:41:29 -0000 1.8 *************** *** 41,44 **** --- 41,48 ---- type_= H2dFileFormatType.CL_LIQUIDE.getId(); } + + public FileFormatVersion getLastVersionInstance(){ + return getLastVersionImpl(); + } public class TelemacLiquideVersion extends FileFormatVersion { TelemacLiquideVersion(String _b) { *************** *** 69,73 **** * */ ! public FileOperationSynthese writeMaillage( File _f, TelemacLiquideInterface _source, --- 73,77 ---- * */ ! public FileOperationSynthese writeClLiquid( File _f, TelemacLiquideInterface _source, Index: TelemacLiquideReader.java =================================================================== RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/io/TelemacLiquideReader.java,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** TelemacLiquideReader.java 25 Nov 2003 10:11:59 -0000 1.9 --- TelemacLiquideReader.java 11 Dec 2003 12:41:29 -0000 1.10 *************** *** 63,66 **** --- 63,67 ---- for (int i= 0; i < nbValue; i++) { stemp= in_.stringField(i + 1); + int indexPar= stemp.indexOf('('); int indexParFermante= stemp.indexOf(')'); *************** *** 77,81 **** Integer.parseInt( stemp.substring(indexPar + 1, indexParFermante)); ! evols[i]= new H2dEvolutionFrontiereLiquideMutable(var, itemp); } } --- 78,83 ---- Integer.parseInt( stemp.substring(indexPar + 1, indexParFermante)); ! evols[i]= new H2dEvolutionFrontiereLiquideMutable(var, itemp-1); ! evols[i].setNom(stemp); } } *************** *** 139,143 **** } catch (EOFException _e) { if (DodicoLib.DEBUG) ! System.out.println("end of file"); } catch (NumberFormatException _e) { DodicoAnalyze.manageException(_e, analyze_); --- 141,145 ---- } catch (EOFException _e) { if (DodicoLib.DEBUG) ! DodicoLib.debug("end of file for telemac liquid file"); } catch (NumberFormatException _e) { DodicoAnalyze.manageException(_e, analyze_); Index: TelemacLiquideWriter.java =================================================================== RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/io/TelemacLiquideWriter.java,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** TelemacLiquideWriter.java 25 Nov 2003 10:11:59 -0000 1.7 --- TelemacLiquideWriter.java 11 Dec 2003 12:41:29 -0000 1.8 *************** *** 9,12 **** --- 9,13 ---- package org.fudaa.dodico.telemac.io; import java.io.IOException; + import java.text.DateFormat; import java.util.Calendar; import org.fudaa.dodico.commun.DodicoAnalyze; *************** *** 82,86 **** + H2dResource.getS("Généré le") + DodicoLib.ESPACE ! + Calendar.getInstance().toString() + lineSep_); write(b); --- 83,87 ---- + H2dResource.getS("Généré le") + DodicoLib.ESPACE ! + DateFormat.getDateInstance().format(Calendar.getInstance().getTime()) + lineSep_); write(b); |
Update of /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/reflux/io
In directory sc8-pr-cvs1:/tmp/cvs-serv23146/reflux/io
Modified Files:
CLTransitoireFileFormat.java CorEleBthFileFormat.java
INPFileFormat.java INPReader.java INPWriter.java
PnTransitoireFileFormat.java
Log Message:
Ajout de fonctionnalites au modele h2d
Index: CLTransitoireFileFormat.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/reflux/io/CLTransitoireFileFormat.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** CLTransitoireFileFormat.java 25 Nov 2003 10:11:49 -0000 1.4
--- CLTransitoireFileFormat.java 11 Dec 2003 12:41:28 -0000 1.5
***************
*** 52,55 ****
--- 52,59 ----
return new CLTransitoireFileFormat.CLVersion();
}
+
+ public FileFormatVersion getLastVersionInstance(){
+ return getLastVersionImpl();
+ }
public class CLVersion extends FileFormatVersion {
public CLVersion() {
Index: CorEleBthFileFormat.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/reflux/io/CorEleBthFileFormat.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** CorEleBthFileFormat.java 25 Nov 2003 10:11:50 -0000 1.9
--- CorEleBthFileFormat.java 11 Dec 2003 12:41:28 -0000 1.10
***************
*** 9,12 ****
--- 9,13 ----
package org.fudaa.dodico.reflux.io;
import java.io.File;
+
import org.fudaa.dodico.commun.ProgressionInterface;
import org.fudaa.dodico.fichiers.FileFormat;
***************
*** 31,35 ****
return INSTANCE;
}
- private CorEleBthVersion lastVersion_;
protected CorEleBthFileFormat() {
super(NB_FILE);
--- 32,35 ----
***************
*** 44,49 ****
type_= H2dFileFormatType.MAILLAGE.getId();
}
! public class CorEleBthVersion
! extends FileFormatVersion
implements H2dFileFormatMaillageVersion {
public CorEleBthVersion(String _version) {
--- 44,53 ----
type_= H2dFileFormatType.MAILLAGE.getId();
}
!
! public FileFormatVersion getLastVersionInstance() {
! return getLastVersionImpl();
! }
!
! public class CorEleBthVersion extends FileFormatVersion
implements H2dFileFormatMaillageVersion {
public CorEleBthVersion(String _version) {
***************
*** 118,121 ****
--- 122,148 ----
return write(_f, inter, _prog);
}
+ /**
+ *
+ */
+ public FileOperationSynthese readGrid(
+ File _f,
+ ProgressionInterface _prog) {
+ FileOperationSynthese f= read(_f, _prog);
+ if (f == null)
+ return f;
+ CorEleBthInterface in= (CorEleBthInterface)f.getSource();
+ if (in == null)
+ return f;
+ f.setSource(in.getMaillage());
+ return f;
+ }
+
+ /**
+ *
+ */
+ public boolean canWriteOnlyGrid() {
+ return true;
+ }
+
}
/**
***************
*** 128,130 ****
--- 155,164 ----
return new CorEleBthVersion(getLastVersion());
}
+ /**
+ *
+ */
+ public boolean containsGrid() {
+ return true;
+ }
+
}
Index: INPFileFormat.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/reflux/io/INPFileFormat.java,v
retrieving revision 1.12
retrieving revision 1.13
diff -C2 -d -r1.12 -r1.13
*** INPFileFormat.java 25 Nov 2003 10:11:50 -0000 1.12
--- INPFileFormat.java 11 Dec 2003 12:41:28 -0000 1.13
***************
*** 13,39 ****
import java.util.Iterator;
import java.util.List;
! import java.util.Locale;
! import com.memoire.fu.FuLib;
import org.fudaa.dodico.commun.DodicoLib;
import org.fudaa.dodico.commun.ProgressionInterface;
- import org.fudaa.dodico.dico.DicoCasFileFormat;
import org.fudaa.dodico.dico.DicoCasFileFormatAbstract;
- import org.fudaa.dodico.dico.DicoCasFileFormatVersion;
import org.fudaa.dodico.dico.DicoCasFileFormatVersionAbstract;
- import org.fudaa.dodico.dico.DicoCasReader;
- import org.fudaa.dodico.dico.DicoCasWriter;
import org.fudaa.dodico.dico.DicoEntite;
import org.fudaa.dodico.dico.DicoEntiteGenerate;
import org.fudaa.dodico.dico.DicoEntiteList;
import org.fudaa.dodico.dico.DicoLanguage;
- import org.fudaa.dodico.dico.DicoManager;
import org.fudaa.dodico.fichiers.FileFormatSoftware;
import org.fudaa.dodico.fichiers.FileOperationSynthese;
import org.fudaa.dodico.fichiers.FileReadOperationAbstract;
import org.fudaa.dodico.fichiers.FileWriteOperationAbstract;
import org.fudaa.dodico.h2d.H2dResource;
import org.fudaa.dodico.h2d.reflux.H2dRefluxDicoModel;
- import org.fudaa.dodico.h2d.type.H2dBoundaryType;
import org.fudaa.dodico.h2d.type.H2dBcType;
import org.fudaa.dodico.h2d.type.H2dFileFormatType;
import org.fudaa.dodico.h2d.type.H2dVariableType;
--- 13,36 ----
import java.util.Iterator;
import java.util.List;
!
import org.fudaa.dodico.commun.DodicoLib;
import org.fudaa.dodico.commun.ProgressionInterface;
import org.fudaa.dodico.dico.DicoCasFileFormatAbstract;
import org.fudaa.dodico.dico.DicoCasFileFormatVersionAbstract;
import org.fudaa.dodico.dico.DicoEntite;
import org.fudaa.dodico.dico.DicoEntiteGenerate;
import org.fudaa.dodico.dico.DicoEntiteList;
import org.fudaa.dodico.dico.DicoLanguage;
import org.fudaa.dodico.fichiers.FileFormatSoftware;
+ import org.fudaa.dodico.fichiers.FileFormatVersion;
import org.fudaa.dodico.fichiers.FileOperationSynthese;
import org.fudaa.dodico.fichiers.FileReadOperationAbstract;
import org.fudaa.dodico.fichiers.FileWriteOperationAbstract;
+ import org.fudaa.dodico.h2d.H2dFileFormatMaillageVersion;
+ import org.fudaa.dodico.h2d.H2dGrid;
import org.fudaa.dodico.h2d.H2dResource;
import org.fudaa.dodico.h2d.reflux.H2dRefluxDicoModel;
import org.fudaa.dodico.h2d.type.H2dBcType;
+ import org.fudaa.dodico.h2d.type.H2dBoundaryType;
import org.fudaa.dodico.h2d.type.H2dFileFormatType;
import org.fudaa.dodico.h2d.type.H2dVariableType;
***************
*** 59,63 ****
type_= H2dFileFormatType.PROJET.getId();
}
! public class INPVersion extends DicoCasFileFormatVersionAbstract {
public INPVersion(String _version) {
super(getInstance(), new H2dRefluxDicoModel(_version));
--- 56,71 ----
type_= H2dFileFormatType.PROJET.getId();
}
!
! public boolean containsGrid() {
! return true;
! }
!
! public FileFormatVersion getLastVersionInstance() {
! return getLastVersionImpl();
! }
!
! public class INPVersion
! extends DicoCasFileFormatVersionAbstract
! implements H2dFileFormatMaillageVersion {
public INPVersion(String _version) {
super(getInstance(), new H2dRefluxDicoModel(_version));
***************
*** 249,259 ****
return 3;
} /**
! * Renvoie le format concernant la ligne declarant le bloc Coor.
! */
public int[] getCOORFormat() {
return new int[] { 5, 15, 5, 5 };
} /**
! * Renvoie le format concernant les lignes declarant les coordonnées.
! */
public int[] getTroisDoubleFormat() {
return new int[] { 10, 10, 10 };
--- 257,267 ----
return 3;
} /**
! * Renvoie le format concernant la ligne declarant le bloc Coor.
! */
public int[] getCOORFormat() {
return new int[] { 5, 15, 5, 5 };
} /**
! * Renvoie le format concernant les lignes declarant les coordonnées.
! */
public int[] getTroisDoubleFormat() {
return new int[] { 10, 10, 10 };
***************
*** 452,455 ****
--- 460,496 ----
return null;
}
+ /**
+ *
+ */
+ public boolean canWriteOnlyGrid() {
+ return false;
+ }
+
+ /**
+ *
+ */
+ public FileOperationSynthese readGrid(
+ File _f,
+ ProgressionInterface _prog) {
+ FileOperationSynthese o= read(_f, _prog);
+ if (o == null)
+ return null;
+ INPInterface inter= (INPInterface)o.getSource();
+ if (inter == null)
+ return o;
+ o.setSource(inter.getMaillage());
+ return o;
+ }
+
+ /**
+ *
+ */
+ public FileOperationSynthese writeMaillage(
+ File _f,
+ H2dGrid _m,
+ ProgressionInterface _prog) {
+ return null;
+ }
+
}
/**
Index: INPReader.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/reflux/io/INPReader.java,v
retrieving revision 1.12
retrieving revision 1.13
diff -C2 -d -r1.12 -r1.13
*** INPReader.java 25 Nov 2003 10:11:51 -0000 1.12
--- INPReader.java 11 Dec 2003 12:41:28 -0000 1.13
***************
*** 57,70 ****
TIntDoubleHashMap fixe;
TIntArrayList libre;
- String nom_;
int taille_;
TIntObjectHashMap transitoire;
H2dVariableType type_;
! TemplateGroupeElement(H2dVariableType _type, int _taille) {
! this(_taille);
! type_= _type;
! nom_= type_.getNom();
! }
! TemplateGroupeElement(int _taille) {
taille_= _taille;
libre= new TIntArrayList(taille_);
--- 57,66 ----
TIntDoubleHashMap fixe;
TIntArrayList libre;
int taille_;
TIntObjectHashMap transitoire;
H2dVariableType type_;
! String nom_;
! TemplateGroupeElement(String _nom, int _taille) {
! nom_= _nom;
taille_= _taille;
libre= new TIntArrayList(taille_);
***************
*** 73,85 ****
}
/**
- * Le nom du groupe et sa taille maximale.
- * @param _taille le nombre d'element max de ce groupe: c'est
- * donc l'indice max egalement
- */
- TemplateGroupeElement(String _nom, int _taille) {
- taille_= _taille;
- nom_= _nom;
- }
- /**
* Ajoute en tant que prop permanente de valeur <code>_v</code>
* l'indice <code>_i</code> (si inferieur a la taille max).
--- 69,72 ----
***************
*** 135,140 ****
}
H2dNodalPropertyMixte r=
! new H2dNodalPropertyMixte(nom_, type_, libre, fixe, transitoire);
! r.computeFixe();
return r;
}
--- 122,126 ----
}
H2dNodalPropertyMixte r=
! new H2dNodalPropertyMixte(nom_, fixe, transitoire);
return r;
}
***************
*** 659,663 ****
temp2= fmt.length;
//Ce chiffre indique le nombre de courbe que doit contenir
! //finalement le fichier clv.
//NOTE : les courbes sont stockes dans la liste evols
// projet_.setNbCLTransitoires(courbeTransitoireCLIndex);
--- 645,649 ----
temp2= fmt.length;
//Ce chiffre indique le nombre de courbe que doit contenir
! //finalement le fichier pnv.
//NOTE : les courbes sont stockes dans la liste evols
// projet_.setNbCLTransitoires(courbeTransitoireCLIndex);
***************
*** 1021,1051 ****
TemplateGroupeElement[] propElem= new TemplateGroupeElement[temp];
//on connait le nom des 4 premieres prop. Pour les autres, PROP+ indices.
! if (temp > 4) {
! for (int i= 4; i < temp - 1; i++) {
! propElem[i]= new TemplateGroupeElement("PROP " + i, nbElemFond);
! }
! temp1= 4;
! }
! //On affecte les noms pour les connus.
! switch (temp) {
! case 4 :
! propElem[3]=
! new TemplateGroupeElement(H2dVariableType.PERTE_CHARGE, nbElemFond);
! case 3 :
! propElem[2]=
! new TemplateGroupeElement(
! H2dVariableType.ALPHA_LONGUEUR_MELANGE,
! nbElemFond);
! case 2 :
! propElem[1]=
! new TemplateGroupeElement(H2dVariableType.RUGOSITE, nbElemFond);
! case 1 :
! propElem[0]=
! new TemplateGroupeElement(H2dVariableType.VISCOSITE, nbElemFond);
}
//Format: 16 colonnes de largeur 5 (entier)
fmt= version_.getSeizeEntierFormat();
//temp=le nombre de prop elementaire
! temp= propElem.length;
//le nombre d'entier sur une ligne
temp1= fmt.length;
--- 1007,1017 ----
TemplateGroupeElement[] propElem= new TemplateGroupeElement[temp];
//on connait le nom des 4 premieres prop. Pour les autres, PROP+ indices.
! for (int i= temp-1; i >=0; i--) {
! propElem[i]= new TemplateGroupeElement("PROP " + (i+1), nbElemFond);
}
//Format: 16 colonnes de largeur 5 (entier)
fmt= version_.getSeizeEntierFormat();
//temp=le nombre de prop elementaire
! //temp= propElem.length;
//le nombre d'entier sur une ligne
temp1= fmt.length;
***************
*** 1093,1096 ****
--- 1059,1063 ----
}
}
+ Double viscositeTransit=null;
for (int i= 0; i < nbGroupe; i++) {
//Attention: les prop elementaires normales sont donnees puis celle
***************
*** 1145,1150 ****
if (code == clTransitoire) {
codeFinal= H2dBcType.TRANSITOIRE;
- // evol= new H2dEvolution("PN" + (courbeTransitoirePnIndex++));
- // evols.add(evol);
} else {
codeFinal= H2dBcType.LIBRE;
--- 1112,1115 ----
***************
*** 1161,1166 ****
//les indices des points concernes
int itemp= indexElement - nbElemFond;
- // int[] elemBordRugosite= elemBord[itemp].getIndex();
- // int t= elemBordRugosite.length;
H2dBoundaryType bordType= elemBord[itemp].getBord();
if (bordType != H2dBoundaryType.SOLIDE) {
--- 1126,1129 ----
***************
*** 1205,1209 ****
//indexEnCours=nb prop lu.
//temp=le nombre de prop elementaire
! if (indexEnCours != temp) {
analyze_.addWarning(
H2dResource.getS(
--- 1168,1176 ----
//indexEnCours=nb prop lu.
//temp=le nombre de prop elementaire
! if(temp2==0){
! in_.readFields(fmt);
! viscositeTransit=new Double(in_.doubleField(0));
! }
! else if (indexEnCours != temp) {
analyze_.addWarning(
H2dResource.getS(
***************
*** 1386,1390 ****
H2dTimeStepGroup gt= new H2dTimeStepGroup();
//le nombre de pas de temps
! gt.setNbPasTemps(Integer.parseInt(sTemp));
sTemp= in_.readLine().trim();
if (sTemp.equals(refluxProjetNom)) {
--- 1353,1357 ----
H2dTimeStepGroup gt= new H2dTimeStepGroup();
//le nombre de pas de temps
! int nbTemps=Integer.parseInt(sTemp);
sTemp= in_.readLine().trim();
if (sTemp.equals(refluxProjetNom)) {
***************
*** 1399,1402 ****
--- 1366,1370 ----
if (schema != null) {
gt.setSchema(schema);
+ gt.setNbPasTemps(nbTemps);
//si non stationnaire on peut lire les donnees
if (schema != H2dResolutionSchemaType.STATIONNAIRE) {
***************
*** 1432,1435 ****
--- 1400,1410 ----
gt.setMethode(meth);
}
+ if(meth.needViscosity()){
+ double d=0;
+ if(viscositeTransit==null){ System.out.println("prob with transit viscosity"); }
+ else d=viscositeTransit.doubleValue();
+ if(DodicoLib.DEBUG) System.out.println("DEBUG: transit viscosity value= "+d);
+ gt.setMethodeValue(H2dVariableType.VISCOSITE, d);
+ }
gt.setRelaxation(in_.doubleField(1));
gt.setPrecision(in_.doubleField(2));
***************
*** 1496,1500 ****
} catch (EOFException _e) {
if (DodicoLib.DEBUG)
! System.out.println("DEBUG: End of file");
if (!foundEntete) {
analyze_.addFatalError(H2dResource.getS("Fichier invalide"), in_);
--- 1471,1475 ----
} catch (EOFException _e) {
if (DodicoLib.DEBUG)
! DodicoLib.debug("End of file for inp file");
if (!foundEntete) {
analyze_.addFatalError(H2dResource.getS("Fichier invalide"), in_);
Index: INPWriter.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/reflux/io/INPWriter.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** INPWriter.java 25 Nov 2003 10:11:51 -0000 1.9
--- INPWriter.java 11 Dec 2003 12:41:28 -0000 1.10
***************
*** 10,13 ****
--- 10,14 ----
import gnu.trove.TIntArrayList;
import gnu.trove.TIntHashSet;
+ import gnu.trove.TIntObjectHashMap;
import java.io.File;
import java.io.FileWriter;
***************
*** 15,18 ****
--- 16,20 ----
import java.util.ArrayList;
import java.util.Arrays;
+ import java.util.Collections;
import java.util.HashMap;
import java.util.Iterator;
***************
*** 515,522 ****
H2dRefluxBoundaryCondition cli;
CLGroup temp= new CLGroup();
! for (DodicoIntIterator it= m.getFrontiers().getFrontierIterator();
! it.hasNext();
! ) {
! cli= _inter.getConditionLimite(it.next());
//h
if (cli.getHType() != H2dBcType.LIBRE) {
--- 517,525 ----
H2dRefluxBoundaryCondition cli;
CLGroup temp= new CLGroup();
! TIntObjectHashMap globIdxBc=
! new TIntObjectHashMap(m.getFrontiers().getNbTotalPt());
! for (int i= m.getFrontiers().getNbTotalPt() - 1; i >= 0; i--) {
! cli= _inter.getConditionLimite(i);
! globIdxBc.put(cli.getIndexPt(), cli);
//h
if (cli.getHType() != H2dBcType.LIBRE) {
***************
*** 572,577 ****
out_.writeFields(version_.getTroisDoubleFormat());
ArrayList l= (ArrayList)clGroupeCL.get(temp);
indexEnCours= 0;
! //pour le sero final
int nbl= l.size() + 1;
fmt= version_.getSeizeEntierFormat();
--- 575,581 ----
out_.writeFields(version_.getTroisDoubleFormat());
ArrayList l= (ArrayList)clGroupeCL.get(temp);
+ Collections.sort(l);
indexEnCours= 0;
! //pour le zero final
int nbl= l.size() + 1;
fmt= version_.getSeizeEntierFormat();
***************
*** 624,628 ****
int normalId= version_.getCodePermanent();
for (int i= 0; i < nbPoint; i++) {
! cli= _inter.getConditionLimite(i);
if (cli == null) {
itemp1= 0;
--- 628,632 ----
int normalId= version_.getCodePermanent();
for (int i= 0; i < nbPoint; i++) {
! cli= (H2dRefluxBoundaryCondition)globIdxBc.get(i);
if (cli == null) {
itemp1= 0;
***************
*** 655,659 ****
double d1, d2;
for (int i= 0; i < nbPoint; i++) {
! cli= _inter.getConditionLimite(i);
if (cli == null) {
d1= 0d;
--- 659,663 ----
double d1, d2;
for (int i= 0; i < nbPoint; i++) {
! cli= (H2dRefluxBoundaryCondition)globIdxBc.get(i);
if (cli == null) {
d1= 0d;
***************
*** 798,802 ****
tempEvols[j]= null;
} else {
! tempVal[j]= gpEl[j].getPermanentValueForIndex(i);
tempEvols[j]= null;
}
--- 802,806 ----
tempEvols[j]= null;
} else {
! tempVal[j]= gpEl[j].getPermanentValueFor(i);
tempEvols[j]= null;
}
***************
*** 868,874 ****
return;
}
- out_.stringField(0, version_.getPREL());
- out_.intField(2, grpFond.size());
out_.intField(3, gpEl.length);
out_.writeFields(version_.getPRELFormat());
indexEnCours= 0;
--- 872,883 ----
return;
}
out_.intField(3, gpEl.length);
+ out_.stringField(0, version_.getPREL());
+ Double viscosityVal=
+ H2dTimeStepGroup.isViscosityTransitUsed(_inter.getGroupePasTemps());
+ if (viscosityVal != null)
+ out_.intField(2, grpFond.size() + 1);
+ else
+ out_.intField(2, grpFond.size());
out_.writeFields(version_.getPRELFormat());
indexEnCours= 0;
***************
*** 893,896 ****
--- 902,919 ----
egp.addEvolInList(pnTransitoireCourbeList);
}
+ if (viscosityVal != null) {
+ int code= version_.getCode(H2dBcType.PERMANENT);
+ for (int i= gpEl.length - 1; i >= 0; i--) {
+ out_.intField(i, code);
+ }
+ out_.writeFields(fmt);
+ for (int i= gpEl.length - 1; i > 0; i--) {
+ out_.doubleField(i, 0d);
+ }
+ System.out.println("vale="+viscosityVal.doubleValue());
+ out_.doubleField(0, viscosityVal.doubleValue());
+ out_.writeFields(fmt2);
+
+ }
out_.println();
out_.println();
***************
*** 968,972 ****
out_.stringField(0, schema.getRefluxId());
out_.doubleField(1, gpTemps[i].getValeurPasTemps());
! out_.doubleField(1, gpTemps[i].getCoefSchema());
out_.writeFields(version_.getFLUTSchemaResolutionFormat());
}
--- 991,995 ----
out_.stringField(0, schema.getRefluxId());
out_.doubleField(1, gpTemps[i].getValeurPasTemps());
! out_.doubleField(2, gpTemps[i].getCoefSchema());
out_.writeFields(version_.getFLUTSchemaResolutionFormat());
}
Index: PnTransitoireFileFormat.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/reflux/io/PnTransitoireFileFormat.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** PnTransitoireFileFormat.java 25 Nov 2003 10:11:51 -0000 1.3
--- PnTransitoireFileFormat.java 11 Dec 2003 12:41:28 -0000 1.4
***************
*** 43,46 ****
--- 43,50 ----
type_= H2dFileFormatType.COURBE_TRANSITOIRE.getId();
}
+
+ public FileFormatVersion getLastVersionInstance(){
+ return getLastVersionImpl();
+ }
/**
*
|
|
From: <de...@us...> - 2003-12-11 12:41:31
|
Update of /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac
In directory sc8-pr-cvs1:/tmp/cvs-serv23146/telemac
Modified Files:
TelemacDicoManager.java
Log Message:
Ajout de fonctionnalites au modele h2d
Index: TelemacDicoManager.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/telemac/TelemacDicoManager.java,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -d -r1.13 -r1.14
*** TelemacDicoManager.java 25 Nov 2003 10:11:56 -0000 1.13
--- TelemacDicoManager.java 11 Dec 2003 12:41:28 -0000 1.14
***************
*** 79,83 ****
&& (DicoLanguage.getCurrentID() == _language)) {
if (DodicoLib.DEBUG)
! System.out.println("new instance for telemac 2d");
if (telemac2dv5p3_ == null)
telemac2dv5p3_= _ft.createVersion(createDico(name, _v, _language));
--- 79,83 ----
&& (DicoLanguage.getCurrentID() == _language)) {
if (DodicoLib.DEBUG)
! DodicoLib.debug("new instance for telemac 2d");
if (telemac2dv5p3_ == null)
telemac2dv5p3_= _ft.createVersion(createDico(name, _v, _language));
|
|
From: <de...@us...> - 2003-12-11 12:41:31
|
Update of /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/h2d/telemac
In directory sc8-pr-cvs1:/tmp/cvs-serv23146/h2d/telemac
Modified Files:
H2dTelemacBcManager.java H2dTelemacBoundary.java
H2dTelemacBoundaryCondition.java
H2dTelemacBoundaryMutable.java
H2dTelemacDicoFileFormatVersion.java H2dTelemacParameters.java
H2dTelemacTransient.java
Log Message:
Ajout de fonctionnalites au modele h2d
Index: H2dTelemacBcManager.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/h2d/telemac/H2dTelemacBcManager.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** H2dTelemacBcManager.java 25 Nov 2003 10:11:37 -0000 1.2
--- H2dTelemacBcManager.java 11 Dec 2003 12:41:27 -0000 1.3
***************
*** 13,41 ****
import gnu.trove.TObjectDoubleIterator;
import gnu.trove.TObjectIntHashMap;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collection;
! import java.util.HashSet;
! import java.util.Iterator;
import org.fudaa.dodico.commun.DodicoAnalyze;
import org.fudaa.dodico.commun.DodicoCommand;
- import org.fudaa.dodico.commun.DodicoCommandComposite;
[...1122 lines suppressed...]
! }
! /**
! *
! */
public void dicoParamsProjectModifyStateChanged(DicoParams _cas) {}
}
--- 1571,1583 ----
}
};
! } /**
! *
! */
public void dicoParamsStateLoadedEntiteChanged(
DicoParams _cas,
DicoEntite _ent) {
! } /**
! *
! */
public void dicoParamsProjectModifyStateChanged(DicoParams _cas) {}
}
Index: H2dTelemacBoundary.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/h2d/telemac/H2dTelemacBoundary.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** H2dTelemacBoundary.java 25 Nov 2003 10:11:37 -0000 1.2
--- H2dTelemacBoundary.java 11 Dec 2003 12:41:27 -0000 1.3
***************
*** 9,17 ****
--- 9,24 ----
package org.fudaa.dodico.h2d.telemac;
import java.util.Arrays;
+ import java.util.Collections;
import java.util.HashMap;
+ import java.util.Iterator;
+ import java.util.List;
import java.util.Map;
+ import java.util.TreeMap;
import org.fudaa.dodico.commun.DodicoLib;
import org.fudaa.dodico.commun.DodicoPermanentList;
import org.fudaa.dodico.h2d.H2dBoundary;
+ import org.fudaa.dodico.h2d.H2dEvolution;
+ import org.fudaa.dodico.h2d.H2dEvolutionFrontiereLiquideMutable;
+ import org.fudaa.dodico.h2d.H2dFrontier;
import org.fudaa.dodico.h2d.type.H2dBoundaryType;
import org.fudaa.dodico.h2d.type.H2dBcType;
***************
*** 22,29 ****
*/
public class H2dTelemacBoundary extends H2dBoundary {
! H2dBcType tracerType_;
! H2dBcType uType_;
H2dBcType vType_;
- // H2dClType hType_;
String elevation_;
String velocity_;
--- 29,35 ----
*/
public class H2dTelemacBoundary extends H2dBoundary {
! private H2dBcType tracerType_;
! private H2dBcType uType_;
H2dBcType vType_;
String elevation_;
String velocity_;
***************
*** 32,105 ****
String velocityProfil_;
String liquidOption_;
! public final static DodicoPermanentList VARIABLE_TYPE=
! new DodicoPermanentList(
! DodicoLib
! .sort(new H2dVariableType[] {
! H2dVariableType.VITESSE_U,
! H2dVariableType.VITESSE_V, // H2dVariableType.COTE_EAU,
! H2dVariableType.TRACEUR }));
! private static Map BORD_TYPE_VARIABLE_ACCEPTED;
public final static void createMapBordTypeVar() {
BORD_TYPE_VARIABLE_ACCEPTED= new HashMap(10);
! H2dVariableType[] vs=
! new H2dVariableType[] {
! H2dVariableType.TRACEUR,
! H2dVariableType.TRACEUR_COEF_A,
! H2dVariableType.TRACEUR_COEF_B };
! Arrays.sort(vs);
! BORD_TYPE_VARIABLE_ACCEPTED.put(H2dBoundaryType.LIQUIDE, vs);
! vs=
! new H2dVariableType[] {
! H2dVariableType.DEBIT,
! H2dVariableType.VITESSE_U,
! H2dVariableType.VITESSE_V,
! H2dVariableType.TRACEUR,
! H2dVariableType.TRACEUR_COEF_A,
! H2dVariableType.TRACEUR_COEF_B };
! Arrays.sort(vs);
! BORD_TYPE_VARIABLE_ACCEPTED.put(H2dBoundaryType.LIQUIDE_DEBIT_IMPOSE, vs);
! vs=
! new H2dVariableType[] {
! H2dVariableType.COTE_EAU,
! H2dVariableType.TRACEUR,
! H2dVariableType.TRACEUR_COEF_A,
! H2dVariableType.TRACEUR_COEF_B };
! Arrays.sort(vs);
BORD_TYPE_VARIABLE_ACCEPTED.put(
! H2dBoundaryType.LIQUIDE_HAUTEUR_IMPOSEE,
! vs);
vs=
new H2dVariableType[] {
H2dVariableType.COTE_EAU,
H2dVariableType.VITESSE_U,
! H2dVariableType.VITESSE_V,
! H2dVariableType.TRACEUR,
! H2dVariableType.TRACEUR_COEF_A,
! H2dVariableType.TRACEUR_COEF_B };
! Arrays.sort(vs);
BORD_TYPE_VARIABLE_ACCEPTED.put(
H2dBoundaryType.LIQUIDE_HAUTEUR_VITESSES_IMPOSEES,
! vs);
! vs=
! new H2dVariableType[] {
! H2dVariableType.TRACEUR,
! H2dVariableType.TRACEUR_COEF_A,
! H2dVariableType.TRACEUR_COEF_B };
! Arrays.sort(vs);
! BORD_TYPE_VARIABLE_ACCEPTED.put(H2dBoundaryType.LIQUIDE_ONDE_INCIDENCE, vs);
vs=
new H2dVariableType[] {
H2dVariableType.VITESSE_U,
! H2dVariableType.VITESSE_V,
! H2dVariableType.TRACEUR,
! H2dVariableType.TRACEUR_COEF_A,
! H2dVariableType.TRACEUR_COEF_B };
! Arrays.sort(vs);
BORD_TYPE_VARIABLE_ACCEPTED.put(
H2dBoundaryType.LIQUIDE_VITESSES_IMPOSEES,
! vs);
! vs= new H2dVariableType[] { H2dVariableType.RUGOSITE };
! Arrays.sort(vs);
! BORD_TYPE_VARIABLE_ACCEPTED.put(H2dBoundaryType.SOLIDE, vs);
}
/**
--- 38,222 ----
String velocityProfil_;
String liquidOption_;
! Map varEvolution_;
! protected static DodicoPermanentList FLOWRATE_ALLOWED_PTS_VARIABLES;
! public interface AvailableVariable {
! public DodicoPermanentList getAvailableVariableForPoint(
! H2dTelemacDicoFileFormatVersion _v,
! H2dTelemacBoundary _t);
! public DodicoPermanentList getAvailableTransientVariable();
! }
!
! public static class AvailableVariableSolid implements AvailableVariable {
! DodicoPermanentList varPoint_;
!
! /**
! *
! */
! public DodicoPermanentList getAvailableTransientVariable() {
! return null;
! }
!
! /**
! *
! */
! public DodicoPermanentList getAvailableVariableForPoint(
! H2dTelemacDicoFileFormatVersion _v,
! H2dTelemacBoundary _t) {
! if (varPoint_ == null){
! varPoint_=
! new DodicoPermanentList(
! new H2dVariableType[] { H2dVariableType.RUGOSITE });
! }
! return varPoint_;
! }
!
! }
! public static class AvailableVariableDefault implements AvailableVariable {
! DodicoPermanentList varPoint_;
! DodicoPermanentList varTrans_;
!
! public AvailableVariableDefault(
! H2dVariableType[] _vPoint,
! H2dVariableType[] _vTransitoire) {
! int n= _vPoint.length;
! H2dVariableType[] vf= new H2dVariableType[n + 3];
! System.arraycopy(_vPoint, 0, vf, 0, n);
! vf[n]= H2dVariableType.TRACEUR;
! vf[n + 1]= H2dVariableType.TRACEUR_COEF_A;
! vf[n + 2]= H2dVariableType.TRACEUR_COEF_B;
! Arrays.sort(vf);
! varPoint_= new DodicoPermanentList(vf);
! n= _vTransitoire.length;
! vf= new H2dVariableType[n + 1];
! System.arraycopy(_vTransitoire, 0, vf, 0, n);
! vf[n]= H2dVariableType.TRACEUR;
! Arrays.sort(vf);
! varTrans_= new DodicoPermanentList(vf);
! }
!
! /**
! *
! */
! public DodicoPermanentList getAvailableTransientVariable() {
! return varTrans_;
! }
! /**
! *
! */
! public DodicoPermanentList getAvailableVariableForPoint(
! H2dTelemacDicoFileFormatVersion _v,
! H2dTelemacBoundary _t) {
! return varPoint_;
! }
!
! }
!
! public static class AvailableVariableFlowrate implements AvailableVariable {
! DodicoPermanentList varTrans_;
!
! /**
! *
! */
! public DodicoPermanentList getAvailableTransientVariable() {
! if (varTrans_ == null) {
! varTrans_=
! new DodicoPermanentList(
! DodicoLib.sort(
! new H2dVariableType[] {
! H2dVariableType.DEBIT,
! H2dVariableType.TRACEUR }));
! }
! return varTrans_;
! }
!
! /**
! *
! */
! public DodicoPermanentList getAvailableVariableForPoint(
! H2dTelemacDicoFileFormatVersion _v,
! H2dTelemacBoundary _b) {
! String opt= _b.getVelocityProfil();
! if (_v.isFlowrateComputeFromElevation(opt)) {
! return new DodicoPermanentList(
! DodicoLib.sort(
! new H2dVariableType[] {
! H2dVariableType.TRACEUR,
! H2dVariableType.TRACEUR_COEF_A,
! H2dVariableType.TRACEUR_COEF_B,
! H2dVariableType.COTE_EAU }));
! } else if (_v.isFlowrateComputeFromVelocities(opt)) {
! return new DodicoPermanentList(
! DodicoLib.sort(
! new H2dVariableType[] {
! H2dVariableType.TRACEUR,
! H2dVariableType.TRACEUR_COEF_A,
! H2dVariableType.TRACEUR_COEF_B,
! H2dVariableType.VITESSE_U,
! H2dVariableType.VITESSE_V }));
! } else if (_v.isFlowrateComputeFromVelocityU(opt)) {
! return new DodicoPermanentList(
! DodicoLib.sort(
! new H2dVariableType[] {
! H2dVariableType.TRACEUR,
! H2dVariableType.TRACEUR_COEF_A,
! H2dVariableType.TRACEUR_COEF_B,
! H2dVariableType.VITESSE_U }));
! } else {
! if (FLOWRATE_ALLOWED_PTS_VARIABLES == null) {
! FLOWRATE_ALLOWED_PTS_VARIABLES=
! new DodicoPermanentList(
! DodicoLib.sort(
! new H2dVariableType[] {
! H2dVariableType.TRACEUR,
! H2dVariableType.TRACEUR_COEF_A,
! H2dVariableType.TRACEUR_COEF_B }));
! }
! return FLOWRATE_ALLOWED_PTS_VARIABLES;
! }
! }
!
! }
!
! public static Map BORD_TYPE_VARIABLE_ACCEPTED;
public final static void createMapBordTypeVar() {
+ if (BORD_TYPE_VARIABLE_ACCEPTED != null)
+ return;
BORD_TYPE_VARIABLE_ACCEPTED= new HashMap(10);
! H2dVariableType[] vs;
! vs= new H2dVariableType[0];
! AvailableVariableDefault def= new AvailableVariableDefault(vs, vs);
! BORD_TYPE_VARIABLE_ACCEPTED.put(H2dBoundaryType.LIQUIDE, (AvailableVariable)def);
BORD_TYPE_VARIABLE_ACCEPTED.put(
! H2dBoundaryType.LIQUIDE_ONDE_INCIDENCE,
! (AvailableVariable)def);
! vs= new H2dVariableType[1];
! vs[0]= H2dVariableType.COTE_EAU;
! def= new AvailableVariableDefault(vs, vs);
! BORD_TYPE_VARIABLE_ACCEPTED.put(
! H2dBoundaryType.LIQUIDE_HAUTEUR_IMPOSEE,def);
vs=
new H2dVariableType[] {
H2dVariableType.COTE_EAU,
H2dVariableType.VITESSE_U,
! H2dVariableType.VITESSE_V };
! def= new AvailableVariableDefault(vs, vs);
BORD_TYPE_VARIABLE_ACCEPTED.put(
H2dBoundaryType.LIQUIDE_HAUTEUR_VITESSES_IMPOSEES,
! def);
vs=
new H2dVariableType[] {
H2dVariableType.VITESSE_U,
! H2dVariableType.VITESSE_V };
! def= new AvailableVariableDefault(vs, vs);
BORD_TYPE_VARIABLE_ACCEPTED.put(
H2dBoundaryType.LIQUIDE_VITESSES_IMPOSEES,
! def);
! BORD_TYPE_VARIABLE_ACCEPTED.put(
! H2dBoundaryType.LIQUIDE_DEBIT_IMPOSE,
! new AvailableVariableFlowrate());
! BORD_TYPE_VARIABLE_ACCEPTED.put(
! H2dBoundaryType.SOLIDE,
! new AvailableVariableSolid());
!
}
/**
***************
*** 110,121 ****
uType_= H2dBcType.LIBRE;
vType_= H2dBcType.LIBRE;
- //hType_= H2dClType.LIBRE;
}
! public H2dTelemacBoundary(H2dTelemacBoundary _init) {
! super(_init);
! //telemac
! initFrom(_init);
}
! protected final void initFrom(H2dTelemacBoundary _init) {
tracerType_= _init.tracerType_;
elevation_= _init.elevation_;
--- 227,245 ----
uType_= H2dBcType.LIBRE;
vType_= H2dBcType.LIBRE;
}
! // public H2dTelemacBoundary(H2dTelemacBoundary _init) {
! // super(_init);
! // //telemac
! // initFrom(_init);
! // }
! public H2dTelemacBoundary createMemento() {
! H2dTelemacBoundary r= new H2dTelemacBoundary();
! r.initFrom(this);
! return r;
}
! private final void initSimpleValues(H2dTelemacBoundary _init) {
! idxDeb_= _init.idxDeb_;
! idxFin_= _init.idxFin_;
! type_= _init.type_;
tracerType_= _init.tracerType_;
elevation_= _init.elevation_;
***************
*** 127,144 ****
uType_= _init.uType_;
vType_= _init.vType_;
- // hType_= _init.hType_;
}
! public final static boolean isVariableCompatible(
! H2dBoundaryType _b,
! H2dVariableType _v) {
! if (BORD_TYPE_VARIABLE_ACCEPTED == null)
! H2dTelemacBoundary.createMapBordTypeVar();
! H2dVariableType[] v= (H2dVariableType[])BORD_TYPE_VARIABLE_ACCEPTED.get(_b);
! if (v == null) {
! new Throwable("boundary not found").printStackTrace();
! return false;
}
- return Arrays.binarySearch(v, _v) >= 0;
}
/**
* Pour les bords permettant de modifier les comportements des variables u et v,
--- 251,359 ----
uType_= _init.uType_;
vType_= _init.vType_;
}
! protected final void fillListWithLiquidEvolution(List _l, int _idx) {
! if ((varEvolution_ != null) && (varEvolution_.size() > 0)) {
! for (Iterator it= varEvolution_.entrySet().iterator(); it.hasNext();) {
! Map.Entry e= (Map.Entry)it.next();
! H2dEvolutionFrontiereLiquideMutable liq=
! new H2dEvolutionFrontiereLiquideMutable(
! (H2dVariableType)e.getKey(),
! _idx);
! H2dEvolution evol= (H2dEvolution)e.getValue();
! liq.setEvolution(evol);
! if (evol.getUnite() == null) {
! evol.setUnite(((H2dVariableType)e.getKey()).getCommonUnit());
! }
! _l.add(liq);
! }
}
}
+ private final void initFrom(H2dTelemacBoundary _init) {
+ initSimpleValues(_init);
+ if (_init.varEvolution_ == null) {
+ if (varEvolution_ != null)
+ varEvolution_.clear();
+ } else
+ varEvolution_= new HashMap(_init.varEvolution_);
+ }
+ public final Map createVarEvolMemento() {
+ return (varEvolution_ == null) ? null : new HashMap(varEvolution_);
+ }
+ public final void updateVarEvolFromMemento(Map _m) {
+ if ((_m == null) || (_m.size() == 0)) {
+ if (DodicoLib.DEBUG)
+ DodicoLib.debug("memento is empty");
+ if ((varEvolution_ != null) && (varEvolution_.size() > 0)) {
+ for (Iterator it= varEvolution_.values().iterator(); it.hasNext();) {
+ ((H2dEvolution)it.next()).setUnUsed();
+ }
+ varEvolution_.clear();
+ }
+ } else if ((varEvolution_ == null) || (varEvolution_.size() == 0)) {
+ if (DodicoLib.DEBUG)
+ DodicoLib.debug("current is empty");
+ if (varEvolution_ == null)
+ varEvolution_= new HashMap(_m.size());
+ for (Iterator it= _m.entrySet().iterator(); it.hasNext();) {
+ Map.Entry e= (Map.Entry)it.next();
+ H2dEvolution evol= (H2dEvolution)e.getValue();
+ evol.setUsed();
+ varEvolution_.put((H2dVariableType)e.getKey(), evol);
+ }
+ } else {
+ Map newMap= new HashMap(_m.size());
+ if (DodicoLib.DEBUG)
+ DodicoLib.debug("synchronize current and memento");
+ for (Iterator it= varEvolution_.entrySet().iterator(); it.hasNext();) {
+ Map.Entry e= (Map.Entry)it.next();
+ H2dVariableType v= (H2dVariableType)e.getKey();
+ H2dEvolution evol= (H2dEvolution)e.getValue();
+ if (!_m.containsKey(v)) {
+ evol.setUnUsed();
+ } else {
+ H2dEvolution savedEvol= (H2dEvolution)_m.get(v);
+ newMap.put(v, savedEvol);
+ if (!savedEvol.equals(evol)) {
+ evol.setUnUsed();
+ savedEvol.setUsed();
+ }
+ }
+ }
+ for (Iterator it= _m.entrySet().iterator(); it.hasNext();) {
+ Map.Entry e= (Map.Entry)it.next();
+ H2dVariableType v= (H2dVariableType)e.getKey();
+ H2dEvolution evol= (H2dEvolution)e.getValue();
+ if (!varEvolution_.containsKey(v)) {
+ evol.setUsed();
+ newMap.put(v, evol);
+ }
+ }
+ varEvolution_= newMap;
+ }
+ }
+ protected final void updateFrom(H2dTelemacBoundary _init) {
+ initSimpleValues(_init);
+ updateVarEvolFromMemento(_init.varEvolution_);
+ }
+ public H2dEvolution getEvolution(H2dVariableType _t) {
+ return (
+ (varEvolution_ == null) ? null : (H2dEvolution)varEvolution_.get(_t));
+ }
+ public boolean containsEvol() {
+ return (varEvolution_ != null) && (varEvolution_.size() > 0);
+ }
+ // public final static boolean isVariableCompatible(
+ // H2dBoundaryType _b,
+ // H2dVariableType _v) {
+ // if (BORD_TYPE_VARIABLE_ACCEPTED == null)
+ // H2dTelemacBoundary.createMapBordTypeVar();
+ // DodicoPermanentList v=
+ // ((AvailableVariable)BORD_TYPE_VARIABLE_ACCEPTED.get(_b)).get;
+ // if (v == null) {
+ // new Throwable("boundary not found").printStackTrace();
+ // return false;
+ // }
+ // return Collections.binarySearch(v, _v) >= 0;
+ // }
/**
* Pour les bords permettant de modifier les comportements des variables u et v,
***************
*** 150,158 ****
*/
public final static boolean canUandVBeSetAsFixedFor(H2dBoundaryType _b) {
! if ((_b == H2dBoundaryType.LIQUIDE_HAUTEUR_VITESSES_IMPOSEES)
! || (_b == H2dBoundaryType.LIQUIDE_VITESSES_IMPOSEES))
! return true;
! else
! return false;
}
/**
--- 365,371 ----
*/
public final static boolean canUandVBeSetAsFixedFor(H2dBoundaryType _b) {
! return (
! (_b == H2dBoundaryType.LIQUIDE_HAUTEUR_VITESSES_IMPOSEES)
! || (_b == H2dBoundaryType.LIQUIDE_VITESSES_IMPOSEES));
}
/**
***************
*** 169,184 ****
return false;
}
! public boolean isVariableCompatibleWithBoundaryType(H2dVariableType _v) {
! return isVariableCompatible(getType(), _v);
}
! public H2dVariableType[] getVariablesAllowed() {
createMapBordTypeVar();
! H2dVariableType[] ri=
! (H2dVariableType[])BORD_TYPE_VARIABLE_ACCEPTED.get(getType());
! if (ri == null)
! return null;
! H2dVariableType[] r= new H2dVariableType[ri.length];
! System.arraycopy(ri, 0, r, 0, r.length);
! return r;
}
/**
--- 382,415 ----
return false;
}
!
! public final static boolean canUandVBeChanged(H2dBoundaryType _b) {
! return (
! (_b == H2dBoundaryType.LIQUIDE_HAUTEUR_VITESSES_IMPOSEES)
! || (_b == H2dBoundaryType.LIQUIDE_VITESSES_IMPOSEES)
! || (_b == H2dBoundaryType.LIQUIDE_DEBIT_IMPOSE) );
}
!
! public final boolean canUandVBeChanged() {
! return canUandVBeChanged(getType());
! }
!
! public DodicoPermanentList getVariablesAllowedForPoints(H2dTelemacDicoFileFormatVersion _v) {
! return getVariablesAllowedForPoints(this, _v);
! }
!
! public static DodicoPermanentList getVariablesAllowedForPoints(
! H2dTelemacBoundary _t,
! H2dTelemacDicoFileFormatVersion _v) {
createMapBordTypeVar();
! AvailableVariable v= (AvailableVariable)BORD_TYPE_VARIABLE_ACCEPTED.get(_t.getType());
! return ((v == null) ? null : v.getAvailableVariableForPoint(_v, _t));
! }
! public DodicoPermanentList getTransientVariableAllowed() {
! return getTransientVariableAllowed(getType());
! }
! public static DodicoPermanentList getTransientVariableAllowed(H2dBoundaryType _t) {
! createMapBordTypeVar();
! AvailableVariable v= (AvailableVariable)BORD_TYPE_VARIABLE_ACCEPTED.get(_t);
! return v == null ? null : v.getAvailableTransientVariable();
}
/**
***************
*** 188,212 ****
return tracerType_;
}
! // public int isIntersectBy(int _min, int _max, int _nbPt) {
! // if (isUnique())
! // return 1;
! // int deb= idxDeb_;
! // int fin= idxFin_;
! // if (!getType().isLiquide()) {
! // deb++;
! // fin--;
! // }
! // if (((idxDeb_ > idxFin_) && (deb < fin))
! // || ((idxDeb_ < idxFin_) && (deb > fin)))
! // new Throwable().printStackTrace();
! // return isBordIntersectBy(deb, fin, _min, _max, _nbPt);
! // }
! /**
! *
! */
! // protected void setTracerType(H2dClType _type) {
! // if (getType().isLiquide())
! // tracerType_= _type;
! // }
public boolean isTracerImposed() {
return tracerType_ == H2dBcType.PERMANENT;
--- 419,423 ----
return tracerType_;
}
!
public boolean isTracerImposed() {
return tracerType_ == H2dBcType.PERMANENT;
***************
*** 228,231 ****
--- 439,455 ----
return false;
}
+ protected void modifyUsedState(boolean _b) {
+ if ((varEvolution_ != null) && (varEvolution_.size() > 0)) {
+ if (_b) {
+ for (Iterator it= varEvolution_.values().iterator(); it.hasNext();) {
+ ((H2dEvolution)it.next()).setUsed();
+ }
+ } else {
+ for (Iterator it= varEvolution_.values().iterator(); it.hasNext();) {
+ ((H2dEvolution)it.next()).setUnUsed();
+ }
+ }
+ }
+ }
private boolean setVTypeImposed(boolean _b) {
if (_b != isVTypeImposed()) {
***************
*** 235,251 ****
return false;
}
! // protected boolean setHTypeImposed(boolean _b) {
! // if ((getType().isLiquide())
! // && (_b != isHTypeImposed())
! // && (isVariableCompatibleWithBoundaryType(H2dVariableType.COTE_EAU))) {
! // hType_= _b ? H2dClType.PERMANENT : H2dClType.LIBRE;
! // return true;
! // }
! // return false;
! // }
protected boolean setTracerTypeImposed(boolean _b) {
! if ((getType().isLiquide())
! && (_b != isTracerImposed())
! && (isVariableCompatibleWithBoundaryType(H2dVariableType.TRACEUR))) {
tracerType_= _b ? H2dBcType.PERMANENT : H2dBcType.LIBRE;
return true;
--- 459,465 ----
return false;
}
!
protected boolean setTracerTypeImposed(boolean _b) {
! if ((getType().isLiquide()) && (_b != isTracerImposed())) {
tracerType_= _b ? H2dBcType.PERMANENT : H2dBcType.LIBRE;
return true;
***************
*** 253,274 ****
return false;
}
! // protected boolean setUType(H2dClType _t) {
! // if ((_t == H2dClType.PERMANENT) || (_t == H2dClType.LIBRE)) {
! // return setUTypeImposed(_t == H2dClType.PERMANENT);
! // }
! // return false;
! // }
! // protected boolean setVType(H2dClType _t) {
! // if ((_t == H2dClType.PERMANENT) || (_t == H2dClType.LIBRE)) {
! // return setVTypeImposed(_t == H2dClType.PERMANENT);
! // }
! // return false;
! // }
! // protected boolean setHType(H2dClType _t) {
! // if ((_t == H2dClType.PERMANENT) || (_t == H2dClType.LIBRE)) {
! // return setHTypeImposed(_t == H2dClType.PERMANENT);
! // }
! // return false;
! // }
protected boolean setTracerType(H2dBcType _t) {
if ((_t == H2dBcType.PERMANENT) || (_t == H2dBcType.LIBRE)) {
--- 467,471 ----
return false;
}
!
protected boolean setTracerType(H2dBcType _t) {
if ((_t == H2dBcType.PERMANENT) || (_t == H2dBcType.LIBRE)) {
***************
*** 277,292 ****
return false;
}
! protected boolean setBordType(H2dBoundaryType _type) {
! boolean r= super.setBordType(_type);
if (r) {
createMapBordTypeVar();
! H2dVariableType[] vs=
! (H2dVariableType[])BORD_TYPE_VARIABLE_ACCEPTED.get(getType());
! H2dVariableType v;
! for (int i= VARIABLE_TYPE.size() - 1; i >= 0; i--) {
! v= (H2dVariableType)VARIABLE_TYPE.get(i);
! //if the variable is not compatible with the type of boundary
! if (Arrays.binarySearch(vs, v) < 0)
! setTypeImposed(v, false);
}
}
--- 474,504 ----
return false;
}
! protected boolean setBoundaryType(H2dBoundaryType _type) {
! boolean r= super.setBoundaryType(_type);
if (r) {
createMapBordTypeVar();
! if (!canTracerBeSet())
! setTypeImposed(H2dVariableType.TRACEUR, false);
! if (!canUandVBeChanged()){
! setTypeImposed(H2dVariableType.VITESSE_V, false);
! setTypeImposed(H2dVariableType.VITESSE_U, false);
! }
! if ((varEvolution_ != null) && (varEvolution_.size() > 0)) {
! DodicoPermanentList allow= getTransientVariableAllowed();
! H2dVariableType v;
! for (Iterator it= varEvolution_.entrySet().iterator(); it.hasNext();) {
! Map.Entry e= (Map.Entry)it.next();
! v= (H2dVariableType)e.getKey();
! H2dEvolution evol= (H2dEvolution)e.getValue();
! if (Collections.binarySearch(allow, v) < 0) {
! it.remove();
! evol.setUnUsed();
! }
! }
! }
! if ((_type != H2dBoundaryType.LIQUIDE_HAUTEUR_VITESSES_IMPOSEES)
! && (_type != H2dBoundaryType.LIQUIDE_VITESSES_IMPOSEES)) {
! uType_= H2dBcType.LIBRE;
! vType_= H2dBcType.LIBRE;
}
}
***************
*** 435,438 ****
--- 647,727 ----
return false;
}
+ }
+ public boolean isVariableTransient(H2dVariableType _v) {
+ if (varEvolution_ == null)
+ return false;
+ else
+ return varEvolution_.containsKey(_v);
+ }
+ public static boolean isTransientVariableAllowed(
+ H2dBoundaryType _t,
+ H2dVariableType _v) {
+ if (BORD_TYPE_VARIABLE_ACCEPTED == null)
+ createMapBordTypeVar();
+ AvailableVariable v= (AvailableVariable)BORD_TYPE_VARIABLE_ACCEPTED.get(_t);
+ if (v == null)
+ return false;
+ DodicoPermanentList l= v.getAvailableTransientVariable();
+ if (l == null)
+ return false;
+ else
+ return Collections.binarySearch(l, _v) >= 0;
+ }
+
+ public boolean isTransientVariableAllowed(H2dVariableType _v) {
+ return isTransientVariableAllowed(getType(), _v);
+ }
+ public static boolean canTracerBeSet(H2dBoundaryType _t) {
+ return _t.isLiquide();
+ }
+ public boolean canTracerBeSet() {
+ return canTracerBeSet(getType());
+ }
+
+ protected boolean setVariableTransient(
+ H2dVariableType _v,
+ H2dEvolution _evol) {
+ if (!isTransientVariableAllowed(_v))
+ return false;
+ if (varEvolution_ == null) {
+ if (_evol == H2dTelemacTransient.EMPTY_EVOL)
+ return false;
+ varEvolution_= new HashMap();
+ _evol.setUsed();
+ varEvolution_.put(_v, _evol);
+ return true;
+ } else if (!varEvolution_.containsKey(_v)) {
+ if (_evol == H2dTelemacTransient.EMPTY_EVOL)
+ return false;
+ varEvolution_.put(_v, _evol);
+ _evol.setUsed();
+ return true;
+ } else {
+ H2dEvolution old= (H2dEvolution)varEvolution_.get(_v);
+ if (_evol == H2dTelemacTransient.EMPTY_EVOL) {
+ old.setUnUsed();
+ varEvolution_.remove(_v);
+ return true;
+ } else if (old != _evol) {
+ old.setUnUsed();
+ varEvolution_.put(_v, _evol);
+ _evol.setUsed();
+ return true;
+ } else
+ return false;
+ }
+ }
+ protected boolean setVariableTransient(Map _m) {
+ if (_m == null)
+ return false;
+ boolean r= false;
+ for (Iterator it= _m.entrySet().iterator(); it.hasNext();) {
+ Map.Entry e= (Map.Entry)it.next();
+ r
+ |= setVariableTransient(
+ (H2dVariableType)e.getKey(),
+ (H2dEvolution)e.getValue());
+ }
+ return r;
}
protected boolean setTypeImposed(boolean _u, boolean _v, boolean _t) {
Index: H2dTelemacBoundaryCondition.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/h2d/telemac/H2dTelemacBoundaryCondition.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** H2dTelemacBoundaryCondition.java 25 Nov 2003 10:11:37 -0000 1.2
--- H2dTelemacBoundaryCondition.java 11 Dec 2003 12:41:27 -0000 1.3
***************
*** 23,37 ****
double traceurCoefA_;
double traceurCoefB_;
! public static final DodicoPermanentList VARIABLE_LIST=
! new DodicoPermanentList(
! DodicoLib.sort(
! new H2dVariableType[] {
! H2dVariableType.COTE_EAU,
! H2dVariableType.VITESSE_U,
! H2dVariableType.VITESSE_V,
! H2dVariableType.TRACEUR,
! H2dVariableType.TRACEUR_COEF_A,
! H2dVariableType.TRACEUR_COEF_B,
! H2dVariableType.RUGOSITE }));
/**
*
--- 23,37 ----
double traceurCoefA_;
double traceurCoefB_;
! // public static final DodicoPermanentList VARIABLE_LIST=
! // new DodicoPermanentList(
! // DodicoLib.sort(
! // new H2dVariableType[] {
! // H2dVariableType.COTE_EAU,
! // H2dVariableType.VITESSE_U,
! // H2dVariableType.VITESSE_V,
! // H2dVariableType.TRACEUR,
! // H2dVariableType.TRACEUR_COEF_A,
! // H2dVariableType.TRACEUR_COEF_B,
! // H2dVariableType.RUGOSITE }));
/**
*
Index: H2dTelemacBoundaryMutable.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/h2d/telemac/H2dTelemacBoundaryMutable.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** H2dTelemacBoundaryMutable.java 25 Nov 2003 10:11:37 -0000 1.2
--- H2dTelemacBoundaryMutable.java 11 Dec 2003 12:41:27 -0000 1.3
***************
*** 22,31 ****
super();
}
- /**
- * @param _init
- */
- public H2dTelemacBoundaryMutable(H2dTelemacBoundary _init) {
- super(_init);
- }
public boolean setFlowrate(String _string) {
return super.setFlowrate(_string);
--- 22,25 ----
***************
*** 52,57 ****
return super.setTracerTypeImposed(_b);
}
! public boolean setBordType(H2dBoundaryType _type) {
! return super.setBordType(_type);
}
public boolean setValue(H2dVariableType _type, String _string) {
--- 46,51 ----
return super.setTracerTypeImposed(_b);
}
! public boolean setBoundaryType(H2dBoundaryType _type) {
! return super.setBoundaryType(_type);
}
public boolean setValue(H2dVariableType _type, String _string) {
Index: H2dTelemacDicoFileFormatVersion.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/h2d/telemac/H2dTelemacDicoFileFormatVersion.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** H2dTelemacDicoFileFormatVersion.java 25 Nov 2003 10:11:37 -0000 1.4
--- H2dTelemacDicoFileFormatVersion.java 11 Dec 2003 12:41:27 -0000 1.5
***************
*** 29,32 ****
--- 29,33 ----
public abstract DicoEntite getMaillageEntiteFile();
public abstract DicoEntite getCLEntiteFile();
+ public abstract DicoEntite getCLLiquideEntiteFile();
public abstract DicoEntite getPrescribedFlowrate();
public abstract DicoEntite getPrescribedVelocity();
***************
*** 39,42 ****
* @return true if the velocities (or flowrate) are fixed for this value of velocity profil.
*/
! public abstract boolean isVelocitiesFixedByVelocityProfils(String _v);
}
--- 40,45 ----
* @return true if the velocities (or flowrate) are fixed for this value of velocity profil.
*/
! public abstract boolean isFlowrateComputeFromVelocities(String _v);
! public abstract boolean isFlowrateComputeFromVelocityU(String _v);
! public abstract boolean isFlowrateComputeFromElevation(String _v);
}
Index: H2dTelemacParameters.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/h2d/telemac/H2dTelemacParameters.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** H2dTelemacParameters.java 25 Nov 2003 10:11:37 -0000 1.2
--- H2dTelemacParameters.java 11 Dec 2003 12:41:27 -0000 1.3
***************
*** 13,17 ****
--- 13,20 ----
import org.fudaa.dodico.commun.DodicoPermanentList;
import org.fudaa.dodico.commun.ProgressionInterface;
+ import org.fudaa.dodico.dico.DicoParams;
import org.fudaa.dodico.h2d.H2dBcManagerBlockInterface;
+ import org.fudaa.dodico.h2d.H2dEvolutionFrontiereLiquide;
+ import org.fudaa.dodico.h2d.H2dEvolutionManager;
import org.fudaa.dodico.h2d.H2dParameters;
import org.fudaa.dodico.h2d.H2dResource;
***************
*** 47,50 ****
--- 50,66 ----
return BORD_LIST;
}
+ public static boolean isTransientAvailable(DicoParams _p){
+ return _p.getDicoFileFormat().getID().equals("TELEMAC2D");
+ }
+ public boolean isTransientAvailable(){
+ return isTransientAvailable(dicoParams_);
+ }
+
+ public H2dEvolutionManager getEvolMng() {
+ if (evolMng_ == null) {
+ evolMng_= new H2dEvolutionManager(listener_);
+ }
+ return evolMng_;
+ }
public void setProjectListener(H2dTelemacProjectDispatcherListener _l) {
if (_l == listener_)
***************
*** 98,101 ****
--- 114,127 ----
public H2dTelemacBcManager getTelemacCLManager() {
return clMng_;
+ }
+ public void setEvolution(H2dEvolutionFrontiereLiquide[] _liquid) {
+ if(_liquid!=null){
+ H2dEvolutionManager eMng=getEvolMng();
+ for(int i=_liquid.length-1;i>=0;i--){
+ eMng.add(_liquid[i].getEvol());
+
+ }
+ }
+ clMng_.setEvolution(_liquid);
}
/**
Index: H2dTelemacTransient.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/h2d/telemac/H2dTelemacTransient.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** H2dTelemacTransient.java 25 Nov 2003 10:11:37 -0000 1.2
--- H2dTelemacTransient.java 11 Dec 2003 12:41:27 -0000 1.3
***************
*** 11,14 ****
--- 11,16 ----
import org.fudaa.dodico.commun.DodicoLib;
import org.fudaa.dodico.commun.DodicoPermanentList;
+ import org.fudaa.dodico.h2d.H2dEvolution;
+ import org.fudaa.dodico.h2d.H2dResource;
import org.fudaa.dodico.h2d.type.H2dVariableType;
/**
***************
*** 17,20 ****
--- 19,24 ----
*/
public class H2dTelemacTransient {
+
+ public static H2dEvolution EMPTY_EVOL=new H2dEvolution(H2dResource.getS("Vide"));
public static DodicoPermanentList TRANSIENT_VARIABLES=
new DodicoPermanentList(
|
|
From: <de...@us...> - 2003-12-11 12:41:31
|
Update of /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/reflux
In directory sc8-pr-cvs1:/tmp/cvs-serv23146/reflux
Modified Files:
RefluxExec.java
Log Message:
Ajout de fonctionnalites au modele h2d
Index: RefluxExec.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/reflux/RefluxExec.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** RefluxExec.java 25 Nov 2003 10:11:49 -0000 1.3
--- RefluxExec.java 11 Dec 2003 12:41:28 -0000 1.4
***************
*** 9,12 ****
--- 9,14 ----
package org.fudaa.dodico.reflux;
import java.io.File;
+ import java.util.Arrays;
+ import java.util.List;
import com.memoire.fu.FuLib;
import org.fudaa.dodico.calcul.CalculExec;
***************
*** 19,29 ****
*/
public class RefluxExec extends CalculExec {
/**
! * les arguments _codeArgs sont ignores.
*/
! public String[] getLaunchArray(
File _paramsFile,
- String[] _codeArgs,
DodicoUI _ui) {
if (FuLib.isWindows())
return CalculExec.manageLauncher(
--- 21,36 ----
*/
public class RefluxExec extends CalculExec {
+ public RefluxExec() {
+ setChangeWorkingDirectory(true);
+ setLauchInNewTerm(true);
+ }
/**
! *
*/
! public String[] getLaunchCmd(
File _paramsFile,
DodicoUI _ui) {
+ String[] param=
+ new String[] { DodicoLib.getSansExtension(_paramsFile.getName())};
if (FuLib.isWindows())
return CalculExec.manageLauncher(
***************
*** 32,36 ****
"reflux-launch.tpl.bat",
"reflux-launch.bat",
! computeArgs(CalculExec.getWinParams(_paramsFile, null)),
_ui);
else if (FuLib.isLinux())
--- 39,43 ----
"reflux-launch.tpl.bat",
"reflux-launch.bat",
! param,
_ui);
else if (FuLib.isLinux())
***************
*** 40,59 ****
"reflux-launch.tpl.sh",
"reflux-launch.sh",
! computeArgs(CalculExec.getUnixParams(_paramsFile, null)),
_ui);
! else {
! return null;
! }
! }
! public int getMaxArgsNb() {
! return 0;
! }
! private String[] computeArgs(String[] _args) {
! if (_args != null) {
! int n= _args.length - 1;
! if (n >= 0)
! _args[n]= DodicoLib.getSansExtension(_args[n]);
! }
! return _args;
}
}
--- 47,53 ----
"reflux-launch.tpl.sh",
"reflux-launch.sh",
! param,
_ui);
! return null;
}
}
|
|
From: <de...@us...> - 2003-12-11 12:41:31
|
Update of /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/olb In directory sc8-pr-cvs1:/tmp/cvs-serv23146/olb Added Files: OLBExec.java Log Message: Ajout de fonctionnalites au modele h2d --- NEW FILE: OLBExec.java --- (This appears to be a binary file; contents omitted.) |
|
From: <de...@us...> - 2003-12-11 12:41:31
|
Update of /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/objet
In directory sc8-pr-cvs1:/tmp/cvs-serv23146/objet
Modified Files:
CExec.java
Log Message:
Ajout de fonctionnalites au modele h2d
Index: CExec.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/objet/CExec.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** CExec.java 25 Nov 2003 10:11:46 -0000 1.7
--- CExec.java 11 Dec 2003 12:41:27 -0000 1.8
***************
*** 9,12 ****
--- 9,13 ----
package org.fudaa.dodico.objet;
import java.io.BufferedReader;
+ import java.io.File;
import java.io.IOException;
import java.io.InputStreamReader;
***************
*** 34,37 ****
--- 35,39 ----
MyReaderThread thOut_, thErr_;
CExecListener listener_;
+ File execDirectory_;
/**
* Commandes a null et les exceptions seront catchés et ecrites sur la sortie
***************
*** 54,58 ****
*/
public void setCommand(String[] _cmd) {
- System.out.println(_cmd.length);
cmd_= _cmd;
}
--- 56,59 ----
***************
*** 98,102 ****
return;
try {
! _th.join(2000);
} catch (InterruptedException _e) {}
if (!_th.isAlive())
--- 99,103 ----
return;
try {
! _th.join(500);
} catch (InterruptedException _e) {}
if (!_th.isAlive())
***************
*** 111,115 ****
}
try {
! _th.join(1000);
} catch (InterruptedException _e) {}
//on a attendu 50ms, on interrompt le thread
--- 112,116 ----
}
try {
! _th.join(500);
} catch (InterruptedException _e) {}
//on a attendu 50ms, on interrompt le thread
***************
*** 117,125 ****
_th.finish();
try {
! _th.join(2000);
} catch (InterruptedException _e) {}
}
} catch (SecurityException _e) {
! System.err.println(_e.getMessage());
}
}
--- 118,126 ----
_th.finish();
try {
! _th.join(500);
} catch (InterruptedException _e) {}
}
} catch (SecurityException _e) {
! DodicoLib.error(_e.getMessage());
}
}
***************
*** 145,149 ****
if (DodicoLib.DEBUG)
System.out.println("lancement processus");
! p= Runtime.getRuntime().exec(cmd_);
if (listener_ != null)
listener_.setProcess(p);
--- 146,153 ----
if (DodicoLib.DEBUG)
System.out.println("lancement processus");
! if (execDirectory_ != null)
! p= Runtime.getRuntime().exec(cmd_,null, execDirectory_);
! else
! p= Runtime.getRuntime().exec(cmd_);
if (listener_ != null)
listener_.setProcess(p);
***************
*** 299,302 ****
--- 303,318 ----
public void setListener(CExecListener _listener) {
listener_= _listener;
+ }
+ /**
+ *
+ */
+ public File getExecDirectory() {
+ return execDirectory_;
+ }
+ /**
+ *
+ */
+ public void setExecDirectory(File _file) {
+ execDirectory_= _file;
}
}
|
Update of /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/h2d/type
In directory sc8-pr-cvs1:/tmp/cvs-serv23146/h2d/type
Modified Files:
H2dResolutionMethodType.java H2dResolutionSchemaType.java
H2dVariableType.java
Log Message:
Ajout de fonctionnalites au modele h2d
Index: H2dResolutionMethodType.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/h2d/type/H2dResolutionMethodType.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** H2dResolutionMethodType.java 25 Nov 2003 10:11:37 -0000 1.2
--- H2dResolutionMethodType.java 11 Dec 2003 12:41:27 -0000 1.3
***************
*** 8,13 ****
--- 8,15 ----
*/
package org.fudaa.dodico.h2d.type;
+ import java.util.Collections;
import java.util.Iterator;
import java.util.List;
+
import org.fudaa.dodico.commun.DodicoLib;
import org.fudaa.dodico.commun.DodicoPermanentList;
***************
*** 19,43 ****
public class H2dResolutionMethodType extends H2dEnumType {
public static H2dResolutionMethodType LINEAIRE=
! new H2dResolutionMethodType(1, H2dResource.getS("Linéaire"), "LINEAIRE");
public static H2dResolutionMethodType NEWTON_RAPHSON=
new H2dResolutionMethodType(
2,
H2dResource.getS("Newton Raphson"),
! "NEWTON");
public static H2dResolutionMethodType NEWTON_RAPHSON_BCD=
new H2dResolutionMethodType(
3,
! H2dResource.getS("Newton Raphson banc découvrant"),
! "NEWTON_BCD");
public static H2dResolutionMethodType SELECT_LUMPING=
new H2dResolutionMethodType(
4,
H2dResource.getS("Select Lumping"),
! "SELUMP");
public static H2dResolutionMethodType SELECT_LUMPING_BCD=
new H2dResolutionMethodType(
5,
! H2dResource.getS("Select Lumping banc découvrant"),
! "SELUMP_BCD");
public static final List LIST=
new DodicoPermanentList(
--- 21,61 ----
public class H2dResolutionMethodType extends H2dEnumType {
public static H2dResolutionMethodType LINEAIRE=
! new H2dResolutionMethodType(
! 1,
! H2dResource.getS("Linéaire"),
! "LINEAIRE",null);
public static H2dResolutionMethodType NEWTON_RAPHSON=
new H2dResolutionMethodType(
2,
H2dResource.getS("Newton Raphson"),
! "NEWTON",
! new H2dVariableType[] {
! H2dVariableType.RELAXATION,
! H2dVariableType.PRECISION_METHOD,
! H2dVariableType.NB_MAX_IT_METHOD });
public static H2dResolutionMethodType NEWTON_RAPHSON_BCD=
new H2dResolutionMethodType(
3,
! H2dResource.getS("Newton Raphson banc c/d"),
! "NEWTON_BCD",
! new H2dVariableType[] {
! H2dVariableType.RELAXATION,
! H2dVariableType.PRECISION_METHOD,
! H2dVariableType.NB_MAX_IT_METHOD,
! H2dVariableType.VISCOSITE,
! H2dVariableType.PRECISION_BCD_METHOD });
public static H2dResolutionMethodType SELECT_LUMPING=
new H2dResolutionMethodType(
4,
H2dResource.getS("Select Lumping"),
! "SELUMP",null);
public static H2dResolutionMethodType SELECT_LUMPING_BCD=
new H2dResolutionMethodType(
5,
! H2dResource.getS("Select Lumping banc c/d"),
! "SELUMP_BCD",
! new H2dVariableType[] {
! H2dVariableType.VISCOSITE,
! H2dVariableType.PRECISION_BCD_METHOD });
public static final List LIST=
new DodicoPermanentList(
***************
*** 50,60 ****
SELECT_LUMPING_BCD }));
private String refluxId_;
/**
* @param _id
* @param _nom
*/
! public H2dResolutionMethodType(int _id, String _nom, String _refluxId) {
super(_id, _nom);
refluxId_= _refluxId;
}
public static H2dResolutionMethodType getTypeForRefluxId(String _id) {
--- 68,85 ----
SELECT_LUMPING_BCD }));
private String refluxId_;
+ private DodicoPermanentList var_;
/**
* @param _id
* @param _nom
*/
! public H2dResolutionMethodType(
! int _id,
! String _nom,
! String _refluxId,
! H2dVariableType[] _var) {
super(_id, _nom);
refluxId_= _refluxId;
+ if (_var != null)
+ var_= new DodicoPermanentList(DodicoLib.sort(_var));
}
public static H2dResolutionMethodType getTypeForRefluxId(String _id) {
***************
*** 72,75 ****
--- 97,111 ----
public String getRefluxId() {
return refluxId_;
+ }
+
+ public DodicoPermanentList getVarList() {
+ return var_;
+ }
+
+ public boolean isUsed(H2dVariableType _t) {
+ return (var_ != null) && (Collections.binarySearch(var_, _t) >= 0);
+ }
+ public boolean needViscosity() {
+ return isUsed(H2dVariableType.VISCOSITE);
}
}
Index: H2dResolutionSchemaType.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/h2d/type/H2dResolutionSchemaType.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** H2dResolutionSchemaType.java 25 Nov 2003 10:11:37 -0000 1.2
--- H2dResolutionSchemaType.java 11 Dec 2003 12:41:27 -0000 1.3
***************
*** 8,11 ****
--- 8,12 ----
*/
package org.fudaa.dodico.h2d.type;
+ import java.util.Collections;
import java.util.Iterator;
import java.util.List;
***************
*** 18,21 ****
--- 19,30 ----
*/
public class H2dResolutionSchemaType extends H2dEnumType {
+ public static DodicoPermanentList TRANSITOIRE_VAR=
+ new DodicoPermanentList(
+ DodicoLib.sort(
+ new H2dVariableType[] {
+ H2dVariableType.FREQUENCE_PRINT_SCHEMA,
+ H2dVariableType.COEF_SCHEMA,
+ H2dVariableType.NB_TIME_STEP_SCHEMA,
+ H2dVariableType.VALUE_TIME_STEP_SCHEMA }));
public static H2dResolutionSchemaType STATIONNAIRE=
new H2dResolutionSchemaType(
***************
*** 36,40 ****
new H2dResolutionMethodType[] {
H2dResolutionMethodType.SELECT_LUMPING,
! H2dResolutionMethodType.SELECT_LUMPING_BCD });
public static H2dResolutionSchemaType EULER=
new H2dResolutionSchemaType(
--- 45,50 ----
new H2dResolutionMethodType[] {
H2dResolutionMethodType.SELECT_LUMPING,
! H2dResolutionMethodType.SELECT_LUMPING_BCD },
! TRANSITOIRE_VAR);
public static H2dResolutionSchemaType EULER=
new H2dResolutionSchemaType(
***************
*** 45,49 ****
H2dResolutionMethodType.NEWTON_RAPHSON,
H2dResolutionMethodType.NEWTON_RAPHSON_BCD,
! H2dResolutionMethodType.LINEAIRE });
public static final List LIST=
new DodicoPermanentList(
--- 55,60 ----
H2dResolutionMethodType.NEWTON_RAPHSON,
H2dResolutionMethodType.NEWTON_RAPHSON_BCD,
! H2dResolutionMethodType.LINEAIRE },
! TRANSITOIRE_VAR);
public static final List LIST=
new DodicoPermanentList(
***************
*** 59,64 ****
--- 70,81 ----
return null;
}
+ public static H2dResolutionSchemaType[] getRefluxTranSchema() {
+ return new H2dResolutionSchemaType[] {
+ H2dResolutionSchemaType.EULER,
+ H2dResolutionSchemaType.KAWAHARA };
+ }
String refluxId_;
DodicoPermanentList methodeList_;
+ DodicoPermanentList varList_;
/**
* @param _id
***************
*** 70,79 ****
String refluxId,
H2dResolutionMethodType[] _methode) {
super(_id, _nom);
refluxId_= refluxId;
! methodeList_= new DodicoPermanentList(_methode);
}
public boolean isSupported(H2dResolutionMethodType _methode) {
! return methodeList_.contains(_methode);
}
public String getRefluxId() {
--- 87,115 ----
String refluxId,
H2dResolutionMethodType[] _methode) {
+ this(_id, _nom, refluxId, _methode, null);
+ }
+ public H2dResolutionSchemaType(
+ int _id,
+ String _nom,
+ String refluxId,
+ H2dResolutionMethodType[] _methode,
+ DodicoPermanentList _var) {
super(_id, _nom);
refluxId_= refluxId;
! methodeList_= new DodicoPermanentList(DodicoLib.sort(_methode));
! if (_var != null)
! varList_= _var;
}
public boolean isSupported(H2dResolutionMethodType _methode) {
! return Collections.binarySearch(methodeList_, _methode) >= 0;
! }
! public DodicoPermanentList getMethodList() {
! return methodeList_;
! }
! public DodicoPermanentList getVarList() {
! return varList_;
! }
! public boolean isUsed(H2dVariableType _t) {
! return (varList_ != null) && (Collections.binarySearch(varList_, _t) >= 0);
}
public String getRefluxId() {
Index: H2dVariableType.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/dodico/src/org/fudaa/dodico/h2d/type/H2dVariableType.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** H2dVariableType.java 25 Nov 2003 10:11:37 -0000 1.6
--- H2dVariableType.java 11 Dec 2003 12:41:27 -0000 1.7
***************
*** 23,26 ****
--- 23,34 ----
return _c.getQ();
}
+ public boolean canBeTransient(){
+ return true;
+ }
+
+ public String getCommonUnit(){
+ return "m3/s";
+
+ }
};
public static final H2dVariableType COTE_EAU=
***************
*** 29,32 ****
--- 37,48 ----
return _c.getH();
}
+ public boolean canBeTransient(){
+ return true;
+ }
+
+ public String getCommonUnit(){
+ return "m";
+
+ }
};
public static final H2dVariableType TRACEUR=
***************
*** 35,38 ****
--- 51,62 ----
return _c.getTracer();
}
+ public boolean canBeTransient(){
+ return true;
+ }
+
+ public String getCommonUnit(){
+ return "g/l";
+
+ }
};
public static final H2dVariableType TRACEUR_COEF_A=
***************
*** 41,44 ****
--- 65,73 ----
return _c.getTracerCoeffA();
}
+
+ public String getCommonUnit(){
+ return DodicoLib.EMPTY_STRING;
+
+ }
};
public static final H2dVariableType TRACEUR_COEF_B=
***************
*** 47,50 ****
--- 76,85 ----
return _c.getTracerCoeffB();
}
+
+ public String getCommonUnit(){
+ return DodicoLib.EMPTY_STRING;
+
+ }
+
};
public static final H2dVariableType VITESSE_U=
***************
*** 53,56 ****
--- 88,99 ----
return _c.getU();
}
+ public boolean canBeTransient(){
+ return true;
+ }
+
+ public String getCommonUnit(){
+ return "m/s";
+
+ }
};
public static final H2dVariableType VITESSE_V=
***************
*** 59,62 ****
--- 102,113 ----
return _c.getV();
}
+ public boolean canBeTransient(){
+ return true;
+ }
+
+ public String getCommonUnit(){
+ return "m/s";
+
+ }
};
public static final H2dVariableType RUGOSITE=
***************
*** 89,106 ****
return _c.getVelocity();
}
};
- private static DodicoPermanentList LIST_REFLUX;
- public static List LIST_REFLUX() {
- if (LIST_REFLUX == null)
- LIST_REFLUX=
- new DodicoPermanentList(
- DodicoLib.sort(
- new H2dVariableType[] {
- ALPHA_LONGUEUR_MELANGE,
- RUGOSITE,
- VISCOSITE,
- PERTE_CHARGE }));
- return LIST_REFLUX;
- }
public final static boolean isTracerVariable(H2dVariableType _t) {
return (_t == H2dVariableType.TRACEUR)
--- 140,200 ----
return _c.getVelocity();
}
+
+ public String getCommonUnit(){
+ return "m/s";
+
+ }
+ };
+ public static final H2dVariableType RELAXATION=
+ new H2dVariableType(13, H2dResource.getS("Relaxation"), null) {
+ public double getValue(H2dVariableTypeContainer _c) {
+ return 0;
+ }
+ };
+ public static final H2dVariableType PRECISION_METHOD=
+ new H2dVariableType(13, H2dResource.getS("Précision"), null) {
+ public double getValue(H2dVariableTypeContainer _c) {
+ return 0;
+ }
+ };
+ public static final H2dVariableType PRECISION_BCD_METHOD=
+ new H2dVariableType(14, H2dResource.getS("Précision banc c/d"), null) {
+ public double getValue(H2dVariableTypeContainer _c) {
+ return 0;
+ }
+ };
+ public static final H2dVariableType NB_MAX_IT_METHOD=
+ new H2dVariableType(15, H2dResource.getS("Nombre d'itération max"), null) {
+ public double getValue(H2dVariableTypeContainer _c) {
+ return 0;
+ }
+ public boolean isInteger(){return true;}
+ };
+ public static final H2dVariableType FREQUENCE_PRINT_SCHEMA=
+ new H2dVariableType(16, H2dResource.getS("Fréquence impression"), null) {
+ public double getValue(H2dVariableTypeContainer _c) {
+ return 0;
+ }
+ public boolean isInteger(){return true;}
+ };
+ public static final H2dVariableType COEF_SCHEMA=
+ new H2dVariableType(17, H2dResource.getS("Coefficient schéma"), null) {
+ public double getValue(H2dVariableTypeContainer _c) {
+ return 0;
+ }
+ };
+ public static final H2dVariableType NB_TIME_STEP_SCHEMA=
+ new H2dVariableType(18, H2dResource.getS("Nombre de pas de temps"), null) {
+ public double getValue(H2dVariableTypeContainer _c) {
+ return 0;
+ }
+ public boolean isInteger(){return true;}
+ };
+ public static final H2dVariableType VALUE_TIME_STEP_SCHEMA=
+ new H2dVariableType(19, H2dResource.getS("Valeur pas de temps"), null) {
+ public double getValue(H2dVariableTypeContainer _c) {
+ return 0;
+ }
};
public final static boolean isTracerVariable(H2dVariableType _t) {
return (_t == H2dVariableType.TRACEUR)
***************
*** 125,128 ****
--- 219,232 ----
return _o == null ? false : (_o.id_ == id_);
}
+
+ public boolean canBeTransient(){
+ return false;
+ }
+
+ public String getCommonUnit(){
+ return DodicoLib.EMPTY_STRING;
+ }
+
+ public boolean isInteger(){return false;}
public abstract double getValue(H2dVariableTypeContainer _container);
}
|
|
From: <de...@us...> - 2003-12-11 12:39:55
|
Update of /cvsroot/fudaa/fudaa_devel/ctulu/src/ghm/followgui In directory sc8-pr-cvs1:/tmp/cvs-serv22884/followgui Log Message: Directory /cvsroot/fudaa/fudaa_devel/ctulu/src/ghm/followgui added to the repository |
|
From: <de...@us...> - 2003-12-11 12:39:55
|
Update of /cvsroot/fudaa/fudaa_devel/ctulu/src/ghm/follow In directory sc8-pr-cvs1:/tmp/cvs-serv22884/follow Log Message: Directory /cvsroot/fudaa/fudaa_devel/ctulu/src/ghm/follow added to the repository |
|
From: <de...@us...> - 2003-12-11 12:37:44
|
Update of /cvsroot/fudaa/fudaa_devel/ctulu/src/ghm In directory sc8-pr-cvs1:/tmp/cvs-serv22518/ghm Log Message: Directory /cvsroot/fudaa/fudaa_devel/ctulu/src/ghm added to the repository |
|
From: <jm_...@us...> - 2003-12-09 16:27:37
|
Update of /cvsroot/fudaa//fudaa_devel/dodico/src/org/fudaa/dodico/mascaret
In directory sc8-pr-cvs1:/tmp/cvs-serv27162/dodico/src/org/fudaa/dodico/mascaret
Modified Files:
CConversionHydraulique1d.java
Log Message:
Version du code = 2
Index: CConversionHydraulique1d.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/dodico/src/org/fudaa/dodico/mascaret/CConversionHydraulique1d.java,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -d -r1.10 -r1.11
*** CConversionHydraulique1d.java 8 Dec 2003 18:22:47 -0000 1.10
--- CConversionHydraulique1d.java 9 Dec 2003 16:27:33 -0000 1.11
***************
*** 229,233 ****
SParametresGen paramMas= new SParametresGen();
// version du code
! paramMas.versionCode= 1;
// noyau code : 1->SARAP, 2->REZO, 3->MASCARET
paramMas.code= regime.value() + 1;
--- 229,233 ----
SParametresGen paramMas= new SParametresGen();
// version du code
! paramMas.versionCode= 2;
// noyau code : 1->SARAP, 2->REZO, 3->MASCARET
paramMas.code= regime.value() + 1;
|
|
From: <jm_...@us...> - 2003-12-08 18:22:51
|
Update of /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/mascaret
In directory sc8-pr-cvs1:/tmp/cvs-serv30418/fudaa/src/org/fudaa/fudaa/mascaret
Modified Files:
MascaretImplementation.java
Log Message:
Mise à jour des nouvelles fonctionnalités Casier
YapodTestEnumereCorba : sérialise aussi
Debug léger
Index: MascaretImplementation.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/mascaret/MascaretImplementation.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** MascaretImplementation.java 25 Nov 2003 10:13:58 -0000 1.8
--- MascaretImplementation.java 8 Dec 2003 18:22:48 -0000 1.9
***************
*** 137,142 ****
static {
isApp_.name= "Mascaret";
! isApp_.version= "1.1";
! isApp_.date= "05-Aug-2003";
isApp_.rights= "Tous droits réservés. EDF (c) 2001-2003";
isApp_.contact= "nic...@ed...";
--- 137,142 ----
static {
isApp_.name= "Mascaret";
! isApp_.version= "1.1.1";
! isApp_.date= "08-Dec-2003";
isApp_.rights= "Tous droits réservés. EDF (c) 2001-2003";
isApp_.contact= "nic...@ed...";
***************
*** 156,160 ****
isApp_.thanks= new String[] { "Fudaa team" };
idApp_.name= "Etude";
! idApp_.version= "1.1";
idApp_.organization= "EDF";
idApp_.author= "Jean-Marc.Lacombe";
--- 156,160 ----
isApp_.thanks= new String[] { "Fudaa team" };
idApp_.name= "Etude";
! idApp_.version= "1.1.1";
idApp_.organization= "EDF";
idApp_.author= "Jean-Marc.Lacombe";
***************
*** 201,205 ****
((BuMenu)mb.getMenu("IMPORTER")).addMenuItem("XML", "IMPORTXML", true);
((BuMenu)mb.getMenu("EXPORTER")).addMenuItem(
! "Mascaret 5.1",
"EXPORTMASCARET",
false);
--- 201,205 ----
((BuMenu)mb.getMenu("IMPORTER")).addMenuItem("XML", "IMPORTXML", true);
((BuMenu)mb.getMenu("EXPORTER")).addMenuItem(
! "Mascaret 5.2",
"EXPORTMASCARET",
false);
***************
*** 364,368 ****
getApp(),
getInformationsSoftware(),
! "Noyau de calcul:\n Mascaret 5.1\nAuteur:\n EDF/LNHE\nContact:\n Nicole Goutal (EDF R&D / LNHE)")
.activate();
} else if (action.equals("CREER")) {
--- 364,368 ----
getApp(),
getInformationsSoftware(),
! "Noyau de calcul:\n Mascaret 5.2\nAuteur:\n EDF/LNHE\nContact:\n Nicole Goutal (EDF R&D / LNHE)")
.activate();
} else if (action.equals("CREER")) {
|
|
From: <jm_...@us...> - 2003-12-08 18:22:51
|
Update of /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/reseau
In directory sc8-pr-cvs1:/tmp/cvs-serv30418/fudaa/src/org/fudaa/fudaa/hydraulique1d/reseau
Modified Files:
Hydraulique1dReseauFrame.java
Hydraulique1dReseauGridAdapter.java
Log Message:
Mise à jour des nouvelles fonctionnalités Casier
YapodTestEnumereCorba : sérialise aussi
Debug léger
Index: Hydraulique1dReseauFrame.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/reseau/Hydraulique1dReseauFrame.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** Hydraulique1dReseauFrame.java 25 Nov 2003 10:13:47 -0000 1.8
--- Hydraulique1dReseauFrame.java 8 Dec 2003 18:22:48 -0000 1.9
***************
*** 8,37 ****
*/
package org.fudaa.fudaa.hydraulique1d.reseau;
! import com.memoire.dja.*;
! import org.fudaa.ebli.impression.EbliDjaFrame;
! import com.memoire.bu.*;
! import org.fudaa.fudaa.hydraulique1d.ihmhelper.Hydraulique1dIHMRepository;
! import org.fudaa.fudaa.hydraulique1d.reseau.*;
! import org.fudaa.fudaa.hydraulique1d.editor.*;
! import org.fudaa.fudaa.hydraulique1d.*;
! import java.util.*;
! import java.awt.*;
! import java.awt.event.*;
! import javax.swing.*;
import javax.swing.border.BevelBorder;
import org.fudaa.ebli.impression.EbliDjaFrame;
! import org.fudaa.dodico.hydraulique1d.*;
! import org.fudaa.dodico.corba.hydraulique1d.*;
! import org.fudaa.dodico.corba.hydraulique1d.singularite.*;
/**
* @version $Revision$ $Date$ by $Author$
* @author Jean-Marc Lacombe
*/
! public class Hydraulique1dReseauFrame extends EbliDjaFrame {
! protected BuPopupButton pbReseau_;
IEtude1d etude_;
IReseau reseau_;
Hydraulique1dIHMRepository ihmP_;
BuLabel lbStatus1_, lbStatus2_;
public Hydraulique1dReseauFrame(
BuCommonImplementation _app,
--- 8,72 ----
*/
package org.fudaa.fudaa.hydraulique1d.reseau;
! import java.util.Enumeration;
! import java.awt.Color;
! import java.awt.Dimension;
! import java.awt.event.ActionEvent;
! import javax.swing.JComponent;
import javax.swing.border.BevelBorder;
+ import org.fudaa.dodico.corba.evenement.IObjetEvent;
+ import org.fudaa.dodico.corba.evenement.IObjetEventListenerSupport;
+ import org.fudaa.dodico.corba.hydraulique1d.casier.ICaracteristiqueLiaison;
+ import org.fudaa.dodico.corba.hydraulique1d.LSensDebitLiaison;
+ import org.fudaa.dodico.corba.hydraulique1d.IBief;
+ import org.fudaa.dodico.corba.hydraulique1d.ICasier;
+ import org.fudaa.dodico.corba.hydraulique1d.IEtude1d;
+ import org.fudaa.dodico.corba.hydraulique1d.IExtremite;
+ import org.fudaa.dodico.corba.hydraulique1d.ILiaison;
+ import org.fudaa.dodico.corba.hydraulique1d.INoeud;
+ import org.fudaa.dodico.corba.hydraulique1d.IReseau;
+ import org.fudaa.dodico.corba.hydraulique1d.ISingularite;
+ import org.fudaa.dodico.corba.hydraulique1d.LRegime;
+ import org.fudaa.dodico.corba.hydraulique1d.singularite.IApport;
+ import org.fudaa.dodico.corba.hydraulique1d.singularite.IDeversoir;
+ import org.fudaa.dodico.corba.hydraulique1d.singularite.IPerteCharge;
+ import org.fudaa.dodico.corba.hydraulique1d.singularite.ISeuil;
+ import org.fudaa.dodico.corba.objet.IObjet;
+ import org.fudaa.dodico.evenement.DObjetEventListenerSupport;
+ import org.fudaa.dodico.evenement.ObjetEventListener;
+ import org.fudaa.dodico.hydraulique1d.CGlobal;
+ import org.fudaa.dodico.objet.CDodico;
import org.fudaa.ebli.impression.EbliDjaFrame;
! import org.fudaa.fudaa.hydraulique1d.Hydraulique1dBaseApplication;
! import org.fudaa.fudaa.hydraulique1d.Hydraulique1dResource;
! import org.fudaa.fudaa.hydraulique1d.editor.Hydraulique1dSeuilChooser;
! import org.fudaa.fudaa.hydraulique1d.ihmhelper.Hydraulique1dIHMRepository;
! import com.memoire.bu.BuBorderLayout;
! import com.memoire.bu.BuCommonImplementation;
! import com.memoire.bu.BuCommonInterface;
! import com.memoire.bu.BuDesktop;
! import com.memoire.bu.BuDialogMessage;
! import com.memoire.bu.BuLabel;
! import com.memoire.bu.BuPanel;
! import com.memoire.bu.BuPopupButton;
! import com.memoire.dja.DjaGrid;
! import com.memoire.dja.DjaGridInteractive;
! import com.memoire.dja.DjaObject;
! import com.memoire.dja.DjaPaletteBracket;
! import com.memoire.dja.DjaPaletteStroke;
! import com.memoire.dja.DjaPaletteThickness;
! import com.memoire.dja.DjaResource;
/**
* @version $Revision$ $Date$ by $Author$
* @author Jean-Marc Lacombe
*/
! public final class Hydraulique1dReseauFrame
! extends EbliDjaFrame implements ObjetEventListener {
! private BuPopupButton pbReseau_;
IEtude1d etude_;
IReseau reseau_;
Hydraulique1dIHMRepository ihmP_;
BuLabel lbStatus1_, lbStatus2_;
+ private DObjetEventListenerSupport evtSupport_;
+
public Hydraulique1dReseauFrame(
BuCommonImplementation _app,
***************
*** 51,54 ****
--- 86,95 ----
reseau_= _etude.reseau();
ihmP_= _ihmP;
+ // écouteur des évènementss hydraulique1d
+ evtSupport_= new DObjetEventListenerSupport();
+ evtSupport_.clientListener(this);
+ CDodico.findUsine().addObjetEventListener(
+ (IObjetEventListenerSupport)evtSupport_.tie());
+ //
Hydraulique1dReseauPalette srcReseau= new Hydraulique1dReseauPalette(this);
pbReseau_= new BuPopupButton("Reseau hydraulique", srcReseau);
***************
*** 362,370 ****
}
}
- /*public String[] getEnabledActions()
- {
- String[] r=new String[] { "IMPRIMER","PREVISUALISER","MISEENPAGE" };
- return r;
- }*/
public JComponent[] getSpecificTools() {
JComponent[] r;
--- 403,406 ----
***************
*** 393,396 ****
--- 429,533 ----
r[17]= pbReseau_;
return r;
+ }
+ /**
+ * Implementation de ObjetEventListener appelé en cas de création.
+ * @param e l'évement corba à traiter en cas de création.
+ */
+ public void objetCree(IObjetEvent e) {
+ }
+ /**
+ * Implementation de ObjetEventListener appelé en cas de suppression.
+ * @param e l'évement corba à traiter en cas de création.
+ */
+ public void objetSupprime(IObjetEvent e) {
+ }
+ /**
+ * Implementation de ObjetEventListener appelé en cas de modification.
+ * @param e l'évement corba à traiter en cas de création.
+ */
+ public void objetModifie(IObjetEvent e) {
+ IObjet source = e.getSource();
+ String champ = e.getChamp();
+ if (("sensDebit".equals(champ)) &&
+ (source instanceof ICaracteristiqueLiaison)) {
+ ICaracteristiqueLiaison icaracLiaison = (ICaracteristiqueLiaison) source;
+ Hydraulique1dReseauLiaisonCasier liaisonGraphique = rechercheLiaison(icaracLiaison);
+ if (liaisonGraphique == null) {
+ System.out.println("rechercheLiaison(icaracLiaison) == null");
+ return;
+ }
+ int sensDebit = icaracLiaison.getSensDebit().value();
+ switch (sensDebit) {
+ case LSensDebitLiaison._DEUX_SENS:
+ liaisonGraphique.setBeginType(0);
+ liaisonGraphique.setEndType(0);
+ break;
+ case LSensDebitLiaison._FIN_VERS_ORIGINE:
+ liaisonGraphique.setBeginType(5);
+ liaisonGraphique.setEndType(0);
+ break;
+ case LSensDebitLiaison._ORIGINE_VERS_FIN:
+ liaisonGraphique.setBeginType(0);
+ liaisonGraphique.setEndType(5);
+ break;
+ }
+ } else if (("caracteristiques".equals(champ)) &&
+ (source instanceof ILiaison)) {
+ ILiaison iliaison = (ILiaison)source;
+ Hydraulique1dReseauLiaisonCasier liaisonGraph = rechercheLiaison(iliaison);
+ if (liaisonGraph == null) {
+ System.out.println("rechercheLiaison(iliaison) == null");
+ return;
+ }
+ if (iliaison.isChenal()) {
+ liaisonGraph.setBeginType(0);
+ liaisonGraph.setEndType(0);
+ liaisonGraph.setForeground(Color.green);
+ } else if (iliaison.isOrifice()) {
+ liaisonGraph.setForeground(Color.orange);
+ } else if (iliaison.isSeuil()) {
+ liaisonGraph.setBeginType(0);
+ liaisonGraph.setEndType(0);
+ liaisonGraph.setForeground(Color.blue);
+ } else if (iliaison.isSiphon()) {
+ liaisonGraph.setBeginType(0);
+ liaisonGraph.setEndType(0);
+ liaisonGraph.setForeground(Color.red);
+ }
+ }
+
+ }
+ private Hydraulique1dReseauLiaisonCasier rechercheLiaison(
+ ICaracteristiqueLiaison icaracLiai) {
+ System.out.println("rechercheLiaison(icaracLiai="+icaracLiai.enChaine());
+ DjaGridInteractive grille= (DjaGridInteractive)grid_;
+ Enumeration enum= grille.getObjects().
+ enumerate(Hydraulique1dReseauLiaisonCasier.class);
+ while(enum.hasMoreElements()) {
+ Hydraulique1dReseauLiaisonCasier liaisonGraph =
+ (Hydraulique1dReseauLiaisonCasier)enum.nextElement();
+ ILiaison iliaison = (ILiaison)liaisonGraph.getData("liaison");
+ System.out.println("liaisonGraph.getData(liaison)="+iliaison.enChaine());
+ if (icaracLiai.id() == iliaison.caracteristiques().id() ) {
+ return liaisonGraph;
+ }
+ }
+ return null;
+ }
+ private Hydraulique1dReseauLiaisonCasier rechercheLiaison(ILiaison iLiaison) {
+ System.out.println("rechercheLiaison(iLiaison="+iLiaison.enChaine());
+ DjaGridInteractive grille= (DjaGridInteractive)grid_;
+ Enumeration enum= grille.getObjects().
+ enumerate(Hydraulique1dReseauLiaisonCasier.class);
+ while(enum.hasMoreElements()) {
+ Hydraulique1dReseauLiaisonCasier liaisonGraph =
+ (Hydraulique1dReseauLiaisonCasier)enum.nextElement();
+ ILiaison liaison = (ILiaison)liaisonGraph.getData("liaison");
+ System.out.println("liaisonGraph.getData(liaison)="+liaison.enChaine());
+ if (liaison.enChaine().equals(iLiaison.enChaine()) ) {
+ return liaisonGraph;
+ }
+ }
+ return null;
}
private boolean casierAutoriser() {
Index: Hydraulique1dReseauGridAdapter.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/reseau/Hydraulique1dReseauGridAdapter.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** Hydraulique1dReseauGridAdapter.java 25 Nov 2003 10:13:47 -0000 1.5
--- Hydraulique1dReseauGridAdapter.java 8 Dec 2003 18:22:48 -0000 1.6
***************
*** 53,74 ****
}
public void objectConnected(DjaGridEvent evt) {
! if (evt.getObject() instanceof Hydraulique1dReseauSingularite) {
! Hydraulique1dReseauSingularite sing=
! (Hydraulique1dReseauSingularite)evt.getObject();
! Hydraulique1dReseauBiefCourbe leBief=
! (Hydraulique1dReseauBiefCourbe)sing.getBeginObject();
Enumeration enum= evt.getGrid().getObjects().elements();
! int nbSingSurLeBief= 0;
while (enum.hasMoreElements()) {
Object o= enum.nextElement();
! if (o instanceof Hydraulique1dReseauSingularite) {
! Hydraulique1dReseauSingularite s= (Hydraulique1dReseauSingularite)o;
! if (s.getBeginObject() == leBief) {
! nbSingSurLeBief++;
}
}
}
! if (nbSingSurLeBief == leBief.nbAnchors) {
! leBief.setNbAnchors(nbSingSurLeBief + 1);
leBief.paintAnchors(evt.getGrid().getGraphics());
}
--- 53,80 ----
}
public void objectConnected(DjaGridEvent evt) {
! if ( (evt.getObject() instanceof Hydraulique1dReseauSingularite)
! || (evt.getObject() instanceof Hydraulique1dReseauLiaisonCasier) ) {
! DjaLink lien=(DjaLink)evt.getObject();
! Hydraulique1dReseauBiefCourbe leBief= null;
! if (lien.getBeginObject() instanceof Hydraulique1dReseauBiefCourbe) {
! leBief=(Hydraulique1dReseauBiefCourbe)lien.getBeginObject();
! } else if (lien.getEndObject() instanceof Hydraulique1dReseauBiefCourbe) {
! leBief=(Hydraulique1dReseauBiefCourbe)lien.getEndObject();
! }
! if (leBief == null) return;
Enumeration enum= evt.getGrid().getObjects().elements();
! int nbLienSurLeBief= 0;
while (enum.hasMoreElements()) {
Object o= enum.nextElement();
! if ( (o instanceof Hydraulique1dReseauSingularite)
! || (o instanceof Hydraulique1dReseauLiaisonCasier) ) {
! DjaLink l= (DjaLink)o;
! if ((l.getBeginObject() == leBief)||(l.getEndObject() == leBief)) {
! nbLienSurLeBief++;
}
}
}
! if (nbLienSurLeBief == leBief.nbAnchors) {
! leBief.setNbAnchors(nbLienSurLeBief + 1);
leBief.paintAnchors(evt.getGrid().getGraphics());
}
|
|
From: <jm_...@us...> - 2003-12-08 18:22:51
|
Update of /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/casier
In directory sc8-pr-cvs1:/tmp/cvs-serv30418/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/casier
Modified Files:
Hydraulique1dCasierCaracLiaisonPanel.java
Log Message:
Mise à jour des nouvelles fonctionnalités Casier
YapodTestEnumereCorba : sérialise aussi
Debug léger
Index: Hydraulique1dCasierCaracLiaisonPanel.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/casier/Hydraulique1dCasierCaracLiaisonPanel.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** Hydraulique1dCasierCaracLiaisonPanel.java 25 Nov 2003 10:13:45 -0000 1.4
--- Hydraulique1dCasierCaracLiaisonPanel.java 8 Dec 2003 18:22:47 -0000 1.5
***************
*** 8,29 ****
*/
package org.fudaa.fudaa.hydraulique1d.editor.casier;
! import org.fudaa.dodico.corba.objet.*;
import org.fudaa.dodico.corba.hydraulique1d.ILiaison;
import org.fudaa.dodico.corba.hydraulique1d.LSensDebitLiaison;
- import org.fudaa.dodico.hydraulique1d.*;
- import com.memoire.bu.*;
- import org.fudaa.ebli.ressource.*;
- import org.fudaa.ebli.dialog.*;
import org.fudaa.ebli.controle.border.LineChoiceBorder;
! import org.fudaa.ebli.commun.*;
! import org.fudaa.fudaa.commun.*;
! import org.fudaa.fudaa.hydraulique1d.*;
! import org.fudaa.fudaa.hydraulique1d.editor.*;
! import javax.swing.*;
! import javax.swing.border.*;
! import java.awt.*;
! import java.awt.event.*;
! import java.beans.*;
! import java.util.*;
/**
* @version $Revision$ $Date$ by $Author$
--- 8,31 ----
*/
package org.fudaa.fudaa.hydraulique1d.editor.casier;
! import java.awt.Dimension;
! import java.awt.GridBagConstraints;
! import java.awt.GridBagLayout;
! import java.awt.Insets;
! import java.awt.event.ActionEvent;
! import java.awt.event.ActionListener;
! import javax.swing.BorderFactory;
! import javax.swing.ButtonGroup;
! import javax.swing.JFrame;
! import javax.swing.border.Border;
import org.fudaa.dodico.corba.hydraulique1d.ILiaison;
import org.fudaa.dodico.corba.hydraulique1d.LSensDebitLiaison;
import org.fudaa.ebli.controle.border.LineChoiceBorder;
! import com.memoire.bu.BuBorderLayout;
! import com.memoire.bu.BuComboBox;
! import com.memoire.bu.BuGridLayout;
! import com.memoire.bu.BuLabel;
! import com.memoire.bu.BuPanel;
! import com.memoire.bu.BuRadioButton;
! import com.memoire.bu.BuTextField;
/**
* @version $Revision$ $Date$ by $Author$
***************
*** 40,47 ****
tfSiphonSection_,
tfSiphonCoefPerteCharge_;
! private BuTextField tfOrificeCoefPerteCharge_,
! tfOrificeSection_,
! tfOrificeCoefQ_;
! private BuTextField tfOrificeLargeur_, tfOrificeCoteMin_;
private BuComboBox cmbSensDebit_;
private BuPanel pnTFSeuil_, pnTFChenal_, pnTFSiphon_, pnTFOrifice_;
--- 42,47 ----
tfSiphonSection_,
tfSiphonCoefPerteCharge_;
! private BuTextField tfOrificeSection_, tfOrificeCoefQSeuil_;
! private BuTextField tfOrificeLargeur_, tfOrificeCoefQOrifice_;
private BuComboBox cmbSensDebit_;
private BuPanel pnTFSeuil_, pnTFChenal_, pnTFSiphon_, pnTFOrifice_;
***************
*** 126,131 ****
double coefActivation=
((Double)tfSeuilCoefActivation_.getValue()).doubleValue();
! if (coefActivation != model_.getCoefEnnoiment()) {
! model_.setCoefEnnoiment(coefActivation);
changed= true;
}
--- 126,131 ----
double coefActivation=
((Double)tfSeuilCoefActivation_.getValue()).doubleValue();
! if (coefActivation != model_.getCoefActivation()) {
! model_.setCoefActivation(coefActivation);
changed= true;
}
***************
*** 196,218 ****
changed= true;
}
! double coefQ= ((Double)tfOrificeCoefQ_.getValue()).doubleValue();
if (coefQ != model_.getCoefQ()) {
model_.setCoefQ(coefQ);
changed= true;
}
! double perteCharge=
! ((Double)tfOrificeCoefPerteCharge_.getValue()).doubleValue();
! if (perteCharge != model_.getCoefPerteCharge()) {
! model_.setCoefPerteCharge(perteCharge);
! changed= true;
! }
! double coteMin= ((Double)tfOrificeCoteMin_.getValue()).doubleValue();
! if (coteMin != model_.getCoteMin()) {
! model_.setCoteMin(coteMin);
changed= true;
}
int sensDebit= cmbSensDebit_.getSelectedIndex();
if (sensDebit != model_.getSensDebit().value()) {
! model_.setSensDebit(LSensDebitLiaison.from_int(sensDebit));
changed= true;
}
--- 196,218 ----
changed= true;
}
! double coefQ= ((Double)tfOrificeCoefQSeuil_.getValue()).doubleValue();
if (coefQ != model_.getCoefQ()) {
model_.setCoefQ(coefQ);
changed= true;
}
! double coefQOrifice= ((Double)tfOrificeCoefQOrifice_.getValue()).doubleValue();
! if (coefQOrifice != model_.getCoefQOrifice()) {
! model_.setCoefQOrifice(coefQOrifice);
changed= true;
}
int sensDebit= cmbSensDebit_.getSelectedIndex();
+ System.out.println("cmbSensDebit_.getSelectedIndex()="+sensDebit);
+ System.out.println("model_.getSensDebit().value()="+model_.getSensDebit().value());
if (sensDebit != model_.getSensDebit().value()) {
! System.out.println("changed= true");
! System.out.println("newValeur = LSensDebitLiaison.from_int("+sensDebit+")");
! LSensDebitLiaison newValeur = LSensDebitLiaison.from_int(sensDebit);
! System.out.println("newValeur.value()="+newValeur.value());
! model_.setSensDebit(newValeur);
changed= true;
}
***************
*** 253,257 ****
setEnabledSiphon(false);
setEnabledOrifice(false);
! tfSeuilCoefActivation_.setValue(new Double(model_.getCoefEnnoiment()));
tfSeuilCoefQ_.setValue(new Double(model_.getCoefQ()));
tfSeuilLargeur_.setValue(new Double(model_.getLargeur()));
--- 253,257 ----
setEnabledSiphon(false);
setEnabledOrifice(false);
! tfSeuilCoefActivation_.setValue(new Double(model_.getCoefActivation()));
tfSeuilCoefQ_.setValue(new Double(model_.getCoefQ()));
tfSeuilLargeur_.setValue(new Double(model_.getLargeur()));
***************
*** 272,279 ****
tfOrificeLargeur_.setValue(new Double(model_.getLargeur()));
tfOrificeSection_.setValue(new Double(model_.getSection()));
! tfOrificeCoefQ_.setValue(new Double(model_.getCoefQ()));
! tfOrificeCoefPerteCharge_.setValue(
! new Double(model_.getCoefPerteCharge()));
! tfOrificeCoteMin_.setValue(new Double(model_.getCoteMin()));
cmbSensDebit_.setSelectedIndex(model_.getSensDebit().value());
}
--- 272,277 ----
tfOrificeLargeur_.setValue(new Double(model_.getLargeur()));
tfOrificeSection_.setValue(new Double(model_.getSection()));
! tfOrificeCoefQSeuil_.setValue(new Double(model_.getCoefQ()));
! tfOrificeCoefQOrifice_.setValue(new Double(model_.getCoefQOrifice()));
cmbSensDebit_.setSelectedIndex(model_.getSensDebit().value());
}
***************
*** 371,376 ****
dimPlusGrandLabel);
// pour la construction du Panel contenant les champs de saisie de l'Orifice
! tabConstraintsLabel= new GridBagConstraints[6];
! tabConstraintsTextField= new GridBagConstraints[6];
for (int i= 0; i < tabConstraintsLabel.length; i++) {
tabConstraintsLabel[i]=
--- 369,374 ----
dimPlusGrandLabel);
// pour la construction du Panel contenant les champs de saisie de l'Orifice
! tabConstraintsLabel= new GridBagConstraints[5];
! tabConstraintsTextField= new GridBagConstraints[5];
for (int i= 0; i < tabConstraintsLabel.length; i++) {
tabConstraintsLabel[i]=
***************
*** 401,406 ****
0);
}
! tabTextLabel= new String[6];
! tabTextField= new BuTextField[5];
tabTextLabel[0]= "largeur (m)";
tfOrificeLargeur_= BuTextField.createDoubleField();
--- 399,404 ----
0);
}
! tabTextLabel= new String[5];
! tabTextField= new BuTextField[4];
tabTextLabel[0]= "largeur (m)";
tfOrificeLargeur_= BuTextField.createDoubleField();
***************
*** 409,422 ****
tfOrificeSection_= BuTextField.createDoubleField();
tabTextField[1]= tfOrificeSection_;
! tabTextLabel[2]= "coef. de débit";
! tfOrificeCoefQ_= BuTextField.createDoubleField();
! tabTextField[2]= tfOrificeCoefQ_;
! tabTextLabel[3]= "coef. perte de charge";
! tfOrificeCoefPerteCharge_= BuTextField.createDoubleField();
! tabTextField[3]= tfOrificeCoefPerteCharge_;
! tabTextLabel[4]= "cote minimale";
! tfOrificeCoteMin_= BuTextField.createDoubleField();
! tabTextField[4]= tfOrificeCoteMin_;
! tabTextLabel[5]= "sens débit";
cmbSensDebit_= new BuComboBox(TYPES_SENS_DEBIT);
pnTFOrifice_=
--- 407,417 ----
tfOrificeSection_= BuTextField.createDoubleField();
tabTextField[1]= tfOrificeSection_;
! tabTextLabel[2]= "coef. de débit seuil";
! tfOrificeCoefQSeuil_= BuTextField.createDoubleField();
! tabTextField[2]= tfOrificeCoefQSeuil_;
! tabTextLabel[3]= "coef. de débit orifice";
! tfOrificeCoefQOrifice_= BuTextField.createDoubleField();
! tabTextField[3]= tfOrificeCoefQOrifice_;
! tabTextLabel[4]= "sens débit";
cmbSensDebit_= new BuComboBox(TYPES_SENS_DEBIT);
pnTFOrifice_=
***************
*** 469,473 ****
lb.setPreferredSize(dimPlusGrandLabel);
panel.add(lb, tabConstraintsLabel[i]);
! if (i != 5) {
BuTextField tf= tabTextField[i];
tf.setColumns(10);
--- 464,468 ----
lb.setPreferredSize(dimPlusGrandLabel);
panel.add(lb, tabConstraintsLabel[i]);
! if (i != 4) {
BuTextField tf= tabTextField[i];
tf.setColumns(10);
***************
*** 514,520 ****
tfOrificeLargeur_.setEnabled(enabled);
tfOrificeSection_.setEnabled(enabled);
! tfOrificeCoefQ_.setEnabled(enabled);
! tfOrificeCoefPerteCharge_.setEnabled(enabled);
! tfOrificeCoteMin_.setEnabled(enabled);
cmbSensDebit_.setEnabled(enabled);
pnTFOrifice_.setEnabled(enabled);
--- 509,514 ----
tfOrificeLargeur_.setEnabled(enabled);
tfOrificeSection_.setEnabled(enabled);
! tfOrificeCoefQSeuil_.setEnabled(enabled);
! tfOrificeCoefQOrifice_.setEnabled(enabled);
cmbSensDebit_.setEnabled(enabled);
pnTFOrifice_.setEnabled(enabled);
***************
*** 538,544 ****
tfOrificeLargeur_.setValue(new Double(1));
tfOrificeSection_.setValue(new Double(10));
! tfOrificeCoefQ_.setValue(new Double(0.4));
! tfOrificeCoefPerteCharge_.setValue(new Double(0.5));
! tfOrificeCoteMin_.setValue(new Double(1));
cmbSensDebit_.setSelectedIndex(LSensDebitLiaison._DEUX_SENS);
}
--- 532,537 ----
tfOrificeLargeur_.setValue(new Double(1));
tfOrificeSection_.setValue(new Double(10));
! tfOrificeCoefQSeuil_.setValue(new Double(0.4));
! tfOrificeCoefQOrifice_.setValue(new Double(0.5));
cmbSensDebit_.setSelectedIndex(LSensDebitLiaison._DEUX_SENS);
}
|
|
From: <jm_...@us...> - 2003-12-08 18:22:50
|
Update of /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/ihmhelper In directory sc8-pr-cvs1:/tmp/cvs-serv30418/fudaa/src/org/fudaa/fudaa/hydraulique1d/ihmhelper Modified Files: Hydraulique1dIHM_Base.java Log Message: Mise à jour des nouvelles fonctionnalités Casier YapodTestEnumereCorba : sérialise aussi Debug léger Index: Hydraulique1dIHM_Base.java =================================================================== RCS file: /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/ihmhelper/Hydraulique1dIHM_Base.java,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Hydraulique1dIHM_Base.java 25 Nov 2003 10:13:47 -0000 1.5 --- Hydraulique1dIHM_Base.java 8 Dec 2003 18:22:47 -0000 1.6 *************** *** 8,23 **** */ package org.fudaa.fudaa.hydraulique1d.ihmhelper; ! import org.fudaa.dodico.corba.objet.*; ! import org.fudaa.dodico.objet.*; ! import org.fudaa.dodico.corba.evenement.*; ! import org.fudaa.dodico.evenement.*; ! import org.fudaa.dodico.corba.hydraulique1d.*; ! import org.fudaa.dodico.hydraulique1d.*; ! import org.fudaa.fudaa.commun.*; ! import org.fudaa.fudaa.hydraulique1d.*; ! import org.fudaa.fudaa.hydraulique1d.editor.*; ! import java.util.*; ! import java.beans.*; import javax.swing.JComponent; /******************************************************************************/ /* */ --- 8,24 ---- */ package org.fudaa.fudaa.hydraulique1d.ihmhelper; ! import java.beans.PropertyChangeEvent; ! import java.beans.PropertyChangeListener; ! import java.util.Vector; import javax.swing.JComponent; + import org.fudaa.dodico.corba.evenement.IObjetEvent; + import org.fudaa.dodico.corba.evenement.IObjetEventListenerSupport; + import org.fudaa.dodico.corba.hydraulique1d.IEtude1d; + import org.fudaa.dodico.evenement.DObjetEventListenerSupport; + import org.fudaa.dodico.evenement.ObjetEventListener; + import org.fudaa.dodico.objet.CDodico; + import org.fudaa.fudaa.hydraulique1d.Hydraulique1dBaseApplication; + import org.fudaa.fudaa.hydraulique1d.editor.Hydraulique1dCustomizer; + import org.fudaa.fudaa.hydraulique1d.editor.Hydraulique1dDialogTableau; /******************************************************************************/ /* */ |
|
From: <jm_...@us...> - 2003-12-08 18:22:50
|
Update of /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor
In directory sc8-pr-cvs1:/tmp/cvs-serv30418/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor
Modified Files:
Hydraulique1dApportEditor.java
Hydraulique1dDeversoirEditor.java
Hydraulique1dSeuilAvecLoiEditor.java
Hydraulique1dSeuilLoiEditor.java
Hydraulique1dSeuilTransEditor.java
Hydraulique1dSeuilVanneEditor.java
Log Message:
Mise à jour des nouvelles fonctionnalités Casier
YapodTestEnumereCorba : sérialise aussi
Debug léger
Index: Hydraulique1dApportEditor.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/Hydraulique1dApportEditor.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** Hydraulique1dApportEditor.java 25 Nov 2003 10:13:44 -0000 1.4
--- Hydraulique1dApportEditor.java 8 Dec 2003 18:22:47 -0000 1.5
***************
*** 8,33 ****
*/
package org.fudaa.fudaa.hydraulique1d.editor;
! import org.fudaa.dodico.corba.objet.*;
! import org.fudaa.dodico.corba.hydraulique1d.*;
! import org.fudaa.dodico.corba.hydraulique1d.singularite.*;
! import org.fudaa.dodico.corba.hydraulique1d.loi.*;
! import org.fudaa.dodico.corba.evenement.*;
! import org.fudaa.dodico.hydraulique1d.*;
! import org.fudaa.dodico.hydraulique1d.singularite.*;
! import org.fudaa.dodico.hydraulique1d.loi.*;
! import com.memoire.bu.*;
! import org.fudaa.ebli.commun.*;
! import org.fudaa.ebli.ressource.*;
! import org.fudaa.ebli.dialog.*;
! import org.fudaa.fudaa.commun.*;
! import org.fudaa.fudaa.hydraulique1d.*;
! import org.fudaa.fudaa.hydraulique1d.editor.*;
! import org.fudaa.ebli.controle.border.*;
! import javax.swing.*;
! import javax.swing.border.*;
! import java.awt.*;
! import java.awt.event.*;
! import java.beans.*;
! import java.util.*;
/**
* @version $Revision$ $Date$ by $Author$
--- 8,35 ----
*/
package org.fudaa.fudaa.hydraulique1d.editor;
! import java.awt.BorderLayout;
! import java.awt.Container;
! import java.awt.Dimension;
! import java.awt.Insets;
! import java.awt.event.ActionEvent;
! import java.awt.event.ActionListener;
! import javax.swing.JComboBox;
! import javax.swing.border.CompoundBorder;
! import javax.swing.border.EmptyBorder;
! import javax.swing.border.EtchedBorder;
! import org.fudaa.dodico.corba.evenement.IObjetEvent;
! import org.fudaa.dodico.corba.hydraulique1d.IBief;
! import org.fudaa.dodico.corba.hydraulique1d.IDonneesHydrauliques;
! import org.fudaa.dodico.corba.hydraulique1d.loi.ILoiHydrogramme;
! import org.fudaa.dodico.corba.hydraulique1d.singularite.IApport;
! import org.fudaa.dodico.corba.objet.IObjet;
! import org.fudaa.ebli.commun.EbliPreferences;
! import org.fudaa.ebli.dialog.BDialogContent;
! import com.memoire.bu.BuButton;
! import com.memoire.bu.BuHorizontalLayout;
! import com.memoire.bu.BuLabel;
! import com.memoire.bu.BuPanel;
! import com.memoire.bu.BuTextField;
! import com.memoire.bu.BuVerticalLayout;
/**
* @version $Revision$ $Date$ by $Author$
Index: Hydraulique1dDeversoirEditor.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/Hydraulique1dDeversoirEditor.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** Hydraulique1dDeversoirEditor.java 25 Nov 2003 10:13:44 -0000 1.4
--- Hydraulique1dDeversoirEditor.java 8 Dec 2003 18:22:47 -0000 1.5
***************
*** 53,57 ****
BuGridLayout loValZQ_;
private IDeversoir deversoir_;
- private IDeversoir deversoirOld_;
private IDonneesHydrauliques donneesHydro_;
private IBief bief_;
--- 53,56 ----
***************
*** 206,210 ****
} else if ("VALIDER".equals(cmd)) {
if (getValeurs()) {
! firePropertyChange("singularite", deversoirOld_, deversoir_);
}
fermer();
--- 205,209 ----
} else if ("VALIDER".equals(cmd)) {
if (getValeurs()) {
! firePropertyChange("singularite", null, deversoir_);
}
fermer();
***************
*** 218,222 ****
return;
deversoir_= (IDeversoir)_dev;
- deversoirOld_= (IDeversoir)deversoir_.creeClone();
setValeurs();
}
--- 217,220 ----
Index: Hydraulique1dSeuilAvecLoiEditor.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/Hydraulique1dSeuilAvecLoiEditor.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** Hydraulique1dSeuilAvecLoiEditor.java 25 Nov 2003 10:13:44 -0000 1.6
--- Hydraulique1dSeuilAvecLoiEditor.java 8 Dec 2003 18:22:47 -0000 1.7
***************
*** 47,51 ****
BuVerticalLayout loSeuil_, loNomLoi_;
BuHorizontalLayout loNumero_, loAbscisse_, loNom_, loZRupture_;
! private ISeuil seuil_, seuilOld_;
private IDonneesHydrauliques donneesHydro_;
private IBief bief_;
--- 47,51 ----
BuVerticalLayout loSeuil_, loNomLoi_;
BuHorizontalLayout loNumero_, loAbscisse_, loNom_, loZRupture_;
! private ISeuil seuil_;
private IDonneesHydrauliques donneesHydro_;
private IBief bief_;
***************
*** 135,139 ****
} else if ("VALIDER".equals(cmd)) {
if (getValeurs()) {
! firePropertyChange("singularite", seuilOld_, seuil_);
}
fermer();
--- 135,139 ----
} else if ("VALIDER".equals(cmd)) {
if (getValeurs()) {
! firePropertyChange("singularite", null, seuil_);
}
fermer();
***************
*** 144,148 ****
if (_o instanceof ISeuil) {
seuil_= (ISeuil)_o;
- seuilOld_= (ISeuil)seuil_.creeClone();
setValeurs();
if (seuil_ instanceof ISeuilDenoye) {
--- 144,147 ----
Index: Hydraulique1dSeuilLoiEditor.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/Hydraulique1dSeuilLoiEditor.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** Hydraulique1dSeuilLoiEditor.java 25 Nov 2003 10:13:44 -0000 1.7
--- Hydraulique1dSeuilLoiEditor.java 8 Dec 2003 18:22:47 -0000 1.8
***************
*** 45,49 ****
BuHorizontalLayout loHorizontal_;
private ISeuilLoi seuil_;
- private ISeuilLoi seuilOld_;
private IBief bief_;
private final static String[] TYPE_EPAISSEUR= { "épais", "mince" };
--- 45,48 ----
***************
*** 152,156 ****
} else if ("VALIDER".equals(cmd)) {
if (getValeurs()) {
! firePropertyChange("singularite", seuilOld_, seuil_);
}
fermer();
--- 151,155 ----
} else if ("VALIDER".equals(cmd)) {
if (getValeurs()) {
! firePropertyChange("singularite", null, seuil_);
}
fermer();
***************
*** 162,167 ****
bief_= (IBief)_o;
else if (_o instanceof ISeuilLoi) {
seuil_= (ISeuilLoi)_o;
- seuilOld_= (ISeuilLoi)seuil_.creeClone();
setValeurs();
}
--- 161,166 ----
bief_= (IBief)_o;
else if (_o instanceof ISeuilLoi) {
+ if (seuil_ == _o) return;
seuil_= (ISeuilLoi)_o;
setValeurs();
}
Index: Hydraulique1dSeuilTransEditor.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/Hydraulique1dSeuilTransEditor.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** Hydraulique1dSeuilTransEditor.java 25 Nov 2003 10:13:44 -0000 1.7
--- Hydraulique1dSeuilTransEditor.java 8 Dec 2003 18:22:47 -0000 1.8
***************
*** 59,63 ****
private final static String[] TYPE_EPAISSEUR= { "épais", "mince" };
private ISeuilTranscritique seuil_;
- private ISeuilTranscritique seuilOld_;
private IBief bief_;
private IDonneesHydrauliques donneesHydro_;
--- 59,62 ----
***************
*** 227,231 ****
} else if ("VALIDER".equals(cmd)) {
if (getValeurs()) {
! firePropertyChange("singularite", seuilOld_, seuil_);
}
fermer();
--- 226,230 ----
} else if ("VALIDER".equals(cmd)) {
if (getValeurs()) {
! firePropertyChange("singularite", null, seuil_);
}
fermer();
***************
*** 237,242 ****
bief_= (IBief)_o;
else if (_o instanceof ISeuilTranscritique) {
seuil_= (ISeuilTranscritique)_o;
- seuilOld_= (ISeuilTranscritique)seuil_.creeClone();
setValeurs();
} else if (_o instanceof IDonneesHydrauliques) {
--- 236,241 ----
bief_= (IBief)_o;
else if (_o instanceof ISeuilTranscritique) {
+ if (seuil_ == _o) return;
seuil_= (ISeuilTranscritique)_o;
setValeurs();
} else if (_o instanceof IDonneesHydrauliques) {
Index: Hydraulique1dSeuilVanneEditor.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/fudaa/src/org/fudaa/fudaa/hydraulique1d/editor/Hydraulique1dSeuilVanneEditor.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** Hydraulique1dSeuilVanneEditor.java 25 Nov 2003 10:13:44 -0000 1.4
--- Hydraulique1dSeuilVanneEditor.java 8 Dec 2003 18:22:47 -0000 1.5
***************
*** 45,49 ****
BuVerticalLayout loSeuil_, loNomLoi_;
BuHorizontalLayout loNumero_, loAbscisse_, loLargeur_, loNom_, loZRupture_;
! private ISeuilVanne seuil_, seuilOld_;
private IDonneesHydrauliques donneesHydro_;
private IBief bief_;
--- 45,49 ----
BuVerticalLayout loSeuil_, loNomLoi_;
BuHorizontalLayout loNumero_, loAbscisse_, loLargeur_, loNom_, loZRupture_;
! private ISeuilVanne seuil_;
private IDonneesHydrauliques donneesHydro_;
private IBief bief_;
***************
*** 146,150 ****
} else if ("VALIDER".equals(cmd)) {
if (getValeurs()) {
! firePropertyChange("singularite", seuilOld_, seuil_);
}
fermer();
--- 146,150 ----
} else if ("VALIDER".equals(cmd)) {
if (getValeurs()) {
! firePropertyChange("singularite", null, seuil_);
}
fermer();
***************
*** 155,159 ****
if (_o instanceof ISeuilVanne) {
seuil_= (ISeuilVanne)_o;
- seuilOld_= (ISeuilVanne)seuil_.creeClone();
setValeurs();
} else if (_o instanceof IBief)
--- 155,158 ----
***************
*** 235,256 ****
}
public void objetSupprime(IObjetEvent e) {
- System.out.println("SeuilVanneEditor objetSupprime(IObjetEvent e)");
IObjet src= e.getSource();
- System.out.println("src.getClass().getName()=" + src.getClass().getName());
if (src == null)
return;
if (src instanceof ILoiOuvertureVanne) {
- System.out.println("src instanceof ILoiOuvertureVanne");
initListeLoi();
}
}
public void objetModifie(IObjetEvent e) {
- System.out.println("SeuilVanneEditor objetModifie(IObjetEvent e)");
IObjet src= e.getSource();
- System.out.println("src.getClass().getName()=" + src.getClass().getName());
if (src == null)
return;
if (src instanceof ILoiOuvertureVanne) {
- System.out.println("src instanceof ILoiOuvertureVanne");
initListeLoi();
}
--- 234,249 ----
|
|
From: <jm_...@us...> - 2003-12-08 18:22:50
|
Update of /cvsroot/fudaa//fudaa_devel/dodico/src/org/fudaa/dodico/mascaret
In directory sc8-pr-cvs1:/tmp/cvs-serv30418/dodico/src/org/fudaa/dodico/mascaret
Modified Files:
CConversionHydraulique1d.java DCalculMascaret.java
DParametresMascaret.java
Log Message:
Mise à jour des nouvelles fonctionnalités Casier
YapodTestEnumereCorba : sérialise aussi
Debug léger
Index: CConversionHydraulique1d.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/dodico/src/org/fudaa/dodico/mascaret/CConversionHydraulique1d.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** CConversionHydraulique1d.java 25 Nov 2003 10:11:42 -0000 1.9
--- CConversionHydraulique1d.java 8 Dec 2003 18:22:47 -0000 1.10
***************
*** 798,804 ****
paramMas.liaisons.section= new double[nbLiaison];
paramMas.liaisons.coefPerteCharge= new double[nbLiaison];
! paramMas.liaisons.coefDebit= new double[nbLiaison];
! paramMas.liaisons.coefEnnoiment= new double[nbLiaison];
! paramMas.liaisons.coteMin= new double[nbLiaison];
paramMas.liaisons.typeOrifice= new int[nbLiaison];
paramMas.liaisons.abscBief= new double[nbLiaison];
--- 798,804 ----
paramMas.liaisons.section= new double[nbLiaison];
paramMas.liaisons.coefPerteCharge= new double[nbLiaison];
! paramMas.liaisons.coefDebitSeuil= new double[nbLiaison];
! paramMas.liaisons.coefActivation= new double[nbLiaison];
! paramMas.liaisons.coefDebitOrifice= new double[nbLiaison];
paramMas.liaisons.typeOrifice= new int[nbLiaison];
paramMas.liaisons.abscBief= new double[nbLiaison];
***************
*** 816,819 ****
--- 816,821 ----
if (iliaison.isSiphon())
paramMas.liaisons.types[i]= 3;
+ if (iliaison.isOrifice())
+ paramMas.liaisons.types[i]= 4;
// nature de la liaison
if (iliaison.isRiviereCasier())
***************
*** 839,858 ****
if (iliaison.isSiphon() || iliaison.isOrifice())
paramMas.liaisons.section[i]= iliaison.getSection();
! // coef de perte de charge de la liaison pour les liaisons de type siphon ou orifice, -1 sinon
paramMas.liaisons.coefPerteCharge[i]= -1.;
! if (iliaison.isSiphon() || iliaison.isOrifice())
paramMas.liaisons.coefPerteCharge[i]= iliaison.getCoefPerteCharge();
// coef de débit de la liaison pour les liaisons de type seuil ou orifice, -1 sinon
! paramMas.liaisons.coefDebit[i]= -1.;
if (iliaison.isSeuil() || iliaison.isOrifice())
! paramMas.liaisons.coefDebit[i]= iliaison.getCoefQ();
! // coef d'ennoiment de la liaison pour les liaisons de type seuil, -1 sinon
! paramMas.liaisons.coefEnnoiment[i]= -1.;
if (iliaison.isSeuil())
! paramMas.liaisons.coefEnnoiment[i]= iliaison.getCoefEnnoiment();
! // cote minimale de la liaison pour les liaisons de type orifice, -1 sinon
! paramMas.liaisons.coteMin[i]= -1.;
if (iliaison.isOrifice())
! paramMas.liaisons.coteMin[i]= iliaison.getCoteMin();
// type de l'orifice de la liaison pour les liaisons de type orifice, -1 sinon
paramMas.liaisons.typeOrifice[i]= -1;
--- 841,860 ----
if (iliaison.isSiphon() || iliaison.isOrifice())
paramMas.liaisons.section[i]= iliaison.getSection();
! // coef de perte de charge de la liaison pour les liaisons de type siphon, -1 sinon
paramMas.liaisons.coefPerteCharge[i]= -1.;
! if (iliaison.isSiphon())
paramMas.liaisons.coefPerteCharge[i]= iliaison.getCoefPerteCharge();
// coef de débit de la liaison pour les liaisons de type seuil ou orifice, -1 sinon
! paramMas.liaisons.coefDebitSeuil[i]= -1.;
if (iliaison.isSeuil() || iliaison.isOrifice())
! paramMas.liaisons.coefDebitSeuil[i]= iliaison.getCoefQ();
! // coef d'activation de la liaison pour les liaisons de type seuil, -1 sinon
! paramMas.liaisons.coefActivation[i]= -1.;
if (iliaison.isSeuil())
! paramMas.liaisons.coefActivation[i]= iliaison.getCoefActivation();
! // coef de débit orifice de la liaison pour les liaisons de type orifice, -1 sinon
! paramMas.liaisons.coefDebitOrifice[i]= -1.;
if (iliaison.isOrifice())
! paramMas.liaisons.coefDebitOrifice[i]= iliaison.getCoefQOrifice();
// type de l'orifice de la liaison pour les liaisons de type orifice, -1 sinon
paramMas.liaisons.typeOrifice[i]= -1;
***************
*** 1511,1515 ****
IDescriptionVariable[] descripVarHydr=calculHydraulique1d.etude().paramResultats().variables();
SResultatsOPT optMas= new SResultatsOPT();
!
optMas.variables = new SResultatsVariable[descripVarHydr.length];
for (int i=0; i< descripVarHydr.length ; i++) {
--- 1513,1517 ----
IDescriptionVariable[] descripVarHydr=calculHydraulique1d.etude().paramResultats().variables();
SResultatsOPT optMas= new SResultatsOPT();
!
optMas.variables = new SResultatsVariable[descripVarHydr.length];
for (int i=0; i< descripVarHydr.length ; i++) {
***************
*** 1530,1537 ****
}
}
!
IBief[] biefsHydr=calculHydraulique1d.etude().reseau().biefs();
Vector v = new Vector();
!
for (int i=0; i< biefsHydr.length ; i++) {
String codeBief = Integer.toString(biefsHydr[i].numero());
--- 1532,1539 ----
}
}
!
IBief[] biefsHydr=calculHydraulique1d.etude().reseau().biefs();
Vector v = new Vector();
!
for (int i=0; i< biefsHydr.length ; i++) {
String codeBief = Integer.toString(biefsHydr[i].numero());
***************
*** 1548,1554 ****
optMas.resultats = (SParametresResultat[])v.toArray();
Arrays.sort(optMas.resultats, new CComparateurParamResultatTemps());
!
parametresMascaret.parametresOPT(optMas);
!
}*/
public static final SParametresREP convertirParametresRep(IParametresReprise repHydr) {
--- 1550,1556 ----
optMas.resultats = (SParametresResultat[])v.toArray();
Arrays.sort(optMas.resultats, new CComparateurParamResultatTemps());
!
parametresMascaret.parametresOPT(optMas);
!
}*/
public static final SParametresREP convertirParametresRep(IParametresReprise repHydr) {
***************
*** 1863,1867 ****
}
/* public static SResultatsOPT convertirResultatsOpt(IEtude1d etude) {
!
if (etude.paramResultats()==null) return null;
if (etude.paramResultats().variables()==null) return null;
--- 1865,1869 ----
}
/* public static SResultatsOPT convertirResultatsOpt(IEtude1d etude) {
!
if (etude.paramResultats()==null) return null;
if (etude.paramResultats().variables()==null) return null;
***************
*** 1872,1876 ****
if (etude.reseau().biefs()[0].resultatsBief()==null) return null;
if (etude.reseau().biefs()[0].resultatsBief().pasTemps()==null) return null;
!
// description variables
IDescriptionVariable[] descripVar1d = etude.paramResultats().variables();
--- 1874,1878 ----
if (etude.reseau().biefs()[0].resultatsBief()==null) return null;
if (etude.reseau().biefs()[0].resultatsBief().pasTemps()==null) return null;
!
// description variables
IDescriptionVariable[] descripVar1d = etude.paramResultats().variables();
***************
*** 1900,1904 ****
descripVarMas[i] = new SResultatsVariable(descripVar1d[i].description(), descripVar1d[i].nom(), unite, descripVar1d[i].nbDecimales());
}
!
// les variables
IResultatsBiefPasTemps[] resPasTps1d = etude.reseau().biefs()[0].resultatsBief().pasTemps();
--- 1902,1906 ----
descripVarMas[i] = new SResultatsVariable(descripVar1d[i].description(), descripVar1d[i].nom(), unite, descripVar1d[i].nbDecimales());
}
!
// les variables
IResultatsBiefPasTemps[] resPasTps1d = etude.reseau().biefs()[0].resultatsBief().pasTemps();
Index: DCalculMascaret.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/dodico/src/org/fudaa/dodico/mascaret/DCalculMascaret.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** DCalculMascaret.java 25 Nov 2003 10:11:42 -0000 1.7
--- DCalculMascaret.java 8 Dec 2003 18:22:47 -0000 1.8
***************
*** 236,240 ****
cmd= new String[3];
cmd[0]= "mascaret";
! cmd[1]= "-RV5P1";
cmd[2]= ficCAS.getCanonicalPath();
System.out.println(cmd[0] + " " + cmd[1] + " " + cmd[2]);
--- 236,240 ----
cmd= new String[3];
cmd[0]= "mascaret";
! cmd[1]= "-RV5P2";
cmd[2]= ficCAS.getCanonicalPath();
System.out.println(cmd[0] + " " + cmd[1] + " " + cmd[2]);
Index: DParametresMascaret.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/dodico/src/org/fudaa/dodico/mascaret/DParametresMascaret.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** DParametresMascaret.java 25 Nov 2003 10:11:42 -0000 1.7
--- DParametresMascaret.java 8 Dec 2003 18:22:47 -0000 1.8
***************
*** 477,483 ****
descriptionChampLiaison[7]= "LIAISON SECTION";
descriptionChampLiaison[8]= "LIAISON COEFFICIENT PERTE DE CHARGE";
! descriptionChampLiaison[9]= "LIAISON COEFFICIENT DE DEBIT";
! descriptionChampLiaison[10]= "LIAISON COEFFICIENT D'ENNOIEMENT";
! descriptionChampLiaison[11]= "LIAISON COTE MIN";
descriptionChampLiaison[12]= "LIAISON TYPE ORIFICE";
descriptionChampLiaison[13]= "LIAISON NUMERO DU CASIER ORIGINE";
--- 477,483 ----
descriptionChampLiaison[7]= "LIAISON SECTION";
descriptionChampLiaison[8]= "LIAISON COEFFICIENT PERTE DE CHARGE";
! descriptionChampLiaison[9]= "LIAISON COEFFICIENT DE DEBIT SEUIL";
! descriptionChampLiaison[10]= "LIAISON COEFFICIENT D'ACTIVATION";
! descriptionChampLiaison[11]= "LIAISON COEFFICIENT DE DEBIT ORIFICE";
descriptionChampLiaison[12]= "LIAISON TYPE ORIFICE";
descriptionChampLiaison[13]= "LIAISON NUMERO DU CASIER ORIGINE";
***************
*** 823,837 ****
return paramsOPT_;
}
!
public void parametresOPT(SParametresOPT _paramsOPT)
{
paramsOPT_ = _paramsOPT;
}
!
public static void ecritParametresOPT(File fichier, SParametresOPT params)
{
ecritParametresOPT(fichier, params, Double.NaN);
}
!
public static void ecritParametresOPT(File fichier, SParametresOPT params, double t)
{
--- 823,837 ----
return paramsOPT_;
}
!
public void parametresOPT(SParametresOPT _paramsOPT)
{
paramsOPT_ = _paramsOPT;
}
!
public static void ecritParametresOPT(File fichier, SParametresOPT params)
{
ecritParametresOPT(fichier, params, Double.NaN);
}
!
public static void ecritParametresOPT(File fichier, SParametresOPT params, double t)
{
***************
*** 852,865 ****
}
fopt.println("[resultats]");
!
DecimalFormat formatTps = new DecimalFormat("#0.###");
formatTps.setDecimalFormatSymbols(new DecimalFormatSymbols(java.util.Locale.US));
formatTps.setDecimalSeparatorAlwaysShown(true);
!
NumberFormat formatAbs;
formatAbs = NumberFormat.getInstance(java.util.Locale.US);
formatAbs.setGroupingUsed(false);
formatAbs.setMinimumFractionDigits(2);
!
for (int i=0; i<params.resultatsPasTemps.length; i++) {
SResultatPasTemps resPasTemps = params.resultatsPasTemps[i];
--- 852,865 ----
}
fopt.println("[resultats]");
!
DecimalFormat formatTps = new DecimalFormat("#0.###");
formatTps.setDecimalFormatSymbols(new DecimalFormatSymbols(java.util.Locale.US));
formatTps.setDecimalSeparatorAlwaysShown(true);
!
NumberFormat formatAbs;
formatAbs = NumberFormat.getInstance(java.util.Locale.US);
formatAbs.setGroupingUsed(false);
formatAbs.setMinimumFractionDigits(2);
!
for (int i=0; i<params.resultatsPasTemps.length; i++) {
SResultatPasTemps resPasTemps = params.resultatsPasTemps[i];
|
|
From: <jm_...@us...> - 2003-12-08 18:22:50
|
Update of /cvsroot/fudaa//fudaa_devel/dodico/src/org/fudaa/dodico/hydraulique1d/singularite
In directory sc8-pr-cvs1:/tmp/cvs-serv30418/dodico/src/org/fudaa/dodico/hydraulique1d/singularite
Modified Files:
DSeuilLoi.java DSeuilTranscritique.java
Log Message:
Mise à jour des nouvelles fonctionnalités Casier
YapodTestEnumereCorba : sérialise aussi
Debug léger
Index: DSeuilLoi.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/dodico/src/org/fudaa/dodico/hydraulique1d/singularite/DSeuilLoi.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** DSeuilLoi.java 2 Dec 2003 19:54:40 -0000 1.6
--- DSeuilLoi.java 8 Dec 2003 18:22:47 -0000 1.7
***************
*** 41,44 ****
--- 41,48 ----
}
public String[] getInfos() {
+ String epaisseur="mince";
+ if (epaisseur_.value() == LEpaisseurSeuil._EPAIS) {
+ epaisseur="épais";
+ }
String[] res= new String[2];
res[0]= "Seuil (Zcrête,coef.Q)";
***************
*** 53,57 ****
+ coefQ_
+ " Epaisseur : "
! + epaisseur_;
return res;
}
--- 57,61 ----
+ coefQ_
+ " Epaisseur : "
! + epaisseur;
return res;
}
Index: DSeuilTranscritique.java
===================================================================
RCS file: /cvsroot/fudaa//fudaa_devel/dodico/src/org/fudaa/dodico/hydraulique1d/singularite/DSeuilTranscritique.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** DSeuilTranscritique.java 2 Dec 2003 19:54:40 -0000 1.5
--- DSeuilTranscritique.java 8 Dec 2003 18:22:47 -0000 1.6
***************
*** 12,15 ****
--- 12,16 ----
import org.fudaa.dodico.corba.hydraulique1d.singularite.ISeuilTranscritique;
import org.fudaa.dodico.corba.hydraulique1d.singularite.ISeuilTranscritiqueOperations;
+ import org.fudaa.dodico.corba.hydraulique1d.singularite.LEpaisseurSeuil;
import org.fudaa.dodico.corba.objet.IObjet;
import org.fudaa.dodico.objet.CDodico;
***************
*** 46,49 ****
--- 47,54 ----
public String[] getInfos() {
String[] res= new String[2];
+ String epaisseur="mince";
+ if (epaisseur_.value() == LEpaisseurSeuil._EPAIS) {
+ epaisseur="épais";
+ }
res[0]= "Seuil Loi Transc.";
res[1]=
***************
*** 57,61 ****
+ coefQ_
+ " Epais. : "
! + epaisseur_;
if (ruptureInstantanee_)
res[1] += " rupture instantanée";
--- 62,66 ----
+ coefQ_
+ " Epais. : "
! + epaisseur;
if (ruptureInstantanee_)
res[1] += " rupture instantanée";
|